C1ToolbarDropDown control represents a drop-down button on the C1ToobarStrip.
When clicking it displays popup panel with Content property or context menu set by Menu property.
Namespace:
C1.Silverlight.ToolbarAssembly: C1.Silverlight.Toolbar (in C1.Silverlight.Toolbar.dll)
Syntax
C# |
---|
[TemplatePartAttribute(Name = "HorizontalTemplate", Type = typeof(Grid))] [TemplatePartAttribute(Name = "VerticalTemplate", Type = typeof(Grid))] public class C1ToolbarDropDown : C1DropDown, IC1ToolbarControl |
Visual Basic |
---|
<TemplatePartAttribute(Name := "HorizontalTemplate", Type := GetType(Grid))> _ <TemplatePartAttribute(Name := "VerticalTemplate", Type := GetType(Grid))> _ Public Class C1ToolbarDropDown _ Inherits C1DropDown _ Implements IC1ToolbarControl |
Remarks
Examples
Example 1.
Drop-down with popup stack panel with buttons.
Example 2.
Dropdown with popup menu.
Copy CodeC#
> <c1:C1ToolbarDropDown Padding="2" Header="Color"> <c1:C1ToolbarDropDown.Content> <StackPanel Margin="2" Orientation="Horizontal"> <Button Margin="2" Content="Red" Foreground="Red" /> <Button Margin="2" Content="Green" Foreground="Green" /> <Button Margin="2" Content="Blue" Foreground="Blue" /> </StackPanel> </c1:C1ToolbarDropDown.Content> </c1:C1ToolbarDropDown> |
Copy CodeC#
> <c1:C1ToolbarDropDown Padding="2" Header="Color"> <c1:C1ToolbarDropDown.Menu> <c1:C1ContextMenu> <c1:C1MenuItem IsCheckable="True" Header="Red" HeaderForeground="Red" /> <c1:C1MenuItem IsCheckable="True" Header="Green" HeaderForeground="Green" /> <c1:C1MenuItem IsCheckable="True" Header="Blue" HeaderForeground="Blue" /> </c1:C1ContextMenu> </c1:C1ToolbarDropDown.Menu> </c1:C1ToolbarDropDown> |
Inheritance Hierarchy
System..::..Object
System.Windows..::..DependencyObject
System.Windows..::..UIElement
System.Windows..::..FrameworkElement
System.Windows.Controls..::..Control
System.Windows.Controls..::..ContentControl
C1HeaderedContentControl
C1DropDownButton
C1DropDown
C1.Silverlight.Toolbar..::..C1ToolbarDropDown
C1.Silverlight.Toolbar..::..C1ToolbarSplitButton
System.Windows..::..DependencyObject
System.Windows..::..UIElement
System.Windows..::..FrameworkElement
System.Windows.Controls..::..Control
System.Windows.Controls..::..ContentControl
C1HeaderedContentControl
C1DropDownButton
C1DropDown
C1.Silverlight.Toolbar..::..C1ToolbarDropDown
C1.Silverlight.Toolbar..::..C1ToolbarSplitButton