Modulecuddle-1.8.1.0GHC2021
Codec.CBOR.Cuddle.Pretty.Columnar
This module provides some utility functions to help with aligning pretty printed values by column.
- 4 types
- 8 values
- Packagecuddle-1.8.1.0
- Exports12
- LanguageGHC2021
- LicenceApache-2.0
- SourceColumnar.hs
Creates a cell by pretty printing the input value and then left-aligning the resulting Doc within the table.
Creates a cell by pretty printing the input value and then right-aligning the resulting Doc within the table.
A cell that takes up a cell but has no content.
Checks whether the cell contains a Doc with a rendered width of zero.
Pretty print the Columnar as a table.
Pretty prints the Columnar so that the rows are separated by by the separator Doc provided as the third argument and then everything is enclosed within the left and right brackets provided as the first and second argument accordingly. The brackets will be aligned with the separators in the first column, e.g. ``` [ foo , bar ] ```
Pretty prints the Columnar so that every line after the first has a separator prepended to it. This can be useful when you want to align the rows, but the separator would cause all the other rows after the first to be shifted right by one. The way you use this is you reduce the indentation on the following lines by the width of the separator. ``` foo = x , y , z ```
A row with a single left-aligned document