Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- data TextInput t = TextInput {
- _textInput_value :: Dynamic t Text
- _textInput_lines :: Dynamic t Int
- data TextInputConfig t = TextInputConfig {}
- textInput :: (Reflex t, MonadHold t m, MonadFix m) => TextInputConfig t -> VtyWidget t m (TextInput t)
- multilineTextInput :: (Reflex t, MonadHold t m, MonadFix m) => TextInputConfig t -> VtyWidget t m (TextInput t)
- textInputTile :: (Reflex t, MonadHold t m, MonadFix m, MonadNodeId m) => VtyWidget t m (TextInput t) -> Dynamic t Int -> Layout t m (TextInput t)
- cursorAttributes :: Attr
- images :: [[Span Attr]] -> [Image]
- image :: [[Span Attr]] -> Image
- spanToImage :: Span Attr -> Image
- updateTextZipper :: Int -> Int -> Event -> TextZipper -> TextZipper
- def :: Default a => a
Documentation
The output produced by text input widgets, including the text value and the number of display lines (post-wrapping). Note that some display lines may not be visible due to scrolling.
TextInput | |
|
data TextInputConfig t Source #
Configuration options for a textInput
. For more information on
TextZipper
, see Zipper
.
TextInputConfig | |
|
Instances
Reflex t => Default (TextInputConfig t) Source # | |
Defined in Reflex.Vty.Widget.Input.Text def :: TextInputConfig t # |
textInput :: (Reflex t, MonadHold t m, MonadFix m) => TextInputConfig t -> VtyWidget t m (TextInput t) Source #
A widget that allows text input
multilineTextInput :: (Reflex t, MonadHold t m, MonadFix m) => TextInputConfig t -> VtyWidget t m (TextInput t) Source #
A widget that allows multiline text input
textInputTile :: (Reflex t, MonadHold t m, MonadFix m, MonadNodeId m) => VtyWidget t m (TextInput t) -> Dynamic t Int -> Layout t m (TextInput t) Source #
Wraps a textInput
or multilineTextInput
in a tile. Uses
the computed line count to greedily size the tile when vertically
oriented, and uses the fallback width when horizontally oriented.
cursorAttributes :: Attr Source #
Default attributes for the text cursor
images :: [[Span Attr]] -> [Image] Source #
Turn a set of display line rows into a list of images (one per line)
:: Int | Tab width |
-> Int | Page size |
-> Event | The vty event to handle |
-> TextZipper | The zipper to modify |
-> TextZipper |
Default vty event handler for text inputs