FIXME: support lines that wrap FIXME: better controls maybe
Defines the list of standard colors understood by Terminal.
When capturing input, what events are you interested in?
Defines how terminal output should be handled.
Some methods will try not to send unnecessary commands to the screen. You can override their judgement using a ForceOption parameter, if present
similar to interrupted.
you might periodically check this in a long operation and abort if it is set. Remember it is volatile. It is also sent through the input event loop via RealTimeConsoleInput
Input event for characters
Sent upon receiving end-of-file from stdin.
If the user hangs up (for example, closes the terminal emulator without exiting the app), this is sent. If you receive it, you should generally cleanly exit.
GetNextEvent returns this. Check the type, then use get to get the more detailed input
.
.
Encapsulates the stream of input events received from the terminal input.
.
Encapsulates the I/O capabilities of a terminal.
the user hitting ctrl+c will send this You should drop what you're doing and perhaps exit when this happens.
Module for supporting cursor and color manipulation on the console.
The main interface for this module is the Terminal struct, which encapsulates the functions of the terminal. Creating an instance of this struct will perform console initialization; when the struct goes out of scope, any changes in console settings will be automatically reverted.
Note: on Posix, it traps SIGINT and translates it into an input event. You should keep your event loop moving and keep an eye open for this to exit cleanly; simply break your event loop upon receiving a UserInterruptionEvent. (Without the signal handler, ctrl+c can leave your terminal in a bizarre state.)
As a user, if you have to forcibly kill your program and the event doesn't work, there's still ctrl+\