|
|
|
|
Synopsis |
|
|
|
Documentation |
|
|
The main object. At most one should be created.
An alternative is to use unsafePerformIO to automatically create a singleton Vty instance when
required.
This does not assure any thread safety. In theory, as long as an update action is not executed
when another update action is already then it's safe to call this on multiple threads.
todo: Once the Terminal interface encompasses input this interface will be deprecated.
Currently, just using the Terminal interface there is no support for input events.
| Constructors | Vty | | update :: Picture -> IO () | Outputs the given Picture. Equivalent to output_picture applied to a display context
implicitly managed by Vty.
| next_event :: IO Event | Get one Event object, blocking if necessary.
| terminal :: TerminalHandle | Handle to the terminal interface. See Terminal
The use of Vty typically follows this process:
0. initialize vty
1. use the update equation of Vty to display a picture
2. repeat
3. shutdown vty.
todo: provide a similar abstraction to Graphics.Vty.Terminal for input. Use haskeline's
input backend for implementation.
todo: remove explicit shutdown requirement.
| refresh :: IO () | Refresh the display. Normally the library takes care of refreshing. Nonetheless, some
other program might output to the terminal and mess the display. In that case the user
might want to force a refresh.
| shutdown :: IO () | Clean up after vty.
|
|
|
|
|
|
Set up the state object for using vty. At most one state object should be
created at a time.
|
|
|
|
module Graphics.Vty.Terminal |
|
module Graphics.Vty.Picture |
|
module Graphics.Vty.DisplayRegion |
|
|
Representations of non-modifier keys.
| Constructors | KEsc | | KFun Int | | KBackTab | | KPrtScr | | KPause | | KASCII Char | | KBS | | KIns | | KHome | | KPageUp | | KDel | | KEnd | | KPageDown | | KNP5 | | KUp | | KMenu | | KLeft | | KDown | | KRight | | KEnter | |
| Instances | |
|
|
|
Modifier keys. Key codes are interpreted such that users are more likely to
have Meta than Alt; for instance on the PC Linux console, MMeta will
generally correspond to the physical Alt key.
| Constructors | | Instances | |
|
|
|
Mouse buttons. Not yet used.
| Constructors | | Instances | |
|
|
|
Generic events.
| Constructors | | Instances | |
|
|
Produced by Haddock version 2.4.2 |