pub struct ViewportDocument {
pub width: f32,
pub height: f32,
pub zoom: f32,
pub pan_x: f32,
pub pan_y: f32,
}Expand description
Viewport information.
Fields§
§width: f32Width in pixels.
height: f32Height in pixels.
zoom: f32Zoom level.
pan_x: f32Horizontal pan offset.
pan_y: f32Vertical pan offset.
Trait Implementations§
Source§impl Clone for ViewportDocument
impl Clone for ViewportDocument
Source§fn clone(&self) -> ViewportDocument
fn clone(&self) -> ViewportDocument
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ViewportDocument
impl Debug for ViewportDocument
Source§impl<'de> Deserialize<'de> for ViewportDocument
impl<'de> Deserialize<'de> for ViewportDocument
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<&Scene> for ViewportDocument
impl From<&Scene> for ViewportDocument
Source§impl Serialize for ViewportDocument
impl Serialize for ViewportDocument
impl Copy for ViewportDocument
Auto Trait Implementations§
impl Freeze for ViewportDocument
impl RefUnwindSafe for ViewportDocument
impl Send for ViewportDocument
impl Sync for ViewportDocument
impl Unpin for ViewportDocument
impl UnwindSafe for ViewportDocument
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more