Back


The Linguist swing package

This package is still under development. Contributions are welcome from anyone able to fill in some of the missing parts.

add border button color create
cursor deselect disable enable find
font hide image label move
on select set show style
textpanel window      

Numeric values
String values
Conditional expressions


Numeric Values

These values can be used in either a numeric or string expression:

the screen size/width/height
Returns the size, width or height of the screen. The latter two can be transferred to a variable and used in subsequent calculations, while the the screen size can only be used directly, as in set the size of Button1 to the size of Button2.

the left/top/right/bottom/width/height of {component}
Returns the appropriate measurement for the component.

the left/right/top/bottom inset of {component}
Returns the appropriate inset for the component. In the case of a window, this is the width or height of the frame border currently in effect.

the mouse left/top
Returns the current location of the mouse. This can only be used inside a callback generated as a result of a mouse event in a component - see on.

the key code
Returns an integer value being the code for the key just pressed. This can only be used inside a callback generated as a result of a key pressed or key released event in a component - see on.

Return to top


String Values

These values can be used in a string expression:

the key char
Returns the character for the key just pressed. This can only be used inside a callback generated as a result of a key typed event in a component - see on.

the target
Returns the contents of the tag that generated the callback we're in. - see style. This can only be used inside a callback generated as a result of a mouse click in a textpanel - see on.

Return to top


Back