Struct usvg::Rect
[−]
[src]
pub struct Rect { pub x: f64, pub y: f64, pub width: f64, pub height: f64, }
A rect representation.
Fields
x: f64
y: f64
width: f64
height: f64
Methods
impl Rect
[src]
pub fn new(x: f64, y: f64, width: f64, height: f64) -> Self
[src]
Creates a new Rect
from values.
pub fn size(&self) -> Size
[src]
Returns rect's size.
pub fn transform(&self, ts: Transform) -> Self
[src]
Returns transformed rect.
Trait Implementations
impl Clone for Rect
[src]
fn clone(&self) -> Rect
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Copy for Rect
[src]
impl PartialEq for Rect
[src]
fn eq(&self, __arg_0: &Rect) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Rect) -> bool
[src]
This method tests for !=
.
impl Debug for Rect
[src]
fn fmt(&self, f: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more
impl Display for Rect
[src]
fn fmt(&self, f: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more