Search
Palette Members
Constructors Properties Methods
 


Represents a tool palette control that displays DiagramItem objects grouped into categories. Items from the palette can be added to a diagram by drag-and-drop.

The following tables list the members exposed by the Palette type.

 Public Constructors

  Name Description

Palette

Overloaded.  

 Public Properties

  Name Description

AddScriptReferences

Gets or sets a value indicating whether the control should render references to the client scripts.

AutoClasses

Gets the registered client types with JSON templates.

AutoConnectDistance

Gets or sets the maximum distance to a node when auto connecting links.

AutoConnectLinks

Gets or sets whether links should be automatically connected to the nearest node.

BackColor

Gets or sets the background color of the Palette control.

CaptionFont

Gets or sets the font of the items captions.

ClientScriptLocation

Gets or sets the URL to the MindFusion.Diagramming.js file.

Columns

Gets or sets the number of columns in palette's layout.

Enabled

Gets or sets a value indicating whether handling of mouse events is enabled.

IconSize

Gets or sets the size of items displayed in the palette.

Id

Gets or sets the id of the control.

LabelPosition

Gets or sets a value indicating the position of labels relative to item icons.

MeasureUnit

Gets or sets the unit of measure used to specify item sizes.

MinVisibleFontSize

Gets or sets a threshold value that hides text if scaled font sizes become smaller.

NewInstanceSize

Gets or sets the default size of items created by drag-and-drop from this palette.

Orientation

Gets or sets the layout orientation of the control.

Padding

Gets or sets the padding space between item's slot bounds and its contents.

ShapeLibraryLocation

The location of a shape library file containing custom shape definitions. It can be set to a full URL of the file, or a relative file path.

TextColor

Gets or sets the color of the items captions.

Theme

Gets or sets the theme used to style the control.

 Public Methods

  Name Description

AddCategory

Overloaded.  

AddItem

Adds a DiagramItem to the displayed items collection.

ControlLoadedScript

Sets the name of a JavaScript function that should be invoked when the control is loaded on the client side.

FromJson

Overloaded.  

FromRequest

Initializes a new instance of the Palette class.

Init

Renders the Palette's initializing scripts on a web page under the specified function name.

LinkSelectedScript

Sets the name of a JavaScript function that should be invoked when a link is selected, either programmatically or by the user.

LoadFromJson

Loads the specified JSON data.

NodeSelectedScript

Sets the name of a JavaScript function that should be invoked when a node is selected, either programmatically or by the user.

RegisterItemType

Overloaded.  

RegisterSession

Registers the session instance with the ItemTypeResolver used in custom item serialization.

RemoveCategory

Removes a category from the palette.

RemoveItem

Removes a DiagramItem from the displayed items collection.

Render

Renders the Palette on a web page.

SaveToJson

Serializes the Palette's data to JSON.

SetAddScriptReferences

Sets a value indicating whether the control should render references to the client scripts.

SetAutoConnectDistance

Sets the maximum distance to a node when auto connecting links.

SetAutoConnectLinks

Sets whether links should be automatically connected to the nearest node.

SetBackColor

Sets the background color of the Palette control.

SetCaptionFont

Sets the font of the items captions.

SetColumns

Sets the number of columns in control's layout.

SetEnabled

Sets a value indicating whether handling of mouse events is enabled.

SetIconSize

Sets the size of the items displayed in the view.

SetLabelPosition

Sets a value indicating the position of labels relative to item icons.

SetMinVisibleFontSize

Sets a threshold value that hides text if scaled font sizes become smaller.

SetNewInstanceSize

Sets the default size with which items dragged onto a diagram will be created.

SetOrientation

Sets the layout orientation of the control.

SetTextColor

Sets the text color of the items captions.

SetTheme

Sets the theme used to style the control.

ShapeLibraryLoadedScript

Sets the name of a JavaScript function that should be invoked when a shape library is loaded.

ToJson

Serializes the Palette's data to JSON.

 See Also