pub struct TextBuffer<'a> {
    pub redraw: bool,
    /* private fields */
}
Expand description

A buffer of text that is shaped and laid out

Fields

redraw: bool

Implementations

Pre-shape lines in the buffer, up to lines, return actual number of layout lines

Shape lines until cursor, also scrolling to include cursor in view

Get the current cursor position

Get the current TextMetrics

Set the current TextMetrics

Get the current buffer dimensions (width, height)

Set the current buffer dimensions

Get the current scroll location

Get the number of lines that can be viewed in the buffer

Set attributes

Set text of buffer

Get the lines of the original text

Perform a TextAction on the buffer

Get the visible layout runs for rendering and other tasks

Draw the buffer

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

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

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.