pub enum GraphStyle {
Ascii,
Curves,
Heavy,
Bubbles,
BubblesX,
}Expand description
Visual glyph set for the graph. Pure data, no rendering — render reads
the glyphs from the supplied set when emitting commit / transition lines.
Variants§
Ascii
Plain ASCII (* | / \). Maximum portability.
Curves
Unicode box-drawing curves (● │ ╮ ╰). Recommended default.
Heavy
Heavy box-drawing (⬢ ┃ ┓ ┗). Bold, attention-grabbing.
Bubbles
Wide spacing + filled circles. Compact one-line per commit.
BubblesX
Same glyphs as Bubbles but each commit spans 2 lines: a node row
followed by an info-padding row. Use with expanded_extra_lines().
Implementations§
Source§impl GraphStyle
impl GraphStyle
pub fn from_str(s: &str) -> Self
pub fn as_str(self) -> &'static str
Sourcepub fn commit_glyph(self, parent_count: usize) -> char
pub fn commit_glyph(self, parent_count: usize) -> char
Glyph for the active commit on its lane, varying by parent count: 0 = root, 1 = normal, ≥2 = merge.
Curves / Bubbles / BubblesX share the bullseye family (〇 ⦿ ◉) for a “node-on-a-line” look that reads like a graph editor (≈ kraken).
Sourcepub fn lane_glyph(self) -> char
pub fn lane_glyph(self) -> char
Vertical lane-continues glyph.
Sourcepub fn close_left_glyph(self) -> char
pub fn close_left_glyph(self) -> char
Glyph for a lane closing toward the left (fork-end / merge-target). Curves / Bubbles use ◟ (lower-left half-circle) to suggest a smooth arc from the closing lane into its target.
Sourcepub fn open_right_glyph(self) -> char
pub fn open_right_glyph(self) -> char
Glyph for a lane opening toward the right (new merge parent). Curves / Bubbles use ◝ (upper-right half-circle) — mirror of ◟.
Sourcepub fn lane_spacing(self) -> usize
pub fn lane_spacing(self) -> usize
Cells of horizontal padding between lanes. Bubbles styles use wider spacing so commit nodes have room to breathe.
Sourcepub fn expanded_extra_lines(self) -> usize
pub fn expanded_extra_lines(self) -> usize
Number of extra padding lines to insert below each commit row. 0 for compact styles. BubblesX uses 1 (commit row + breather row).
Trait Implementations§
Source§impl Clone for GraphStyle
impl Clone for GraphStyle
Source§fn clone(&self) -> GraphStyle
fn clone(&self) -> GraphStyle
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for GraphStyle
Source§impl Debug for GraphStyle
impl Debug for GraphStyle
Source§impl Default for GraphStyle
impl Default for GraphStyle
impl Eq for GraphStyle
Source§impl PartialEq for GraphStyle
impl PartialEq for GraphStyle
Source§fn eq(&self, other: &GraphStyle) -> bool
fn eq(&self, other: &GraphStyle) -> bool
self and other values to be equal, and is used by ==.impl StructuralPartialEq for GraphStyle
Auto Trait Implementations§
impl Freeze for GraphStyle
impl RefUnwindSafe for GraphStyle
impl Send for GraphStyle
impl Sync for GraphStyle
impl Unpin for GraphStyle
impl UnsafeUnpin for GraphStyle
impl UnwindSafe for GraphStyle
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.