DocumentDesigner 類別

定義

基底設計工具類別,可支援巢狀控制項和應接收捲動訊息的 Control,擴充其設計模式行為並提供其根層級設計模式檢視。Base designer class for extending the design mode behavior of, and providing a root-level design mode view for, a Control that supports nested controls and should receive scroll messages.

public ref class DocumentDesigner : System::Windows::Forms::Design::ScrollableControlDesigner, IDisposable, System::ComponentModel::Design::IRootDesigner, System::Drawing::Design::IToolboxUser
public class DocumentDesigner : System.Windows.Forms.Design.ScrollableControlDesigner, IDisposable, System.ComponentModel.Design.IRootDesigner, System.Drawing.Design.IToolboxUser
type DocumentDesigner = class
    inherit ScrollableControlDesigner
    interface IRootDesigner
    interface IDesigner
    interface IDisposable
    interface IToolboxUser
Public Class DocumentDesigner
Inherits ScrollableControlDesigner
Implements IDisposable, IRootDesigner, IToolboxUser
繼承
實作

備註

這個設計工具是根設計工具,這表示它會在設計模式中觀看相關聯的檔時,提供根層級的設計模式視圖。This designer is a root designer, meaning that it provides the root-level design mode view for the associated document when it is viewed in design mode.

您可以使用DesignerAttribute,將設計工具與型別產生關聯。You can associate a designer with a type using a DesignerAttribute. 如需自訂設計階段行為的總覽,請參閱擴充設計階段支援For an overview of customizing design time behavior, see Extending Design-Time Support.

建構函式

DocumentDesigner()

初始化 DocumentDesigner 類別的新執行個體。Initializes a new instance of the DocumentDesigner class.

欄位

accessibilityObj

指定設計工具的可及性物件。Specifies the accessibility object for the designer.

(繼承來源 ControlDesigner)
menuEditorService

將 menuEditorService 變數初始化為 nullInitializes the menuEditorService variable to null.

屬性

AccessibilityObject

取得指定給控制項的 AccessibleObjectGets the AccessibleObject assigned to the control.

(繼承來源 ControlDesigner)
ActionLists

取得與設計工具相關之元件所支援的設計階段動作清單。Gets the design-time action lists supported by the component associated with the designer.

(繼承來源 ComponentDesigner)
AllowControlLasso

取得值,指出是否重設選取之控制項的父代。Gets a value indicating whether selected controls will be re-parented.

(繼承來源 ParentControlDesigner)
AllowGenericDragBox

取得值,指出將工具箱項目拖曳至設計工具的介面上時,是否應繪製泛型拖曳方塊。Gets a value indicating whether a generic drag box should be drawn when dragging a toolbox item over the designer's surface.

(繼承來源 ParentControlDesigner)
AllowSetChildIndexOnDrop

取得值,指出將控制項拖曳至 ParentControlDesigner 時,是否應維持被拖曳控制項的疊置順序 (Z-order)。Gets a value indicating whether the z-order of dragged controls should be maintained when dropped on a ParentControlDesigner.

(繼承來源 ParentControlDesigner)
AssociatedComponents

取得元件集合,該集合與設計工具管理的元件相關聯。Gets the collection of components associated with the component managed by the designer.

(繼承來源 ControlDesigner)
AutoResizeHandles

取得或設定值,指出縮放控點的配置是否取決於 AutoSize 屬性的值。Gets or sets a value indicating whether resize handle allocation depends on the value of the AutoSize property.

(繼承來源 ControlDesigner)
BehaviorService

從設計環境取得 BehaviorServiceGets the BehaviorService from the design environment.

(繼承來源 ControlDesigner)
Component

取得這個設計工具正在設計的元件。Gets the component this designer is designing.

(繼承來源 ComponentDesigner)
Control

取得設計工具正在設計的控制項。Gets the control that the designer is designing.

(繼承來源 ControlDesigner)
DefaultControlLocation

取得加入至設計工具的控制項的預設位置。Gets the default location for a control added to the designer.

(繼承來源 ParentControlDesigner)
DrawGrid

取得或設定值,指出是否應在這個設計工具的控制項上繪製格線。Gets or sets a value indicating whether a grid should be drawn on the control for this designer.

(繼承來源 ParentControlDesigner)
EnableDragRect

取得值,指出是否由設計工具繪製拖曳矩形。Gets a value indicating whether drag rectangles are drawn by the designer.

(繼承來源 ParentControlDesigner)
GridSize

取得或設定設計工具在繪製格線模式時,所繪製的格線中每一個方形的大小。Gets or sets the size of each square of the grid that is drawn when the designer is in grid draw mode.

(繼承來源 ParentControlDesigner)
InheritanceAttribute

取得設計工具的 InheritanceAttributeGets the InheritanceAttribute of the designer.

(繼承來源 ControlDesigner)
Inherited

取得值,表示是否要繼承這個元件。Gets a value indicating whether this component is inherited.

(繼承來源 ComponentDesigner)
MouseDragTool

取得值,指出設計工具在拖曳作業期間是否具有有效的工具。Gets a value indicating whether the designer has a valid tool during a drag operation.

(繼承來源 ParentControlDesigner)
ParentComponent

取得 ControlDesigner 的父元件。Gets the parent component for the ControlDesigner.

(繼承來源 ControlDesigner)
ParticipatesWithSnapLines

取得值,指出 ControlDesigner 是否可以在拖曳作業期間採用以對齊線為準的對齊方式。Gets a value indicating whether the ControlDesigner will allow snapline alignment during a drag operation.

(繼承來源 ControlDesigner)
SelectionRules

取得設計工具的 SelectionRulesGets the SelectionRules for the designer.

ShadowProperties

取得覆寫使用者設定的屬性值集合。Gets a collection of property values that override user settings.

(繼承來源 ComponentDesigner)
SnapLines

取得 SnapLine 物件的清單,表示此控制項的重要對齊點。Gets a list of SnapLine objects representing significant alignment points for this control.

(繼承來源 ParentControlDesigner)
Verbs

取得與設計工具相關元件所支援的設計階段動詞命令 (Verb)。Gets the design-time verbs supported by the component that is associated with the designer.

(繼承來源 ComponentDesigner)

方法

AddPaddingSnapLines(ArrayList)

加入邊框距離對齊線。Adds padding snaplines.

(繼承來源 ParentControlDesigner)
BaseWndProc(Message)

處理 Windows 訊息。Processes Windows messages.

(繼承來源 ControlDesigner)
CanAddComponent(IComponent)

當元件加入至父容器時呼叫。Called when a component is added to the parent container.

(繼承來源 ParentControlDesigner)
CanBeParentedTo(IDesigner)

指示指定的設計工具控制項是否可以成為這個設計工具控制項的父系。Indicates if this designer's control can be parented by the control of the specified designer.

(繼承來源 ControlDesigner)
CanParent(Control)

指示指定的控制項是否可以為這個設計工具管理的控制項的子系。Indicates whether the specified control can be a child of the control managed by this designer.

(繼承來源 ParentControlDesigner)
CanParent(ControlDesigner)

指示由指定的設計工具管理的控制項,是否可以是這個設計工具管理的控制項的子系。Indicates whether the control managed by the specified designer can be a child of the control managed by this designer.

(繼承來源 ParentControlDesigner)
CreateTool(ToolboxItem)

利用指定的工具建立元件或控制項,並將其加入至目前的設計文件。Creates a component or control from the specified tool and adds it to the current design document.

(繼承來源 ParentControlDesigner)
CreateTool(ToolboxItem, Point)

利用指定的工具建立元件或控制項,並將其加入至目前的設計文件中指定的位置。Creates a component or control from the specified tool and adds it to the current design document at the specified location.

(繼承來源 ParentControlDesigner)
CreateTool(ToolboxItem, Rectangle)

利用指定的工具建立元件或控制項,並將其加入至指定矩形範圍內的目前設計文件。Creates a component or control from the specified tool and adds it to the current design document within the bounds of the specified rectangle.

(繼承來源 ParentControlDesigner)
CreateToolCore(ToolboxItem, Int32, Int32, Int32, Int32, Boolean, Boolean)

提供所有 CreateTool(ToolboxItem) 方法的核心功能。Provides core functionality for all the CreateTool(ToolboxItem) methods.

(繼承來源 ParentControlDesigner)
DefWndProc(Message)

提供 Windows 訊息的預設處理。Provides default processing for Windows messages.

(繼承來源 ControlDesigner)
DisplayError(Exception)

向使用者顯示指定之例外狀況的相關資訊。Displays information about the specified exception to the user.

(繼承來源 ControlDesigner)
Dispose()

釋放 ComponentDesigner 所使用的所有資源。Releases all resources used by the ComponentDesigner.

(繼承來源 ComponentDesigner)
Dispose(Boolean)

釋放 DocumentDesigner 所使用的 Unmanaged 資源,並選擇性地釋放 Managed 資源。Releases the unmanaged resources used by the DocumentDesigner and optionally releases the managed resources.

DoDefaultAction()

在元件上預設事件的原始程式碼檔案中建立方法簽章,並將使用者的游標巡覽至該位置。Creates a method signature in the source code file for the default event on the component and navigates the user's cursor to that location.

(繼承來源 ComponentDesigner)
EnableDesignMode(Control, String)

啟用子控制項的設計階段功能。Enables design time functionality for a child control.

(繼承來源 ControlDesigner)
EnableDragDrop(Boolean)

啟用或停用設計中之控制項的拖放支援。Enables or disables drag-and-drop support for the control being designed.

(繼承來源 ControlDesigner)
EnsureMenuEditorService(IComponent)

檢查功能表編輯器服務是否存在,如果不存在,會建立一個服務。Checks for the existence of a menu editor service and creates one if one does not already exist.

Equals(Object)

判斷指定的物件是否等於目前的物件。Determines whether the specified object is equal to the current object.

(繼承來源 Object)
GetControl(Object)

從指定元件的設計工具取得控制項。Gets the control from the designer of the specified component.

(繼承來源 ParentControlDesigner)
GetControlGlyph(GlyphSelectionType)

取得主體圖像 (Glyph),表示控制項的界限。Gets a body glyph that represents the bounds of the control.

(繼承來源 ParentControlDesigner)
GetGlyphs(GlyphSelectionType)

取得 GlyphCollection,表示 Glyph 物件。Gets a GlyphCollection representing the Glyph objects.

GetHashCode()

做為預設雜湊函式。Serves as the default hash function.

(繼承來源 Object)
GetHitTest(Point)

指示在指定的點按一下滑鼠是否應由控制項處理。Indicates whether a mouse click at the specified point should be handled by the control.

(繼承來源 ScrollableControlDesigner)
GetParentForComponent(IComponent)

衍生類別會在加入元件時,據以判斷是否傳回正在設計的控制項,或是其他的 ContainerUsed by deriving classes to determine if it returns the control being designed or some other Container while adding a component to it.

(繼承來源 ParentControlDesigner)
GetService(Type)

嘗試從設計工具元件的設計模式站台擷取指定的服務類型。Attempts to retrieve the specified type of service from the design mode site of the designer's component.

(繼承來源 ComponentDesigner)
GetToolSupported(ToolboxItem)

指示設計工具是否支援指定的工具。Indicates whether the specified tool is supported by the designer.

GetType()

取得目前執行個體的 TypeGets the Type of the current instance.

(繼承來源 Object)
GetUpdatedRect(Rectangle, Rectangle, Boolean)

更新所指定矩形的位置,如果啟用了格線對齊模式,並將其調整為對齊格線。Updates the position of the specified rectangle, adjusting it for grid alignment if grid alignment mode is enabled.

(繼承來源 ParentControlDesigner)
HookChildControls(Control)

從指定的控制項的子控制項傳送訊息至設計工具。Routes messages from the child controls of the specified control to the designer.

(繼承來源 ControlDesigner)
Initialize(IComponent)

使用指定的元件,初始化設計工具。Initializes the designer with the specified component.

InitializeExistingComponent(IDictionary)

重新初始化現有的元件。Re-initializes an existing component.

(繼承來源 ControlDesigner)
InitializeNewComponent(IDictionary)

初始化新建立的元件。Initializes a newly created component.

(繼承來源 ParentControlDesigner)
InitializeNonDefault()

將控制項的屬性初始化為任何非預設值。Initializes properties of the control to any non-default values.

(繼承來源 ControlDesigner)
InternalControlDesigner(Int32)

傳回 ControlDesigner 中含指定索引的內部控制項設計工具。Returns the internal control designer with the specified index in the ControlDesigner.

(繼承來源 ControlDesigner)
InvokeGetInheritanceAttribute(ComponentDesigner)

取得指定 InheritanceAttributeComponentDesignerGets the InheritanceAttribute of the specified ComponentDesigner.

(繼承來源 ComponentDesigner)
MemberwiseClone()

建立目前 Object 的淺層複本 (Shallow Copy)。Creates a shallow copy of the current Object.

(繼承來源 Object)
NumberOfInternalControlDesigners()

傳回 ControlDesigner 中內部控制項設計工具的數目。Returns the number of internal control designers in the ControlDesigner.

(繼承來源 ControlDesigner)
OnContextMenu(Int32, Int32)

在應顯示內容功能表時呼叫。Called when the context menu should be displayed.

OnCreateHandle()

在建立設計工具的控制代碼後立即呼叫。Called immediately after the handle for the designer has been created.

OnDragComplete(DragEventArgs)

需要清除拖放作業時呼叫。Called in order to clean up a drag-and-drop operation.

(繼承來源 ParentControlDesigner)
OnDragDrop(DragEventArgs)

在拖放物件放在控制項設計工具檢視上時呼叫。Called when a drag-and-drop object is dropped onto the control designer view.

(繼承來源 ParentControlDesigner)
OnDragEnter(DragEventArgs)

在拖放作業進入控制項設計工具檢視時呼叫。Called when a drag-and-drop operation enters the control designer view.

(繼承來源 ParentControlDesigner)
OnDragLeave(EventArgs)

在拖放作業離開控制項設計工具檢視時呼叫。Called when a drag-and-drop operation leaves the control designer view.

(繼承來源 ParentControlDesigner)
OnDragOver(DragEventArgs)

在拖放物件拖曳至控制項設計工具檢視上時呼叫。Called when a drag-and-drop object is dragged over the control designer view.

(繼承來源 ParentControlDesigner)
OnGiveFeedback(GiveFeedbackEventArgs)

在拖放作業進行中時呼叫,以提供拖曳作業進行時以滑鼠位置為基礎的視覺提示。Called when a drag-and-drop operation is in progress to provide visual cues based on the location of the mouse while a drag operation is in progress.

(繼承來源 ParentControlDesigner)
OnMouseDragBegin(Int32, Int32)

呼叫以回應在元件上按住滑鼠左鍵。Called in response to the left mouse button being pressed and held while over the component.

(繼承來源 ParentControlDesigner)
OnMouseDragEnd(Boolean)

在拖放作業結束時呼叫,以完成或取消作業。Called at the end of a drag-and-drop operation to complete or cancel the operation.

(繼承來源 ParentControlDesigner)
OnMouseDragMove(Int32, Int32)

在拖放作業當中,滑鼠每次移動時呼叫。Called for each movement of the mouse during a drag-and-drop operation.

(繼承來源 ParentControlDesigner)
OnMouseEnter()

在滑鼠首次進入控制項時呼叫。Called when the mouse first enters the control.

(繼承來源 ParentControlDesigner)
OnMouseHover()

在滑鼠停留在控制項上方後呼叫。Called after the mouse hovers over the control.

(繼承來源 ParentControlDesigner)
OnMouseLeave()

在滑鼠首次進入控制項時呼叫。Called when the mouse first enters the control.

(繼承來源 ParentControlDesigner)
OnPaintAdornments(PaintEventArgs)

在設計工具正在管理的控制項繪製其介面時呼叫,讓設計工具可以在控制項之上繪製任何其他的裝飾。Called when the control that the designer is managing has painted its surface so the designer can paint any additional adornments on top of the control.

(繼承來源 ParentControlDesigner)
OnSetComponentDefaults()

當設計工具已初始化時呼叫。Called when the designer is initialized.

(繼承來源 ControlDesigner)
OnSetCursor()

提供變更目前滑鼠游標的機會。Provides an opportunity to change the current mouse cursor.

(繼承來源 ParentControlDesigner)
PostFilterAttributes(IDictionary)

允許設計工具變更或移除它經由 TypeDescriptor 公開的屬性集中的項目。Allows a designer to change or remove items from the set of attributes that it exposes through a TypeDescriptor.

(繼承來源 ComponentDesigner)
PostFilterEvents(IDictionary)

允許設計工具變更或移除它經由 TypeDescriptor 公開的事件集中的項目。Allows a designer to change or remove items from the set of events that it exposes through a TypeDescriptor.

(繼承來源 ComponentDesigner)
PostFilterProperties(IDictionary)

允許設計工具變更或移除它經由 TypeDescriptor 公開的屬性集中的項目。Allows a designer to change or remove items from the set of properties that it exposes through a TypeDescriptor.

(繼承來源 ComponentDesigner)
PreFilterAttributes(IDictionary)

允許設計工具加入至它經由 TypeDescriptor 公開的屬性集。Allows a designer to add to the set of attributes that it exposes through a TypeDescriptor.

(繼承來源 ComponentDesigner)
PreFilterEvents(IDictionary)

允許設計工具加入至它經由 TypeDescriptor 公開的事件集。Allows a designer to add to the set of events that it exposes through a TypeDescriptor.

(繼承來源 ComponentDesigner)
PreFilterProperties(IDictionary)

調整元件透過 TypeDescriptor 公開的屬性集。Adjusts the set of properties the component exposes through a TypeDescriptor.

RaiseComponentChanged(MemberDescriptor, Object, Object)

告知 IComponentChangeService 這個元件已經變更。Notifies the IComponentChangeService that this component has been changed.

(繼承來源 ComponentDesigner)
RaiseComponentChanging(MemberDescriptor)

告知 IComponentChangeService 這個元件正要變更。Notifies the IComponentChangeService that this component is about to be changed.

(繼承來源 ComponentDesigner)
ToolPicked(ToolboxItem)

選取指定的工具。Selects the specified tool.

ToString()

傳回代表目前物件的字串。Returns a string that represents the current object.

(繼承來源 Object)
UnhookChildControls(Control)

將指定的控制項的子系訊息傳送至每一個控制項,而非傳送至父設計工具。Routes messages for the children of the specified control to each control rather than to a parent designer.

(繼承來源 ControlDesigner)
WndProc(Message)

處理 Windows 訊息。Processes Windows messages.

明確介面實作

IDesignerFilter.PostFilterAttributes(IDictionary)

如需這個成員的描述,請參閱 PostFilterAttributes(IDictionary) 方法。For a description of this member, see the PostFilterAttributes(IDictionary) method.

(繼承來源 ComponentDesigner)
IDesignerFilter.PostFilterEvents(IDictionary)

如需這個成員的描述,請參閱 PostFilterEvents(IDictionary) 方法。For a description of this member, see the PostFilterEvents(IDictionary) method.

(繼承來源 ComponentDesigner)
IDesignerFilter.PostFilterProperties(IDictionary)

如需這個成員的描述,請參閱 PostFilterProperties(IDictionary) 方法。For a description of this member, see the PostFilterProperties(IDictionary) method.

(繼承來源 ComponentDesigner)
IDesignerFilter.PreFilterAttributes(IDictionary)

如需這個成員的描述,請參閱 PreFilterAttributes(IDictionary) 方法。For a description of this member, see the PreFilterAttributes(IDictionary) method.

(繼承來源 ComponentDesigner)
IDesignerFilter.PreFilterEvents(IDictionary)

如需這個成員的描述,請參閱 PreFilterEvents(IDictionary) 方法。For a description of this member, see the PreFilterEvents(IDictionary) method.

(繼承來源 ComponentDesigner)
IDesignerFilter.PreFilterProperties(IDictionary)

如需這個成員的描述,請參閱 PreFilterProperties(IDictionary) 方法。For a description of this member, see the PreFilterProperties(IDictionary) method.

(繼承來源 ComponentDesigner)
IRootDesigner.GetView(ViewTechnology)

如需這個成員的說明,請參閱 ViewTechnologyFor a description of this member, see ViewTechnology.

IRootDesigner.SupportedTechnologies

如需這個成員的說明,請參閱 SupportedTechnologiesFor a description of this member, see SupportedTechnologies.

IToolboxUser.GetToolSupported(ToolboxItem)

如需這個成員的說明,請參閱 GetToolSupported(ToolboxItem)For a description of this member, see GetToolSupported(ToolboxItem).

IToolboxUser.ToolPicked(ToolboxItem)

如需這個成員的說明,請參閱 ToolPicked(ToolboxItem)For a description of this member, see ToolPicked(ToolboxItem).

ITreeDesigner.Children

如需這個成員的描述,請參閱 Children 屬性。For a description of this member, see the Children property.

(繼承來源 ComponentDesigner)
ITreeDesigner.Parent

如需這個成員的描述,請參閱 Parent 屬性。For a description of this member, see the Parent property.

(繼承來源 ComponentDesigner)

適用於

另請參閱