toggleF :: Bool -> [(ModState, KeySym)] -> F a b -> F (Either Bool a) (Either Bool b)
toggleF inside keys lblF
toggleF
creates a toggle button. An argument fudgets determines the
label placed to the right of the button.
Left on
switches on or off the button. Right x
passes x
to the label fudget.
Left on
when the button is toggled. Right y
when the
label fudget outputs y
.
inside :: Bool
True
to put the label inside the button.
keys :: [(ModState, KeySym)]
lblF :: F a b
toggleF False [] nullF