ASP.NET Pack Programmer's Guide
DiagramItem Members
Constructors Fields Properties Methods
 


Represents an item in the diagram document. All classes representing diagram elements derive from DiagramItem.

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

 Protected Constructors

  Name Description

DiagramItem

Overloaded. Initializes a new instance of the DiagramItem class.

 Protected Fields

  Name Description

disposed

For internal use.

 Public Properties

  Name Description

Brush

Gets or sets the brush used to fill the interior of this item.

EffectiveBrush

Gets the effective brush of the item.

EffectiveFont

Gets the currently effective font of the item.

EffectivePen

Gets the effective pen of the item.

EffectiveShadowBrush

Gets the effective shadow brush of the item.

EffectiveTextBrush

Gets the effective text brush of the item.

Font

Gets or sets the font used to render the item's text.

HyperLink

Gets or sets the hyperlink associated with this diagram item.

Id

Gets or sets user-defined identifier associated with this item.

IgnoreLayout

Gets or sets a value indicating whether the position of this item should not be changed by automatic layout methods.

LayerIndex

Gets or sets the zero-based index of the layer this item is associated with, or -1, if the item is not associated with a layer.

LayoutTraits

Contains layout properties of the node, used by some layout algorithms and by DiagramView3D.

Locked

Gets or sets a value indicating whether users are allowed to edit the diagram item.

Parent

Gets the diagram that contains this item.

Pen

Gets or sets the pen used to paint the frame of the item.

Printable

Gets or sets a value indicating whether to print the item.

RuntimeIndex

For internal use.

Selected

Gets or sets a value indicating whether a diagram item is selected.

ShadowBrush

Gets or sets the brush used to paint the item's shadow.

ShadowOffsetX

Gets or sets the horizontal offset of the shadow of this item.

ShadowOffsetY

Gets or sets the vertical offset of the shadow of this item.

Style

Gets or sets the style associated with the item.

SubordinateGroup

Gets a reference to the group of items that are attached to this one.

Tag

Gets or sets user-defined data associated with this item.

Text

Gets or sets the text displayed by this item.

TextBrush

Gets or sets the brush used to paint texts inside the item.

TextFormat

Gets or sets the alignment of text displayed inside this item.

TextPadding

Gets or sets the spacing between the item boundaries and its text.

ToolTip

Gets or sets a short text message displayed when the mouse pointer rests over the diagram element.

TopLevel

True if this is a top-level item in the diagram, or false if it is inside a container.

Visible

Gets or sets a value indicating whether this item is visible.

Weight

Gets or sets a weight value used in layout and path-finding algorithms.

ZIndex

Gets or sets the z-order position of this item.

 Protected Properties

  Name Description

MeasureUnit

Returns the diagram measure unit.

 Public Methods

  Name Description

Clone

Creates a copy of this item.

ContainsPoint

Overloaded. Determines whether this item contains the specified point.

Dispose

Overloaded.  

DoModify

For internal use.

Draw

Draws the item on the specified IGraphics surface.

DrawHandles

Renders the adjustment handles of this item.

DrawShadow

Draws the shadow of this item on the specified IGraphics surface.

GetBounds

Gets the bounding rectangle of this item.

GetEffectiveBrush

Creates a System.Drawing.Brush object representing the currently effective brush of the item.

GetEffectivePen

Creates a System.Drawing.Pen object representing the currently effective pen of the item.

GetEffectiveShadowBrush

Creates a System.Drawing.Brush object representing the currently effective shadow brush of the item.

GetEffectiveTextBrush

Creates a System.Drawing.Brush object representing the currently effective text brush of the item.

GetOutlinePoly

Gets a polygon approximating the outline of this object.

GetRepaintRect

Gets the repaint region for this item, taking into account factors such as pen, selection handles and shadow.

GetRotatedBounds

Gets the bounding rectangle of this item when it is rotated.

GetToolTip

Gets the tooltip that should be displayed for this item at the specified point.

HitTest

Returns the diagram item that contains the specified point.

HitTestHandle

Determines whether a selection handle of this item is located at the specified point.

HitTestManipulators

Finds the Manipulator object located at the specified point.

NotInteractive

Gets whether the user is prevented from manipulating this item.

NowModifying

Gets a flag indicating whether this object is being currently modified interactively by the user.

OnLoad

Called after successful deserialization.

Query

Returns the items that can be reached from this item by following the path specified in the given query expression.

RestoreItemProperties

For internal use.

SaveItemProperties

For internal use.

ZBottom

Moves the item to the bottom of the z-order.

ZLevelDown

Moves the item one level down in the z-order.

ZLevelUp

Moves the item one level up in the z-order.

ZTop

Moves the item to the top of the z-order.

 Protected Methods

  Name Description

AddManipulator

Adds the specified manipulator to this object.

AllowCreate

Invoked during interactive creation of items to test whether the operation can be completed in the current context.

AllowModify

Invoked during interactive modification of items to test whether the operation can be completed in the current context.

CancelModify

Invoked when the interactive modification of this object has been canceled.

CompleteCreate

Invoked when the item creation has been completed.

CompleteModify

Invoked when the item modification has been completed.

CreateProperties

Creates an item property set corresponding to the type of this diagram item.

CreateState

Creates an item state corresponding to the type of this diagram item.

DrawManipulators

Overloaded. Draws the associated manipulators on a specified graphics.

Finalize

DiagramItem finalizer.

FreeResources

Called when the item is completely disassociated from a Diagram, that is, when it is no longer referenced from an item collection or the undo/redo history.

GetValue

Gets the effective value of the style property with the specified name.

LoadFrom

Deserializes the item from the specified reader.

LoadFromJson

Loads the item from a JSON object.

LoadFromXml

Loads the item content from an XML element.

LoadObsolete

For internal use.

OnAdd

Called when the item is added to a Diagram, either by the user, programmatically or via undo / redo.

OnChildModified

Called when a group child node has been modified.

OnClick

Invoked when the user clicks this item.

OnDoubleClick

Invoked when the user double-clicks this item.

OnMeasureUnitChanged

Called when the diagram's MeasureUnit changes.

OnRemove

Called when an item is removed from a Diagram, either by the user, programmatically or via undo / redo.

OnStyleChanged

Invoked when the associated style or theme have changed.

OnTextChanged

Called when the value of the Text property changes.

OnTextFormatChanged

Called when the value of the TextFormat property changes.

OnZoomChanged

Called when the diagram's ZoomFactor changes.

RemoveManipulator

Removes the specified manipulator from the object.

Repaint

Overloaded.  

RestoreProperties

Restores the properties of this diagram item.

RestoreState

Restores the state of this diagram item.

SaveProperties

Saves the properties of this diagram item.

SaveState

Saves the state of this diagram item.

SaveTo

Serializes the item to the specified writer.

SaveToJson

Saves the item as a JSON object.

SaveToXml

Saves the item content into an XML element.

SetDiagramDirty

Marks the diagram as changed.

SetExpanded

Sets whether the item is in expanded or collapsed state.

SetReference

Called during deserialization, after all objects have been instantiated, in order to update the references between them.

ShouldRender

Determines whether the item should be rendered in the current context.

StartCreate

Invoked once when the user starts creating a new item interactively.

StartModify

Invoked when the user starts modifying this item interactively.

UpdateCreate

Invoked during interactive creation of this item.

UpdateGroup

Called to update the positions of subordinate nodes attached to this item when the attachment style is set to ControlledByMaster.

UpdateModify

Invoked during interactive modification of this item.

 See Also

DiagramItem Class
MindFusion.Diagramming Namespace