Bug 1957541: Enable font-variation-settings property for servo engine (r=jwatt)
Signed-off-by: Nico Burns <nico@nicoburns.com> Differential Revision: https://phabricator.services.mozilla.com/D243750
This commit is contained in:
@@ -242,7 +242,8 @@ ${helpers.predefined_type(
|
||||
${helpers.predefined_type(
|
||||
"font-variation-settings",
|
||||
"FontVariationSettings",
|
||||
engines="gecko",
|
||||
engines="gecko servo",
|
||||
servo_pref="layout.unimplemented",
|
||||
gecko_pref="layout.css.font-variations.enabled",
|
||||
has_effect_on_gecko_scrollbars=False,
|
||||
initial_value="computed::FontVariationSettings::normal()",
|
||||
|
||||
@@ -84,6 +84,7 @@ where
|
||||
ToResolvedValue,
|
||||
ToShmem,
|
||||
)]
|
||||
#[cfg_attr(feature = "servo", derive(Deserialize, Serialize))]
|
||||
pub struct VariationValue<Number> {
|
||||
/// A four-character tag, packed into a u32 (one byte per character).
|
||||
#[animation(constant)]
|
||||
@@ -102,6 +103,7 @@ impl<T> TaggedFontValue for VariationValue<T> {
|
||||
#[derive(
|
||||
Clone, Debug, Eq, MallocSizeOf, PartialEq, SpecifiedValueInfo, ToAnimatedValue, ToCss, ToResolvedValue, ToShmem,
|
||||
)]
|
||||
#[cfg_attr(feature = "servo", derive(Deserialize, Serialize))]
|
||||
#[css(comma)]
|
||||
pub struct FontSettings<T>(#[css(if_empty = "normal", iterable)] pub Box<[T]>);
|
||||
|
||||
@@ -154,6 +156,7 @@ impl<T: Parse> Parse for FontSettings<T> {
|
||||
ToResolvedValue,
|
||||
ToShmem,
|
||||
)]
|
||||
#[cfg_attr(feature = "servo", derive(Deserialize, Serialize))]
|
||||
pub struct FontTag(pub u32);
|
||||
|
||||
impl ToCss for FontTag {
|
||||
|
||||
Reference in New Issue
Block a user