org.gnu.gtk
Class Menu
A Menu is a MenuShell that implements a drop down menu consisting of a list
of MenuItem objects which can be navigated and activated by the user to
perform application functions.
Menu() - Create a new Menu.
|
Menu(Handle handle) - Create a new Menu from a handle to a native resource.
|
void | detach() - Detaches the menu from the widget to which it had been attached.
|
ArrayList | getAttachedMenus() - Returns a list of the menus which are attached to this widget.
|
static Menu | getMenu(Handle handle) - Create a new Menu from a handle to a native resource.
|
String | getTitle() - Returns the title of the menu.
|
static Type | getType() - Retrieve the runtime type used by the GLib library.
|
void | popup() - Displays a menu and makes it available for selection.
|
void | reorderMenuItem(MenuItem child, int position) - Move a MenuItem to a new position within the Menu.
|
void | setAccelGroup(AccelGroup accelGroup) - Set the AccelGroup which holds global accelerators for the menu.
|
void | setTitle(String title) - Sets the title string for this Menu.
|
activateItem , append , cancel , deactivate , deselect , getTakeFocus , getType , insert , prepend , selectFirst , selectItem , setTakeFocus |
add , addListener , getBorderWidth , getChildren , getEventListenerClass , getEventType , getResizeMode , getType , remove , removeListener , resizeChildren , setBorderWidth , setResizeMode |
activate , addAccelerator , addEvents , addListener , addListener , addListener , addListener , addListener , addListener , addListener , addListener , addListener , addListener , addListener , canActivateAccel , createContext , createLayout , draw , drawArea , drawArea , finish , getAccessible , getAllocation , getCanFocus , getColormap , getContext , getData , getDisplay , getDragData , getEventListenerClass , getEventType , getExtensionEvents , getModifierStyle , getName , getParent , getParentWindow , getPointer , getRootWindow , getScreen , getSensitive , getStyle , getToplevel , getType , getWidget , getWindow , grabDefault , grabFocus , hasFocus , hasScreen , hide , hideAll , highlight , highlight , intersect , isAncestor , makeWidget , modifyStyle , popColormap , pushColormap , realize , removeAccelerator , removeListener , removeListener , removeListener , removeListener , removeListener , removeListener , removeListener , removeListener , removeListener , removeListener , removeListener , reparent , setBackgroundColor , setBaseColor , setCanFocus , setColormap , setDoubleBuffered , setDragDestination , setDragIcon , setDragIconPixbuf , setDragIconStock , setDragSource , setEvents , setExtensionEvents , setFont , setForegroundColor , setMinimumSize , setName , setNoDragDestination , setNoDragSource , setSensitive , setTextColor , shapeCombineMask , show , showAll , unHighlight , unHighlight |
addEventHandler , addEventHandler , addEventHandler , addEventHandler , addEventHandler , addEventHandler , addEventHandler , addListener , collect , freezeNotify , getBooleanProperty , getData , getDoubleProperty , getEventListenerClass , getEventType , getFloatProperty , getGObjectFromHandle , getIntProperty , getJavaObjectProperty , getLongProperty , getPixbufProperty , getProperty , getStringProperty , hasProperty , notify , removeEventHandler , removeListener , setBooleanProperty , setData , setDoubleProperty , setFloatProperty , setIntProperty , setJavaObjectProperty , setLongProperty , setPixbufProperty , setProperty , setStringProperty , thawNotify |
Menu
public Menu()
Create a new Menu.
Menu
public Menu(Handle handle)
Create a new Menu from a handle to a native resource.
detach
public void detach()
Detaches the menu from the widget to which it had been attached.
getAttachedMenus
public ArrayList getAttachedMenus()
Returns a list of the menus which are attached to this widget.
getMenu
public static Menu getMenu(Handle handle)
Create a new Menu from a handle to a native resource.
getTitle
public String getTitle()
Returns the title of the menu.
getType
public static Type getType()
Retrieve the runtime type used by the GLib library.
- getType in interface MenuShell
popup
public void popup()
Displays a menu and makes it available for selection. Applications can
use this method to provide context-sensitive menus.
reorderMenuItem
public void reorderMenuItem(MenuItem child,
int position)
Move a MenuItem to a new position within the Menu.
child
- The MenuItem to be moved.position
- The new position to place the MenuItem.
setAccelGroup
public void setAccelGroup(AccelGroup accelGroup)
Set the AccelGroup which holds global accelerators for the menu. The
accelerator group needs to also be added to all windows that this menu is
being used in.
accelGroup
- The AccelGroup to be associated with this Menu.
setTitle
public void setTitle(String title)
Sets the title string for this Menu. The title is displayed when the menu
is shown as a tearoff menu.
title
- The title for the Menu.