Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Printer combinators for lining up multiple elements.
Synopsis
- hvTuple :: [Printer ()] -> Printer ()
- hvTuple' :: [Printer ()] -> Printer ()
- hTuple :: [Printer ()] -> Printer ()
- vTuple :: [Printer ()] -> Printer ()
- vTuple' :: [Printer ()] -> Printer ()
- hPromotedTuple :: [Printer ()] -> Printer ()
- hvUnboxedTuple' :: [Printer ()] -> Printer ()
- hUnboxedTuple :: [Printer ()] -> Printer ()
- hvUnboxedSum' :: [Printer ()] -> Printer ()
- hvFields :: [Printer ()] -> Printer ()
- hFields :: [Printer ()] -> Printer ()
- vFields :: [Printer ()] -> Printer ()
- vFields' :: [Printer ()] -> Printer ()
- hList :: [Printer ()] -> Printer ()
- vList :: [Printer ()] -> Printer ()
- hvPromotedList :: [Printer ()] -> Printer ()
- hvBarSep :: [Printer ()] -> Printer ()
- hBarSep :: [Printer ()] -> Printer ()
- vBarSep :: [Printer ()] -> Printer ()
- hvCommaSep :: [Printer ()] -> Printer ()
- hCommaSep :: [Printer ()] -> Printer ()
- vCommaSep :: [Printer ()] -> Printer ()
- spaced :: [Printer ()] -> Printer ()
- lined :: [Printer ()] -> Printer ()
- blanklined :: [Printer ()] -> Printer ()
- hDotSep :: [Printer ()] -> Printer ()
- spacePrefixed :: [Printer ()] -> Printer ()
- newlinePrefixed :: [Printer ()] -> Printer ()
- prefixedLined :: String -> [Printer ()] -> Printer ()
- inter :: Printer () -> [Printer ()] -> Printer ()
Tuples
hvTuple' :: [Printer ()] -> Printer () Source #
Applies hTuple'
if the result fits in a line or vTuple'
otherwise.
vTuple :: [Printer ()] -> Printer () Source #
Runs printers to construct a tuple where elements are aligned vertically.
vTuple' :: [Printer ()] -> Printer () Source #
Similar to vTuple
, but the closing parenthesis is in the last
element.
hPromotedTuple :: [Printer ()] -> Printer () Source #
Runs printers to construct a promoted tuple in a line.
Unboxed tuples
hvUnboxedTuple' :: [Printer ()] -> Printer () Source #
Runs printers to construct an unboxed tuple. The elements are aligned either in a line or vertically.
hUnboxedTuple :: [Printer ()] -> Printer () Source #
Runs printers to construct an unboxed tuple in a line.
Unboxed sums
hvUnboxedSum' :: [Printer ()] -> Printer () Source #
Runs printers to construct an unboxed sum. The elements are aligned either in a line or vertically.
The enclosing parenthesis will be printed on the same line as the last element.
Records
vFields :: [Printer ()] -> Printer () Source #
Runs printers to construct a record where elements are aligned vertically.
vFields' :: [Printer ()] -> Printer () Source #
Similar to vFields
, but the closing brace is in the same line as the
last element.
Lists
vList :: [Printer ()] -> Printer () Source #
Runs printers to construct a list where elements are aligned vertically.
hvPromotedList :: [Printer ()] -> Printer () Source #
Runs printers to construct a promoted list where elements are aligned in a line or vertically.
Bars
vBarSep :: [Printer ()] -> Printer () Source #
Runs printers where each line except the first one has |
as
a prefix.
Commas
hvCommaSep :: [Printer ()] -> Printer () Source #
hCommaSep :: [Printer ()] -> Printer () Source #
Runs printers in a line with a comma as the separator.
vCommaSep :: [Printer ()] -> Printer () Source #
Runs printers with each line except the first one has ,
as
a prefix.
Others
blanklined :: [Printer ()] -> Printer () Source #
Runs printers with a blank line as the separator.
spacePrefixed :: [Printer ()] -> Printer () Source #
Prints each element after a space like.
newlinePrefixed :: [Printer ()] -> Printer () Source #
Prints each element after a new line.