[−][src]Struct doryen_extra::FPosition
A struct representing a floating-point
Position
determined by its x
and y
values.
Fields
x: f32
The x
value the Position
is currently representing.
y: f32
The y
value the Position
is currently representing.
Implementations
impl FPosition
[src]
pub const ORIGIN: Self
[src]
A constant representing a Position
where both x
and y
are 0.
pub const fn new(x: f32, y: f32) -> Self
[src]
Returns a Position
with the given x
and y
values.
impl FPosition
[src]
pub fn round(self) -> Position
[src]
Returns a non-floating point position where the decimal parts of the width and height have been rounded.
pub fn truncate(self) -> Position
[src]
Returns a non-floating point position where the decimal parts of the width and height have been truncated.
pub fn truncate_u(self) -> UPosition
[src]
Returns a non-floating point position where the decimal parts of the width and height have been truncated.
Trait Implementations
impl Add<(f32, f32)> for FPosition
[src]
type Output = Self
The resulting type after applying the +
operator.
fn add(self, rhs: (f32, f32)) -> Self::Output
[src]
impl Add<FPosition> for FPosition
[src]
type Output = Self
The resulting type after applying the +
operator.
fn add(self, rhs: Self) -> Self::Output
[src]
impl Add<FSize> for FPosition
[src]
type Output = FRectangle
The resulting type after applying the +
operator.
fn add(self, rhs: FSize) -> Self::Output
[src]
impl Add<f32> for FPosition
[src]
type Output = Self
The resulting type after applying the +
operator.
fn add(self, rhs: f32) -> Self::Output
[src]
impl AddAssign<(f32, f32)> for FPosition
[src]
impl AddAssign<f32> for FPosition
[src]
fn add_assign(&mut self, rhs: f32)
[src]
impl Clone for FPosition
[src]
impl Copy for FPosition
[src]
impl Debug for FPosition
[src]
impl Default for FPosition
[src]
impl Display for FPosition
[src]
impl Div<f32> for FPosition
[src]
type Output = Self
The resulting type after applying the /
operator.
fn div(self, rhs: f32) -> Self::Output
[src]
impl DivAssign<f32> for FPosition
[src]
fn div_assign(&mut self, rhs: f32)
[src]
impl From<(f32, f32)> for FPosition
[src]
impl From<FPosition> for (f32, f32)
[src]
impl Mul<f32> for FPosition
[src]
type Output = Self
The resulting type after applying the *
operator.
fn mul(self, rhs: f32) -> Self::Output
[src]
impl MulAssign<f32> for FPosition
[src]
fn mul_assign(&mut self, rhs: f32)
[src]
impl Neg for FPosition
[src]
type Output = Self
The resulting type after applying the -
operator.
fn neg(self) -> Self::Output
[src]
impl PartialEq<FPosition> for FPosition
[src]
impl Rem<f32> for FPosition
[src]
type Output = Self
The resulting type after applying the %
operator.
fn rem(self, rhs: f32) -> Self::Output
[src]
impl RemAssign<f32> for FPosition
[src]
fn rem_assign(&mut self, rhs: f32)
[src]
impl StructuralPartialEq for FPosition
[src]
impl Sub<(f32, f32)> for FPosition
[src]
type Output = Self
The resulting type after applying the -
operator.
fn sub(self, rhs: (f32, f32)) -> Self::Output
[src]
impl Sub<FPosition> for FPosition
[src]
type Output = Self
The resulting type after applying the -
operator.
fn sub(self, rhs: Self) -> Self::Output
[src]
impl Sub<f32> for FPosition
[src]
type Output = Self
The resulting type after applying the -
operator.
fn sub(self, rhs: f32) -> Self::Output
[src]
impl SubAssign<(f32, f32)> for FPosition
[src]
impl SubAssign<f32> for FPosition
[src]
fn sub_assign(&mut self, rhs: f32)
[src]
Auto Trait Implementations
impl RefUnwindSafe for FPosition
impl Send for FPosition
impl Sync for FPosition
impl Unpin for FPosition
impl UnwindSafe for FPosition
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Downcast for T where
T: Any,
T: Any,
fn into_any(self: Box<T>) -> Box<dyn Any + 'static>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
fn as_any(&self) -> &(dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
impl<T> DowncastSync for T where
T: Send + Sync + Any,
T: Send + Sync + Any,
impl<T> Erased for T
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, Rhs> NumAssignOps<Rhs> for T where
T: AddAssign<Rhs> + SubAssign<Rhs> + MulAssign<Rhs> + DivAssign<Rhs> + RemAssign<Rhs>,
[src]
T: AddAssign<Rhs> + SubAssign<Rhs> + MulAssign<Rhs> + DivAssign<Rhs> + RemAssign<Rhs>,
impl<T, Rhs, Output> NumOps<Rhs, Output> for T where
T: Sub<Rhs, Output = Output> + Mul<Rhs, Output = Output> + Div<Rhs, Output = Output> + Add<Rhs, Output = Output> + Rem<Rhs, Output = Output>,
[src]
T: Sub<Rhs, Output = Output> + Mul<Rhs, Output = Output> + Div<Rhs, Output = Output> + Add<Rhs, Output = Output> + Rem<Rhs, Output = Output>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,