pub struct DrawEdge {Show 13 fields
pub colour: (u8, u8, u8),
pub width: f64,
pub line: EdgeLine,
pub class: Option<String>,
pub tooltip: String,
pub label: Option<String>,
pub label_at: Option<f64>,
pub undirected: bool,
pub label_math: bool,
pub attrs: Vec<DataAttr>,
pub label_attrs: Vec<DataAttr>,
pub cut: bool,
pub blocked: bool,
}Expand description
What an edge looks like, and its attributes. Its points come from the
layout (GraphLayout::edges); the arrowhead is on its last point,
unless undirected.
Fields§
§colour: (u8, u8, u8)§width: f64Line width (px), see flow_width.
line: EdgeLine§class: Option<String>Extra CSS classes on the path.
tooltip: String§label: Option<String>A label (\n breaks lines) on the edge, clear of the boxes.
label_at: Option<f64>Where along the edge the label goes (0 at its start, 1 at its end),
e.g. near a factor for an interface name; None: the middle, moved
along the edge until no box covers it.
undirected: boolNo arrowhead (a factor graph’s edges).
label_math: boolThe label names a variable (Forney style: the edge is the variable):
set in GraphStyle::math_font when there is one, in the heading
colour.
attrs: Vec<DataAttr>data-* on the path; every edge lists the same names, in the same
order.
label_attrs: Vec<DataAttr>data-* on the label (and on a cut edge’s break mark).
cut: boolThe edge is cut (its child is set by an intervention, so the parent no longer acts on it): a break mark across its middle — a gap and two slashes in the edge’s colour. Give it a muted colour.
blocked: boolThe edge is blocked (a path through it is closed, e.g. by adjusting for a node on it): a bar across its middle, square to the line, in the edge’s colour.
Trait Implementations§
Auto Trait Implementations§
impl Forget for DrawEdge
impl Freeze for DrawEdge
impl Move for DrawEdge
impl RefUnwindSafe for DrawEdge
impl Send for DrawEdge
impl Sync for DrawEdge
impl Unpin for DrawEdge
impl UnsafeUnpin for DrawEdge
impl UnwindSafe for DrawEdge
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<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more