ToolboxService ToolboxService ToolboxService ToolboxService Class

Definition

Provides a default implementation of the IToolboxService interface.

public ref class ToolboxService abstract : System::ComponentModel::Design::IComponentDiscoveryService, System::Drawing::Design::IToolboxService
[System.Security.SecurityCritical]
public abstract class ToolboxService : System.ComponentModel.Design.IComponentDiscoveryService, System.Drawing.Design.IToolboxService
type ToolboxService = class
    interface IToolboxService
    interface IComponentDiscoveryService
Public MustInherit Class ToolboxService
Implements IComponentDiscoveryService, IToolboxService
Inheritance
ToolboxServiceToolboxServiceToolboxServiceToolboxService
Attributes
Implements

Remarks

The ToolboxService class is a partial implementation of the IToolboxService interface. To use this implementation you must derive from this class and implement the abstract methods. Once implemented, you may add this class to your designer application's service container. There should be one toolbox service for each designer application.

ToolboxService provides much of the complex logic of creating a toolbox service, but requires that you define the storage containers for categories and items. This allows for simple toolboxes or very complex ones.

Constructors

ToolboxService() ToolboxService() ToolboxService() ToolboxService()

Initializes a new instance of the ToolboxService class.

Properties

CategoryNames CategoryNames CategoryNames CategoryNames

Gets a collection of strings depicting available categories of the toolbox.

SelectedCategory SelectedCategory SelectedCategory SelectedCategory

Gets or sets the name of the currently selected category.

SelectedItemContainer SelectedItemContainer SelectedItemContainer SelectedItemContainer

Gets or sets the currently selected item container.

Methods

CreateItemContainer(IDataObject) CreateItemContainer(IDataObject) CreateItemContainer(IDataObject) CreateItemContainer(IDataObject)

Creates a new toolbox item container from a saved data object.

CreateItemContainer(ToolboxItem, IDesignerHost) CreateItemContainer(ToolboxItem, IDesignerHost) CreateItemContainer(ToolboxItem, IDesignerHost) CreateItemContainer(ToolboxItem, IDesignerHost)

Creates a new toolbox item container from a toolbox item.

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

Determines whether the specified object is equal to the current object.

(Inherited from Object)
FilterChanged() FilterChanged() FilterChanged() FilterChanged()

Occurs when the toolbox service detects that the active designer's toolbox item filter has changed.

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

Serves as the default hash function.

(Inherited from Object)
GetItemContainers() GetItemContainers() GetItemContainers() GetItemContainers()

Returns an IList containing all items on the toolbox.

GetItemContainers(String) GetItemContainers(String) GetItemContainers(String) GetItemContainers(String)

Returns an IList containing all items in a given category.

GetToolboxItem(Type) GetToolboxItem(Type) GetToolboxItem(Type) GetToolboxItem(Type)

Returns a toolbox item for a given type.

GetToolboxItem(Type, Boolean) GetToolboxItem(Type, Boolean) GetToolboxItem(Type, Boolean) GetToolboxItem(Type, Boolean)

Returns a toolbox item for a given type.

GetToolboxItems(Assembly, String) GetToolboxItems(Assembly, String) GetToolboxItems(Assembly, String) GetToolboxItems(Assembly, String)

Returns an ICollection containing all the toolbox items in the given assembly.

GetToolboxItems(Assembly, String, Boolean) GetToolboxItems(Assembly, String, Boolean) GetToolboxItems(Assembly, String, Boolean) GetToolboxItems(Assembly, String, Boolean)

Returns an ICollection of ToolboxItem objects for the given assembly.

GetToolboxItems(AssemblyName) GetToolboxItems(AssemblyName) GetToolboxItems(AssemblyName) GetToolboxItems(AssemblyName)

Returns an ICollection of ToolboxItem objects for the given assembly.

GetToolboxItems(AssemblyName, Boolean) GetToolboxItems(AssemblyName, Boolean) GetToolboxItems(AssemblyName, Boolean) GetToolboxItems(AssemblyName, Boolean)

Returns an ICollection of ToolboxItem objects for the given assembly.

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

Gets the Type of the current instance.

(Inherited from Object)
IsItemContainer(IDataObject, IDesignerHost) IsItemContainer(IDataObject, IDesignerHost) IsItemContainer(IDataObject, IDesignerHost) IsItemContainer(IDataObject, IDesignerHost)

Returns a value indicating whether the given data object represents an item container.

IsItemContainerSupported(ToolboxItemContainer, IDesignerHost) IsItemContainerSupported(ToolboxItemContainer, IDesignerHost) IsItemContainerSupported(ToolboxItemContainer, IDesignerHost) IsItemContainerSupported(ToolboxItemContainer, IDesignerHost)

Determines whether the toolbox item container is supported by the given designer host.

MemberwiseClone() MemberwiseClone() MemberwiseClone() MemberwiseClone()

Creates a shallow copy of the current Object.

(Inherited from Object)
Refresh() Refresh() Refresh() Refresh()

Refreshes the state of the toolbox items.

SelectedItemContainerUsed() SelectedItemContainerUsed() SelectedItemContainerUsed() SelectedItemContainerUsed()

Receives a call from the toolbox service when a user reports that a selected toolbox item has been used.

SetCursor() SetCursor() SetCursor() SetCursor()

Sets the current application's cursor to a cursor that represents the currently selected tool.

ToString() ToString() ToString() ToString()

Returns a string that represents the current object.

(Inherited from Object)
UnloadToolboxItems() UnloadToolboxItems() UnloadToolboxItems() UnloadToolboxItems()

Unloads any assemblies that were locked as a result of calling the GetToolboxItems method.

Explicit Interface Implementations

IComponentDiscoveryService.GetComponentTypes(IDesignerHost, Type) IComponentDiscoveryService.GetComponentTypes(IDesignerHost, Type) IComponentDiscoveryService.GetComponentTypes(IDesignerHost, Type) IComponentDiscoveryService.GetComponentTypes(IDesignerHost, Type)

Gets the list of available component types.

IToolboxService.AddCreator(ToolboxItemCreatorCallback, String) IToolboxService.AddCreator(ToolboxItemCreatorCallback, String) IToolboxService.AddCreator(ToolboxItemCreatorCallback, String) IToolboxService.AddCreator(ToolboxItemCreatorCallback, String)

For a description of this member, see the AddCreator(ToolboxItemCreatorCallback, String) method.

IToolboxService.AddCreator(ToolboxItemCreatorCallback, String, IDesignerHost) IToolboxService.AddCreator(ToolboxItemCreatorCallback, String, IDesignerHost) IToolboxService.AddCreator(ToolboxItemCreatorCallback, String, IDesignerHost) IToolboxService.AddCreator(ToolboxItemCreatorCallback, String, IDesignerHost)

For a description of this member, see the AddCreator(ToolboxItemCreatorCallback, String, IDesignerHost) method.

IToolboxService.AddLinkedToolboxItem(ToolboxItem, IDesignerHost) IToolboxService.AddLinkedToolboxItem(ToolboxItem, IDesignerHost) IToolboxService.AddLinkedToolboxItem(ToolboxItem, IDesignerHost) IToolboxService.AddLinkedToolboxItem(ToolboxItem, IDesignerHost)

For a description of this member, see the AddLinkedToolboxItem(ToolboxItem, IDesignerHost) method.

IToolboxService.AddLinkedToolboxItem(ToolboxItem, String, IDesignerHost) IToolboxService.AddLinkedToolboxItem(ToolboxItem, String, IDesignerHost) IToolboxService.AddLinkedToolboxItem(ToolboxItem, String, IDesignerHost) IToolboxService.AddLinkedToolboxItem(ToolboxItem, String, IDesignerHost)

For a description of this member, see the AddLinkedToolboxItem(ToolboxItem, String, IDesignerHost) method.

IToolboxService.AddToolboxItem(ToolboxItem) IToolboxService.AddToolboxItem(ToolboxItem) IToolboxService.AddToolboxItem(ToolboxItem) IToolboxService.AddToolboxItem(ToolboxItem)

For a description of this member, see the AddToolboxItem(ToolboxItem) method.

IToolboxService.AddToolboxItem(ToolboxItem, String) IToolboxService.AddToolboxItem(ToolboxItem, String) IToolboxService.AddToolboxItem(ToolboxItem, String) IToolboxService.AddToolboxItem(ToolboxItem, String)

For a description of this member, see the AddToolboxItem(ToolboxItem, String) method.

IToolboxService.CategoryNames IToolboxService.CategoryNames IToolboxService.CategoryNames IToolboxService.CategoryNames

For a description of this member, see the CategoryNames property.

IToolboxService.DeserializeToolboxItem(Object) IToolboxService.DeserializeToolboxItem(Object) IToolboxService.DeserializeToolboxItem(Object) IToolboxService.DeserializeToolboxItem(Object)

For a description of this member, see the DeserializeToolboxItem(Object) method.

IToolboxService.DeserializeToolboxItem(Object, IDesignerHost) IToolboxService.DeserializeToolboxItem(Object, IDesignerHost) IToolboxService.DeserializeToolboxItem(Object, IDesignerHost) IToolboxService.DeserializeToolboxItem(Object, IDesignerHost)

For a description of this member, see the DeserializeToolboxItem(Object, IDesignerHost) method.

IToolboxService.GetSelectedToolboxItem() IToolboxService.GetSelectedToolboxItem() IToolboxService.GetSelectedToolboxItem() IToolboxService.GetSelectedToolboxItem()

For a description of this member, see the GetSelectedToolboxItem method.

IToolboxService.GetSelectedToolboxItem(IDesignerHost) IToolboxService.GetSelectedToolboxItem(IDesignerHost) IToolboxService.GetSelectedToolboxItem(IDesignerHost) IToolboxService.GetSelectedToolboxItem(IDesignerHost)

For a description of this member, see the GetSelectedToolboxItem(IDesignerHost) method.

IToolboxService.GetToolboxItems() IToolboxService.GetToolboxItems() IToolboxService.GetToolboxItems() IToolboxService.GetToolboxItems()

Gets the entire collection of toolbox items from the toolbox.

IToolboxService.GetToolboxItems(IDesignerHost) IToolboxService.GetToolboxItems(IDesignerHost) IToolboxService.GetToolboxItems(IDesignerHost) IToolboxService.GetToolboxItems(IDesignerHost)

Gets the collection of toolbox items that are associated with the specified designer host from the toolbox.

IToolboxService.GetToolboxItems(String) IToolboxService.GetToolboxItems(String) IToolboxService.GetToolboxItems(String) IToolboxService.GetToolboxItems(String)

Gets a collection of toolbox items from the toolbox that match the specified category.

IToolboxService.GetToolboxItems(String, IDesignerHost) IToolboxService.GetToolboxItems(String, IDesignerHost) IToolboxService.GetToolboxItems(String, IDesignerHost) IToolboxService.GetToolboxItems(String, IDesignerHost)

Gets the collection of toolbox items that are associated with the specified designer host and category from the toolbox.

IToolboxService.IsSupported(Object, ICollection) IToolboxService.IsSupported(Object, ICollection) IToolboxService.IsSupported(Object, ICollection) IToolboxService.IsSupported(Object, ICollection)

Gets a value indicating whether the specified object, which represents a serialized toolbox item, matches the specified attributes.

IToolboxService.IsSupported(Object, IDesignerHost) IToolboxService.IsSupported(Object, IDesignerHost) IToolboxService.IsSupported(Object, IDesignerHost) IToolboxService.IsSupported(Object, IDesignerHost)

Gets a value indicating whether the specified object, which represents a serialized toolbox item, can be used by the specified designer host.

IToolboxService.IsToolboxItem(Object) IToolboxService.IsToolboxItem(Object) IToolboxService.IsToolboxItem(Object) IToolboxService.IsToolboxItem(Object)

Gets a value indicating whether the specified object is a serialized toolbox item.

IToolboxService.IsToolboxItem(Object, IDesignerHost) IToolboxService.IsToolboxItem(Object, IDesignerHost) IToolboxService.IsToolboxItem(Object, IDesignerHost) IToolboxService.IsToolboxItem(Object, IDesignerHost)

Gets a value indicating whether the specified object is a serialized toolbox item by using the specified designer host.

IToolboxService.Refresh() IToolboxService.Refresh() IToolboxService.Refresh() IToolboxService.Refresh()

Refreshes the state of the toolbox items.

IToolboxService.RemoveCreator(String) IToolboxService.RemoveCreator(String) IToolboxService.RemoveCreator(String) IToolboxService.RemoveCreator(String)

Removes a previously added toolbox item creator of the specified data format.

IToolboxService.RemoveCreator(String, IDesignerHost) IToolboxService.RemoveCreator(String, IDesignerHost) IToolboxService.RemoveCreator(String, IDesignerHost) IToolboxService.RemoveCreator(String, IDesignerHost)

Removes a previously added toolbox creator that is associated with the specified data format and the specified designer host.

IToolboxService.RemoveToolboxItem(ToolboxItem) IToolboxService.RemoveToolboxItem(ToolboxItem) IToolboxService.RemoveToolboxItem(ToolboxItem) IToolboxService.RemoveToolboxItem(ToolboxItem)

Removes the specified toolbox item from the toolbox.

IToolboxService.RemoveToolboxItem(ToolboxItem, String) IToolboxService.RemoveToolboxItem(ToolboxItem, String) IToolboxService.RemoveToolboxItem(ToolboxItem, String) IToolboxService.RemoveToolboxItem(ToolboxItem, String)

Removes the specified toolbox item from the toolbox.

IToolboxService.SelectedCategory IToolboxService.SelectedCategory IToolboxService.SelectedCategory IToolboxService.SelectedCategory

For a description of this member, see the SelectedCategory property.

IToolboxService.SelectedToolboxItemUsed() IToolboxService.SelectedToolboxItemUsed() IToolboxService.SelectedToolboxItemUsed() IToolboxService.SelectedToolboxItemUsed()

Notifies the toolbox service that the selected tool has been used.

IToolboxService.SerializeToolboxItem(ToolboxItem) IToolboxService.SerializeToolboxItem(ToolboxItem) IToolboxService.SerializeToolboxItem(ToolboxItem) IToolboxService.SerializeToolboxItem(ToolboxItem)

Gets a serializable object that represents the specified toolbox item.

IToolboxService.SetCursor() IToolboxService.SetCursor() IToolboxService.SetCursor() IToolboxService.SetCursor()

Sets the current application's cursor to a cursor that represents the currently selected tool.

IToolboxService.SetSelectedToolboxItem(ToolboxItem) IToolboxService.SetSelectedToolboxItem(ToolboxItem) IToolboxService.SetSelectedToolboxItem(ToolboxItem) IToolboxService.SetSelectedToolboxItem(ToolboxItem)

Selects the specified toolbox item.

Security

NamedPermissionSet
for full access to system resources. Demand values: LinkDemand, InheritanceDemand. Associated state:

Applies to

See also