| Safe Haskell | None | 
|---|---|
| Language | Haskell2010 | 
Graphics.Vty.Output.Interface
Description
This module provides an abstract interface for performing terminal
 output. The only user-facing part of this API is Output.
Synopsis
- data Output = Output {
- terminalID :: String
 - releaseTerminal :: IO ()
 - reserveDisplay :: IO ()
 - releaseDisplay :: IO ()
 - displayBounds :: IO DisplayRegion
 - outputByteBuffer :: ByteString -> IO ()
 - contextColorCount :: Int
 - supportsCursorVisibility :: Bool
 - supportsMode :: Mode -> Bool
 - setMode :: Mode -> Bool -> IO ()
 - getModeStatus :: Mode -> IO Bool
 - assumedStateRef :: IORef AssumedState
 - mkDisplayContext :: Output -> DisplayRegion -> IO DisplayContext
 - ringTerminalBell :: IO ()
 - supportsBell :: IO Bool
 
 - data AssumedState = AssumedState {}
 - data DisplayContext = DisplayContext {
- contextDevice :: Output
 - contextRegion :: DisplayRegion
 - writeMoveCursor :: Int -> Int -> Write
 - writeShowCursor :: Write
 - writeHideCursor :: Write
 - writeSetAttr :: Bool -> FixedAttr -> Attr -> DisplayAttrDiff -> Write
 - writeDefaultAttr :: Bool -> Write
 - writeRowEnd :: Write
 - inlineHack :: IO ()
 
 - data Mode
 - displayContext :: Output -> DisplayRegion -> IO DisplayContext
 - outputPicture :: DisplayContext -> Picture -> IO ()
 - initialAssumedState :: AssumedState
 - limitAttrForDisplay :: Output -> Attr -> Attr
 
Documentation
The Vty terminal output interface.
Constructors
| Output | |
Fields 
  | |
data AssumedState Source #
Constructors
| AssumedState | |
Fields  | |
data DisplayContext Source #
Constructors
| DisplayContext | |
Fields 
  | |
Modal terminal features that can be enabled and disabled.
Constructors
| Mouse | Mouse mode (whether the terminal is configured to provide mouse input events)  | 
| BracketedPaste | Paste mode (whether the terminal is configured to provide events on OS pastes)  | 
| Focus | Focus-in/focus-out events (whether the terminal is configured to provide events on focus change)  | 
| Hyperlink | Hyperlink mode via the   | 
displayContext :: Output -> DisplayRegion -> IO DisplayContext Source #
outputPicture :: DisplayContext -> Picture -> IO () Source #
Displays the given Picture.
- The image is cropped to the display size.
 - Converted into a sequence of attribute changes and text spans.
 - The cursor is hidden.
 - Serialized to the display.
 - The cursor is then shown and positioned or kept hidden.