pub struct IrEmitter { /* private fields */ }Expand description
IR emitter for layout code, replacing TeX shipout.
Implementations§
Source§impl IrEmitter
impl IrEmitter
Sourcepub fn new(metadata: FragmentMetadata) -> Self
pub fn new(metadata: FragmentMetadata) -> Self
Creates a new emitter for a fragment with the given metadata.
Sourcepub fn set_surface(&mut self, surface: Surface)
pub fn set_surface(&mut self, surface: Surface)
Sets the drawing surface dimensions for the current fragment.
Sourcepub fn emit_box(&mut self, node: EmitNode, layout_box: LayoutBox) -> NodeId
pub fn emit_box(&mut self, node: EmitNode, layout_box: LayoutBox) -> NodeId
Emits a box node and returns its identifier.
Sourcepub fn emit_list(
&mut self,
node: EmitNode,
kind: ListKind,
children: Vec<NodeId>,
) -> NodeId
pub fn emit_list( &mut self, node: EmitNode, kind: ListKind, children: Vec<NodeId>, ) -> NodeId
Emits a list node wrapping the given children and returns its identifier.
Sourcepub fn emit_glyph_run(&mut self, node: EmitNode, glyph_run: GlyphRun) -> NodeId
pub fn emit_glyph_run(&mut self, node: EmitNode, glyph_run: GlyphRun) -> NodeId
Emits a glyph run node and returns its identifier.
Sourcepub fn emit_rule(&mut self, node: EmitNode, rule: Rule) -> NodeId
pub fn emit_rule(&mut self, node: EmitNode, rule: Rule) -> NodeId
Emits a rule node and returns its identifier.
Sourcepub fn emit_glue(&mut self, node: EmitNode, glue: Glue) -> NodeId
pub fn emit_glue(&mut self, node: EmitNode, glue: Glue) -> NodeId
Emits a glue node and returns its identifier.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for IrEmitter
impl RefUnwindSafe for IrEmitter
impl Send for IrEmitter
impl Sync for IrEmitter
impl Unpin for IrEmitter
impl UnsafeUnpin for IrEmitter
impl UnwindSafe for IrEmitter
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