Source codeContentsIndex
Menu
Description
HTk's menus. A Menu is a container for menu structures.
Synopsis
data Menu = Menu GUIOBJECT (Ref Int)
class (GUIObject w) => HasMenu w where
menu :: Menu -> Config w
createMenu :: (GUIObject par) => par -> Bool -> [Config Menu] -> IO Menu
popup :: (GUIObject i) => Menu -> Position -> Maybe i -> IO ()
post :: Menu -> Position -> IO ()
unpost :: Menu -> IO ()
Documentation
data Menu
The Menu datatype.
Constructors
Menu GUIOBJECT (Ref Int)
Instances
Eq Menu
GUIObject Menu
Destroyable Menu
Widget Menu
Synchronized Menu
HasBorder Menu
HasColour Menu
HasFont Menu
class (GUIObject w) => HasMenu w where
Containers for menus (toplevel windows and menubuttons) instantiate the class HasMenu.
Methods
menu :: Menu -> Config w
Instances
(Window w) => HasMenu w
HasMenu MenuButton
HasMenu MenuCascade
createMenu :: (GUIObject par) => par -> Bool -> [Config Menu] -> IO Menu
popup
:: (GUIObject i)
=> Menu The menu to post.
-> Position The position to pop-up.
-> Maybe i An optional entry to activate when the menu pops-up.
-> IO () None.
Posts a menu (e.g. in respose of a keystroke or mousebutton press).
post
:: Menu the menu to post.
-> Position the position to post the menu at.
-> IO () None.
Displays a menu at the specified position.
unpost
:: Menu the menu to unmap.
-> IO () None.
Unmaps the menu.
Produced by Haddock version 0.3