DiagramLite Programmer's Guide
Selection Members
Constructors Fields Properties Methods
 


Represents a set of items selected in the diagram document.

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

 Public Constructors

  Name Description

Selection

Initializes a new instance of the Selection class.

 Inherited Public Fields

  Name Description

AutoCaptureMouseProperty

Identifies the AutoCaptureMouse dependency property. (Inherited from DiagramItem.)

BrushProperty

Identifies the Brush dependency property. (Inherited from DiagramItem.)

HyperLinkProperty

Identifies the HyperLink dependency property. (Inherited from DiagramItem.)

IsMouseDownProperty

Identifies the IsMouseDown dependency property. (Inherited from DiagramItem.)

IsMouseOverProperty

Identifies the IsMouseOver dependency property. (Inherited from DiagramItem.)

StrokeDashArrayProperty

Identifies the StrokeDashArray dependency property. (Inherited from DiagramItem.)

StrokeDashCapProperty

Identifies the StrokeDashCap dependency property. (Inherited from DiagramItem.)

StrokeDashOffsetProperty

Identifies the StrokeDashOffset dependency property. (Inherited from DiagramItem.)

StrokeEndLineCapProperty

Identifies the StrokeEndLineCap dependency property. (Inherited from DiagramItem.)

StrokeLineJoinProperty

Identifies the StrokeLineJoin dependency property. (Inherited from DiagramItem.)

StrokeMiterLimitProperty

Identifies the StrokeMiterLimit dependency property. (Inherited from DiagramItem.)

StrokeProperty

Identifies the Stroke dependency property. (Inherited from DiagramItem.)

StrokeStartLineCapProperty

Identifies the StrokeStartLineCap dependency property. (Inherited from DiagramItem.)

StrokeThicknessProperty

Identifies the StrokeThickness dependency property. (Inherited from DiagramItem.)

TextBrushProperty

Identifies the TextBrush dependency property. (Inherited from DiagramItem.)

 Inherited Protected Fields

  Name Description

handles

A list of the Rectangle objects that represent the item's adjustment handles. (Inherited from DiagramItem.)

 Public Properties

  Name Description

AllowMultipleSelection

Gets or sets a value indicating whether more than one items can be selected simultaneously.

Items

Gets the selected diagram items.

Links

Gets a collection of all selected links.

Nodes

Gets a collection of all selected nodes.

 Inherited Public Properties

  Name Description

AutoCaptureMouse

Gets or sets whether the item should capture the mouse input when the left button is pressed over it. This is a dependency property. (Inherited from DiagramItem.)

Brush

Gets or sets the Brush that specifies how to paint the interior of the item. This is a dependency property. (Inherited from DiagramItem.)

Diagram

Gets the parent diagram. (Inherited from DiagramItem.)

HandlesStyle

Gets or sets a value indicating how the node adjustment handles behave and what do they look like. (Inherited from DiagramItem.)

HyperLink

Gets or sets the hyperlink associated with this diagram item. This is a dependency property. (Inherited from DiagramItem.)

Id

Gets or sets user-defined identifier associated with this item. (Inherited from DiagramItem.)

IgnoreLayout

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

IsMouseDown

Gets a value indicating whether the mouse button is pressed over this item. This is a dependency property. (Inherited from DiagramItem.)

IsMouseOver

Gets a value indicating whether the mouse pointer is located over this item. This is a dependency property. (Inherited from DiagramItem.)

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. (Inherited from DiagramItem.)

LayoutTraits

Contains properties specific to each layout algorithm. (Inherited from DiagramItem.)

Locked

Gets or sets a value indicating whether users are allowed to edit the diagram item. (Inherited from DiagramItem.)

RuntimeIndex

For internal use. (Inherited from DiagramItem.)

Selected

Gets or sets a value indicating whether a diagram item is selected. (Inherited from DiagramItem.)

Stroke

Gets or sets the Brush that specifies how the item outline is painted. (Inherited from DiagramItem.)

StrokeDashArray

Gets or sets a collection of double values that indicate the pattern of dashes and gaps that is used to outline nodes. This is a dependency property. (Inherited from DiagramItem.)

StrokeDashCap

Gets or sets a PenLineCap enumeration value that specifies how the ends of a dash are drawn. (Inherited from DiagramItem.)

StrokeDashOffset

Gets or sets a double value that specifies the distance within the dash pattern where a dash begins. This is a dependency property. (Inherited from DiagramItem.)

StrokeEndLineCap

Gets or sets a PenLineCap enumeration value that specifies what shape to draw at the end of a Stroke. (Inherited from DiagramItem.)

StrokeLineJoin

Gets or sets a PenLineJoin enumeration value that specifies the type of join that is used at the vertices of the item's outline. (Inherited from DiagramItem.)

StrokeMiterLimit

Gets or sets a limit on the ratio of the miter length to half the StrokeThickness of an item outline element. This is a dependency property. (Inherited from DiagramItem.)

StrokeStartLineCap

Gets or sets a PenLineCap enumeration value that specifies what shape to draw at the start of a Stroke. (Inherited from DiagramItem.)

StrokeThickness

Gets or sets the width of the DiagramItem stroke outline. (Inherited from DiagramItem.)

TextBrush

Gets or sets the brush used to draw the item's text. (Inherited from DiagramItem.)

ToolTip

Gets or sets the contents of the tooltip displayed when the mouse pointer rests over the diagram element. (Inherited from DiagramItem.)

Visible

Gets or sets a value indicating whether this item is visible. (Inherited from DiagramItem.)

Weight

Gets or sets a weight value used in layout and path-finding algorithms. (Inherited from DiagramItem.)

ZIndex

Gets or sets the z-order position of the object. (Inherited from DiagramItem.)

 Inherited Protected Properties

  Name Description

Size

Gets the size of this item. (Inherited from DiagramItem.)

 Public Methods

  Name Description

AddItem

Adds a new item to the current selection.

Change

Selects an item and deselects all others.

Clear

Removes all items from the selection.

GetBounds

Gets the bounding rectangle of this item.

GetRotatedBounds

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

HitTestHandle

DiagramItem.HitTestHandle override.

RemoveItem

Removes an item from the selection.

Toggle

Toggles the selection state of an item.

 Protected Methods

  Name Description

AddHandlesToCanvas

DiagramItem.AddHandlesToCanvas override.

CancelDrag

DiagramItem.CancelDrag override.

EndDrag

DiagramItem.EndDrag override.

OnRemove

DiagramItem.OnRemove override.

StartDrag

DiagramItem.StartDrag override.

UpdateDrag

DiagramItem.UpdateDrag override.

UpdateVisuals

DiagramItem.UpdateVisuals override.

 Inherited Public Methods

  Name Description

Clone

Creates a copy of this item. (Inherited from DiagramItem.)

ContainsPoint

Determines whether this item contains the specified point. (Inherited from DiagramItem.)

GetBounds

Gets the bounding rectangle of this item. (Inherited from DiagramItem.)

GetOutlinePoly

Gets a polygon approximating the outline of this object. (Inherited from DiagramItem.)

GetRepaintRect

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

GetRotatedBounds

Gets the bounding rectangle of this item when it is rotated. (Inherited from DiagramItem.)

HitTestHandle

Determines whether a selection handle of this item is located at the specified point. (Inherited from DiagramItem.)

NotInteractive

Gets whether the user is prevented from manipulating this item. (Inherited from DiagramItem.)

OnApplyTemplate

Control.OnApplyTemplate override. (Inherited from DiagramItem.)

Query

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

RestoreLocationState

Restores the state of this diagram item. (Inherited from DiagramItem.)

SaveLocationState

Saves the state of this diagram item. (Inherited from DiagramItem.)

TransformDiagramToItem

Transforms a point in diagram coordinates to item coordinates. (Inherited from DiagramItem.)

TransformItemToDiagram

Gets the diagram coordinates of a point specified in the local coordinate system of this item. (Inherited from DiagramItem.)

ZBottom

Moves the item to the bottom of the z-order. (Inherited from DiagramItem.)

ZLevelDown

Moves the item one level down in the z-order. (Inherited from DiagramItem.)

ZLevelUp

Moves the item one level up in the z-order. (Inherited from DiagramItem.)

ZTop

Moves the item to the top of the z-order. (Inherited from DiagramItem.)

 Inherited Protected Methods

  Name Description

AddHandlesToCanvas

Overloaded.   (Inherited from DiagramItem.)

AllowDrag

Invoked to validate the drag operation. (Inherited from DiagramItem.)

CancelDrag

Invoked when the interactive modification of this object has been canceled. (Inherited from DiagramItem.)

CreateState

Creates an item state corresponding to the type of this diagram item. (Inherited from DiagramItem.)

EndDrag

Invoked when the user stops dragging this item. (Inherited from DiagramItem.)

LoadFromXml

Loads the item content from an XML element. (Inherited from DiagramItem.)

OnAdd

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

OnChildModified

Called when a group child node has been modified. (Inherited from DiagramItem.)

OnLoad

Called after successful deserialization. (Inherited from DiagramItem.)

OnLostMouseCapture

Control.OnLostMouseCapture override. (Inherited from DiagramItem.)

OnMeasureUnitChanged

Called when the diagram's MeasureUnit changes. (Inherited from DiagramItem.)

OnMouseEnter

Control.OnMouseEnter override. (Inherited from DiagramItem.)

OnMouseLeave

Control.OnMouseLeave override. (Inherited from DiagramItem.)

OnMouseLeftButtonDown

Control.OnMouseLeftButtonDown override. (Inherited from DiagramItem.)

OnMouseLeftButtonUp

Control.OnMouseLeftButtonUp override. (Inherited from DiagramItem.)

OnRemove

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

RemoveHandlesFromCanvas

Invoked when the item's selection handles should be removed. (Inherited from DiagramItem.)

RestoreState

Restores the state of this diagram item. (Inherited from DiagramItem.)

SaveState

Saves the state of this diagram item. (Inherited from DiagramItem.)

SaveToXml

Saves the item content into an XML element. (Inherited from DiagramItem.)

ScaleElements

Scales the item's elements by specified amount. (Inherited from DiagramItem.)

StartDrag

Invoked when the user starts dragging this item. (Inherited from DiagramItem.)

UpdateDrag

Invoked while the user drags this item. (Inherited from DiagramItem.)

UpdateHandleColors

Sets the handle colors according to the current selection state of the item and the enabled bits in the EnabledHandles property. (Inherited from DiagramItem.)

UpdateHandlePositions

Invoked when the item's selection handles should change their position. (Inherited from DiagramItem.)

UpdateStates

Sets the current VisualStates of this item. (Inherited from DiagramItem.)

UpdateVisuals

Invoked when an item should update its visual elements. (Inherited from DiagramItem.)

 See Also

Selection Class
MindFusion.Diagramming Namespace