PRadioButtons
(Dialog Library)
Description: |
Parameter Setting Radio Buttons. This module draws a set of labeled radio buttons with optional title and border.
|
Returns: | Nothing |
Usage: | Steady State only. |
Function Groups: | Graphics |
Related to: | GUITransform | PAddressEntry | PAlmPriority | PAreaSelect | PCheckBox | PColorEdit | PColorSelect | PContributor | PDroplist | PEditField | PEditName | PFileChooser | PFileChooser | PHSliderBar | PHueSelect | PImageSelect | PIPAddressList | PIPListenerGroup | PMultiCheckBox | PPageSelect | PPhraseEdit | PSecBit | PSelectObject | PServerListName | PSpinbox | PTimeZone | PTypeToggle | SiteDispParms |
Format: | \DialogLibrary.PRadioButtons(ParmNum, FocusID, Border, Title, Options, AlignTitle, L0 [, L1, ..., L15]) |
Parameters: |
ParmNum |
Required. Any numeric expression giving the parameter number (from 0) in the caller to alter. |
FocusID |
Boolean. If this value is FALSE (0), the field will display its current setting, but cannot be opened (i.e. its value cannot be changed), and will appear disabled (grayed-out). |
Border |
Numeric that may have the following values: 0 = No outline (default) 1 = Raised box outline 2 = Bevel outline |
Title |
Any text expression to be used as a title with the radio buttons. The default value is to have no title. |
Options |
A bit-wise expression. Bit 0 controls left/right placement of the buttons. If set, buttons will be placed to the left of the labels. Bit 1 controls vertical/horizontal orientation. If set, the radio buttons will be displayed horizontally. Bit 0 has no effect while bit 1 is set. Bit 2, if set, causes the radio buttons to adopt a "standard" vertical spacing of 5 pixels. Defaults to 0 - neither bit set. |
AlignTitle |
Any logical expression; if TRUE (non-0) the title is drawn within the radio buttons' boundaries, if FALSE (0) the buttons fill their bounding area and the title is added at the top (i.e. it extends past the top boundary). The default is true. |
L0 |
Labels. The number of labels determines the number of buttons displayed. At least two must be provided. If L0 is an individual label, then up to L15 individual labels may follow. If L0 is an array of labels, L1 may (optionally) be defined as an array of Return values, similar to the return array in PDropList. |
L1 |
A flexible parameter. If L0 is an array, this may contain a matching array of return values. Otherwise, this may contain the second label. |
L2 |
A flexible parameter. This may contain a logical expression indicating (when TRUE) that expressions should not be translated. Or, this may be the third label. |
L3...L15 |
The remaining labels, if any. |
Comments: |
This module is a member of the VTScada Dialog Library and must therefore be called from within a GUITransform and prefaced by \DialogLibrary.. Usual height: varies according to number of buttons. Seldom less than 50px. |
Example:
GUITransform(50, 400, 450, 100, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, \DialogLibrary.PRadioButtons(7 { Parm num }, TRUE { Focus ID }, TRUE { Draw a border }, "" { No title required }, 0 { Buttons on right }, Invalid { Not req'd title) }, \GetPhrase("OnLabel"), \GetPhrase("OffLabel"), \GetPhrase("ServiceLabel") { Labels }));