[Properties (by Name)] [Methods (by Name)] [Events (by Name)]
Menustrip class is the Parent class for MUI's object oriented menus.
Source position: MUIClass.Menu.pas line 18
type TMUIMenustrip = class(TMUIFamily) |
||
protected |
||
procedure GetCreateTags(); override; |
|
Fill TagList for MUI item creation |
public |
||
constructor Create; override; |
|
Create a MenuStrip object |
procedure CreateObject; override; |
|
Create the MUI item |
published |
||
property Enabled: Boolean; [rw] |
|
Enable or disable the complete menu strip. |
end; |
|
Menustrip class is the Parent class for MUI's object oriented menus. |
|
| | ||
|
Base class with list of children |
|
| | ||
|
Subclass of TNotify to introduce the Parent relation |
|
| | ||
|
Notify class is superclass of all other MUI classes. |
|
| | ||
|
Base class for all MUI Class |
|
| | ||
TObject |
Its children are objects of Menu class, each of them describes exactly one menu.
A Menustrip object doesn't feature many options itself, but as a subclass of Family class, it simply acts as father for multiple Menu objects.
The Menustrip object is usually specified as a child of either Application class or window class with the attributes MUIApp.MenuStrip or Window.MenuStrip.
Example:
MainMenu := TMUIMenuStrip.Create; // MUIApp.MenuStrip := MainMenu; // alternative on the application, activate only one! Window.Menustrip := MainMenu; Men := TMUIMenu.Create; with Men do begin Title := 'Test Menu'; // Name of Menu (thats the one in the ScreenBar) Parent := MainMenu; // attach to the Menustrip end; With TMUIMenuItem.Create do begin Title := 'Config'; // Text on the menu item Parent := Men; // attach to the Menu OnTrigger := @ConfigStart; // Event to call when selected end; with TMUIMenuItem.Create do begin Title := 'Quit'; Parent := Men; OnTrigger := @QuitMe; end;
|
Objects of menu class describe exactly one pulldown menu. |
|
|
Menuitem class describes a single menu item. |