¤ popupMenuF
Types
popupMenuF :: (Graphic b, Eq b) => [(a, b)] -> F c d -> F (Either [(a, b)] c) (Either a d)
Synopsis
popupMenuF alts fudget
Description
popupMenuF provides a popup menu. The menu is normally hidden, but pops up when
the a specific mouse button is pressed over the fudget to which the popup
menu is attached, so that an item can be picked from the
menu. The menu is removed as soon as the mouse button is released.
Input
Left alts causes the current menu to be replaced by a new
list of alternatives alts.
Right y causes y to be passed to the argument fudget.
Output
Left x is output if menu item x is selected.
Right y is output if the argument fudget outputs y.
Arguments
alts :: [(a, b)]- A list of items to choose from. Each item is paired with
its visual representation (a string).
fudget :: F c d- The fudget in which the popup menu will be available.
See Also
buttonF,
menuF,
radioGroupF,
toggleButtonF.
Bugs
Fudget under construction. The type and meaning of Left x input
may change.