[][src]Struct nannou::draw::properties::spatial::dimension::Properties

pub struct Properties<S = Default> {
    pub x: Option<Dimension<S>>,
    pub y: Option<Dimension<S>>,
    pub z: Option<Dimension<S>>,
}

Dimension properties for Drawing a Node.

Fields

x: Option<Dimension<S>>

Dimension over the x axis.

y: Option<Dimension<S>>

Dimension over the y axis.

z: Option<Dimension<S>>

Dimension over the z axis.

Methods

impl<S> Properties<S> where
    S: BaseFloat
[src]

pub fn to_scalars(&self, draw: &Draw<S>) -> (Option<S>, Option<S>, Option<S>)[src]

Return the Dimensions as scalar values.

Trait Implementations

impl<S> SetDimensions<S> for Properties<S>[src]

fn x_dimension(self, x: Dimension<S>) -> Self[src]

Set the length along the x axis.

fn y_dimension(self, y: Dimension<S>) -> Self[src]

Set the length along the y axis.

fn z_dimension(self, z: Dimension<S>) -> Self[src]

Set the length along the z axis.

fn width(self, w: S) -> Self[src]

Set the absolute width for the node.

fn height(self, h: S) -> Self[src]

Set the absolute height for the node.

fn depth(self, d: S) -> Self[src]

Set the absolute depth for the node.

fn w(self, w: S) -> Self[src]

Short-hand for the width method.

fn h(self, h: S) -> Self[src]

Short-hand for the height method.

fn d(self, d: S) -> Self[src]

Short-hand for the depth method.

fn wh(self, v: Vector2<S>) -> Self[src]

Set the x and y dimensions for the node.

fn whd(self, v: Vector3<S>) -> Self[src]

Set the x, y and z dimensions for the node.

fn w_h(self, x: S, y: S) -> Self[src]

Set the width and height for the node.

fn w_h_d(self, x: S, y: S, z: S) -> Self[src]

Set the width and height for the node.

fn x_dimension_relative(self, other: Index, x: Relative<S>) -> Self[src]

Some relative dimension along the x axis.

fn y_dimension_relative(self, other: Index, y: Relative<S>) -> Self[src]

Some relative dimension along the y axis.

fn z_dimension_relative(self, other: Index, z: Relative<S>) -> Self[src]

Some relative dimension along the z axis.

fn w_of(self, other: Index) -> Self[src]

Set the x-axis dimension as the width of the node at the given index.

fn h_of(self, other: Index) -> Self[src]

Set the y-axis dimension as the height of the node at the given index.

fn d_of(self, other: Index) -> Self[src]

Set the z-axis dimension as the depth of the node at the given index.

fn wh_of(self, other: Index) -> Self[src]

Set the dimensions as the dimensions of the node at the given index.

fn whd_of(self, other: Index) -> Self[src]

Set the dimensions as the dimensions of the node at the given index.

fn padded_w_of(self, other: Index, pad: S) -> Self[src]

Set the width as the width of the node at the given index padded at both ends by the given Scalar. Read more

fn padded_h_of(self, other: Index, pad: S) -> Self[src]

Set the height as the height of the node at the given index padded at both ends by the given Scalar. Read more

fn padded_d_of(self, other: Index, pad: S) -> Self[src]

Set the depth as the depth of the node at the given index padded at both ends by the given Scalar. Read more

fn padded_wh_of(self, other: Index, pad: S) -> Self where
    S: Clone
[src]

Set the dimensions as the dimensions of the node at the given index with each dimension padded by the given scalar. Read more

fn padded_whd_of(self, other: Index, pad: S) -> Self where
    S: Clone
[src]

Set the dimensions as the dimensions of the node at the given index with each dimension padded by the given scalar. Read more

fn scaled_w_of(self, other: Index, scale: S) -> Self[src]

Set the width as the width of the node at the given index multiplied by the given scale Scalar value. Read more

fn scaled_h_of(self, other: Index, scale: S) -> Self[src]

Set the height as the height of the node at the given index multiplied by the given scale Scalar value. Read more

fn scaled_d_of(self, other: Index, scale: S) -> Self[src]

Set the depth as the depth of the node at the given index multiplied by the given scale Scalar value. Read more

fn scaled_wh_of(self, other: Index, scale: S) -> Self where
    S: Clone
[src]

Set the dimensions as the dimensions of the node at the given index multiplied by the given scale Scalar value. Read more

fn scaled_whd_of(self, other: Index, scale: S) -> Self where
    S: Clone
[src]

Set the dimensions as the dimensions of the node at the given index multiplied by the given scale Scalar value. Read more

impl<S: PartialEq> PartialEq<Properties<S>> for Properties<S>[src]

impl<S: Clone> Clone for Properties<S>[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl<S> Default for Properties<S>[src]

impl<S: Copy> Copy for Properties<S>[src]

impl<S: Debug> Debug for Properties<S>[src]

Auto Trait Implementations

impl<S> Send for Properties<S> where
    S: Send

impl<S> Sync for Properties<S> where
    S: Sync

Blanket Implementations

impl<T> From<T> for T[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Style for T where
    T: Any + Debug + PartialEq<T>, 
[src]

impl<T> Content for T[src]

impl<T> SafeBorrow<T> for T[src]

impl<T> Erased for T

impl<S> FromSample<S> for S[src]

impl<T, U> ToSample<U> for T where
    U: FromSample<T>, 
[src]

impl<S, T> Duplex<S> for T where
    T: FromSample<S> + ToSample<S>, 
[src]

impl<T> SetParameter for T

fn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Result where
    T: Parameter<Self>, 

Sets value as a parameter of self.

impl<T> SetParameter for T

fn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Result where
    T: Parameter<Self>, 

Sets value as a parameter of self.