RibbonQuickAccessToolBar Class
Represents a quick-access toolbar control, used within a ActiproSoftware.Windows.Controls.Bars.RibbonQuickAccessToolBar.Ribbon.
[TemplatePart(Name = "PART_InlineCustomizeButton", Type = typeof(RibbonQuickAccessToolBarCustomizeButton))]
[TemplatePart(Name = "PART_InlineOverflowButton", Type = typeof(RibbonQuickAccessToolBarOverflowPanel))]
[TemplatePart(Name = "PART_OverflowCustomizeButton", Type = typeof(RibbonQuickAccessToolBarCustomizeButton))]
[TemplatePart(Name = "PART_OverflowPanel", Type = typeof(RibbonQuickAccessToolBarOverflowButton))]
public class RibbonQuickAccessToolBar : ItemsControl, IOverflowingItemsControl, IOrientedElement
- Inheritance:
- object Visual UIElement FrameworkElement Control ItemsControl object
- Implements:
- IOverflowingItemsControl IOrientedElement
Constructors
RibbonQuickAccessToolBar()
Initializes an instance of the class.
public RibbonQuickAccessToolBar()
Properties
AllowLabels
Indicates whether to allow labels on the items in the quick-access toolbar.
public bool AllowLabels { get; set; }
Property Value
- bool:
trueif labels should be allowed on the items in the quick-access toolbar; otherwise,false.
CommonItems
The collection of common items that are available to be quickly added or removed from the Customize button.
CustomizeButtonKeyTipText
The Customize button's key tip text.
[Localizability(LocalizationCategory.Label)]
public string? CustomizeButtonKeyTipText { get; set; }
Property Value
CustomizeButtonToolTip
The Customize button's tooltip.
IsCustomizeButtonVisible
Indicates whether the Customize button is visible.
public bool IsCustomizeButtonVisible { get; set; }
Property Value
- bool:
trueif theCustomizebutton is visible; otherwise,false.
IsInWindowTitleBar
Indicates whether the QAT is in the window's title bar.
public bool IsInWindowTitleBar { get; }
Property Value
- bool:
trueif the QAT is in the window's title bar; otherwise,false.
IsOverflowed
Indicates whether the control currently has overflowed items.
public bool IsOverflowed { get; }
Property Value
- bool:
trueif the control currently has overflowed items; otherwise,false.
KeyTipTextPrefix
The optional text to prefix the numbers used for QAT item key tip text.
public string? KeyTipTextPrefix { get; set; }
Property Value
Remarks
This property is useful when ribbon tab key tip text might start with a number that could conflict with the key tip text of a QAT item.
In that scenario, setting the prefix to a letter such as Q could prevent conflicts.
Location
A RibbonQuickAccessToolBarLocation that indicates the current location of the quick-access toolbar.
public RibbonQuickAccessToolBarLocation Location { get; set; }
Property Value
- RibbonQuickAccessToolBarLocation:
The default value is Below.
OverflowButtonKeyTipText
The Overflow button's key tip text.
[Localizability(LocalizationCategory.Label)]
public string? OverflowButtonKeyTipText { get; set; }
Property Value
OverflowButtonToolTip
The Overflow button's tooltip.
Methods
ClearContainerForItemOverride(DependencyObject, object)
When overridden in a derived class, undoes the effects of the PrepareContainerForItemOverride(DependencyObject, object) method.
protected override void ClearContainerForItemOverride(DependencyObject element, object item)
| Parameter | Type | Description |
|---|---|---|
| element | DependencyObject | The container element. |
| item | object | The item. |
GetContainerForItemOverride()
Creates or identifies the element that is used to display the given item.
protected override DependencyObject GetContainerForItemOverride()
Returns
- DependencyObject:
The element that is used to display the given item.
IsItemItsOwnContainerOverride(object)
Determines if the specified item is (or is eligible to be) its own container.
protected override bool IsItemItsOwnContainerOverride(object item)
| Parameter | Type | Description |
|---|---|---|
| item | object | The item to check. |
Returns
- bool:
trueif the item is (or is eligible to be) its own container; otherwise,false.
OnApplyTemplate()
When overridden in a derived class, is invoked whenever application code or internal processes call ApplyTemplate().
public override void OnApplyTemplate()
OnCreateAutomationPeer()
Returns class-specific AutomationPeer implementations for the Windows Presentation Foundation (WPF) infrastructure.
protected override AutomationPeer OnCreateAutomationPeer()
Returns
- AutomationPeer:
The type-specific AutomationPeer implementation.
OnKeyDown(KeyEventArgs)
Invoked when the KeyDown event is received.
protected override void OnKeyDown(KeyEventArgs e)
| Parameter | Type | Description |
|---|---|---|
| e | KeyEventArgs | Information about the event. |
OnPreviewGotKeyboardFocus(KeyboardFocusChangedEventArgs)
Invoked when an unhandled System.Windows.Input.Keyboard.PreviewGotKeyboardFocus attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event.
protected override void OnPreviewGotKeyboardFocus(KeyboardFocusChangedEventArgs e)
| Parameter | Type | Description |
|---|---|---|
| e | KeyboardFocusChangedEventArgs | The KeyboardFocusChangedEventArgs that contains the event data. |
OnPreviewLostKeyboardFocus(KeyboardFocusChangedEventArgs)
Invoked when an unhandled System.Windows.Input.Keyboard.PreviewKeyDown attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event.
protected override void OnPreviewLostKeyboardFocus(KeyboardFocusChangedEventArgs e)
| Parameter | Type | Description |
|---|---|---|
| e | KeyboardFocusChangedEventArgs | The KeyboardFocusChangedEventArgs that contains the event data. |
PrepareContainerForItemOverride(DependencyObject, object)
Prepares the specified element to display the specified item.
protected override void PrepareContainerForItemOverride(DependencyObject element, object item)
| Parameter | Type | Description |
|---|---|---|
| element | DependencyObject | Element used to display the specified item. |
| item | object | Specified item. |
Fields
AllowLabelsProperty
Defines the AllowLabels property.
public static readonly DependencyProperty AllowLabelsProperty
CommonItemsProperty
Defines the CommonItems property.
public static readonly DependencyProperty CommonItemsProperty
CustomizeButtonKeyTipTextProperty
Defines the CustomizeButtonKeyTipText property.
public static readonly DependencyProperty CustomizeButtonKeyTipTextProperty
CustomizeButtonToolTipProperty
Defines the CustomizeButtonToolTip property.
public static readonly DependencyProperty CustomizeButtonToolTipProperty
IsCustomizeButtonVisibleProperty
Defines the IsCustomizeButtonVisible property.
public static readonly DependencyProperty IsCustomizeButtonVisibleProperty
IsInWindowTitleBarProperty
Defines the IsInWindowTitleBar property.
public static readonly DependencyProperty IsInWindowTitleBarProperty
IsOverflowedProperty
Defines the IsOverflowed property.
public static readonly DependencyProperty IsOverflowedProperty
KeyTipTextPrefixProperty
Defines the KeyTipTextPrefix property.
public static readonly DependencyProperty KeyTipTextPrefixProperty
LocationProperty
Defines the Location property.
public static readonly DependencyProperty LocationProperty
OverflowButtonKeyTipTextProperty
Defines the OverflowButtonKeyTipText property.
public static readonly DependencyProperty OverflowButtonKeyTipTextProperty
OverflowButtonToolTipProperty
Defines the OverflowButtonToolTip property.
public static readonly DependencyProperty OverflowButtonToolTipProperty