RadCommandBarElement
Represents the main element of the RadCommandBar control. Contains a collection of CommandBarRowElement element.
Definition
Namespace:Telerik.WinControls.UI
Assembly:Telerik.WinControls.UI.dll
Syntax:
public class RadCommandBarElement : RadCommandBarVisualElement, INotifyPropertyChanged, ICustomTypeDescriptor, ISupportSystemSkin, IBindableComponent, IComponent, IDisposable, ISupportDrag, ISupportDrop, IShortcutProvider, IStylableElement, IStylableNode, IPrimitiveElement, IShapedElement, IFillElement, IBorderElement, IBoxStyle, IBoxElement, IDrawFillElement, IImageElement, ITextPrimitive, ITextProvider
Inheritance: objectDisposableObjectRadObjectRadElementVisualElementRadComponentElementRadItemUIItemBaseLightVisualElementRadCommandBarVisualElementRadCommandBarElement...
Derived Classes:
Implements:
Inherited Members
Constructors
public RadCommandBarElement()
Fields
protected StackLayoutPanel layoutPanel
protected RadCommandBarLinesElementCollection lines
Properties
Gets or sets the size in pixels when current strip is being Drag and Drop in next or previous row
public Size DragSize { get; set; }
Gets or sets the orientation of the RadCommandBarElement.
[Browsable(false)]
public override Orientation Orientation { get; set; }
Overrides:
Gets the rows of the RadCommandBarElement.
[RadEditItemsAction]
[RadNewItem("", false, true, true)]
public RadCommandBarLinesElementCollection Rows { get; }
Gets the CommandBarStripInfoHolder object that provides information about strips owned by the RadCommandBarElement.
public CommandBarStripInfoHolder StripInfoHolder { get; set; }
Methods
Arranges the command bar element and its children within their allocated space.
Creates and initializes the child elements of the command bar, including layout panel and command bar lines collection.
protected override void CreateChildElements()
Overrides:
Creates a floating form of a specified .
public void CreateFloatingStrip(CommandBarStripElement stripElement, CommandBarRowElement currentRow, Point initialLocation)
The strip element of which the floating form should be created.
currentRowCommandBarRowElementThe that contains the strip element.
The initial location of the floating form.
Releases the managed resources used by the command bar element.
protected override void DisposeManagedResources()
Overrides:
Initializes the fields of the command bar element.
protected override void InitializeFields()
Overrides:
protected virtual void ItemsChanged(RadCommandBarLinesElementCollection changed, CommandBarRowElement target, ItemsChangeOperation operation)
Loads the visual state of the RadCommandBarElement from a specified stream.
Loads the visual state of the RadCommandBarElement from a specified file.
public void LoadLayout(string filename)
The name of the file containing the visual state data.
Loads the visual state of the RadCommandBarElement from a specified XmlReader.
public void LoadLayout(XmlReader xmlReader)
The XmlReader to read the visual state data.
Restores the visual state of the RadCommandBarElement from the specified XmlDocument.
protected virtual void LoadLayoutCore(XmlDocument doc)
The document containing the visual state data.
Moves a specific CommandBarStripElement to the lower CommandBarRowElement.
public void MoveToDownerLine(CommandBarStripElement element, CommandBarRowElement currentHolder)
The element to move.
currentHolderCommandBarRowElementThe CommandBarRowElement that contains the element to move.
Moves a specific CommandBarStripElement to the upper CommandBarRowElement.
public void MoveToUpperLine(CommandBarStripElement element, CommandBarRowElement currentHolder)
The element to move.
currentHolderCommandBarRowElementThe CommandBarRowElement that contains the element to move.
Raises the event
protected virtual void OnBeginDragging(object sender, CancelEventArgs args)
The element that is responsible for firing the event.
argsCancelEventArgsA CancelEventArgs that contains the event data.
Handles the bubbling of events from child elements, particularly drag-related events.
protected override void OnBubbleEvent(RadElement sender, RoutedEventArgs args)
The RadElement that initiated the event.
argsRoutedEventArgsThe event data.
Overrides:
Raises the event
protected virtual void OnDragging(object sender, MouseEventArgs args)
The element that is responsible for firing the event.
argsMouseEventArgsA MouseEventArgs that contains the event data.
Raises the event.
protected virtual void OnFloatingStripCreated(object sender)
The element that is responsible for firing the event - usually this is the strip that is made floating.
Raises the event.
Raises the event.
protected virtual void OnFloatingStripDocked(object sender)
The element that is responsible for firing the event - usually this is the strip that was docked.
Raises the event.
Raises the event.
protected virtual bool OnOrientationChanging(CancelEventArgs e)
A CancelEventArgs that contains the event data.
Returns:True if the change of orientation should be canceled, false otherwise.
Handles the tunneling of events, particularly image list changes for floating forms.
protected override void OnTunnelEvent(RadElement sender, RoutedEventArgs args)
The RadElement that initiated the event.
argsRoutedEventArgsThe event data.
Overrides:
Saves the visual state of the RadCommandBarElement to a specified stream.
Saves the visual state of the RadCommandBarElement to a specified file.
public void SaveLayout(string filename)
The name of the destination file.
Saves the visual state of the RadCommandBarElement to a specified XmlWriter.
public void SaveLayout(XmlWriter writer)
The XmlWriter to save the visual state data.
Creates an XmlDocument containing the current visual state data of the RadCommandBarElement.
protected void SetOrientationCore(Orientation newOrientation)
protected virtual void UnwireEvents()
protected virtual void WireEvents()
Events
Occurs before dragging is started.
public event CancelEventHandler BeginDragging
Occurs when item is being dragged.
public event MouseEventHandler Dragging
Occurs when item is released and dragging is stopped.
public event EventHandler EndDragging
Occurs when a floating strip is created.
public event EventHandler FloatingStripCreated
Occurs before a floating form is created.
public event CancelEventHandler FloatingStripCreating
Occurs when a floating strip is docked.
public event EventHandler FloatingStripDocked
Occurs before a floating strip is docked.
public event CancelEventHandler FloatingStripDocking
Occurs when Orientation property is changed.
public event EventHandler OrientationChanged
Occurs before Orientation property is changed.
public event CancelEventHandler OrientationChanging