The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

IUP::Gauge - [GUI element] shows a percent value that can be updated to simulate a progression

DESCRIPTION

Creates a Gauge control. Shows a percent value that can be updated to simulate a progression. It inherits from IUP::Canvas.

It is recommended that new applications use the IUP::ProgressBar control.

USAGE

CREATION - new() method

 $gauge = IUP::Gauge->new( MIN=>0, MAX=>100 );

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.

ATTRIBUTES

For more info about concept of attributes (setting/getting values etc.) see IUP::Manual::03_Attributes. Attributes specific to this element:

DASHED

Changes the style of the gauge for a dashed pattern. Default is "NO".

FGCOLOR

Controls the gauge and text color. The default is "64 96 192".

MAX

(non inheritable) Contains the maximum value. Default is "1".

MIN

(non inheritable) Contains the minimum value. Default is "0".

PADDING

internal margin. Works just like the MARGIN attribute of the IUP::Hbox and IUP::Vbox containers, but uses a different name to avoid inheritance problems. Default value: "0x0".

SHOW_TEXT

Indicates if the text inside the Gauge is to be shown or not. If the gauge is dashed the text is never shown. Possible values: "YES" or "NO". Default: "YES".

SIZE

(non inheritable) The initial size is "120x14". Set to undef to allow the automatic layout use smaller values.

TEXT

(non inheritable) Contains a text to be shown inside the Gauge when SHOW_TEXT=YES. If it is undef, the percentage calculated from VALUE will be used. If the gauge is dashed the text is never shown.

VALUE

(non inheritable) Contains a number between "MIN" and "MAX", controlling the current position.

The following common attributes are also accepted:

CALLBACKS

For more info about concept of callbacks (setting callback handlers etc.) see IUP::Manual::04_Callbacks. Callbacks specific to this element:

common callbacks are supported: MAP_CB, UNMAP_CB

EXAMPLES

The element IUP::Gauge is used in the following sample scripts:

SEE ALSO

IUP::Canvas

The original doc: iupgauge.html