Crate stylish_core
source ·Expand description
Modules§
Macros§
- format
allocandmacrosCreate astylish::Stringusing interpolation of runtime elements. - format_args
macrosConstructs parameters for the other string-formatting macros. - Writes attributed and formatted data into a buffer.
- Write attributed and formatted data into a buffer, with a newline appended.
Structs§
- A precompiled version of a format string and its by-reference arguments.
- A
Restyleimplementor for settingStyle::background. - The error type which is returned from formatting a message into a stream.
- A
Restyleimplementor for settingStyle::foreground. - A configured output stream.
- String
allocAn attributed version ofalloc::string::Stringwhich has a specificStyleassociated with each character. - A style to render text with, setting the foreground and background colors, along with intensity.
- A diff between two styles.
Enums§
- A color that can be used with
Foregroundto modifyStyle::foregroundorBackgroundto modifyStyle::background. - An intensity to render text with, to emphasise or de-emphasise it as needed.
Traits§
- Format trait for the
stylishformat,{:s}. - A trait for modifications to
Style, allowing an ergonomic API withStyle::withandstylish::Formatter::with. - ToStylishString
allocandmacrosA trait for converting a value to astylish::String. - A trait for writing or formatting into attributed Unicode-accepting buffers or streams.
Functions§
- format
allocTheformatfunction takes astylish::Argumentsstruct and returns the resulting attributed and formattedstylish::String.
Type Aliases§
- The type returned by formatter methods.