Expand description
§facet-pretty
Provides pretty-printing capabilities for Facet types.
§Sponsors
Thanks to all individual sponsors:
…along with corporate sponsors:
…without whom this work could not exist.
§Special thanks
The facet logo was drawn by Misiasart.
§License
Licensed under either of:
- Apache License, Version 2.0 (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)
at your option.
Modules§
- colors
- Tokyo Night color scheme for syntax highlighting
- tokyo_
night - Tokyo Night color palette (RGB values from official theme)
Structs§
- Color
Generator - A color generator that produces unique colors based on a hash value
- Field
Span - Spans for a field or variant, tracking both key (name) and value (type) positions
- Formatted
Shape - Result of formatting a shape with span tracking
- Formatted
Value - Result of formatting a value with span tracking
- Pretty
Display - Display wrapper for any type that implements Facet
- Pretty
Printer - A formatter for pretty-printing Facet types
- RGB
- RGB color representation
- Shape
Format Config - Configuration options for shape formatting
Enums§
- Path
Segment - A segment in a path through a type structure
Traits§
- Facet
Pretty - Extension trait for Facet types to easily pretty-print them
Functions§
- format_
shape - Format a Shape as Rust-like source code (plain text, no colors)
- format_
shape_ colored - Format a Shape as Rust-like source code with ANSI colors (Tokyo Night theme)
- format_
shape_ colored_ into - Format a Shape with ANSI colors into an existing String
- format_
shape_ colored_ into_ with_ config - Format a Shape with ANSI colors into an existing String with config options
- format_
shape_ colored_ with_ config - Format a Shape as Rust-like source code with ANSI colors and config options
- format_
shape_ with_ config - Format a Shape as Rust-like source code with config options (plain text, no colors)
- format_
shape_ with_ spans - Format a Shape with span tracking for each field/variant Note: spans are computed on the plain text (no ANSI codes)
- strip_
ansi - Strip ANSI escape codes from a string