[][src]Struct gelatin::misc::LogicalVector

pub struct LogicalVector {
    pub vec: Vector2<f32>,
}

Used to represent logical pixel coordinates and dimensions.

This struct is distinct from PhysicalVector which represents physical pixel coordinates and dimensions to avoid confusion when dealing with scaled dpi scenarios.

Fields

vec: Vector2<f32>

Implementations

impl LogicalVector[src]

pub fn new(x: f32, y: f32) -> Self[src]

Trait Implementations

impl Add<LogicalVector> for LogicalVector[src]

type Output = Self

The resulting type after applying the + operator.

impl AddAssign<LogicalVector> for LogicalVector[src]

impl Clone for LogicalVector[src]

impl Copy for LogicalVector[src]

impl Debug for LogicalVector[src]

impl Default for LogicalVector[src]

impl<T: Into<f32>> Div<T> for LogicalVector[src]

type Output = Self

The resulting type after applying the / operator.

impl From<LogicalPosition<f32>> for LogicalVector[src]

impl From<LogicalSize<f32>> for LogicalVector[src]

impl<T: Into<f32>> From<Vector2<T>> for LogicalVector[src]

impl<T: Into<f64>> FromPhysical<PhysicalPosition<T>> for LogicalVector[src]

impl<T: Into<f64>> FromPhysical<PhysicalSize<T>> for LogicalVector[src]

impl Into<LogicalPosition<f32>> for LogicalVector[src]

impl Into<LogicalSize<f32>> for LogicalVector[src]

impl Mul<LogicalVector> for f32[src]

type Output = LogicalVector

The resulting type after applying the * operator.

impl<T: Into<f32>> Mul<T> for LogicalVector[src]

type Output = Self

The resulting type after applying the * operator.

impl Sub<LogicalVector> for LogicalVector[src]

type Output = Self

The resulting type after applying the - operator.

Auto Trait Implementations

Blanket Implementations

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

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

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

impl<T> Content for T where
    T: Copy
[src]

type Owned = T

A type that holds a sized version of the content.

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

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

impl<T> Pointable for T

type Init = T

The type for initializers.

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

type Owned = T

The resulting type after obtaining ownership.

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.