FutureBasic Logo

<<    Index    >> FutureBasic

ProgressBar / ProgressIndicator   statement / function



Statement syntax
progressbar tag, value, rect, min, max, wndTag
progressindicator tag, value, rect, min, max, wndTag

Function syntax
value = progressbar(tag)
value = progressindicator(tag)

Description
The progressbar statement puts a new bar-style progress indicator in the current output window and the progressindicator statement a new spinning-style indicator. Both statements alter an existing indicator's characteristics. The progressbar and progressindicator functions return the bar/indicator current value and is equivalent to calling fn ProgressBarDoubleValue or fn ProgressIndicatorDoubleValue.

Note: All functions in the ProgressIndicator.incl header work for both indicator styles.

Parameters
Parameter
Description
tag A number (1 through 1000000) that you assign when you create the progress indicator and that you refer to when altering the indicator. The number you assign must be different from the tag value of all other existing widgets in the current window. A negative tag hides the indicator.
value The value that indicates the current extent of the indicator (default = 0).
rect The indicator's enclosing rectangle. This can be specified in either of two ways:
(i) (x,y,w,h) where x,y are the origin and w,h the size of the indicator.
(ii) A CGRect value
min The minimum value of the indicator (default = 0).
min The maximum value of the indicator (default = 100).
wndTag An optional parameter for when the indicator's window is not the current output window. Note specifying this parameter does not bring the window to the front or make it the output window.
 
Subclass
To subclass a nib progressbar or progressindicator, set its class name to "ProgressIndicatorSC" in the nib.
 

Apple documentation
NSProgressIndicator