IupRadio

Creates a void container for grouping mutual exclusive toggles. Only one of its descendent toggles will be active at a time. The toggles can be at any composition.

It does not have a native representation.

Creation

Ihandle* IupRadio(Ihandle *child); [in C]
iup.radio{child: ihandle} -> (ih: ihandle) [in Lua]
radio(child) [in LED]

child: Identifier of an interface element. Usually it is a vbox or an hbox containing the toggles associated to the radio. It can be NULL (nil in Lua), not optional in LED.

Returns: the identifier of the created element, or NULL if an error occurs.

Attributes

EXPAND (non inheritable): The default value is "YES".

VALUE (non inheritable): name identifier of the active toggle. The name is set by means of IupSetHandle. In Lua you can also use the element reference directly. When consulted if the toggles are not mapped into the native system the return value may be NULL or invalid.

VALUE_HANDLE (non inheritable): Changes the active toggle. The value passed must be the handle of a child contained in the radio. When consulted if the toggles are not mapped into the native system the return value may be NULL or invalid. (since 3.0)

WID (read-only): returns -1 if mapped.


FONT, CLIENTSIZE, CLIENTOFFSET, POSITION, MINSIZE, MAXSIZE, VISIBLE: also accepted.

Notes

The radio can be created with no elements and be dynamic filled using IupAppend or IupInsert

A toggle that is a child of an IupRadio automatically receives a name when its is mapped into the native system.  (since 3.16)

Currently IupFlatButton with TOGGLE=YES, IupToggle, and IupGLToggle are affected when inside a IupRadio.

The IGNORERADIO can be used in any of these children types to disable this functionally. (since 3.21)

Examples

Browse for Example Files