Button

(part of package 'Bootstrap Components') Extends designtime/SolutionModel: JSWebComponent Extends runtime: RuntimeWebComponent

A simple button. It can contain text as well as (optionally) an icon before or after the text.

This is a reference page; many components have detailed usage guides here.

Properties

enabled

Whether the component is enabled or not; blocks onAction, onDoubleClick, onRightClick events.

Type: enabled Default Value: true


imageStyleClass

For buttons showing as plain text, you can also specify an image styleclass to be displayed to the left. Can be font awesome icons.

Type: styleclass


showAs

Option whether button text is shown as plain text, sanitized html or trusted html (as is).

Type: string


styleClass

Button style class, typically one of the bootstrap button classes (e.g. 'btn btn-primary')

Type: styleclass Default Value: "btn btn-default"


tabSeq

Tab sequence index of the form

Type: tabseq


text

The text shown for the button (i18n is supported)

Type: tagstring


toolTipText

Tooltip text shown when hovering over the button (i18n is supported)

Type: tagstring


trailingImageStyleClass

An icon style class property (glyphicon, material design or Font Awesome). Example 'fas fa-search' If you want to use Font Awesome classes you need to enable the Font Awesome service from the Servoy Package Manager.

Type: string


variant

Sets the variant of this button, this sets a certain set of styleclasses at runtime for which this variant is configured for

Type: variant


visible

Whether the button is visible or not

Type: visible


Events

onActionMethodID

Fired when the button is clicked

Parameters:

event JSEvent


onDoubleClickMethodID

Fired when the button is double clicked

Parameters:

event JSEvent


onRightClickMethodID

Fired when the button is right clicked

Parameters:

event JSEvent


API

requestFocus

Set the focus to this button.

@example

 myElement.requestFocus();

Last updated