|
![]() |
Optional attribute for use with an DockPanePlugin derived class.
If this attribute is not used, the default values are the same as using a DockPanePluginAttribute(100,100)
Namespace: Autodesk.Navisworks.Api.Plugins
Assembly: Autodesk.Navisworks.Api (in Autodesk.Navisworks.Api.dll)
Syntax
Visual Basic |
---|
<AttributeUsageAttribute(AttributeTargets.Class)> _ Public NotInheritable Class DockPanePluginAttribute _ Inherits Attribute |
C# |
---|
[AttributeUsageAttribute(AttributeTargets.Class)] public sealed class DockPanePluginAttribute : Attribute |
Visual C++ |
---|
[AttributeUsageAttribute(AttributeTargets::Class)] public ref class DockPanePluginAttribute sealed : public Attribute |
Remarks
In conjunction with DockPanePlugin being used as a base class for adding a dockable pane to the Navisworks GUI, this attribute sets various properties for the pane. If this is omitted then defaults are provided.
The attribute PluginAttribute must be applied to the DockPanePlugin derived class as this provides the unique information relating to any plug-in.
See Plug-ins and Writing Plug-ins for Navisworks for more information on creating plug-ins.

Examples

using System.Windows.Forms; using Autodesk.Navisworks.Api.Plugins; namespace BasicDockPanePlugin { [Plugin("BasicDockPanePlugin.BasicDockPanePlugin", "ADSK", DisplayName = "BasicDockPanePlugin", ToolTip = "Basic Docking Pane Plugin")] [DockPanePlugin(100, 300)] [Strings("BasicDockPanePlugin.ADSK.name")] //name of the Localisation file public class BasicDockPanePlugin : DockPanePlugin { public override Control CreateControlPane() { //create the control that will be used to display in the pane HelloWorldControl control = new HelloWorldControl(); control.Dock = DockStyle.Fill; //localisation control.Text = this.TryGetString("HelloWorldText"); //create the control control.CreateControl(); return control; } public override void DestroyControlPane(Control pane) { pane.Dispose(); } } }
Inheritance Hierarchy
System..::..Object
System..::..Attribute
Autodesk.Navisworks.Api.Plugins..::..DockPanePluginAttribute
System..::..Attribute
Autodesk.Navisworks.Api.Plugins..::..DockPanePluginAttribute