Safe Haskell | Safe |
---|---|
Language | Haskell2010 |
Contains all the data structures and functions for composing pieces of graphical text.
- data Text = Text {}
- data FontWeight
- data FontStyle
- defaultText :: Text
- toText :: String -> Text
- showText :: Show a => a -> Text
- light :: Text -> Text
- bold :: Text -> Text
- italic :: Text -> Text
- oblique :: Text -> Text
- color :: Color -> Text -> Text
- typeface :: String -> Text -> Text
- height :: Double -> Text -> Text
Types
Represents a graphical piece of text, containing a UTF-8 string and any relevant style fields.
Text | |
|
data FontWeight Source
Represents the weight for a text's font.
Represents the style for a text's font.
Composing
Create the default text. By default it is is black sans-serif with a height of 14pt.
toText :: String -> Text Source
Create a text from a string. By default, this text will be 14pt, black and unstyled.