lcd.drawTextLines(x, y, w, h, text [, flags])¶
Draw text inside rectangle (x,y,w,h) with line breaks
Parameters¶
x,y(positive numbers) starting coordinatew,h(positive numbers) width and height of bounding rectangletext(string) text to displayflags(optional) please see Lcd functions overview for drawing flags and colors, and Appendix for available characters in each font set. RIGHT, CENTER and VCENTER are not implemented.
Return value¶
- x,y (integers) point where text drawing ended
Notes¶
Available on¶
- [ ] B\&W LCD radios
- [ ] Grayscale LCD radios
- [x] Color LCD radios
API status¶
| EdgeTX version | Action |
|---|---|
| 2.5.0 | Introduced |
| 2.11.0 | x,y return added |
Examples¶
Example 1¶
local y
_, y = lcd.drawTextLines(1, 0, 100, 40, "No TxGPS detected!", LEFT + TEXT_COLOR)
lcd.drawTextLines(1, y, 100, 100, "Make sure your firmware has GPS support enabled", LEFT + TEXT_COLOR)