pub struct SingleLineResult {
pub width: f32,
pub height: f32,
pub baseline: f32,
pub glyphs: Vec<GlyphQuad>,
pub spans: Vec<LaidOutSpan>,
}Expand description
Result of [crate::Typesetter::layout_single_line].
Contains the measured dimensions and GPU-ready glyph quads for a single line of text. No flow layout, line breaking, or bidi analysis is performed.
Fields§
§width: f32Total advance width of the shaped text, in pixels.
height: f32Line height (ascent + descent + leading), in pixels.
baseline: f32Distance from the top of the line to the baseline, in pixels.
glyphs: Vec<GlyphQuad>GPU-ready glyph quads, positioned at y=0 (no scroll offset).
spans: Vec<LaidOutSpan>Per-span bounding rectangles for markup-aware layout
([crate::Typesetter::layout_single_line_markup]). Empty for
the plain-text layout path.
Auto Trait Implementations§
impl Freeze for SingleLineResult
impl RefUnwindSafe for SingleLineResult
impl Send for SingleLineResult
impl Sync for SingleLineResult
impl Unpin for SingleLineResult
impl UnsafeUnpin for SingleLineResult
impl UnwindSafe for SingleLineResult
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