pub struct Element {
    pub shape: ShapeKind,
    pub pos: Position,
    pub look: StyleAttr,
    pub orientation: Orientation,
}

Fields

shape: ShapeKindpos: Positionlook: StyleAttrorientation: Orientation

Implementations

Trait Implementations

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Render the shape into a canvas. If \p debug is set then extra markers will be rendered. Read more
\Return the coordinate for the connection point of an arrow that’s coming from the direction of \p from. The format of the path is (x, y, cx, cy), where cx and cy, are the control points of the bezier curve. \p force is the magnitude of the edge direction. \p port is the optional port name (for named records). Read more
Computes the coordinate for the connection point of an arrow that’s passing through this edge. coming from the direction of \p from. \returns the bezier path in the format (x, y, cx, cy), where cx and cy, are the control points for the entry path of the bezier curve. The exit path is assumed to be the mirror point for the center (first point). \p force is the magnitude of the edge direction. This works with the get_connector_location method for drawing edges. Read more
\return the Position of the shape.
\return the mutable reference to the Position of the shape.
Return true if the element is a connector.
Swap the coordinates of the location and size.
Update the size of the shape.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.