RadDiagramItem
Abstract base implementation of the IDiagramItem interface.
Definition
Namespace:Telerik.WinControls.UI.Diagrams
Assembly:Telerik.WinControls.RadDiagram.dll
Syntax:
public abstract class RadDiagramItem : FrameworkElement, IDisposable, INotifyPropertyChanged, ICustomTypeDescriptor, ISupportSystemSkin, IStylableNode, ISupportDrop, IDiagramItem, ISerializable, ISupportMouseOver, IPropertyChanged, IGroupable, ISupportManipulation, ISupportVirtualization, IContainerChild, ICollapsible
Inheritance: objectDisposableObjectRadObjectRadElementVisualElementUIElementFrameworkElementRadDiagramItem...
Derived Classes:
Implements:
Inherited Members
Constructors
Initializes a new instance of the RadDiagramItem class.
protected RadDiagramItem()
Fields
Identifies the AllowCopy dependency property.
public static readonly RadProperty AllowCopyProperty
Identifies the AllowCut dependency property.
public static readonly RadProperty AllowCutProperty
Identifies the AllowDelete dependency property.
public static readonly RadProperty AllowDeleteProperty
Identifies the AllowPaste dependency property.
public static readonly RadProperty AllowPasteProperty
Identifies the EditTemplate dependency property.
public static readonly RadProperty EditTemplateProperty
The inline text editor used while this item is in edit mode.
protected RadTextBoxControlElement editTextBox
Identifies the EndEdit routed event.
public static readonly RoutedEvent EndEditEvent
Identifies the Group dependency property.
public static readonly RadProperty GroupProperty
Identifies the IsConnectorsManipulationEnabled dependency property.
public static readonly RadProperty IsConnectorsManipulationEnabledProperty
Identifies the IsDraggingEnabled dependency property.
public static readonly RadProperty IsDraggingEnabledProperty
Identifies the IsEditable dependency property.
public static readonly RadProperty IsEditableProperty
Identifies the IsInEditMode dependency property.
public static readonly RadProperty IsInEditModeProperty
Identifies the IsManipulationAdornerVisible dependency property.
public static readonly RadProperty IsManipulationAdornerVisibleProperty
Identifies the IsResizingEnabled dependency property.
public static readonly RadProperty IsResizingEnabledProperty
Identifies the IsRotationEnabled dependency property.
public static readonly RadProperty IsRotationEnabledProperty
Identifies the IsSelected dependency property.
public static readonly RadProperty IsSelectedProperty
Identifies the Position dependency property.
public static readonly RadProperty PositionProperty
Identifies the StrokeDashArray dependency property.
public static readonly RadProperty StrokeDashArrayProperty
Identifies the Stroke dependency property.
public static readonly RadProperty StrokeProperty
Identifies the StrokeThickness dependency property.
public static readonly RadProperty StrokeThicknessProperty
Properties
The actual size of the item.
protected virtual Size ActualSize { get; }
Gets or sets the preferred location of the element if its size is less than its parent size.
[Browsable(false)]
public override ContentAlignment Alignment { get; set; }
Overrides:
Gets or sets a value indicating whether copying is allowed.
public bool AllowCopy { get; set; }
True if copying is allowed; otherwise, false.
Implements:
Gets or sets a value indicating whether cutting is allowed.
public bool AllowCut { get; set; }
True if cutting is allowed; otherwise, false.
Implements:
Gets or sets a value indicating whether deleting is allowed.
public bool AllowDelete { get; set; }
True if deleting is allowed; otherwise, false.
Implements:
Gets or sets a value indicating whether pasting is allowed.
public bool AllowPaste { get; set; }
True if pasting is allowed; otherwise, false.
Implements:
Gets or sets the rotation transform angle used when painting the element and its children.
[Browsable(false)]
public override float AngleTransform { get; set; }
Overrides:
Gets the bounds.
[Browsable(false)]
public virtual Rect Bounds { get; }
The bounds.
Implements:
Gets or sets the object's data value and updates Text with its string representation.
[Browsable(false)]
public object Content { get; set; }
Implements:
Gets or sets the data object associated with this item for diagram data binding.
public object DataBoundItem { get; set; }
Gets the owning diagram of this instance.
protected IGraphInternal Diagram { get; }
Gets the unique identifier of this entity.
public string Id { get; }
An identifier for this entity.
Implements:
Gets or sets a value indicating whether manipulation on the connectors is enabled.
public bool IsConnectorsManipulationEnabled { get; set; }
True if manipulation on connectors is enabled; otherwise, false.
Implements:
Gets or sets a value indicating whether dragging is enabled.
public bool IsDraggingEnabled { get; set; }
True if dragging is enabled; otherwise, false.
Implements:
Gets or sets whether this item is dynamically generated.
[Browsable(false)]
public bool IsDynamic { get; set; }
If true then this item will not be serialized as part of the diagram.
Implements:
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
truethe serialization pipeline will omit the element.
Gets or sets a value indicating whether editing is enabled on this item.
public bool IsEditable { get; set; }
True if editing is enabled; otherwise, false.
Implements:
Note that the similar higher-level IsEditable can potentially overrule this setting.
Gets or sets the item's enabled state through its inherited Enabled property.
public virtual bool IsEnabled { get; set; }
Implements:
Gets or sets a value indicating whether this instance is in edit mode.
public bool IsInEditMode { get; set; }
True if this instance is in edit mode; otherwise, false.
Implements:
Gets or sets a value indicating whether the manipulation adorner is visible.
public bool IsManipulationAdornerVisible { get; set; }
True if the manipulation adorner is visible; otherwise, false.
Implements:
Gets or sets a value indicating whether resizing is enabled.
public bool IsResizingEnabled { get; set; }
True if resizing is enabled; otherwise, false.
Implements:
Gets or sets a value indicating whether rotation is enabled.
public bool IsRotationEnabled { get; set; }
true if this rotation is enabled; otherwise, false.
Implements:
Gets or sets whether the diagram entity is selected.
public bool IsSelected { get; set; }
True if selected; otherwise, false.
Implements:
Gets a value indicating whether this instance is selected in group.
protected bool IsSelectedInGroup { get; set; }
True if this item is selected in group; otherwise, false.
Gets whether any service is manipulating at the moment.
protected bool IsServiceManipulation { get; }
ParentContainer
[Browsable(false)]
public IContainerShape ParentContainer { get; }
Implements:
Gets or sets the group.
[Browsable(false)]
public IGroup ParentGroup { get; set; }
The group.
Implements:
Gets or sets the position of the top left corner of the bounding rectangle of the item.
public Point Position { get; set; }
Implements:
Gets or sets the direction of flow of the elements and whether elements are aligned to support locales using right-to-left fonts.
[Browsable(false)]
public override bool RightToLeft { get; set; }
Overrides:
Gets the service locator.
protected IGraphServiceLocator ServiceLocator { get; }
Gets or sets whether layout can expand the element to use available horizontal space.
[Browsable(false)]
public override bool StretchHorizontally { get; set; }
Overrides:
Gets or sets whether layout can expand the element to use available vertical space.
[Browsable(false)]
public override bool StretchVertically { get; set; }
Overrides:
Gets or sets the stroke of this item.
[Browsable(false)]
public virtual Brush Stroke { get; set; }
The stroke.
Gets or sets the stroke dash array of this item.
[Browsable(false)]
public DoubleCollection StrokeDashArray { get; set; }
The stroke dash array.
Gets or sets the stroke thickness of this item.
public double StrokeThickness { get; set; }
The stroke thickness.
Gets or sets the horizontal position of this item.
public double X { get; set; }
The x-coordinate.
Gets or sets the vertical position of this item.
public double Y { get; set; }
The y-coordinate.
Methods
Raises the BeginEdit event when a handler is subscribed.
protected virtual void CallBeginEditEvent()
Configures the inline text editor, hides manipulation handles, and selects the item's current text.
protected virtual void CustomizeTextBoxEditor()
Deserializes the serialization info in this diagram entity.
public virtual void Deserialize(SerializationInfo info)
A SerializationInfo instance.
Implements:
Initializes the specified service locator and parent graph.
protected virtual void Initialize(IGraphServiceLocator serviceLocator, IGraphInternal graph)
The service locator.
graphIGraphInternalThe diagram control.
Copies diagram-level manipulation and clipboard settings to properties that have no local value on this item.
protected virtual void InitializeGlobalSettingsFromDiagram(RadDiagramElement diagramParent)
The diagram that supplies the default settings.
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.
public override void OnApplyTemplate()
Overrides:
Called when the group name changes.
protected virtual void OnGroupNameChanged()
Applies diagram-level settings when the item is attached to a diagram.
protected override void OnParentChanged(RadElement previousParent)
The element that was the item's parent before the change.
Overrides:
Called when a property value changed.
protected virtual void OnPropertyChanged(string propertyName)
Name of the property.
Invoked when the StrokeThickness property has changed.
protected virtual void OnStrokeThicknessChanged()
Refreshes the is selected in group property.
protected virtual void RefreshIsSelectedInGroup()
Serializes this instance.
Updates the visual states.
protected virtual void UpdateVisualStates()
Events
Identifies the BeginEdit routed event.
public event EventHandler BeginEdit
Occurs when the editing ends.
public event EventHandler<RadRoutedEditEventArgs> EndEdit
Occurs when [group changed].
public event EventHandler<PropertyEventArgs<IGroup>> ParentGroupChanged
Implements:
Occurs before the editing starts.
public event CancelEventHandler PreviewBeginEdit
Occurs before the editing ends.
public event CancelEventHandler PreviewEndEdit
Occurs when this item reports a property change; the event arguments identify the changed property.
public event EventHandler<PropertyEventArgs> PropertyChanged
Implements: