3D PLM Enterprise Architecture

User Interface - Dialogs

CATDlgSubmenu

Makes menus and submenus
Quick Reference

CATDialog
  |
  +---CATDlgMenu
        |
        +---CATDlgSubMenu

The Menu and the Submenu
CATDlgSubMenu.jpg (6585 bytes) A menu, such as Tools, is displayed in the menu bar and, when clicked, displays the list of menu items it contains. The submenu, or child menu, such as Image, is a menu displayed beside a menu, called the parent menu, when the end user clicks the submenu caption in the parent menu. It features an arrowhead pointing to the right. A menu or a submenu is made of other submenus, and of push items, check items, radio items, and separators. The CATDlgSubMenu class is dedicated to both menus and submenus.

Use menus and submenus whenever you want to create or enrich the menu bar.


Inheritance
A menu or a submenu instance parent must be an instance of the CATDlgMenu class.

Styles
Name Description
default The submenu cannot be detached from its parent menu. Applies to menus and submenus
CATDlgMnuPinnable The submenu can be detached from its parent menu, and becomes a dialog box. Applies to menus and submenus. This is available with UNIX only.
Such menus are displayed with a dash line at the top Dragging this dash line converts the submenu into a dialog box
CATDlgSubMenuU2.jpg (8070 bytes) CATDlgSubMenuU5.jpg (3285 bytes)
CATDlgMnuHelp The menu is located at the utmost right position in the menu bar, such as the Help menu below. Applies to menus only. This is available with UNIX only.

CATDlgSubMenuU1.jpg (4922 bytes)


Programmer's Guide

A CATDlgSubMenu can be the parent of CATDlgSubMenu, CATDlgPushItem, CATDlgCheckItem, CATDlgRadioItem, and CATDlgSeparatorItem instances.

Constructing a Menu or a Submenu

A menu or submenu can be constructed as follows.

default
_pDefaultSubMenu = new CATDlgSubMenu(iParent, iName);
Pinnable
_pPinnableSubMenu = new CATDlgSubMenu(iParent, iName, CATDlgMnuPinnable);
Right menu
_pHelpMenu = new CATDlgSubMenu(iParent, iName, CATDlgMnuHelp);

Setting a Title to a Menu or a Submenu

The menu or submenu title should be set by the resource file using a key built with the identifier you declare as the second parameter of the menu or submenu constructor.

[Top]


History

Version: 1 [Jan 2000] Document created
[Top]

Copyright © 2000, Dassault Systèmes. All rights reserved.