pub struct MapPoint {
pub raw_point: RawPoint,
pub connections: Vec<String>,
/* private fields */
}Expand description
A node on the map: an id, a position and an optional display name.
Nodes are loaded into the widget through
Map::add_hashmap_points, keyed by their
id.
Fields§
§raw_point: RawPointPosition of the node, in map coordinates.
connections: Vec<String>Ids of the lines connecting this node with others.
Each entry must match a key of the map passed to
Map::add_lines. The usual pattern is to push
the same line id into the connections of both endpoint nodes.
Line visibility is computed from the segment bounding boxes (R-tree),
not from node visibility, so a line is drawn whenever its bounding box
intersects the viewport.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for MapPoint
impl RefUnwindSafe for MapPoint
impl Send for MapPoint
impl Sync for MapPoint
impl Unpin for MapPoint
impl UnsafeUnpin for MapPoint
impl UnwindSafe for MapPoint
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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>
Converts
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>
Converts
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