Aztec® Programming Language
Version 1.1 Alpha 2

Copyright © 2010-2017, Aztec Development Group, All Rights Reserved

Download Aztec

Search        Contact Us

Well let the fires burn...

Let the floods return...

We will prevail.

- Jackson Browne

 

aztec.ui.MenuBar

public class MenuBar from<SelectBar>

Base

Window

SelectBar

MenuBar

The MenuBar class represents a single menu page within a frame or dialog menu system. A MenuBar object has a parent of Dialog, Frame, ParentFrame or MenuItem. Using a MenuItem object as the parent is how a sub menu is tied to a menu item..

 

Note that the MenuBar class currently has some problems with the ChildFrame and ParentFrame classes, but works well with the Frame and Dialog classes.

 

The MenuItem class (or a class derived from it) is the only valid child window for the MenuBar class.

Valid Child Windows for MenuBar

MenuBar Methods

MenuBar() Constructor for the MenuBar class
AddSeparator() Virtual method to add a separator to the menu bar
NumSeparators() Virtual method to return number of separators in the menu bar
NumItems() Virtual method to return number of "menu items" attached to the menu bar

Derived Classes

See Also

 


MenuBar()

public method MenuBar(Window Parent)

Parameters

Parent

Parent window of the menu bar

Return Value

None

Description

Constructor for the MenuBar class. The parent must be specified, and it must be a Dialog, Frame, ParentFrame or MenuItem window type (or derived from one of those). The MenuItem parent is used to tie a sub menu to a menu item.

 

MenuBar Class


AddSeparator()

public virtual method<int> AddSeparator(int Index = 0)

Parameters

Index

Will be added before the one based index. Zero means add to end.

Return Value

One based index where separator was added

Description

This virtual method adds a separator to the menu bar. The specified index is one based, and the separator gets added before that index. If the index is zero (default), the separator gets added to the end.

 

MenuBar Class


NumSeparators()

public virtual method<int> NumSeparators()

Parameters

None

Return Value

Number of separators in the menu bar

Description

This virtual method returns the number of separators which have been added to the menu bar.

 

MenuBar Class


NumItems()

public virtual method<int> NumItems()

Parameters

None

Return Value

Number of "MenuItem" objects attached to menu bar

Description

This virtual method returns the number of "MenuItem" objects which are attached to this menu bar object. It does not include separators.

 

MenuBar Class


GetItem()

public virtual method<SelectItem> GetItem(int Index)

Parameters

Index

One based index for the item

Return Value

Reference to MenuItem object or null

Description

This virtual method returns a reference to the MenuItem object associated with the specified one based index. If the index refers to a separator (or if the index is not valid), a null will be returned. A valid index will be in the range from one to the total of (separators + items).

 

This MenuBar implementation of this method will return a MenuItem reference.

 

MenuBar Class

 

Copyright © 2010-2017

Aztec Development Group

All Rights Reserved

Download Aztec