mirror of
https://github.com/servo/servo.git
synced 2025-08-06 06:00:15 +01:00
Auto merge of #16036 - chenpighead:text-size-adjust, r=upsuper
Stylo: Add support for text-size-adjust property <!-- Please describe your changes on the following line: --> Gecko supports -{moz,webkit}-text-size-adjust properties, but it only supports auto and none value. Implement parsing/serialization for text-size-adjust property and its gecko glue. --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: --> - [X] `./mach build -d` does not report any errors - [X] `./mach test-tidy` does not report any errors - [X] These changes fix #16002 (github issue number if applicable). <!-- Either: --> - [ ] There are tests for these changes OR - [ ] These changes do not require tests because _____ <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. --> <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/16036) <!-- Reviewable:end -->
This commit is contained in:
commit
103e827948
2 changed files with 12 additions and 1 deletions
|
@ -2606,7 +2606,7 @@ fn static_assert() {
|
||||||
|
|
||||||
<%self:impl_trait style_struct_name="InheritedText"
|
<%self:impl_trait style_struct_name="InheritedText"
|
||||||
skip_longhands="text-align text-emphasis-style text-shadow line-height letter-spacing word-spacing
|
skip_longhands="text-align text-emphasis-style text-shadow line-height letter-spacing word-spacing
|
||||||
-webkit-text-stroke-width text-emphasis-position -moz-tab-size">
|
-webkit-text-stroke-width text-emphasis-position -moz-tab-size -moz-text-size-adjust">
|
||||||
|
|
||||||
<% text_align_keyword = Keyword("text-align", "start end left right center justify -moz-center -moz-left " +
|
<% text_align_keyword = Keyword("text-align", "start end left right center justify -moz-center -moz-left " +
|
||||||
"-moz-right match-parent char") %>
|
"-moz-right match-parent char") %>
|
||||||
|
@ -2789,6 +2789,10 @@ fn static_assert() {
|
||||||
|
|
||||||
<%call expr="impl_coord_copy('_moz_tab_size', 'mTabSize')"></%call>
|
<%call expr="impl_coord_copy('_moz_tab_size', 'mTabSize')"></%call>
|
||||||
|
|
||||||
|
<% text_size_adjust_keyword = Keyword("text-size-adjust", "auto none") %>
|
||||||
|
|
||||||
|
${impl_keyword('_moz_text_size_adjust', 'mTextSizeAdjust', text_size_adjust_keyword, need_clone=False)}
|
||||||
|
|
||||||
</%self:impl_trait>
|
</%self:impl_trait>
|
||||||
|
|
||||||
<%self:impl_trait style_struct_name="Text"
|
<%self:impl_trait style_struct_name="Text"
|
||||||
|
|
|
@ -169,6 +169,13 @@ ${helpers.single_keyword("hyphens", "manual none auto",
|
||||||
products="gecko", animatable=False, extra_prefixes="moz",
|
products="gecko", animatable=False, extra_prefixes="moz",
|
||||||
spec="https://drafts.csswg.org/css-text/#propdef-hyphens")}
|
spec="https://drafts.csswg.org/css-text/#propdef-hyphens")}
|
||||||
|
|
||||||
|
// TODO: Support <percentage>
|
||||||
|
${helpers.single_keyword("-moz-text-size-adjust", "auto none",
|
||||||
|
gecko_constant_prefix="NS_STYLE_TEXT_SIZE_ADJUST",
|
||||||
|
products="gecko", animatable=False,
|
||||||
|
spec="https://drafts.csswg.org/css-size-adjust/#adjustment-control",
|
||||||
|
alias="-webkit-text-size-adjust")}
|
||||||
|
|
||||||
${helpers.predefined_type("text-indent",
|
${helpers.predefined_type("text-indent",
|
||||||
"LengthOrPercentage",
|
"LengthOrPercentage",
|
||||||
"computed::LengthOrPercentage::Length(Au(0))",
|
"computed::LengthOrPercentage::Length(Au(0))",
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue