stylo: Support remaining display property values.
draft
stylo: Support remaining display property values.
MozReview-Commit-ID: HjLu7t2g7gF
--- a/servo/components/style/properties/gecko.mako.rs
+++ b/servo/components/style/properties/gecko.mako.rs
@@ -1023,19 +1023,23 @@ fn static_assert() {
scroll-snap-type-y""" %>
<%self:impl_trait style_struct_name="Box" skip_longhands="${skip_box_longhands}">
// We manually-implement the |display| property until we get general
// infrastructure for preffing certain values.
<% display_keyword = Keyword("display", "inline block inline-block table inline-table table-row-group " +
"table-header-group table-footer-group table-row table-column-group " +
"table-column table-cell table-caption list-item flex none " +
- "-moz-box -moz-inline-box",
+ "inline-flex grid inline-grid ruby ruby-base ruby-base-container " +
+ "ruby-text ruby-text-container contents -webkit-box -webkit-inline-box " +
+ "-moz-box -moz-inline-box -moz-grid -moz-inline-grid -moz-grid-group " +
+ "-moz-grid-line -moz-stack -moz-inline-stack -moz-deck -moz-popup " +
+ "-moz-groupbox",
gecko_enum_prefix="StyleDisplay",
- gecko_inexhaustive=True) %>
+ gecko_strip_moz_prefix=False) %>
${impl_keyword('display', 'mDisplay', display_keyword, True)}
// overflow-y is implemented as a newtype of overflow-x, so we need special handling.
// We could generalize this if we run into other newtype keywords.
<% overflow_x = data.longhands_by_name["overflow-x"] %>
pub fn set_overflow_y(&mut self, v: longhands::overflow_y::computed_value::T) {
use properties::longhands::overflow_x::computed_value::T as BaseType;
// FIXME(bholley): Align binary representations and ditch |match| for cast + static_asserts
--- a/servo/components/style/properties/longhand/box.mako.rs
+++ b/servo/components/style/properties/longhand/box.mako.rs
@@ -17,17 +17,21 @@
<%
values = """inline block inline-block
table inline-table table-row-group table-header-group table-footer-group
table-row table-column-group table-column table-cell table-caption
list-item flex
none
""".split()
if product == "gecko":
- values += "-moz-box -moz-inline-box".split()
+ values += """inline-flex grid inline-grid ruby ruby-base ruby-base-container
+ ruby-text ruby-text-container contents -webkit-box -webkit-inline-box
+ -moz-box -moz-inline-box -moz-grid -moz-inline-grid -moz-grid-group
+ -moz-grid-line -moz-stack -moz-inline-stack -moz-deck -moz-popup
+ -moz-groupbox""".split()
%>
pub use self::computed_value::T as SpecifiedValue;
use values::computed::ComputedValueAsSpecified;
use style_traits::ToCss;
use values::NoViewportPercentage;
impl NoViewportPercentage for SpecifiedValue {}
pub mod computed_value {