mirror of
https://github.com/servo/servo.git
synced 2025-08-03 12:40:06 +01:00
Derive ToCss for MozImageRect
This commit is contained in:
parent
44eb8c8e4f
commit
fe19c3810c
5 changed files with 21 additions and 39 deletions
|
@ -17,7 +17,7 @@ use values::computed::position::Position;
|
|||
use values::generics::image::{CompatMode, ColorStop as GenericColorStop, EndingShape as GenericEndingShape};
|
||||
use values::generics::image::{Gradient as GenericGradient, GradientItem as GenericGradientItem};
|
||||
use values::generics::image::{Image as GenericImage, GradientKind as GenericGradientKind};
|
||||
use values::generics::image::{ImageRect as GenericImageRect, LineDirection as GenericLineDirection};
|
||||
use values::generics::image::{LineDirection as GenericLineDirection, MozImageRect as GenericMozImageRect};
|
||||
use values::specified::image::LineDirection as SpecifiedLineDirection;
|
||||
use values::specified::position::{X, Y};
|
||||
|
||||
|
@ -26,7 +26,7 @@ pub type ImageLayer = Either<None_, Image>;
|
|||
|
||||
/// Computed values for an image according to CSS-IMAGES.
|
||||
/// https://drafts.csswg.org/css-images/#image-values
|
||||
pub type Image = GenericImage<Gradient, ImageRect>;
|
||||
pub type Image = GenericImage<Gradient, MozImageRect>;
|
||||
|
||||
/// Computed values for a CSS gradient.
|
||||
/// https://drafts.csswg.org/css-images/#gradients
|
||||
|
@ -65,8 +65,8 @@ pub type GradientItem = GenericGradientItem<RGBA, LengthOrPercentage>;
|
|||
/// A computed color stop.
|
||||
pub type ColorStop = GenericColorStop<RGBA, LengthOrPercentage>;
|
||||
|
||||
/// Computed values for ImageRect.
|
||||
pub type ImageRect = GenericImageRect<NumberOrPercentage>;
|
||||
/// Computed values for MozImageRect.
|
||||
pub type MozImageRect = GenericMozImageRect<NumberOrPercentage>;
|
||||
|
||||
impl GenericLineDirection for LineDirection {
|
||||
fn points_downwards(&self) -> bool {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue