Struct iui::draw::Transform [−][src]
pub struct Transform { /* fields omitted */ }
A transformation which can be applied to the contents of a DrawContext.
Methods
impl Transform
[src]
impl Transform
pub fn from_ui_matrix(ui_matrix: &uiDrawMatrix) -> Transform
[src]
pub fn from_ui_matrix(ui_matrix: &uiDrawMatrix) -> Transform
Create a Transform from an existing raw uiDrawMatrix.
pub fn identity() -> Transform
[src]
pub fn identity() -> Transform
Create a new Transform that does nothing.
pub fn translate(&mut self, x: f64, y: f64)
[src]
pub fn translate(&mut self, x: f64, y: f64)
Modify this Transform to translate by the given amounts.
pub fn scale(&mut self, x_center: f64, y_center: f64, x: f64, y: f64)
[src]
pub fn scale(&mut self, x_center: f64, y_center: f64, x: f64, y: f64)
Modify this Transform to scale by the given amounts from the given center.
pub fn rotate(&mut self, x: f64, y: f64, angle: f64)
[src]
pub fn rotate(&mut self, x: f64, y: f64, angle: f64)
Modify this Transform to rotate around the given center by the given angle.
pub fn skew(&mut self, x: f64, y: f64, xamount: f64, yamount: f64)
[src]
pub fn skew(&mut self, x: f64, y: f64, xamount: f64, yamount: f64)
Modify this Transform to skew from the given point by the given amount.
pub fn compose(&mut self, src: &Transform)
[src]
pub fn compose(&mut self, src: &Transform)
Compose this Transform with another, creating a Transform which represents both operations.
pub fn invertible(&self) -> bool
[src]
pub fn invertible(&self) -> bool
Returns true if inverting this Transform is possible.
pub fn invert(&mut self) -> bool
[src]
pub fn invert(&mut self) -> bool
Attempts to invert the Transform, returning true if it succeeded and false if it failed.
pub fn transform_point(&self, point: (f64, f64)) -> (f64, f64)
[src]
pub fn transform_point(&self, point: (f64, f64)) -> (f64, f64)
pub fn transform_size(&self, size: (f64, f64)) -> (f64, f64)
[src]
pub fn transform_size(&self, size: (f64, f64)) -> (f64, f64)
pub fn ptr(&self) -> *mut uiDrawMatrix
[src]
pub fn ptr(&self) -> *mut uiDrawMatrix
Trait Implementations
impl Copy for Transform
[src]
impl Copy for Transform
impl Clone for Transform
[src]
impl Clone for Transform
fn clone(&self) -> Transform
[src]
fn clone(&self) -> Transform
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl PartialEq for Transform
[src]
impl PartialEq for Transform
fn eq(&self, other: &Transform) -> bool
[src]
fn eq(&self, other: &Transform) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Transform) -> bool
[src]
fn ne(&self, other: &Transform) -> bool
This method tests for !=
.
impl Debug for Transform
[src]
impl Debug for Transform
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl Mul<Transform> for Transform
[src]
impl Mul<Transform> for Transform