powered by CADENAS

Manual

Manual

1.1.6.10.1.2. menustructure-config

In this config the structure of toolbars and menus is specified.

Block [Tweakmenu]

Menu specification

The menus are defined by three keys:

ExportMenuName=ExportMenu
ExportMenuTitle=&Export
ExportMenuContent=ExportCadMenu,-,ExportFileMenuStatic,-,ExportNative,ExportMetafileBatch
  • The name of the menu is stated in the key <name>MenuName.

    Example:

    ExportMenuName=ExportMenu
  • The title of the menu is stated in the key <name>MenuTitle.

    Example:

    ExportMenuTitle=&Export
    [Hinweis] Hinweis

    The key value of <name>MenuTitle (display name of the menu in the application) is translated in the file menustructure_<name of application>.def.

  • What actions (menu items) are grouped by the menu, is stated in the key <name>MenuContent. The items are separated by comma.

    Example:

    ExportMenuContent=ExportCadMenu,ExportFileMenuStatic

    If you want to insert a separator in a menu, you have to insert a minus "-" in the list of actions at the position you want a separator.

    Example:

    ExportMenuContent=ExportCadMenu,-,ExportFileMenuStatic,-,ExportNative,ExportMetafileBatch

Menu order

The values of the key menuOrder represent the desired sequence of the single menus.

menuOrder=FileMenu,ExportMenu,ErpMenu,ViewMenu,TableMenu,ConfiguratorMenu,ExtrasMenu,
 WindowMenu,HelpMenu,DebugMenu

Toolbar areas

The following keys represent the area of the toolbars in the QMainWindow and within the single keys the sequence of toolbars.

  • toolbarOrderTop

  • toolbarOrderRight

  • toolbarOrderLeft

  • toolbarOrderBottom

If an area contains more than one toolbar, then the names are listed comma separated.

If a toolbar shall be shown in a new line, then include a line break “\n” in the list.

Example:

toolbarOrderTop=Details,Export,\n,SAP
toolbarOrderLeft=Standard
toolbarOrderRight=Assembly
toolbarOrderBottom=ERP

This arrangement doesn't make sense but nicely illustrates the use.

This arrangement doesn't make sense but nicely illustrates the use.

Toolbar specification

The toolbars are defined by three keys:

ExportToolbar=MainWindow/Export
ExportToolbarTitle=Exportieren
ExportToolbarContent=ExportCad,ExportFileMenu
  • The name of the toolbar is stated in the key <name>Toolbar. If you want to set a toolbar in an area of a Mainwindow, you must add "Mainwindow/" in front of the name of the toolbar.

    Example:

    ExportToolbar=MainWindow/Export
  • The title of the toolbar is stated by the key <name>ToolbarTitle.

    Example:

    ExportToolbarTitle=Exportieren
  • What actions (buttons) are grouped by the toolbar, is stated by the key <name>ToolbarContent. The items are separated by comma.

    Example:

    ExportToolbarContent=ExportCad,ExportFileMenu

    If you want to insert a separator in a toolbar, you must insert a minus "-" in the list of actions at the position you want a separator.

    Example:

    #MiniToolbarContent=ViewPart,View2D,-,ExtrasPARTbom,-,ShowPreferences

Button layout

If you want to explicitly adjust the layout of the buttons, then set the value of “<name>ToolbarButtonStyle” on one of the following values:

Value Meaning
IconOnly Only display the icons of the buttons.
TextOnly Only display the text of the buttons.
TextBesideIcon The text appears beside the button icon.
TextUnderIcon The text appears under the button icon.

Example:

ExportToolbarButtonStyle=TextBesideIcon

Block [AltButtons]

In the block [AltButtons], those actions are stored, which are created with the “Altbutton” class. These actions are container for other actions.

[ALTBUTTONS]
ViewCPMenuName=ViewCPMenu
ViewCPMenuContent=ViewCP,ViewCPNot,ViewCPMarked

The key values are then used in the "<name of action>Content” keys in the [Tweakmenu] block.

[Tweakmenu]
...
AssemblyToolbarContent=ViewConfigurator,ViewExplosion,ViewAssemblyStructure,
 ExtrasAutomaticBuild,ViewCPMenu

Block [hasSubMenuActions]

In the block [hasSubMenuActions], all actions with an additional menu level are stored. The name of top level actions is set as key. The lower level actions are listed comma separated in the line. Here you can optionally hide subitems.