ClassRadDiagramItem
Abstract base implementation of the IDiagramItem interface.
Definition
Namespace:Telerik.Windows.Controls.Diagrams
Assembly:Telerik.Windows.Controls.Diagrams.dll
Syntax:
public abstract class RadDiagramItem : ContentControl, IDiagramItem, ISerializable, ISupportMouseOver, IPropertyChanged, IGroupable, ISupportManipulation, ISupportVirtualization, IContainerChild, ICollapsible
Inheritance: objectRadDiagramItem
Derived Classes:
Implements:
Constructors
RadDiagramItem()
Initializes a new instance of the RadDiagramItem class.
Declaration
protected RadDiagramItem()
Fields
AllowCopyProperty
Identifies the AllowCopy dependency property.
Declaration
public static readonly DependencyProperty AllowCopyProperty
Field Value
DependencyProperty
AllowCutProperty
Identifies the AllowCut dependency property.
Declaration
public static readonly DependencyProperty AllowCutProperty
Field Value
DependencyProperty
AllowDeleteProperty
Identifies the AllowDelete dependency property.
Declaration
public static readonly DependencyProperty AllowDeleteProperty
Field Value
DependencyProperty
AllowPasteProperty
Identifies the AllowPaste dependency property.
Declaration
public static readonly DependencyProperty AllowPasteProperty
Field Value
DependencyProperty
BeginEditEvent
Identifies the BeginEdit routed event.
Declaration
public static readonly RoutedEvent BeginEditEvent
Field Value
RoutedEvent
EditTemplateProperty
Identifies the EditTemplate dependency property.
Declaration
public static readonly DependencyProperty EditTemplateProperty
Field Value
DependencyProperty
EndEditEvent
Identifies the EndEdit routed event.
Declaration
public static readonly RoutedEvent EndEditEvent
Field Value
RoutedEvent
GroupProperty
Identifies the Group dependency property.
Declaration
public static readonly DependencyProperty GroupProperty
Field Value
DependencyProperty
IsConnectorsManipulationEnabledProperty
Identifies the IsConnectorsManipulationEnabled dependency property.
Declaration
public static readonly DependencyProperty IsConnectorsManipulationEnabledProperty
Field Value
DependencyProperty
IsDraggingEnabledProperty
Identifies the IsDraggingEnabled dependency property.
Declaration
public static readonly DependencyProperty IsDraggingEnabledProperty
Field Value
DependencyProperty
IsEditableProperty
Identifies the IsEditable dependency property.
Declaration
public static readonly DependencyProperty IsEditableProperty
Field Value
DependencyProperty
IsInEditModeProperty
Identifies the IsInEditMode dependency property.
Declaration
public static readonly DependencyProperty IsInEditModeProperty
Field Value
DependencyProperty
IsManipulationAdornerVisibleProperty
Identifies the IsManipulationAdornerVisible dependency property.
Declaration
public static readonly DependencyProperty IsManipulationAdornerVisibleProperty
Field Value
DependencyProperty
IsResizingEnabledProperty
Identifies the IsResizingEnabled dependency property.
Declaration
public static readonly DependencyProperty IsResizingEnabledProperty
Field Value
DependencyProperty
IsRotationEnabledProperty
Identifies the IsRotationEnabled dependency property.
Declaration
public static readonly DependencyProperty IsRotationEnabledProperty
Field Value
DependencyProperty
IsSelectedProperty
Identifies the IsSelected dependency property.
Declaration
public static readonly DependencyProperty IsSelectedProperty
Field Value
DependencyProperty
PositionProperty
Identifies the Position dependency property.
Declaration
public static readonly DependencyProperty PositionProperty
Field Value
DependencyProperty
PreviewBeginEditEvent
Identifies the PreviewBeginEdit routed event.
Declaration
public static readonly RoutedEvent PreviewBeginEditEvent
Field Value
RoutedEvent
PreviewEndEditEvent
Identifies the PreviewEndEdit routed event.
Declaration
public static readonly RoutedEvent PreviewEndEditEvent
Field Value
RoutedEvent
StrokeDashArrayProperty
Identifies the StrokeDashArray dependency property.
Declaration
public static readonly DependencyProperty StrokeDashArrayProperty
Field Value
DependencyProperty
StrokeProperty
Identifies the Stroke dependency property.
Declaration
public static readonly DependencyProperty StrokeProperty
Field Value
DependencyProperty
StrokeThicknessProperty
Identifies the StrokeThickness dependency property.
Declaration
public static readonly DependencyProperty StrokeThicknessProperty
Field Value
DependencyProperty
ZIndexProperty
Identifies the ZIndex dependency property.
Declaration
public static readonly DependencyProperty ZIndexProperty
Field Value
DependencyProperty
Properties
ActualSize
The actual size of the item.
Declaration
protected virtual Size ActualSize { get; }
Property Value
Size
AllowCopy
Gets or sets a value indicating whether copying is allowed.
Declaration
public bool AllowCopy { get; set; }
Property Value
True if copying is allowed; otherwise, false.
Implements
AllowCut
Gets or sets a value indicating whether cutting is allowed.
Declaration
public bool AllowCut { get; set; }
Property Value
True if cutting is allowed; otherwise, false.
Implements
AllowDelete
Gets or sets a value indicating whether deleting is allowed.
Declaration
public bool AllowDelete { get; set; }
Property Value
True if deleting is allowed; otherwise, false.
Implements
AllowPaste
Gets or sets a value indicating whether pasting is allowed.
Declaration
public bool AllowPaste { get; set; }
Property Value
True if pasting is allowed; otherwise, false.
Implements
Bounds
Gets the bounds.
Declaration
public virtual Rect Bounds { get; }
Property Value
Rect
The bounds.
Implements
Diagram
Gets the owning diagram of this instance.
Declaration
protected IGraphInternal Diagram { get; }
Property Value
EditTemplate
Gets or sets the edit template.
Declaration
public DataTemplate EditTemplate { get; set; }
Property Value
DataTemplate
The edit template.
Id
Gets the unique identifier of this entity.
Declaration
public string Id { get; }
Property Value
An identifier for this entity.
Implements
IsConnectorsManipulationEnabled
Gets or sets a value indicating whether manipulation on the connectors is enabled.
Declaration
public bool IsConnectorsManipulationEnabled { get; set; }
Property Value
True if manipulation on connectors is enabled; otherwise, false.
Implements
IsDraggingEnabled
Gets or sets a value indicating whether dragging is enabled.
Declaration
public bool IsDraggingEnabled { get; set; }
Property Value
True if dragging is enabled; otherwise, false.
Implements
IsDynamic
Gets or sets whether this item is dynamically generated.
Declaration
public bool IsDynamic { get; set; }
Property Value
If true then this item will not be serialized as part of the diagram.
Implements
Remarks
In some applications or embeddings of RadDiagram (e.g. workflows) there are shapes or connections
which are generated as part of some layout or organization. In those cases it doesn't make sense to serialize
the elements which are automatically generated as part of the application. By setting this property to true the serialization pipeline will omit the element.
IsEditable
Gets or sets a value indicating whether editing is enabled on this item.
Declaration
public bool IsEditable { get; set; }
Property Value
True if editing is enabled; otherwise, false.
Implements
Remarks
Note that the similar higher-level IsEditable can potentially overrule this setting.
IsInEditMode
Gets or sets a value indicating whether this instance is in edit mode.
Declaration
public bool IsInEditMode { get; set; }
Property Value
True if this instance is in edit mode; otherwise, false.
Implements
IsManipulationAdornerVisible
Gets or sets a value indicating whether the manipulation adorner is visible.
Declaration
public bool IsManipulationAdornerVisible { get; set; }
Property Value
True if the manipulation adorner is visible; otherwise, false.
Implements
IsResizingEnabled
Gets or sets a value indicating whether resizing is enabled.
Declaration
public bool IsResizingEnabled { get; set; }
Property Value
True if resizing is enabled; otherwise, false.
Implements
IsRotationEnabled
Gets or sets a value indicating whether rotation is enabled.
Declaration
public bool IsRotationEnabled { get; set; }
Property Value
true if this rotation is enabled; otherwise, false.
Implements
IsSelected
Gets or sets whether the diagram entity is selected.
Declaration
public bool IsSelected { get; set; }
Property Value
True if selected; otherwise, false.
Implements
IsSelectedInGroup
Gets a value indicating whether this instance is selected in group.
Declaration
protected bool IsSelectedInGroup { get; set; }
Property Value
True if this item is selected in group; otherwise, false.
IsServiceManipulation
Gets whether any service is manipulating at the moment.
ParentContainer
Gets the parent container shape.
Declaration
public IContainerShape ParentContainer { get; }
Property Value
The parent container.
Implements
ParentGroup
Gets or sets the group.
Declaration
public IGroup ParentGroup { get; set; }
Property Value
The group.
Implements
Position
Gets or sets the position of the top left corner of the bounding rectangle of the item.
Declaration
public Point Position { get; set; }
Property Value
Point
Implements
ServiceLocator
Gets the service locator.
Declaration
protected IGraphServiceLocator ServiceLocator { get; }
Property Value
Stroke
Gets or sets the stroke of this item.
Declaration
public Brush Stroke { get; set; }
Property Value
Brush
The stroke.
StrokeDashArray
Gets or sets the stroke dash array of this item.
Declaration
[SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
public DoubleCollection StrokeDashArray { get; set; }
Property Value
DoubleCollection
The stroke dash array.
StrokeThickness
Gets or sets the stroke thickness of this item.
Declaration
public double StrokeThickness { get; set; }
Property Value
The stroke thickness.
X
Gets or sets the horizontal position of this item.
Y
Gets or sets the vertical position of this item.
Methods
Deserialize(SerializationInfo)
Deserializes the serialization info in this diagram entity.
Declaration
public virtual void Deserialize(SerializationInfo info)
Parameters
info
A SerializationInfo instance.
Implements
Initialize(IGraphServiceLocator, IGraphInternal)
Initializes the specified service locator and parent graph.
Declaration
protected virtual void Initialize(IGraphServiceLocator serviceLocator, IGraphInternal graph)
Parameters
serviceLocator
The service locator.
graph
The diagram control.
OnApplyTemplate()
When overridden in a derived class, is invoked whenever application code or internal processes (such as a rebuilding layout pass) call . In simplest terms, this means the method is called just before a UI element displays in an application. For more information, see Remarks.
Declaration
public override void OnApplyTemplate()
OnCreateAutomationPeer()
Creates a peer associated with this object.
Declaration
protected override AutomationPeer OnCreateAutomationPeer()
Returns
AutomationPeer
An instance of the .
OnGroupNameChanged()
Called when the group name changes.
Declaration
protected virtual void OnGroupNameChanged()
OnIsConnectorsManipulationEnabledChanged(bool, bool)
Called when connectors manipulation changes.
OnIsEditableChanged(bool, bool)
Called when IsEditable has changed.
OnIsInEditModeChanged(bool, bool)
Called when IsInEditMode changes.
OnIsSelectedChanged(bool, bool)
Called when the IsSelected property has changed.
OnPositionChanged(Point, Point)
Called when position changes.
Declaration
protected virtual void OnPositionChanged(Point oldPosition, Point newPosition)
Parameters
oldPosition
Point
The old position.
newPosition
Point
The new position.
OnPositionCoerced(Point)
Called when [position coerced].
Declaration
protected virtual object OnPositionCoerced(Point position)
Parameters
position
Point
The position.
Returns
OnPropertyChanged(string)
Called when a property value changed.
Declaration
protected virtual void OnPropertyChanged(string propertyName)
Parameters
propertyName
Name of the property.
OnSizeChanged(Size, Size)
Called when the size changes.
Declaration
protected virtual void OnSizeChanged(Size newSize, Size oldSize)
Parameters
newSize
Size
The new size.
oldSize
Size
The old size.
OnStrokeThicknessChanged()
Invoked when the StrokeThickness property has changed.
Declaration
protected virtual void OnStrokeThicknessChanged()
OnZIndexChanged(int, int)
Called when the ZIndex changes.
RefreshIsSelectedInGroup()
Refreshes the is selected in group property.
Declaration
protected virtual void RefreshIsSelectedInGroup()
Serialize()
Serializes this instance.
Declaration
public virtual SerializationInfo Serialize()
Returns
Implements
UpdateVisualStates()
Updates the visual states.
Declaration
protected virtual void UpdateVisualStates()
Events
BeginEdit
Occurs when the editing begins.
Declaration
public event RadRoutedEventHandler BeginEdit
Event Value
EndEdit
Occurs when the editing ends.
Declaration
public event EventHandler<RadRoutedEditEventArgs> EndEdit
Event Value
ParentGroupChanged
Occurs when [group changed].
Declaration
public event EventHandler<PropertyEventArgs<IGroup>> ParentGroupChanged
Event Value
Implements
PreviewBeginEdit
Occurs before the editing starts.
Declaration
public event RadRoutedEventHandler PreviewBeginEdit
Event Value
PreviewEndEdit
Occurs before the editing ends.
Declaration
public event EventHandler<RadRoutedEditEventArgs> PreviewEndEdit
Event Value
PropertyChanged
Occurs when a property value changes.
Declaration
public event EventHandler<PropertyEventArgs> PropertyChanged
Event Value
Implements