Class ToolBarAdv
Inheritance
Namespace: Syncfusion.Windows.Tools.Controls
Assembly: Syncfusion.Shared.Wpf.dll
Syntax
[SkinType(SkinVisualStyle = Skin.Office2007Black, Type = typeof(ToolBarAdv), XamlResource = "pack://application:,,,/Syncfusion.Shared.Wpf.Classic;component/Controls/ToolBarAdv/Themes/Office2007Black/Office2007BlackStyle.xaml")]
[SkinType(SkinVisualStyle = Skin.Metro, Type = typeof(ToolBarAdv), XamlResource = "pack://application:,,,/Syncfusion.Shared.Wpf.Classic;component/Controls/ToolBarAdv/Themes/Metro/MetroStyle.xaml")]
[SkinType(SkinVisualStyle = Skin.Office2010Blue, Type = typeof(ToolBarAdv), XamlResource = "pack://application:,,,/Syncfusion.Shared.Wpf.Classic;component/Controls/ToolBarAdv/Themes/Office2010Blue/Office2010BlueStyle.xaml")]
[SkinType(SkinVisualStyle = Skin.Office2007Silver, Type = typeof(ToolBarAdv), XamlResource = "pack://application:,,,/Syncfusion.Shared.Wpf.Classic;component/Controls/ToolBarAdv/Themes/Office2007Silver/Office2007SilverStyle.xaml")]
[SkinType(SkinVisualStyle = Skin.Transparent, Type = typeof(ToolBarAdv), XamlResource = "pack://application:,,,/Syncfusion.Shared.Wpf.Classic;component/Controls/ToolBarAdv/Themes/Transparent/TransparentStyle.xaml")]
[SkinType(SkinVisualStyle = Skin.Default, Type = typeof(ToolBarAdv), XamlResource = "/Syncfusion.Shared.Wpf;component/Controls/ToolBarAdv/Themes/Default/DefaultStyle.xaml")]
[SkinType(SkinVisualStyle = Skin.VS2010, Type = typeof(ToolBarAdv), XamlResource = "pack://application:,,,/Syncfusion.Shared.Wpf.Classic;component/Controls/ToolBarAdv/Themes/VS2010/VS2010Style.xaml")]
[SkinType(SkinVisualStyle = Skin.Office2010Black, Type = typeof(ToolBarAdv), XamlResource = "pack://application:,,,/Syncfusion.Shared.Wpf.Classic;component/Controls/ToolBarAdv/Themes/Office2010Black/Office2010BlackStyle.xaml")]
[SkinType(SkinVisualStyle = Skin.Office2010Silver, Type = typeof(ToolBarAdv), XamlResource = "pack://application:,,,/Syncfusion.Shared.Wpf.Classic;component/Controls/ToolBarAdv/Themes/Office2010Silver/Office2010SilverStyle.xaml")]
[SkinType(SkinVisualStyle = Skin.Office2007Blue, Type = typeof(ToolBarAdv), XamlResource = "pack://application:,,,/Syncfusion.Shared.Wpf.Classic;component/Controls/ToolBarAdv/Themes/Office2007Blue/Office2007BlueStyle.xaml")]
[SkinType(SkinVisualStyle = Skin.Blend, Type = typeof(ToolBarAdv), XamlResource = "pack://application:,,,/Syncfusion.Shared.Wpf.Classic;component/Controls/ToolBarAdv/Themes/Blend/BlendStyle.xaml")]
public class ToolBarAdv : ItemsControl
Constructors
ToolBarAdv()
Initializes a new instance of the Syncfusion.Windows.Tools.Controls.ToolBarAdv class.
Declaration
public ToolBarAdv()
Fields
BandIndexProperty
Identifies the Syncfusion.Windows.Tools.Controls.ToolBarAdv.BandIndex dependency property.
Declaration
public static readonly DependencyProperty BandIndexProperty
Field Value
Type | Description |
---|---|
System.Windows.DependencyProperty | The identifier for the Syncfusion.Windows.Tools.Controls.ToolBarAdv.BandIndex dependency property. |
BandProperty
Identifies the Syncfusion.Windows.Tools.Controls.ToolBarAdv.Band dependency property.
Declaration
public static readonly DependencyProperty BandProperty
Field Value
Type | Description |
---|---|
System.Windows.DependencyProperty | The identifier for the Syncfusion.Windows.Tools.Controls.ToolBarAdv.Band dependency property. |
ControlsResourceDictionaryProperty
Using a DependencyProperty as the backing store for ControlsResourceDictionary. This enables,styling, binding, etc...
Declaration
public static readonly DependencyProperty ControlsResourceDictionaryProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
EnableAddRemoveButtonProperty
Using a DependencyProperty as the backing store for EnableAddRemoveButton. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty EnableAddRemoveButtonProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
FloatingBarLocationProperty
Using a DependencyProperty as the backing store for FloatingBarLocation. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty FloatingBarLocationProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
GripperVisibilityProperty
Using a DependencyProperty as the backing store for ShowGripper. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty GripperVisibilityProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
IconProperty
Using a DependencyProperty as the backing store for Icon. This enables, styling, binding, etc...
Declaration
public static readonly DependencyProperty IconProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
IconTemplateProperty
Gets or sets a System.Windows.DataTemplate that determines the template to display an icon in a DropDownMenuItem loaded in overflow popup.
Declaration
public static readonly DependencyProperty IconTemplateProperty
Field Value
Type | Description |
---|---|
System.Windows.DependencyProperty | The System.Windows.DataTemplate value for the specified toolbar item to display an icon. The default value is null. |
Remarks
ToolBarAdv exposes IconTemplateProperty, IconProperty properties for setting the Icon. It loads icon in the following priority order,
IsAvailableProperty
Using a DependencyProperty as the backing store for IsAvailable. This enables , styling, binding, etc...
Declaration
public static readonly DependencyProperty IsAvailableProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
IsOverflowOpenProperty
Identifies the Syncfusion.Windows.Tools.Controls.ToolBarAdv.IsOverflowOpen dependency property.
Declaration
public static readonly DependencyProperty IsOverflowOpenProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
LabelProperty
Using a DependencyProperty as the backing store for Label. This enables,styling, binding, etc...
Declaration
public static readonly DependencyProperty LabelProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
OrientationProperty
Identifies the Syncfusion.Windows.Tools.Controls.Orientation dependency property.
Declaration
public static readonly DependencyProperty OrientationProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
OverflowButtonVisibilityProperty
Declaration
public static readonly DependencyProperty OverflowButtonVisibilityProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
OverflowModeProperty
Using a DependencyProperty as the backing store for OverFlowMode. This enables styling, binding, etc...
Declaration
public static readonly DependencyProperty OverflowModeProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
ToolBarItemInfoCollectionProperty
Identifies the Syncfusion.Windows.Tools.Controls.ToolBarAdv.ToolBarItemInfoCollectionProperty property.
Declaration
public static readonly DependencyProperty ToolBarItemInfoCollectionProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
ToolBarNameProperty
Using a DependencyProperty as the backing store for ToolBarName. This enables styling, binding, etc...
Declaration
public static readonly DependencyProperty ToolBarNameProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
Properties
Band
Declaration
public int Band { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 | The band of the Syncfusion.Windows.Tools.Controls.ToolBarTrayAdv in which the toolbaradv is positioned. The default is 0. |
BandIndex
Gets or sets the band index number that indicates the position of the toolbaradv on the band.
Declaration
public int BandIndex { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 | The position of a toolbaradv on the band of a Syncfusion.Windows.Tools.Controls.ToolBarTrayAdv. |
ControlsResourceDictionary
Gets or Sets resource dictionary from which ToolBarAdv will look up for framework element's styles
Declaration
public ResourceDictionary ControlsResourceDictionary { get; set; }
Property Value
Type |
---|
System.Windows.ResourceDictionary |
EnableAddRemoveButton
Gets or Sets the AddRemoveButton visibility for ToolBarAdv.
Declaration
public bool EnableAddRemoveButton { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | returns boolean value. The default value is false. |
FloatingBarLocation
Gets or Sets the location for floatingBar in ToolBarAdv .
Declaration
public Point FloatingBarLocation { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.Point | returns the x- and y-coordinate |
GripperVisibility
Gets or Sets a value indicating whether gripper can be visible
Declaration
public Visibility GripperVisibility { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.Visibility | returns visibility value. The default value is Visible. |
HasOverflowItems
Gets a value that indicates whether the toolbar has items that are not visible.
Declaration
public bool HasOverflowItems { get; }
Property Value
Type | Description |
---|---|
System.Boolean | true if there are items on the toolbar that are not visible; otherwise, false. The default is false. |
IsOverflowOpen
Gets or sets a value that indicates whether the Syncfusion.Windows.Tools.Controls.ToolBarAdv overflow area is currently visible.
Declaration
public bool IsOverflowOpen { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | true if the overflow area is visible; otherwise, false. |
Orientation
Gets and Sets Orientation of the Syncfusion.Windows.Tools.Controls.ToolBarAdv.
Declaration
public Orientation Orientation { get; }
Property Value
Type | Description |
---|---|
System.Windows.Controls.Orientation | The toolbaradv orientation. The default is Syncfusion.Windows.Tools.Controls.Orientation.Horizontal. |
OverflowButtonVisibility
Gets or sets a value indicating whether overflow button is visible or not.
Declaration
public Visibility OverflowButtonVisibility { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.Visibility | returns visibility. The default value is Visible. |
ToolBarItemInfoCollection
Gets or sets the items to be displayed in the AddRemove Buttons popup
Declaration
public ObservableCollection<ToolBarIteminfo> ToolBarItemInfoCollection { get; set; }
Property Value
Type |
---|
System.Collections.ObjectModel.ObservableCollection<ToolBarIteminfo> |
ToolBarName
Gets or Sets the name of the ToolBarAdv
Declaration
public string ToolBarName { get; set; }
Property Value
Type | Description |
---|---|
System.String | returns the string value |
Methods
ArrangeOverride(Size)
Provides the behavior for the Arrange pass of Silverlight layout. Classes can override this method to define their own Arrange pass behavior.
Declaration
protected override Size ArrangeOverride(Size finalSize)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.Size | finalSize | The final area within the parent that this object should use to arrange itself and its children. |
Returns
Type | Description |
---|---|
System.Windows.Size | The actual size that is used after the element is arranged in layout. |
GetContainerForItemOverride()
Creates or identifies the element that is used to display the given item.
Declaration
protected override DependencyObject GetContainerForItemOverride()
Returns
Type | Description |
---|---|
System.Windows.DependencyObject | The element that is used to display the given item. |
GetIcon(DependencyObject)
Gets the icon for addorRemove button menu
Declaration
public static ImageSource GetIcon(DependencyObject obj)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | obj | Get the value of Object System.Windows.DependencyObject |
Returns
Type | Description |
---|---|
System.Windows.Media.ImageSource | The value of the property. |
GetIconTemplate(DependencyObject)
Gets the IconTemplateProperty value of the specified toolbar item which holds the template to display an icon in a DropDownMenuItem loaded in overflow popup.
Declaration
public static DataTemplate GetIconTemplate(DependencyObject obj)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | obj | The element whose IconTemplateProperty must be retrieved. |
Returns
Type | Description |
---|---|
System.Windows.DataTemplate | The System.Windows.DataTemplate value of the specified toolbar item. |
Remarks
ToolBarAdv exposes IconTemplateProperty, IconProperty properties for setting the Icon. It loads icon in the following priority order,
GetIsAvailable(DependencyObject)
Gets a value indicating whether specified object is hidden
Declaration
public static bool GetIsAvailable(DependencyObject obj)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | obj | Get the value of object |
Returns
Type | Description |
---|---|
System.Boolean | The value of the property. |
GetIsOverflowItem(DependencyObject)
Reads the value of the Syncfusion.Windows.Tools.Controls.ToolBarAdv.IsOverflowItem property from the specified element.
Declaration
public static bool GetIsOverflowItem(DependencyObject obj)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | obj | The element from which to read the property |
Returns
Type | Description |
---|---|
System.Boolean | The value of the property. |
GetLabel(DependencyObject)
Gets the label that displayed in the addRemove buttons menu for a particualar item.
Declaration
public static string GetLabel(DependencyObject obj)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | obj | System.Windows.DependencyObject Read the value of property |
Returns
Type | Description |
---|---|
System.String | The value of the property. |
GetOverflowMode(DependencyObject)
Reads the value of the Syncfusion.Windows.Tools.Controls.ToolBarAdv.OverflowMode property from the specified item.
Declaration
public static OverflowMode GetOverflowMode(DependencyObject obj)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | obj | The element from which to read the property |
Returns
Type | Description |
---|---|
OverflowMode | The value of the OverflowMode property. |
MeasureOverride(Size)
Provides the behavior for the Measure pass of Silverlight layout. Classes can override this method to define their own Measure pass behavior.
Declaration
protected override Size MeasureOverride(Size availableSize)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.Size | availableSize | The available size that this object can give to child objects. Infinity (System.Double.PositiveInfinity) can be specified as a value to indicate that the object will size to whatever content is available. |
Returns
Type | Description |
---|---|
System.Windows.Size | The size that this object determines it needs during layout, based on its calculations of the allocated sizes for child objects; or based on other considerations, such as a fixed container size. |
OnApplyTemplate()
Builds the visual tree for the System.Windows.Controls.ItemsControl when a new template is applied.
Declaration
public override void OnApplyTemplate()
OnBandChanged(DependencyPropertyChangedEventArgs)
Called when BandIndex propery changed
Declaration
protected void OnBandChanged(DependencyPropertyChangedEventArgs args)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyPropertyChangedEventArgs | args | System.Windows.DependencyPropertyChangedEventArgs Provided the data for property changed event |
OnBandIndexChanged(DependencyPropertyChangedEventArgs)
Called when BandIndex property is changed
Declaration
protected void OnBandIndexChanged(DependencyPropertyChangedEventArgs args)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyPropertyChangedEventArgs | args | System.Windows.DependencyPropertyChangedEventArgs Provided the data for property changed event |
OnItemsChanged(NotifyCollectionChangedEventArgs)
Called when the value of the System.Windows.Controls.ItemsControl.Items property changes.
Declaration
protected override void OnItemsChanged(NotifyCollectionChangedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Specialized.NotifyCollectionChangedEventArgs | e | A System.Collections.Specialized.NotifyCollectionChangedEventArgs that contains the event data |
OnItemsSourceChanged(IEnumerable, IEnumerable)
invoked when ItemSource of ToolBarAdv changed
Declaration
protected override void OnItemsSourceChanged(IEnumerable oldValue, IEnumerable newValue)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.IEnumerable | oldValue | |
System.Collections.IEnumerable | newValue |
OnPropertyChanged(DependencyPropertyChangedEventArgs)
Called When the Property Changed
Declaration
protected override void OnPropertyChanged(DependencyPropertyChangedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyPropertyChangedEventArgs | e | Property change details, such as old value and new value |
PrepareContainerForItemOverride(DependencyObject, Object)
Prepares the specified element to display the specified item.
Declaration
protected override void PrepareContainerForItemOverride(DependencyObject element, object item)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | element | The element used to display the specified item. |
System.Object | item | The item to display. |
SetIcon(DependencyObject, ImageSource)
Set the icon for addRemove buttons menu
Declaration
public static void SetIcon(DependencyObject obj, ImageSource value)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | obj | System.Windows.DependencyObject Sets the value to object |
System.Windows.Media.ImageSource | value | The property value to set |
SetIconTemplate(DependencyObject, DataTemplate)
Sets the IconTemplateProperty value of the specified toolbar item which holds the template to display an icon in a DropDownMenuItem loaded in overflow popup.
Declaration
public static void SetIconTemplate(DependencyObject obj, DataTemplate value)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | obj | The element to which the IconTemplateProperty must be set. |
System.Windows.DataTemplate | value | The System.Windows.DataTemplate value of the specified toolbar item. |
Remarks
ToolBarAdv exposes IconTemplateProperty, IconProperty properties for setting the Icon. It loads icon in the following priority order,
SetIsAvailable(DependencyObject, Boolean)
Sets a value indicating whether specified object is hidden
Declaration
public static void SetIsAvailable(DependencyObject obj, bool value)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | obj | System.Windows.DependencyObject Sets the value to object |
System.Boolean | value | The property value to set |
SetLabel(DependencyObject, String)
Sets the label displayed in the add or remove buttons menu for a particualar item.
Declaration
public static void SetLabel(DependencyObject obj, string value)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | obj | System.Windows.DependencyObject Sets the value to object |
System.String | value | The property value to set. |
SetOverflowMode(DependencyObject, OverflowMode)
Set the value of the Syncfusion.Windows.Tools.Controls.ToolBarAdv.OverflowMode property to the specified element.
Declaration
public static void SetOverflowMode(DependencyObject obj, OverflowMode value)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | obj | The element to write the property to. |
OverflowMode | value | The Property Value to set |
Events
ToolBarStateChanged
Occurs when the state of the toolbar changes.
Declaration
public event EventHandler<ToolBarStateChangedEventArgs> ToolBarStateChanged
Event Type
Type |
---|
System.EventHandler<ToolBarStateChangedEventArgs> |