[−][src]Crate rawcmd_utils
Enums
Alignment | Text alignement options. |
Constants
ANSI_PAIR | List of supported ANSI codes. |
ANSI_REGEX | Regex pattern for maching ANSI codes. |
Functions
ansi_pair | Returns opening and closing code for the provided ANSI code. |
match_indices | Uses regex to split the provided text on ANSI codes. It returned list includes text chinks and ANSI delimiters. |
pad_text | Pads a string to fill a certain number of characters. |
repaire_text | Adds missing closing ANSI codes to the multi-line string. |
size_text | Calculates the length of a unicode string containing ANSI codes. The length returned represents the visible string length. |
slice_text | Returns a slice of a string containing ANSI codes. |
strip_codes | Removes ANSI codes from the provided text and return a new string. |
trucate_text | Truncates a string to a certain number of characters. |
wrap_text | Splits long string into multiple lines. |