Safe Haskell | None |
---|---|
Language | Haskell2010 |
Rainbow.Types
Description
All the main types in Rainbow. Using this module you can specify
that you want different formatting for 8- and 256-color terminals.
Many of the names in this module conflict with the names in
Rainbow, so it's probably best to import
this module
qualified
.
- newtype Color a = Color (Maybe a)
- data Enum8
- enum8toWord8 :: Enum8 -> Word8
- black :: Enum8
- red :: Enum8
- green :: Enum8
- yellow :: Enum8
- blue :: Enum8
- magenta :: Enum8
- cyan :: Enum8
- white :: Enum8
- grey :: Word8
- brightRed :: Word8
- brightGreen :: Word8
- brightYellow :: Word8
- brightBlue :: Word8
- brightMagenta :: Word8
- brightCyan :: Word8
- brightWhite :: Word8
- data Format = Format {}
- strikeout :: Functor f => (Bool -> f Bool) -> Format -> f Format
- invisible :: Functor f => (Bool -> f Bool) -> Format -> f Format
- inverse :: Functor f => (Bool -> f Bool) -> Format -> f Format
- blink :: Functor f => (Bool -> f Bool) -> Format -> f Format
- underline :: Functor f => (Bool -> f Bool) -> Format -> f Format
- italic :: Functor f => (Bool -> f Bool) -> Format -> f Format
- faint :: Functor f => (Bool -> f Bool) -> Format -> f Format
- bold :: Functor f => (Bool -> f Bool) -> Format -> f Format
- data Style a = Style {}
- format :: Functor f => (Format -> f Format) -> Style a -> f (Style a)
- back :: Functor f => (Color a -> f (Color a)) -> Style a -> f (Style a)
- fore :: Functor f => (Color a -> f (Color a)) -> Style a -> f (Style a)
- data Scheme = Scheme {}
- style256 :: Functor f => (Style Word8 -> f (Style Word8)) -> Scheme -> f Scheme
- style8 :: Functor f => (Style Enum8 -> f (Style Enum8)) -> Scheme -> f Scheme
- data Chunk a = Chunk {}
- chunk :: a -> Chunk a
- yarn :: Functor f => (t -> f a) -> Chunk t -> f (Chunk a)
- scheme :: Functor f => (Scheme -> f Scheme) -> Chunk a -> f (Chunk a)
- data Radiant = Radiant {}
- color256 :: Functor f => (Color Word8 -> f (Color Word8)) -> Radiant -> f Radiant
- color8 :: Functor f => (Color Enum8 -> f (Color Enum8)) -> Radiant -> f Radiant
Documentation
A simple enumeration for eight values. Represents eight colors.
enum8toWord8 :: Enum8 -> Word8 #
brightGreen :: Word8 #
brightYellow :: Word8 #
brightBlue :: Word8 #
brightMagenta :: Word8 #
brightCyan :: Word8 #
brightWhite :: Word8 #
Text formatting such as bold, italic, etc.
Constructors
Format | |
The foreground and background color, and the Format
. This
represents all colors and formatting attributes for either an 8- or
256-color terminal.
Holds the Style
for both 8- and 256-color terminals.
A chunk is some textual data coupled with a description of what color the text is, attributes like whether it is bold or underlined, etc. The chunk knows what foreground and background colors and what attributes to use for both an 8 color terminal and a 256 color terminal.
Instances
Functor Chunk # | |
Foldable Chunk # | |
Traversable Chunk # | |
Eq a => Eq (Chunk a) # | |
Ord a => Ord (Chunk a) # | |
Show a => Show (Chunk a) # | |
Generic (Chunk a) # | |
Monoid a => Monoid (Chunk a) # | Uses the underlying |
type Rep (Chunk a) # | |
Stores colors that may affect 8-color terminals, 256-color terminals, both, or neither.
Instances