TETextBox example

This commit is contained in:
Jeff Epler 2025-08-10 19:33:16 -05:00
parent a8f115933c
commit 643cb31bf3

View file

@ -0,0 +1,13 @@
import mactypes
import textedit
import toolboxevent
import deskmgr
teJustCenter = 1
textRect = mactypes.Rect(135, 10, 270, 487)
text = bytearray(b"\r".join([b"Hello, World", b"This is MicroPython calling TETextBox", b"", b"Click to exit"]))
textedit.TETextBox(text, len(text), textRect, textedit.teJustCenter)
while not toolboxevent.Button():
deskmgr.SystemTask() # scott added - slows it down on fast machines