pub struct LogicalPixels(/* private fields */);Implementations§
Source§impl LogicalPixels
impl LogicalPixels
pub fn new(value: f32) -> Self
pub fn zero() -> Self
pub fn is_zero(self) -> bool
pub fn value(self) -> f32
pub fn checked_div(self, other: Self) -> Option<Self>
pub fn checked_div_value(self, other: f32) -> Option<Self>
pub fn checked_rem(self, other: Self) -> Option<Self>
pub fn checked_rem_value(self, other: f32) -> Option<Self>
pub fn max(self, other: Self) -> Self
pub fn min(self, other: Self) -> Self
Trait Implementations§
Source§impl Add for LogicalPixels
impl Add for LogicalPixels
Source§impl Add<LogicalPixels> for f32
impl Add<LogicalPixels> for f32
Source§type Output = LogicalPixels
type Output = LogicalPixels
The resulting type after applying the
+ operator.Source§impl Add<f32> for LogicalPixels
impl Add<f32> for LogicalPixels
Source§impl AddAssign for LogicalPixels
impl AddAssign for LogicalPixels
Source§fn add_assign(&mut self, other: Self)
fn add_assign(&mut self, other: Self)
Performs the
+= operation. Read moreSource§impl AddAssign<LogicalPixels> for f32
impl AddAssign<LogicalPixels> for f32
Source§fn add_assign(&mut self, other: LogicalPixels)
fn add_assign(&mut self, other: LogicalPixels)
Performs the
+= operation. Read moreSource§impl AddAssign<f32> for LogicalPixels
impl AddAssign<f32> for LogicalPixels
Source§fn add_assign(&mut self, other: f32)
fn add_assign(&mut self, other: f32)
Performs the
+= operation. Read moreSource§impl Clone for LogicalPixels
impl Clone for LogicalPixels
Source§fn clone(&self) -> LogicalPixels
fn clone(&self) -> LogicalPixels
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for LogicalPixels
Source§impl Debug for LogicalPixels
impl Debug for LogicalPixels
Source§impl Default for LogicalPixels
impl Default for LogicalPixels
Source§fn default() -> LogicalPixels
fn default() -> LogicalPixels
Returns the “default value” for a type. Read more
Source§impl From<LogicalPixels> for f32
impl From<LogicalPixels> for f32
Source§fn from(value: LogicalPixels) -> Self
fn from(value: LogicalPixels) -> Self
Converts to this type from the input type.
Source§impl From<f32> for LogicalPixels
impl From<f32> for LogicalPixels
Source§impl InLogicalScale<LogicalPixels> for PhysicalPixels
impl InLogicalScale<LogicalPixels> for PhysicalPixels
fn in_logical_scale(&self, scale_factor: &ScaleFactor) -> LogicalPixels
Source§impl InLogicalScale<LogicalPixels> for PhysicalPixelsF
impl InLogicalScale<LogicalPixels> for PhysicalPixelsF
fn in_logical_scale(&self, scale_factor: &ScaleFactor) -> LogicalPixels
Source§impl InPhysicalScale<PhysicalPixels> for LogicalPixels
impl InPhysicalScale<PhysicalPixels> for LogicalPixels
fn in_physical_scale(&self, scale_factor: &ScaleFactor) -> PhysicalPixels
Source§impl InPhysicalScale<PhysicalPixelsF> for LogicalPixels
impl InPhysicalScale<PhysicalPixelsF> for LogicalPixels
fn in_physical_scale(&self, scale_factor: &ScaleFactor) -> PhysicalPixelsF
Source§impl Mul for LogicalPixels
impl Mul for LogicalPixels
Source§impl Mul<LogicalPixels> for f32
impl Mul<LogicalPixels> for f32
Source§type Output = LogicalPixels
type Output = LogicalPixels
The resulting type after applying the
* operator.Source§impl Mul<f32> for LogicalPixels
impl Mul<f32> for LogicalPixels
Source§impl MulAssign for LogicalPixels
impl MulAssign for LogicalPixels
Source§fn mul_assign(&mut self, other: Self)
fn mul_assign(&mut self, other: Self)
Performs the
*= operation. Read moreSource§impl MulAssign<LogicalPixels> for f32
impl MulAssign<LogicalPixels> for f32
Source§fn mul_assign(&mut self, other: LogicalPixels)
fn mul_assign(&mut self, other: LogicalPixels)
Performs the
*= operation. Read moreSource§impl MulAssign<f32> for LogicalPixels
impl MulAssign<f32> for LogicalPixels
Source§fn mul_assign(&mut self, other: f32)
fn mul_assign(&mut self, other: f32)
Performs the
*= operation. Read moreSource§impl PartialEq for LogicalPixels
impl PartialEq for LogicalPixels
Source§impl PartialOrd for LogicalPixels
impl PartialOrd for LogicalPixels
impl StructuralPartialEq for LogicalPixels
Source§impl Sub for LogicalPixels
impl Sub for LogicalPixels
Source§impl Sub<LogicalPixels> for f32
impl Sub<LogicalPixels> for f32
Source§type Output = LogicalPixels
type Output = LogicalPixels
The resulting type after applying the
- operator.Source§impl Sub<f32> for LogicalPixels
impl Sub<f32> for LogicalPixels
Source§impl SubAssign for LogicalPixels
impl SubAssign for LogicalPixels
Source§fn sub_assign(&mut self, other: Self)
fn sub_assign(&mut self, other: Self)
Performs the
-= operation. Read moreSource§impl SubAssign<LogicalPixels> for f32
impl SubAssign<LogicalPixels> for f32
Source§fn sub_assign(&mut self, other: LogicalPixels)
fn sub_assign(&mut self, other: LogicalPixels)
Performs the
-= operation. Read moreSource§impl SubAssign<f32> for LogicalPixels
impl SubAssign<f32> for LogicalPixels
Source§fn sub_assign(&mut self, other: f32)
fn sub_assign(&mut self, other: f32)
Performs the
-= operation. Read moreAuto Trait Implementations§
impl Freeze for LogicalPixels
impl RefUnwindSafe for LogicalPixels
impl Send for LogicalPixels
impl Sync for LogicalPixels
impl Unpin for LogicalPixels
impl UnsafeUnpin for LogicalPixels
impl UnwindSafe for LogicalPixels
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