pub(super) struct ExtraDeviceData {
media_type: MediaType,
viewport_size: Size2D<f32, CSSPixel>,
device_pixel_ratio: Scale<f32, CSSPixel, DevicePixel>,
quirks_mode: QuirksMode,
prefers_color_scheme: PrefersColorScheme,
font_metrics_provider: Box<dyn FontMetricsProvider>,
}Fields§
§media_type: MediaTypeThe current media type used by de device.
viewport_size: Size2D<f32, CSSPixel>The current viewport size, in CSS pixels.
device_pixel_ratio: Scale<f32, CSSPixel, DevicePixel>The current device pixel ratio, from CSS pixels to device pixels.
quirks_mode: QuirksModeThe current quirks mode.
prefers_color_scheme: PrefersColorSchemeWhether the user prefers light mode or dark mode
font_metrics_provider: Box<dyn FontMetricsProvider>An implementation of a trait which implements support for querying font metrics.
Trait Implementations§
Source§impl Debug for ExtraDeviceData
impl Debug for ExtraDeviceData
Source§impl MallocSizeOf for ExtraDeviceData
impl MallocSizeOf for ExtraDeviceData
Source§fn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
fn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
Measure the heap usage of all descendant heap-allocated structures, but
not the space taken up by the value itself.
Auto Trait Implementations§
impl Freeze for ExtraDeviceData
impl !RefUnwindSafe for ExtraDeviceData
impl !Send for ExtraDeviceData
impl Sync for ExtraDeviceData
impl Unpin for ExtraDeviceData
impl !UnwindSafe for ExtraDeviceData
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> MaybeBoxed<Box<T>> for T
impl<T> MaybeBoxed<Box<T>> for T
Source§fn maybe_boxed(self) -> Box<T>
fn maybe_boxed(self) -> Box<T>
Convert
Source§impl<T> MaybeBoxed<T> for T
impl<T> MaybeBoxed<T> for T
Source§fn maybe_boxed(self) -> T
fn maybe_boxed(self) -> T
Convert