zng_layout::unit

Type Alias PxVector

source
pub type PxVector = Vector2D<Px, Px>;
Expand description

A vector in device pixels.

Aliased Type§

struct PxVector {
    pub x: Px,
    pub y: Px,
}

Fields§

§x: Px

The x (traditionally, horizontal) coordinate.

§y: Px

The y (traditionally, vertical) coordinate.

Trait Implementations§

source§

impl Div<Factor2d> for PxVector

source§

type Output = Vector2D<Px, Px>

The resulting type after applying the / operator.
source§

fn div(self, rhs: Factor2d) -> PxVector

Performs the / operation. Read more
source§

impl DivAssign<Factor2d> for PxVector

source§

fn div_assign(&mut self, rhs: Factor2d)

Performs the /= operation. Read more
source§

impl From<PxGridSpacing> for PxVector

source§

fn from(s: PxGridSpacing) -> Self

Converts to this type from the input type.
source§

impl IntoVar<Vector> for PxVector

source§

type Var = LocalVar<Vector>

Variable type that will wrap the T value. Read more
source§

fn into_var(self) -> Self::Var

Converts the source value into a var.
source§

fn into_boxed_var(self) -> Box<dyn VarBoxed<T>>
where Self: Sized,

Converts into BoxedVar<T>. Read more
source§

impl Mul<Factor2d> for PxVector

source§

type Output = Vector2D<Px, Px>

The resulting type after applying the * operator.
source§

fn mul(self, rhs: Factor2d) -> PxVector

Performs the * operation. Read more
source§

impl MulAssign<Factor2d> for PxVector

source§

fn mul_assign(&mut self, rhs: Factor2d)

Performs the *= operation. Read more
source§

impl IntoValue<Vector> for PxVector