Struct below_render::RenderConfig [−][src]
pub struct RenderConfig {
pub title: Option<String>,
pub format: Option<RenderFormat>,
pub indented_prefix: Option<String>,
pub suffix: Option<String>,
pub fold: Option<FoldOption>,
pub width: Option<usize>,
}
Expand description
Config object for specifying how to render a Field. Options are ordered roughly by their order of processing.
Fields
title: Option<String>
format: Option<RenderFormat>
Converting Field to String.
indented_prefix: Option<String>
Prefix when rendered with indent. Each extra level adds same number of
spaces equal to the length of this prefix. This allows us to render:
suffix: Option<String>
fold: Option<FoldOption>
Fit a long rendered Field into smaller width by omitting some characters in the middle instead of truncating. Only applies when rendering Field with fixed width. Taken indent, prefix and suffix len into account.
width: Option<usize>
For fixed width rendering. Truncate or pad whitespace to output.
Implementations
Renders Field with all options applied. depth
specifies the depth of
the model of this Field, where the model is Recursive, i.e. it works as
a node in a tree. Currently this only affects indented_prefix.
Trait Implementations
Returns the “default value” for a type. Read more
Performs the conversion.
Performs the conversion.
Auto Trait Implementations
impl RefUnwindSafe for RenderConfig
impl Send for RenderConfig
impl Sync for RenderConfig
impl Unpin for RenderConfig
impl UnwindSafe for RenderConfig
Blanket Implementations
Mutably borrows from an owned value. Read more
Calls the given closure and return the result. Read more
Calls the given closure on self
.