pub struct CanvasSize {
pub device_width: f64,
pub device_height: f64,
pub css_width: f64,
pub css_height: f64,
pub device_pixel_ratio: f64,
}Expand description
A canvas’s own reported size – see TestDriver::canvas_size.
Fields§
§device_width: f64The backing buffer’s width, in device pixels.
device_height: f64The backing buffer’s height, in device pixels.
css_width: f64The element’s own layout box width, in CSS pixels.
css_height: f64The element’s own layout box height, in CSS pixels.
device_pixel_ratio: f64What the browser itself reports for window.devicePixelRatio.
Trait Implementations§
Source§impl Clone for CanvasSize
impl Clone for CanvasSize
impl Copy for CanvasSize
Auto Trait Implementations§
impl Forget for CanvasSize
impl Freeze for CanvasSize
impl Move for CanvasSize
impl RefUnwindSafe for CanvasSize
impl Send for CanvasSize
impl Sync for CanvasSize
impl Unpin for CanvasSize
impl UnsafeUnpin for CanvasSize
impl UnwindSafe for CanvasSize
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