Share

ToolBarSource Class

Description

The toolbar data source.

Architecturally a toolbar is divided into data elements, which provide the content of the toolbar, and visual elements, which provide the display and interaction between the data elements and the user. The data elements consist of the following data items:

  • a validated collection of RibbonItems to populate the toolbar
  • a collection of RibbonMenuItems to populate the additional commands in the customize menu
The visual elements of the toolbar consist of the following items:
  • a collection of controls, one per RibbonItem
  • an access point to the overflow controls
  • a collection of overflow controls
  • an access point to the toolbar�s context menu
  • a context menu to control the visibility of the controls, plus additional commands
The data elements are linked to and drive the visual elements using the concept of Data Binding.

The ToolBarSource class has the responsibility of maintaining:

  • a validated collection of all ribbon items contained within the toolbar.
  • a collection of commands that are added to the customization menu for the toolbar.
It must also ensure that the following are valid:
  1. id.
  2. minimum width.
  3. maximum width
  4. specified height.
  5. enabled state.
  6. visibility state.
  7. resize priority.
Its content property is Items.

Class Hierarchy

Autodesk.Windows.ToolBars.ToolBarSource
    Autodesk.Windows.ToolBars.QuickAccessToolBarSource
    Autodesk.Windows.ToolBars.StatusBarSource

Visual Basic

Public Class ToolBarSource
Inherits ICloneable
Inherits IToolBarCustomization
Inherits INotifyPropertyChanged

C#

public class ToolBarSource : ICloneable, IToolBarCustomization, INotifyPropertyChanged;

Links

ToolBarSource Properties, ToolBarSource Events

Was this information helpful?