[][src]Struct genpdf::render::TextSection

pub struct TextSection<'a, 'f, 'l> { /* fields omitted */ }

A text section that is drawn on an area of a PDF layer.

Implementations

impl<'a, 'f, 'l> TextSection<'a, 'f, 'l>[src]

#[must_use]pub fn add_newline(&mut self) -> bool[src]

Tries to add a new line and returns true if the area was large enough to fit the new line.

pub fn print_str(&mut self, s: impl AsRef<str>, style: Style)[src]

Prints the given string with the given style.

The font cache for this text section must contain the PDF font for the given style.

Trait Implementations

impl<'a, 'f, 'l> Drop for TextSection<'a, 'f, 'l>[src]

Auto Trait Implementations

impl<'a, 'f, 'l> !RefUnwindSafe for TextSection<'a, 'f, 'l>

impl<'a, 'f, 'l> !Send for TextSection<'a, 'f, 'l>

impl<'a, 'f, 'l> !Sync for TextSection<'a, 'f, 'l>

impl<'a, 'f, 'l> Unpin for TextSection<'a, 'f, 'l> where
    'l: 'a, 

impl<'a, 'f, 'l> !UnwindSafe for TextSection<'a, 'f, 'l>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.