
www.4dsystems.com.au
µ
V
G
A
-PICASO-
MD1
16
6.1.4
Text
b
utton
(
b
)
Serial Syntax :
cmd, state, x
(msb:lsb)
, y
(msb:lsb)
,
buttonColour,
font,
textColour, textWidth, textHeight, char1, .., charN, terminator
4DGL Syntax :
(refer to 4DGL programmers manual)
cmd :
62
hex
, b
ascii
state :
Specifies whether the displayed button is drawn as
UP
(not pressed) or
DOWN
(pressed). 0 = Button Down (pressed)
1 = Button Up (not pressed)
x :
top left horizontal start position of the button. 2 bytes
y :
top left vertical start position of the button. 2 bytes
buttonColour :
button colour value. 1 byte
font :
0 = 5x7 font, 1 = 8x8 font, 2 = 8x12 font. This has precedence and does not
affect the Font command.
textColour :
text colour value. 1 byte
textWidth :
horizontal size of the character. 1 byte
textHeight :
vertical size of the character. 1 byte
char1..charN :
string of ASCII characters (limit the string to line width)
terminator :
the string must be terminated with
00
hex
Description :
This command will place a Text button similar to the ones used in a PC
Windows environment.
(x, y)
refers to the top left corner of the button and the size of
the button is automatically calculated and drawn on the screen with the text relatively
justified inside the button box. The button can be displayed in an UP (button not
pressed) or DOWN (button pressed) position by specifying the appropriate value in the
state
byte. Separate button and text colours provide many variations in appearance
and format.