Class RadDropDownMenuElement
Represents the visual element for a drop-down menu that provides layout, scrolling, and rendering capabilities for menu items. This element supports left column icons, header columns, and scrollable content areas.
Inherited Members
Namespace: Telerik.WinControls.UI
Assembly: Telerik.WinControls.UI.dll
Syntax
public class RadDropDownMenuElement : RadElement, IDisposable, INotifyPropertyChanged, ICustomTypeDescriptor, ISupportSystemSkin, IStylableNode
Constructors
RadDropDownMenuElement()
Declaration
public RadDropDownMenuElement()
Fields
DropDownPositionProperty
Identifies the DropDownPosition dependency property.
Declaration
public static readonly RadProperty DropDownPositionProperty
Field Value
|
RadProperty
|
Properties
Border
Gets the border primitive that provides the border rendering for the drop-down menu.
Declaration
public BorderPrimitive Border { get; }
Property Value
|
BorderPrimitive
|
CanHaveOwnStyle
Gets a value indicating whether this element can have its own visual style defined.
Declaration
public override bool CanHaveOwnStyle { get; }
Property Value
|
System.Boolean
|
Overrides
Fill
Gets the fill primitive that provides the background rendering for the drop-down menu.
Declaration
public FillPrimitive Fill { get; }
Property Value
|
FillPrimitive
|
HeaderColumn
Gets the header column element that manages the layout of header text and image elements.
Declaration
public ImageAndTextLayoutPanel HeaderColumn { get; }
Property Value
|
ImageAndTextLayoutPanel
|
HeaderColumnBorder
Gets the border primitive that provides the border rendering for the header column.
Declaration
public BorderPrimitive HeaderColumnBorder { get; }
Property Value
|
BorderPrimitive
|
HeaderColumnFill
Gets the fill primitive that provides the background rendering for the header column.
Declaration
public FillPrimitive HeaderColumnFill { get; }
Property Value
|
FillPrimitive
|
HeaderColumnImage
Gets the image primitive that renders the header column image.
Declaration
public ImagePrimitive HeaderColumnImage { get; }
Property Value
|
ImagePrimitive
|
HeaderColumnText
Gets the text primitive that renders the header column text.
Declaration
public TextPrimitive HeaderColumnText { get; }
Property Value
|
TextPrimitive
|
HeaderImage
Gets or sets the header image of the drop-down menu.
Declaration
public Image HeaderImage { get; set; }
Property Value
|
System.Drawing.Image
|
HeaderText
Gets or sets the header text of the drop-down menu.
Declaration
public string HeaderText { get; set; }
Property Value
|
System.String
|
Layout
Gets the specialized layout manager that handles the arrangement of menu items and columns.
Declaration
public RadDropDownMenuLayout Layout { get; }
Property Value
|
RadDropDownMenuLayout
|
LayoutPanel
Gets the layout panel that contains and arranges the menu items.
Declaration
public RadElement LayoutPanel { get; }
Property Value
|
RadElement
|
LeftColumnBorder
Gets the border primitive that provides the border rendering for the left column.
Declaration
public BorderPrimitive LeftColumnBorder { get; }
Property Value
|
BorderPrimitive
|
LeftColumnElement
Gets the element that represents the left column area of the drop-down menu, typically used for icons or checkmarks.
Declaration
public RadElement LeftColumnElement { get; }
Property Value
|
RadElement
|
LeftColumnFill
Gets the fill primitive that provides the background rendering for the left column.
Declaration
public FillPrimitive LeftColumnFill { get; }
Property Value
|
FillPrimitive
|
ScrollPanel
Gets an instance of the RadScrollViewer class that represents layout panel that provides scrolling functionality.
Declaration
public RadScrollViewer ScrollPanel { get; }
Property Value
|
RadScrollViewer
|
Methods
ApplySizeConstraints(SizeF)
Applies size constraints to the desired size based on popup control settings and screen boundaries.
Declaration
protected virtual SizeF ApplySizeConstraints(SizeF desiredSize)
Parameters
|
System.Drawing.SizeF
desiredSize
The desired size calculated during measurement. |
Returns
|
System.Drawing.SizeF
The final size after applying popup sizing constraints and screen boundary limitations. |
ArrangeOverride(SizeF)
Arranges the child elements of the drop-down menu within the final layout rectangle.
Declaration
protected override SizeF ArrangeOverride(SizeF finalSize)
Parameters
|
System.Drawing.SizeF
finalSize
The final area within the parent that this element should use to arrange itself and its children. |
Returns
|
System.Drawing.SizeF
The actual size that the element used for arrangement. |
Overrides
CreateChildElements()
Creates and initializes all child elements including fill, border, layout panels, and scroll viewer.
Declaration
protected override void CreateChildElements()
Overrides
CreateMenuLayout()
Creates the menu layout panel that manages the arrangement of menu items within the drop-down.
Declaration
protected virtual RadDropDownMenuLayout CreateMenuLayout()
Returns
|
RadDropDownMenuLayout
A new instance of RadDropDownMenuLayout that provides the layout behavior for menu items. |
InitializeFields()
Initializes the element fields and sets the default CSS class for styling.
Declaration
protected override void InitializeFields()
Overrides
MeasureOverride(SizeF)
Measures the child elements of the drop-down menu element and determines the size required for layout.
Declaration
protected override SizeF MeasureOverride(SizeF availableSize)
Parameters
|
System.Drawing.SizeF
availableSize
The available size that the parent element can allocate for this element. |
Returns
|
System.Drawing.SizeF
The size that this element requires to arrange itself and its child elements, with size constraints applied. |
Overrides
OnPropertyChanged(RadPropertyChangedEventArgs)
Called when a property value changes. Handles special logic for DropDownPositionProperty changes.
Declaration
protected override void OnPropertyChanged(RadPropertyChangedEventArgs e)
Parameters
|
RadPropertyChangedEventArgs
e
A RadPropertyChangedEventArgs that contains the event data. |