VT100 library for the Micromite console


Author Message
thwill

Guru

Joined: 16/09/2019
Location: United Kingdom
Posts: 2085
Posted: 11:20am 22 Nov 2021      

Courtesy of @matherp, but any bugs are probably my fault:

' Change the break key.
Option Break 4

' On CTRL-C call my_exit().
On Key 3, my_exit()

Sub my_exit()
 ' Show cursor and clear console attributes.
 Print Chr$(27) "[?25h" Chr$(27) "[0m"

 ' Restore CTRL-C as the break key.
 Option Break 3

 ' End the program.
 End
End Sub

Best wishes,

Tom
Edited 2021-11-22 21:21 by thwill