Trait rsvg::float_eq_cairo::FixedEqCairo
source · pub trait FixedEqCairo {
// Required method
fn fixed_eq_cairo(&self, other: &Self) -> bool;
}
Expand description
Implements a method to check whether two f64
numbers would have
the same fixed-point representation in Cairo.
This generally means that the absolute difference between them, when taken as floating-point numbers, is less than the smallest representable fraction that Cairo can represent in fixed-point.
Implementation detail: Cairo fixed-point numbers use 24 bits for the integral part, and 8 bits for the fractional part. That is, the smallest fraction they can represent is 1/256.
Required Methods§
fn fixed_eq_cairo(&self, other: &Self) -> bool
Object Safety§
This trait is not object safe.