.
Eloquence JDLG contact contact


JDLG object and attribute reference:
PushButton class

 
.
  Document revision: 2017-08-29
Refers to JDLG version: 1.7.6


Contents


The PushButton class implements a clickable button which returns its rule value to the program when clicked or activated by an accelerator key.

A PushButton displays a text label and optionally an icon image.

bgcolor : string, get/set
Note: Depending on the look-and-feel definition, it may be possible that setting the PushButton background color has no effect.

Please refer to the common bgcolor attribute documentation. See also fgcolor below.

border : integer, get/set
Provided for ASCII DLG backward compatibility.

The PushButton border visibility and thickness cannot be specified. A PushButton always has a (platform or look-and-feel specific) border.

The default value is 1.

class : string, get
Returns "PushButton".
fgcolor : string, get/set
Note: Depending on the look-and-feel definition, it may be possible that setting the PushButton foreground color has no effect.

Please refer to the common fgcolor attribute documentation. See also bgcolor above.

icon : string, get/set
Specifies the URL referring to an icon image in png, gif or jpg format, to be displayed in the PushButton.

If a relative URL is specified, the value of the Application.baseurl or System.baseurl attribute or eloquence.config.baseurl configuration property is prepended.

The default value is empty (icon image not specified).

See also iconpressed and textpos below.

iconpressed : string, get/set
Specifies the URL referring to an alternative icon image, to be displayed while the PushButton is clicked.

See also icon below.

rule : integer, get/set
The rule value, regardless if nonzero or zero, is returned to the program, along with the path of the PushButton object (see also ruleoverride below), when the PushButton is clicked or activated by an accelerator key.

The default rule value is zero.

See also the documentation of the common rule attribute.

ruleoverride : integer, get/set
If nonzero, the rule of a previously focused EditText or ComboBox object is overridden (the PushButton rule value combined with the EditText or ComboBox path is returned).

The default ruleoverride value is 1.

For details, please refer to the RuleOverride documentation below.

text : string, get/set
PushButton text.

If an & character occurs in the text, the next character or digit is used to define a corresponding accelerator key. The PushButton is then activated when pressing the ALT key along with this accelerator key.

textpos : string, get/set
Specifies the position of the PushButton text in relation to an icon image.

Possible values are:
 "left"
 "right"
 "top"
 "bottom"

The default textpos value is "right" if an icon image is specified.

Note: If no icon image is specified, the textpos attribute is ignored and the PushButton text is centered.

traversecr : integer, get/set
Zero (default): Pressing the ENTER key triggers a PushButton rule submission, as if the PushButton was clicked.

Nonzero: Pressing the ENTER key moves the focus to the next focusable object.


The ruleoverride attribute is present for object classes which may submit a rule value to the program when clicked with the mouse or activated with an accelerator key, for example the PushButton class (see the list below).

It defines the behavior when a mouse click or accelerator key activates for example a PushButton object and at the same time moves the keyboard focus away from an EditText or ComboBox object.

In this situation, the program should be notified about both the EditText or ComboBox and the PushButton event.

If the ruleoverride attribute value is zero, first the EditText or ComboBox rule is submitted to the program, along with the path of the EditText or ComboBox object.

The PushButton rule value is saved to be submitted immediately on the next DLG DO invocation, along with the path of the PushButton object, except if a DLG SET .focus is executed in between these two DLG DO invocations.

If the ruleoverride attribute value is nonzero, only the PushButton rule is submitted, along with the path of the EditText or ComboBox object. This way, both rule submissions are combined into a single submission.


Note: A special behavior is defined if a non-focusable object is clicked or activated with an accelerator key. A non-focusable object is an Image object or any object located in a ToolBar.

Activating a non-focusable object never moves the keyboard focus away from an EditText or ComboBox object, therefore only one rule submission takes place, in the example above with the PushButton rule value.

If the ruleoverride attribute value of the non-focusable object is zero, this submission uses the path of the PushButton object, if nonzero, it uses the path of the EditText or ComboBox object.


The object classes providing the ruleoverride attribute are:
CheckBox  default ruleoverride value = 0 
Image  default ruleoverride value = 1 (never focusable)
ListBox  default ruleoverride value = 0 
PushButton  default ruleoverride value = 1 
RadioButton  default ruleoverride value = 0 
TabBox  default ruleoverride value = 0 
Tree  default ruleoverride value = 0 


 
 
.
 
 
  Privacy | Webmaster | Terms of use | Impressum Revision:  2017-08-29  
  Copyright © 2002-2017 Marxmeier Software AG