pub struct LayoutSession<'a> { /* private fields */ }Expand description
Incremental wrapper session returned by RenderEngine::begin.
Implementations§
Source§impl LayoutSession<'_>
impl LayoutSession<'_>
Sourcepub fn set_hyphenation_language(&mut self, language_tag: &str)
pub fn set_hyphenation_language(&mut self, language_tag: &str)
Set the hyphenation language hint (e.g. “en”, “en-US”).
Sourcepub fn push(&mut self, item: StyledEventOrRun) -> Result<(), RenderEngineError>
pub fn push(&mut self, item: StyledEventOrRun) -> Result<(), RenderEngineError>
Push one styled item through layout and enqueue closed pages.
Sourcepub fn drain_pages<F>(&mut self, on_page: F)where
F: FnMut(RenderPage),
pub fn drain_pages<F>(&mut self, on_page: F)where
F: FnMut(RenderPage),
Drain currently available pages in FIFO order.
Sourcepub fn finish(&mut self) -> Result<(), RenderEngineError>
pub fn finish(&mut self) -> Result<(), RenderEngineError>
Finish layout and enqueue any remaining pages.
Auto Trait Implementations§
impl<'a> Freeze for LayoutSession<'a>
impl<'a> !RefUnwindSafe for LayoutSession<'a>
impl<'a> !Send for LayoutSession<'a>
impl<'a> !Sync for LayoutSession<'a>
impl<'a> Unpin for LayoutSession<'a>
impl<'a> UnsafeUnpin for LayoutSession<'a>
impl<'a> !UnwindSafe for LayoutSession<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more