Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


Panel
titleGeneral

Component Palette Icon:




Panel
borderStylesolid
titleDescription

The Button component is a versatile component, often used for things like opening/closing windows, writing to tags, and triggering any sort of scripting logic. It can be used for showing status, as well. For example, if you have three buttons, Hand, Off, and Auto, not only can they set those modes, but their background color can display the current mode, although you'd be better off using the Multi-State Button for this. 

 To get buttons to do things, you add an event handler to the actionPerformed event. Many new users to the 1.0.0 module will configure an event handler for the mouseClicked event instead. While this will work, it is better to use the actionPerformed event. Why? Buttons can also be activated by tabbing over to them and hitting the space key, or they could be activated by pressing Alt and the button's mnemonic character. So, to make sure that your button works in all of these cases, configure your event handler on the actionPerformed event, not the mouseClicked event.



Panel
titleProperties


SQL
noDataMessageThere is no data in the database corresponding to this component.
columnLabeltrue
width100%
dataSourcemySQL_confluence
CALL getComponentProperties("Button");




Panel
titleScripting


Panel
titleScripting Functions

This component does not have scripting functions associated with it.Remove the panel below if there are no scripting functions.

Panel
title.doClick()
  • Description

Virtually "clicks" the button, meaning that its actionPerformed event handler will run.

  • Parameters

Nothing

  • Return

Nothing

  • Scope

Client



Panel
titleEvent Handlers


Expand
titleaction


SQL
p1Alarm Status Table
columnLabeltrue
width100%
dataSourcemySQL_mesconfluence
CALL getEventProperties('Button', 'action','actionPerformed');


Expand
titleactionPerformed

Desc_focusgained
Nametest




Expand
titlefocus


Expand
titlefocusGained

Desc_focusgained
Nametest

SQL
p1Alarm Status Table
columnLabeltrue
width100%
dataSourcemySQL_confluence
CALL getEventProperties('Button', 'Focus','focusGained');



Expand
titlefocusLost

Desc_focuslost
Nametest

SQL
p1Alarm Status Table
columnLabeltrue
width100%
dataSourcemySQL_confluence
CALL getEventProperties('Button', 'Focus','focusLost');




Expand
titlekey


Expand
titlekeyPressed

Desc_keypressed
Nametest

SQL
p1Alarm Status Table
columnLabeltrue
width100%
dataSourcemySQL_confluence
CALL getEventProperties('Button', 'Key','keyPressed');



Expand
titlekeyReleased

Desc_keyreleased
Nametest

SQL
p1Alarm Status Table
columnLabeltrue
width100%
dataSourcemySQL_confluence
CALL getEventProperties('Button', 'Key','keyReleased');



Expand
titlekeyTyped

Desc_keytyped
Nametest

SQL
p1Alarm Status Table
columnLabeltrue
width100%
dataSourcemySQL_confluence
CALL getEventProperties('Button', 'Key','keyTyped');




Expand
titlemouse


Expand
titlemouseClicked

Desc_mouseclicked
Nametest

SQL
p1Alarm Status Table
columnLabeltrue
width100%
dataSourcemySQL_confluence
CALL getEventProperties('Button', 'mouse','mouseClicked');



Expand
titlemouseEntered

Desc_mouseentered
Nametest

SQL
p1Alarm Status Table
columnLabeltrue
width100%
dataSourcemySQL_confluence
CALL getEventProperties('Button', 'mouse','mouseEntered');



Expand
titlemouseExited

Desc_mouseexited
Nametest

SQL
p1Alarm Status Table
columnLabeltrue
width100%
dataSourcemySQL_confluence
CALL getEventProperties('Button', 'mouse','mouseExited');



Expand
titlemousePressed

Desc_mousepressed
Nametest

SQL
p1Alarm Status Table
columnLabeltrue
width100%
dataSourcemySQL_confluence
CALL getEventProperties('Button', 'mouse','mousePressed');



Expand
titlemouseReleased

Desc_mousereleased
Nametest

SQL
p1Alarm Status Table
columnLabeltrue
width100%
dataSourcemySQL_confluence
CALL getEventProperties('Button', 'mouse','mouseReleased');




Expand
titlemouseMotion


Expand
titlemouseDragged

Desc_mousedragged
Nametest

SQL
p1Alarm Status Table
columnLabeltrue
width100%
dataSourcemySQL_confluence
CALL getEventProperties('Button', 'mouseMotion','mouseDragged');



Expand
titlemouseMoved

Desc_mousemoved
Nametest

SQL
columnLabeltrue
width100%
dataSourcemySQL_confluence
CALL getEventProperties('Button', 'mouseMotion','mouseMoved');




Expand
titlepropertyChange


Expand
titlepropertyChange

Desc_propertychange
Nametest

SQL
columnLabeltrue
width100%
dataSourcemySQL_confluence
CALL getEventProperties('Button', 'propertyChange','propertyChange');







Panel
titleCustomizers

This component does not have any custom properties.



Panel
titleExamples


Panel
titleStyled Button

Property NameValue
BorderEtched
FontDialog, Bold, 18
TextPress Me!
Image PathBuiltin/icons/48/check2.png



Panel
titleStyled Button

Property NameValue
BorderNo Border
Fill Area?False
Border Painted?False
TextNone
Image PathBuiltin/icons/48/stop.png