Trait Visible

Source
pub trait Visible {
    // Required methods
    fn position(&self) -> Position;
    fn position_mut(&mut self) -> &mut Position;
    fn is_connector(&self) -> bool;
    fn transpose(&mut self);
    fn resize(&mut self);
}
Expand description

This is the trait that all elements that can be arranged need to implement.

Required Methods§

Source

fn position(&self) -> Position

\return the Position of the shape.

Source

fn position_mut(&mut self) -> &mut Position

\return the mutable reference to the Position of the shape.

Source

fn is_connector(&self) -> bool

Return true if the element is a connector.

Source

fn transpose(&mut self)

Swap the coordinates of the location and size.

Source

fn resize(&mut self)

Update the size of the shape.

Implementors§