pub struct CompactMultilineConfig { /* private fields */ }
Expand description

A CompactConfig based configuration plus vertical alignment and formatting options.

Implementations§

source§

impl CompactMultilineConfig

source

pub const fn new() -> Self

Create a new CompactMultilineConfig.

source

pub const fn from_compact(config: CompactConfig) -> Self

Create a new CompactMultilineConfig.

source

pub fn set_alignment_vertical(&mut self, alignment: AlignmentVertical)

Set a horizontal alignment.

source

pub const fn get_alignment_vertical(&self) -> AlignmentVertical

Get a alignment horizontal.

source

pub fn set_margin(&mut self, margin: Sides<Indent>)

Set grid margin.

source

pub const fn get_margin(&self) -> &Sides<Indent>

Returns a grid margin.

source

pub fn set_borders(&mut self, borders: Borders<char>)

Set the Borders value as correct one.

source

pub const fn get_borders(&self) -> &Borders<char>

Returns a current Borders structure.

source

pub const fn get_borders_color(&self) -> &Borders<ANSIStr<'static>>

Returns a current Borders structure.

source

pub fn set_padding(&mut self, padding: Sides<Indent>)

Set a padding to a given cells.

source

pub const fn get_padding(&self) -> &Sides<Indent>

Get a padding for a given.

source

pub fn set_alignment_horizontal(&mut self, alignment: AlignmentHorizontal)

Set a horizontal alignment.

source

pub const fn get_alignment_horizontal(&self) -> AlignmentHorizontal

Get a alignment horizontal.

source

pub fn set_borders_color(&mut self, borders: Borders<ANSIStr<'static>>)

Sets colors of border carcass on the grid.

source

pub fn set_margin_color(&mut self, color: Sides<ANSIStr<'static>>)

Set colors for a margin.

source

pub const fn get_margin_color(&self) -> &Sides<ANSIStr<'static>>

Returns a margin color.

source

pub fn set_padding_color(&mut self, color: Sides<ANSIStr<'static>>)

Set a padding color to all cells.

source

pub const fn get_padding_color(&self) -> &Sides<ANSIStr<'static>>

get a padding color.

source

pub fn set_formatting(&mut self, formatting: Formatting)

Set formatting.

source

pub const fn get_formatting(&self) -> Formatting

Get formatting.

Trait Implementations§

source§

impl Clone for CompactMultilineConfig

source§

fn clone(&self) -> CompactMultilineConfig

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for CompactMultilineConfig

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for CompactMultilineConfig

source§

fn default() -> Self

Returns the “default value” for a type. Read more
source§

impl From<CompactConfig> for CompactMultilineConfig

source§

fn from(config: CompactConfig) -> Self

Converts to this type from the input type.
source§

impl From<CompactMultilineConfig> for CompactConfig

source§

fn from(cfg: CompactMultilineConfig) -> Self

Converts to this type from the input type.
source§

impl From<CompactMultilineConfig> for SpannedConfig

Available on crate feature std only.
source§

fn from(compact: CompactMultilineConfig) -> Self

Converts to this type from the input type.
source§

impl Ord for CompactMultilineConfig

source§

fn cmp(&self, other: &CompactMultilineConfig) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · source§

fn max(self, other: Self) -> Self
where Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · source§

fn min(self, other: Self) -> Self
where Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 · source§

fn clamp(self, min: Self, max: Self) -> Self
where Self: Sized + PartialOrd,

Restrict a value to a certain interval. Read more
source§

impl PartialEq for CompactMultilineConfig

source§

fn eq(&self, other: &CompactMultilineConfig) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialOrd for CompactMultilineConfig

source§

fn partial_cmp(&self, other: &CompactMultilineConfig) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl<T, B, L, R, H, V, Data, Dims, const HSIZE: usize, const VSIZE: usize> TableOption<Data, CompactMultilineConfig, Dims> for Style<T, B, L, R, H, V, HSIZE, VSIZE>

source§

fn change(self, _: &mut Data, cfg: &mut CompactMultilineConfig, _: &mut Dims)

The function modificaties of records and a grid configuration.
source§

fn hint_change(&self) -> Option<Entity>

A hint whether an TableOption is going to change table layout. Read more
source§

impl<R, D> TableOption<R, CompactMultilineConfig, D> for Alignment

source§

fn change(self, _: &mut R, cfg: &mut CompactMultilineConfig, _: &mut D)

The function modificaties of records and a grid configuration.
source§

fn hint_change(&self) -> Option<Entity>

A hint whether an TableOption is going to change table layout. Read more
source§

impl<R, D> TableOption<R, CompactMultilineConfig, D> for AlignmentStrategy

Available on crate feature std only.
source§

fn change(self, _: &mut R, cfg: &mut CompactMultilineConfig, _: &mut D)

The function modificaties of records and a grid configuration.
source§

fn hint_change(&self) -> Option<Entity>

A hint whether an TableOption is going to change table layout. Read more
source§

impl<R, D> TableOption<R, CompactMultilineConfig, D> for Borders<char>

source§

fn change(self, _: &mut R, cfg: &mut CompactMultilineConfig, _: &mut D)

The function modificaties of records and a grid configuration.
source§

fn hint_change(&self) -> Option<Entity>

A hint whether an TableOption is going to change table layout. Read more
source§

impl<R, D> TableOption<R, CompactMultilineConfig, D> for CompactMultilineConfig

Available on crate feature std only.
source§

fn change(self, _: &mut R, config: &mut CompactMultilineConfig, _: &mut D)

The function modificaties of records and a grid configuration.
source§

fn hint_change(&self) -> Option<Entity>

A hint whether an TableOption is going to change table layout. Read more
source§

impl<R, D, C> TableOption<R, CompactMultilineConfig, D> for Margin<C>
where C: Into<ANSIStr<'static>> + Clone,

source§

fn change(self, _: &mut R, cfg: &mut CompactMultilineConfig, _: &mut D)

The function modificaties of records and a grid configuration.
source§

fn hint_change(&self) -> Option<Entity>

A hint whether an TableOption is going to change table layout. Read more
source§

impl<R, D, C> TableOption<R, CompactMultilineConfig, D> for Padding<C>
where C: Into<ANSIStr<'static>> + Clone,

source§

fn change(self, _: &mut R, cfg: &mut CompactMultilineConfig, _: &mut D)

The function modificaties of records and a grid configuration.
source§

fn hint_change(&self) -> Option<Entity>

A hint whether an TableOption is going to change table layout. Read more
source§

impl<R, D> TableOption<R, CompactMultilineConfig, D> for Theme

Available on crate feature std only.
source§

fn change(self, _: &mut R, cfg: &mut CompactMultilineConfig, _: &mut D)

The function modificaties of records and a grid configuration.
source§

fn hint_change(&self) -> Option<Entity>

A hint whether an TableOption is going to change table layout. Read more
source§

impl Copy for CompactMultilineConfig

source§

impl Eq for CompactMultilineConfig

source§

impl StructuralEq for CompactMultilineConfig

source§

impl StructuralPartialEq for CompactMultilineConfig

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.