ProvideToolWindowAttribute Class
Notifies Visual Studio that a VSPackage owns a tool window.
Assembly: Microsoft.VisualStudio.Shell.14.0 (in Microsoft.VisualStudio.Shell.14.0.dll)
System.Attribute
Microsoft.VisualStudio.Shell.RegistrationAttribute
Microsoft.VisualStudio.Shell.ProvideToolWindowAttribute
| Name | Description | |
|---|---|---|
![]() | ProvideToolWindowAttribute(Type) | Initializes a new instance of ProvideToolWindowAttribute. |
| Name | Description | |
|---|---|---|
![]() | DockedHeight | Gets ore sets the default height of the ToolWindow when docked. |
![]() | DockedWidth | Gets ore sets the default width of the ToolWindow when docked. |
![]() | DocumentLikeTool | Set this property to true if you want a tool window that is like a document in its behavior and lifetime. The tool window will only be MDI or floating and will remain visible in its position across all layout changes until manually closed by the user at which point it will be destroyed. This flag implies DontForceCreate and destructive multi instance. |
![]() | Height | Gets or sets the default height of the tool window. |
![]() | MultiInstances | Determines whether multiple instances of the tool window are allowed. |
![]() | Orientation | Gets or sets the default orientation for the tool window relative to the window specified by the Window property. |
![]() | PositionX | Gets or sets the default horizontal value of the top left corner of the tool window. |
![]() | PositionY | Gets or sets the vertical value of the top left corner of the tool window. |
![]() | Style | Gets or sets the default docking style for the tool window. |
![]() | ToolType | Gets or sets the type of the tool window. |
![]() | Transient | Gets or sets whether the tool window should not be reopened when the IDE restarts. |
![]() | TypeId | Gets the current instance of this attribute.(Inherited from RegistrationAttribute.) |
![]() | Width | Gets or sets the default width of the tool window. |
![]() | Window | Gets or sets the GUID of the default window on which the tool window should be docked. |
| Name | Description | |
|---|---|---|
![]() | Equals(Object) | (Inherited from Attribute.) |
![]() | GetHashCode() | (Inherited from Attribute.) |
![]() | GetType() | (Inherited from Object.) |
![]() | IsDefaultAttribute() | (Inherited from Attribute.) |
![]() | Match(Object) | (Inherited from Attribute.) |
![]() | Register(RegistrationAttribute.RegistrationContext) | Registers the tool window.(Overrides RegistrationAttribute.Register(RegistrationAttribute.RegistrationContext).) |
![]() | ToString() | (Inherited from Object.) |
![]() | Unregister(RegistrationAttribute.RegistrationContext) | Removes the registry key for the tool window.(Overrides RegistrationAttribute.Unregister(RegistrationAttribute.RegistrationContext).) |
| Name | Description | |
|---|---|---|
![]() ![]() | _Attribute.GetIDsOfNames(Guid, IntPtr, UInt32, UInt32, IntPtr) | (Inherited from Attribute.) |
![]() ![]() | _Attribute.GetTypeInfo(UInt32, UInt32, IntPtr) | (Inherited from Attribute.) |
![]() ![]() | _Attribute.GetTypeInfoCount(UInt32) | (Inherited from Attribute.) |
![]() ![]() | _Attribute.Invoke(UInt32, Guid, UInt32, Int16, IntPtr, IntPtr, IntPtr, IntPtr) | (Inherited from Attribute.) |
Implement the ProvideToolWindowAttribute class when a VSPackage implements one or more tool windows.
This attribute declares that a specific VSPackage owns a tool window. It also helps determine the positioning and persistence of the tool window when it is created. To use ProvideToolWindowAttribute, place it on a package class derived from Package or implementing IVsPackage.
This attribute is only used to provide data for external registration tools. It does not have any effect on the runtime behavior of the VSPackage.
The ProvideToolWindowAttribute class creates the following registry entries:
<VSROOT>\ToolWindows\{ToolWindowGuid}
<VSROOT>\ToolWindows\{ToolWindowGuid}\@={ToolWindowTypeGuid}
<VSROOT>\ToolWindows\{ToolWindowGuid}\Name=ToolWindowName
The following registry entries are optional:
<VSROOT>\ToolWindows\{ToolWindowGuid}\Float=FloatPosition
<VSROOT>\ToolWindows\{ToolWindowGuid}\Style=ToolWindowStyle
<VSROOT>\ToolWindows\{ToolWindowGuid}\Window=DockWith
<VSROOT>\ToolWindows\{ToolWindowGuid}\Orientation=ToolWindowOrientation
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.



