monomer-1.4.0.0: A GUI library for writing native Haskell applications.
Copyright(c) 2018 Francisco Vallarino
LicenseBSD-3-Clause (see the LICENSE file)
Maintainerfjvallarino@gmail.com
Stabilityexperimental
Portabilitynon-portable
Safe HaskellNone
LanguageHaskell2010

Monomer.Widgets.Singles.Radio

Description

Radio widget, used for interacting with a fixed set of values. Each instance of the radio is associated with a single value. It does not include text, which can be added with a label in the desired position (usually with [hstack/vstack](Monomer.Widgets.Containers.Stack)). Alternatively, Monomer.Widgets.Singles.LabeledRadio provides this functionality out of the box.

radio Option1 optionLens

Monomer.Widgets.Singles.OptionButton provides similar functionality but with the look of a regular button.

Synopsis

Configuration

type RadioValue a = (Eq a, Typeable a) Source #

Constraints for numeric types accepted by the radio widget.

data RadioCfg s e a Source #

Configuration options for radio:

Instances

Instances details
Semigroup (RadioCfg s e a) Source # 
Instance details

Defined in Monomer.Widgets.Singles.Radio

Methods

(<>) :: RadioCfg s e a -> RadioCfg s e a -> RadioCfg s e a #

sconcat :: NonEmpty (RadioCfg s e a) -> RadioCfg s e a #

stimes :: Integral b => b -> RadioCfg s e a -> RadioCfg s e a #

Monoid (RadioCfg s e a) Source # 
Instance details

Defined in Monomer.Widgets.Singles.Radio

Methods

mempty :: RadioCfg s e a #

mappend :: RadioCfg s e a -> RadioCfg s e a -> RadioCfg s e a #

mconcat :: [RadioCfg s e a] -> RadioCfg s e a #

Default (RadioCfg s e a) Source # 
Instance details

Defined in Monomer.Widgets.Singles.Radio

Methods

def :: RadioCfg s e a #

CmbWidth (RadioCfg s e a) Source # 
Instance details

Defined in Monomer.Widgets.Singles.Radio

Methods

width :: Double -> RadioCfg s e a Source #

WidgetEvent e => CmbOnClick (RadioCfg s e a) e Source # 
Instance details

Defined in Monomer.Widgets.Singles.Radio

Methods

onClick :: e -> RadioCfg s e a Source #

WidgetEvent e => CmbOnChange (RadioCfg s e a) a e Source # 
Instance details

Defined in Monomer.Widgets.Singles.Radio

Methods

onChange :: (a -> e) -> RadioCfg s e a Source #

CmbOnClickReq (RadioCfg s e a) s e Source # 
Instance details

Defined in Monomer.Widgets.Singles.Radio

Methods

onClickReq :: WidgetRequest s e -> RadioCfg s e a Source #

WidgetEvent e => CmbOnBlur (RadioCfg s e a) e Path Source # 
Instance details

Defined in Monomer.Widgets.Singles.Radio

Methods

onBlur :: (Path -> e) -> RadioCfg s e a Source #

WidgetEvent e => CmbOnFocus (RadioCfg s e a) e Path Source # 
Instance details

Defined in Monomer.Widgets.Singles.Radio

Methods

onFocus :: (Path -> e) -> RadioCfg s e a Source #

CmbOnChangeReq (RadioCfg s e a) s e a Source # 
Instance details

Defined in Monomer.Widgets.Singles.Radio

Methods

onChangeReq :: (a -> WidgetRequest s e) -> RadioCfg s e a Source #

CmbOnBlurReq (RadioCfg s e a) s e Path Source # 
Instance details

Defined in Monomer.Widgets.Singles.Radio

Methods

onBlurReq :: (Path -> WidgetRequest s e) -> RadioCfg s e a Source #

CmbOnFocusReq (RadioCfg s e a) s e Path Source # 
Instance details

Defined in Monomer.Widgets.Singles.Radio

Methods

onFocusReq :: (Path -> WidgetRequest s e) -> RadioCfg s e a Source #

Constructors

radio :: (RadioValue a, WidgetEvent e) => a -> ALens' s a -> WidgetNode s e Source #

Creates a radio using the given lens.

radio_ :: (RadioValue a, WidgetEvent e) => a -> ALens' s a -> [RadioCfg s e a] -> WidgetNode s e Source #

Creates a radio using the given lens. Accepts config.

radioV :: (RadioValue a, WidgetEvent e) => a -> a -> (a -> e) -> WidgetNode s e Source #

Creates a radio using the given value and onChange event handler.

radioV_ :: (RadioValue a, WidgetEvent e) => a -> a -> (a -> e) -> [RadioCfg s e a] -> WidgetNode s e Source #

Creates a radio using the given value and onChange event handler. Accepts config.

radioD_ :: (RadioValue a, WidgetEvent e) => a -> WidgetData s a -> [RadioCfg s e a] -> WidgetNode s e Source #

Creates a radio providing a WidgetData instance and config.