DockingAttribute DockingAttribute DockingAttribute DockingAttribute Class

定义

指定控件的默认停靠行为。Specifies the default docking behavior for a control.

public ref class DockingAttribute sealed : Attribute
[System.AttributeUsage(System.AttributeTargets.Class)]
public sealed class DockingAttribute : Attribute
type DockingAttribute = class
    inherit Attribute
Public NotInheritable Class DockingAttribute
Inherits Attribute
继承
DockingAttributeDockingAttributeDockingAttributeDockingAttribute
属性

注解

可以在从现有控件或UserControl中派生的 Windows 窗体中创建新控件。You can create new controls in Windows Forms derived either from an existing control or from UserControl. 对新控件使用此特性, 以描述控件置于窗体上时默认停靠的方式。Use this attribute on new controls to describe how the control should dock by default when placed on a form.

构造函数

DockingAttribute() DockingAttribute() DockingAttribute() DockingAttribute()

初始化 DockingAttribute 类的新实例。Initializes a new instance of the DockingAttribute class.

DockingAttribute(DockingBehavior) DockingAttribute(DockingBehavior) DockingAttribute(DockingBehavior) DockingAttribute(DockingBehavior)

使用给定的停靠行为初始化 DockingAttribute 类的新实例。Initializes a new instance of the DockingAttribute class with the given docking behavior.

字段

Default Default Default Default

此控件的默认 DockingAttributeThe default DockingAttribute for this control.

属性

DockingBehavior DockingBehavior DockingBehavior DockingBehavior

获取提供给此特性的停靠行为。Gets the docking behavior supplied to this attribute.

TypeId TypeId TypeId TypeId

在派生类中实现时,获取此 Attribute 的唯一标识符。When implemented in a derived class, gets a unique identifier for this Attribute.

(Inherited from Attribute)

方法

Equals(Object) Equals(Object) Equals(Object) Equals(Object)

将任意对象与 DockingAttribute 对象进行比较以判断是否相等。Compares an arbitrary object with the DockingAttribute object for equality.

GetHashCode() GetHashCode() GetHashCode() GetHashCode()

此对象的哈希代码。The hash code for this object.

GetType() GetType() GetType() GetType()

获取当前实例的 TypeGets the Type of the current instance.

(Inherited from Object)
IsDefaultAttribute() IsDefaultAttribute() IsDefaultAttribute() IsDefaultAttribute()

指定此 DockingAttribute 是否为默认停靠特性。Specifies whether this DockingAttribute is the default docking attribute.

Match(Object) Match(Object) Match(Object) Match(Object)

当在派生类中重写时,返回一个指示此实例是否等于指定对象的值。When overridden in a derived class, returns a value that indicates whether this instance equals a specified object.

(Inherited from Attribute)
MemberwiseClone() MemberwiseClone() MemberwiseClone() MemberwiseClone()

创建当前 Object 的浅表副本。Creates a shallow copy of the current Object.

(Inherited from Object)
ToString() ToString() ToString() ToString()

返回表示当前对象的字符串。Returns a string that represents the current object.

(Inherited from Object)

显式界面实现

_Attribute.GetIDsOfNames(Guid, IntPtr, UInt32, UInt32, IntPtr) _Attribute.GetIDsOfNames(Guid, IntPtr, UInt32, UInt32, IntPtr) _Attribute.GetIDsOfNames(Guid, IntPtr, UInt32, UInt32, IntPtr) _Attribute.GetIDsOfNames(Guid, IntPtr, UInt32, UInt32, IntPtr)

将一组名称映射为对应的一组调度标识符。Maps a set of names to a corresponding set of dispatch identifiers.

(Inherited from Attribute)
_Attribute.GetTypeInfo(UInt32, UInt32, IntPtr) _Attribute.GetTypeInfo(UInt32, UInt32, IntPtr) _Attribute.GetTypeInfo(UInt32, UInt32, IntPtr) _Attribute.GetTypeInfo(UInt32, UInt32, IntPtr)

检索对象的类型信息,然后可以使用该信息获取接口的类型信息。Retrieves the type information for an object, which can be used to get the type information for an interface.

(Inherited from Attribute)
_Attribute.GetTypeInfoCount(UInt32) _Attribute.GetTypeInfoCount(UInt32) _Attribute.GetTypeInfoCount(UInt32) _Attribute.GetTypeInfoCount(UInt32)

检索对象提供的类型信息接口的数量(0 或 1)。Retrieves the number of type information interfaces that an object provides (either 0 or 1).

(Inherited from Attribute)
_Attribute.Invoke(UInt32, Guid, UInt32, Int16, IntPtr, IntPtr, IntPtr, IntPtr) _Attribute.Invoke(UInt32, Guid, UInt32, Int16, IntPtr, IntPtr, IntPtr, IntPtr) _Attribute.Invoke(UInt32, Guid, UInt32, Int16, IntPtr, IntPtr, IntPtr, IntPtr) _Attribute.Invoke(UInt32, Guid, UInt32, Int16, IntPtr, IntPtr, IntPtr, IntPtr)

提供对某一对象公开的属性和方法的访问。Provides access to properties and methods exposed by an object.

(Inherited from Attribute)

适用于

另请参阅