399
TIDE and Tibbo BASIC User Manual
©2000-2008 Tibbo Technology Inc.
text horizontally (remember, text height is equal to
). In the
following example, we align the text output along the right side of the screen. This
requires us to know how wide this output will be:
x=lcd.getprintwidth("Text")
x=lcd.print("Text",lcd.width-x,10)
Aligned text
method outputs your text within a specified rectangular
area. Four properties -- --
-- define how your text will
be printed. To fit within the target area, the lcd. object will split the text into
several lines as necessary. Only the text that can fit within the area will be
displayed. You can add your own line breaks by using the ` character (ASCII code
96). Example:
lcd.textverticalspacing=2
lcd.textalignment=PL_LCD_TEXT_ALIGNMENT_BOTTOM_RIGHT
lcd.printaligned("Multi-line text",0,0,35,33)
Note that lcd.printaligned returns the number of text lines that were produced.
418
426
430
429
430
431