pub struct PrefixLine {
pub parts: Vec<(PrefixLinePart, PrefixLineColor)>,
pub kind: PrefixLineKind,
}Expand description
A left-side graph prefix line before message text is attached.
This is the output of the row-shapes-to-prefix-lines stage. A prefix line may contain a node glyph slot, but it does not know what glyph will fill that slot and it does not contain any right-side message text.
Fields§
§parts: Vec<(PrefixLinePart, PrefixLineColor)>The ordered pieces that make up the graph prefix.
Text pieces can have an optional line ID. Built-in renderers leave node
glyph slots untracked so callers can style them independently.
With coloring enabled, None is used for untracked text and padding.
Without coloring, the metadata type is () and takes no space.
kind: PrefixLineKindThe semantic role of this line within the rendered row.
Implementations§
Source§impl PrefixLine
impl PrefixLine
Sourcepub fn new(kind: PrefixLineKind) -> Self
pub fn new(kind: PrefixLineKind) -> Self
Create an empty prefix line of the given kind.
Trait Implementations§
Source§impl Clone for PrefixLine
impl Clone for PrefixLine
Source§impl Debug for PrefixLine
impl Debug for PrefixLine
impl Eq for PrefixLine
Source§impl PartialEq for PrefixLine
impl PartialEq for PrefixLine
impl StructuralPartialEq for PrefixLine
Auto Trait Implementations§
impl Forget for PrefixLine
impl Freeze for PrefixLine
impl Move for PrefixLine
impl RefUnwindSafe for PrefixLine
impl Send for PrefixLine
impl Sync for PrefixLine
impl Unpin for PrefixLine
impl UnsafeUnpin for PrefixLine
impl UnwindSafe for PrefixLine
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