[][src]Struct arcs::components::Viewport

pub struct Viewport {
    pub centre: Point,
    pub pixels_per_drawing_unit: Scale<f64, DrawingSpace, CanvasSpace>,
}

Fields

centre: Point

The location (in drawing units) this viewport is centred on.

pixels_per_drawing_unit: Scale<f64, DrawingSpace, CanvasSpace>

The number of pixels each drawing unit should take up on the screen.

Trait Implementations

impl Clone for Viewport[src]

impl Component for Viewport[src]

type Storage = HashMapStorage<Self>

Associated storage type for this component.

impl Debug for Viewport[src]

impl PartialEq<Viewport> for Viewport[src]

impl Scale for Viewport[src]

fn scale(&mut self, scale_factor: f64)[src]

Zoom the viewport, where a positive scale_factor will zoom in.

impl StructuralPartialEq for Viewport[src]

impl Translate<DrawingSpace> for Viewport[src]

Auto Trait Implementations

impl RefUnwindSafe for Viewport

impl Send for Viewport

impl Sync for Viewport

impl Unpin for Viewport

impl UnwindSafe for Viewport

Blanket Implementations

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

impl<T> Any for T where
    T: Any
[src]

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

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

impl<T> Event for T where
    T: Send + Sync + 'static, 
[src]

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

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

impl<T> Resource for T where
    T: Any + Send + Sync
[src]

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

impl<T, U> RoundInto<U> for T where
    U: RoundFrom<T>, 
[src]

impl<S> Scale for S where
    S: ScaleNonUniform
[src]

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

type Owned = T

The resulting type after obtaining ownership.

impl<Space, A> Translate<Space> for A where
    A: AffineTransformable
[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.