Skip to main content

FormatterExt

Trait FormatterExt 

Source
pub trait FormatterExt: Sealed {
    // Required method
    fn pad_with_width(&mut self, width: usize, args: Arguments<'_>) -> Result;
}
Expand description

An extension trait for core::fmt::Formatter.

Required Methods§

Source

fn pad_with_width(&mut self, width: usize, args: Arguments<'_>) -> Result

Writes the given arguments to the formatter, padding them with the given width. If width is incorrect, the resulting output will not be the requested width.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl FormatterExt for Formatter<'_>

Source§

fn pad_with_width(&mut self, args_width: usize, args: Arguments<'_>) -> Result

Implementors§