IUP::Radio - [GUI element] container for grouping mutual exclusive toggles (radiobutton)
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.
$radio = IUP::Radio->new( child=>$box );
child: (named parameter) Reference to an interface element. Usually it is a IUP::Vbox or an IUP::Hbox containing the toggles associated to the radio. It can be undef.
undef
Returns: the identifier of the created element, or undef if an error occurs.
NOTE: You can pass to new() other ATTRIBUTE=>'value' or CALLBACKNAME=>\&func pairs relevant to this element - see IUP::Manual::02_Elements.
new()
ATTRIBUTE=>'value'
CALLBACKNAME=>\&func
For more info about concept of attributes (setting/getting values etc.) see IUP::Manual::03_Attributes. Attributes specific to this element:
(non inheritable)
The default value is "YES".
Name identifier or reference to the active toggle element. When consulted if the toggles are not mapped into the native system the return value may be undef or invalid.
ZZZ-test-this(reading the value)
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 undef or invalid.
(read-only)
Returns -1 if mapped.
The following common attributes are also accepted:
FONT, CLIENTSIZE, CLIENTOFFSET, POSITION, MINSIZE, MAXSIZE, VISIBLE
The radio can be created with no elements and be dynamic filled using Append or Insert.
The element IUP::Radio is used in the following sample scripts:
0-basic/cbox.pl - IUP::Cbox example
0-basic/image.pl - IUP::Image example
0-basic/layoutdialog.pl - IUP::LayoutDialog example
0-basic/radio.pl - IUP::Radio example
0-basic/toggle.pl - IUP::Toggle example
1-apps/app-mdi.pl - IUP app example
1-apps/app-sample1.pl - example used for screenshot - IUP.pod
1-apps/app-sample2.pl - example based on the original sample.c
1-apps/app-simple-demo.pl - example used for screenshot - IUP.pod
The original doc: iupradio.html
To install IUP, copy and paste the appropriate command in to your terminal.
cpanm
cpanm IUP
CPAN shell
perl -MCPAN -e shell install IUP
For more information on module installation, please visit the detailed CPAN module installation guide.