Class SeparatorElement
Represents the visual element that renders a separator line with optional shadow effect. This element serves as the core visual component for RadSeparator and supports both horizontal and vertical orientations.
Inheritance
Inherited Members
Namespace: Telerik.WinControls.UI
Assembly: Telerik.WinControls.UI.dll
Syntax
[ComVisible(false)]
public class SeparatorElement : LightVisualElement, INotifyPropertyChanged, ICustomTypeDescriptor, ISupportSystemSkin, IComponent, IDisposable, IBindableComponent, ISupportDrag, ISupportDrop, IShortcutProvider, IStylableElement, IStylableNode, IPrimitiveElement, IShapedElement, IFillElement, IBorderElement, IBoxStyle, IBoxElement, IDrawFillElement, IImageElement, ITextPrimitive, ITextProvider
Constructors
SeparatorElement()
Declaration
public SeparatorElement()
Fields
OrientationProperty
Identifies the Orientation dependency property that determines whether the separator is rendered horizontally or vertically.
Declaration
public static RadProperty OrientationProperty
Field Value
RadProperty
|
ShadowOffsetProperty
Identifies the ShadowOffset dependency property that defines the pixel offset of the shadow relative to the main separator line.
Declaration
public static RadProperty ShadowOffsetProperty
Field Value
RadProperty
|
ShowShadowProperty
Identifies the ShowShadow dependency property that controls whether the shadow effect is displayed alongside the main separator line.
Declaration
public static RadProperty ShowShadowProperty
Field Value
RadProperty
|
Properties
Line1
Gets the primary line primitive that renders the main separator line with a black color.
Declaration
public LinePrimitive Line1 { get; }
Property Value
LinePrimitive
|
Line2
Gets the secondary line primitive that renders the shadow effect with a light gray color when ShowShadow is enabled.
Declaration
public LinePrimitive Line2 { get; }
Property Value
LinePrimitive
|
Orientation
Gets or sets the orientation of the separator line, determining whether it is displayed horizontally or vertically.
Declaration
public Orientation Orientation { get; set; }
Property Value
System.Windows.Forms.Orientation
|
ShadowOffset
Gets or sets the pixel offset of the shadow effect relative to the main separator line. This value is only used when ShowShadow is true.
Declaration
public Point ShadowOffset { get; set; }
Property Value
System.Drawing.Point
|
ShowShadow
Gets or sets a value indicating whether the shadow effect is displayed alongside the main separator line.
Declaration
public bool ShowShadow { get; set; }
Property Value
System.Boolean
|
Methods
ArrangeOverride(SizeF)
Arranges the child line primitives within the specified bounds, positioning them according to the orientation and shadow offset settings.
Declaration
protected override SizeF ArrangeOverride(SizeF finalSize)
Parameters
System.Drawing.SizeF
finalSize
The final size that the element should use to arrange itself and its children |
Returns
System.Drawing.SizeF
The actual size used by the element |
Overrides
CreateChildElements()
Creates the child line primitive elements that compose the visual separator, including the main line and optional shadow line.
Declaration
protected override void CreateChildElements()
Overrides
InitializeFields()
Initializes the default field values for the separator element, setting horizontal orientation and disabling fill and border drawing.
Declaration
protected override void InitializeFields()
Overrides
MeasureOverride(SizeF)
Measures the desired size of the separator element based on the orientation and shadow settings, ensuring proper layout calculation.
Declaration
protected override SizeF MeasureOverride(SizeF availableSize)
Parameters
System.Drawing.SizeF
availableSize
The available size that the element can use for layout |
Returns
System.Drawing.SizeF
The desired size of the separator element based on its child line primitives and orientation |