layout: Implement 2D CSS transforms per CSS-TRANSFORMS § 5, 6, 7, and 8.

This commit is contained in:
Patrick Walton 2014-12-31 14:08:08 -05:00
parent 7bd6cb0091
commit d10627a2b3
14 changed files with 964 additions and 35 deletions

View file

@ -251,6 +251,12 @@ impl Au {
((s as f64) / 60f64).round() as isize
}
#[inline]
pub fn to_frac32_px(&self) -> f32 {
let Au(s) = *self;
(s as f32) / 60f32
}
#[inline]
pub fn to_subpx(&self) -> f64 {
let Au(s) = *self;