Issue #2075 - Part 1: Rename offset-* logical properties to inset-*

This adds aliases behind a pref with the old offset-* names
This commit is contained in:
Moonchild 2022-12-30 22:37:02 +00:00 • committed by roytam1
commit 0c37c0db8f
3 changed files with 32 additions and 12 deletions

View file

@ -50,6 +50,22 @@ CSS_PROP_ALIAS(word-wrap,
overflow_wrap, overflow_wrap,
WordWrap, WordWrap,
"") "")
CSS_PROP_ALIAS(offset-block-start,
inset_block_start,
OffsetBlockStart,
"layout.css.offset-logical-properties.enabled")
CSS_PROP_ALIAS(offset-block-end,
inset_block_end,
OffsetBlockEnd,
"layout.css.offset-logical-properties.enabled")
CSS_PROP_ALIAS(offset-inline-start,
inset_inline_start,
OffsetInlineStart,
"layout.css.offset-logical-properties.enabled")
CSS_PROP_ALIAS(offset-inline-end,
inset_inline_end,
OffsetInlineEnd,
"layout.css.offset-logical-properties.enabled")
CSS_PROP_ALIAS(-moz-transform-origin, CSS_PROP_ALIAS(-moz-transform-origin,
transform_origin, transform_origin,
MozTransformOrigin, MozTransformOrigin,

View file

@ -2979,9 +2979,9 @@ CSS_PROP_POSITION(
offsetof(nsStylePosition, mObjectPosition), offsetof(nsStylePosition, mObjectPosition),
eStyleAnimType_Custom) eStyleAnimType_Custom)
CSS_PROP_LOGICAL( CSS_PROP_LOGICAL(
offset-block-end, inset-block-end,
offset_block_end, inset_block_end,
OffsetBlockEnd, InsetBlockEnd,
CSS_PROPERTY_PARSE_VALUE | CSS_PROPERTY_PARSE_VALUE |
CSS_PROPERTY_STORES_CALC | CSS_PROPERTY_STORES_CALC |
CSS_PROPERTY_GETCS_NEEDS_LAYOUT_FLUSH | CSS_PROPERTY_GETCS_NEEDS_LAYOUT_FLUSH |
@ -2996,9 +2996,9 @@ CSS_PROP_LOGICAL(
CSS_PROP_NO_OFFSET, CSS_PROP_NO_OFFSET,
eStyleAnimType_None) eStyleAnimType_None)
CSS_PROP_LOGICAL( CSS_PROP_LOGICAL(
offset-block-start, inset-block-start,
offset_block_start, inset_block_start,
OffsetBlockStart, InsetBlockStart,
CSS_PROPERTY_PARSE_VALUE | CSS_PROPERTY_PARSE_VALUE |
CSS_PROPERTY_STORES_CALC | CSS_PROPERTY_STORES_CALC |
CSS_PROPERTY_GETCS_NEEDS_LAYOUT_FLUSH | CSS_PROPERTY_GETCS_NEEDS_LAYOUT_FLUSH |
@ -3012,9 +3012,9 @@ CSS_PROP_LOGICAL(
CSS_PROP_NO_OFFSET, CSS_PROP_NO_OFFSET,
eStyleAnimType_None) eStyleAnimType_None)
CSS_PROP_LOGICAL( CSS_PROP_LOGICAL(
offset-inline-end, inset-inline-end,
offset_inline_end, inset_inline_end,
OffsetInlineEnd, InsetInlineEnd,
CSS_PROPERTY_PARSE_VALUE | CSS_PROPERTY_PARSE_VALUE |
CSS_PROPERTY_STORES_CALC | CSS_PROPERTY_STORES_CALC |
CSS_PROPERTY_GETCS_NEEDS_LAYOUT_FLUSH | CSS_PROPERTY_GETCS_NEEDS_LAYOUT_FLUSH |
@ -3028,9 +3028,9 @@ CSS_PROP_LOGICAL(
CSS_PROP_NO_OFFSET, CSS_PROP_NO_OFFSET,
eStyleAnimType_None) eStyleAnimType_None)
CSS_PROP_LOGICAL( CSS_PROP_LOGICAL(
offset-inline-start, inset-inline-start,
offset_inline_start, inset_inline_start,
OffsetInlineStart, InsetInlineStart,
CSS_PROPERTY_PARSE_VALUE | CSS_PROPERTY_PARSE_VALUE |
CSS_PROPERTY_STORES_CALC | CSS_PROPERTY_STORES_CALC |
CSS_PROPERTY_GETCS_NEEDS_LAYOUT_FLUSH | CSS_PROPERTY_GETCS_NEEDS_LAYOUT_FLUSH |

View file

@ -2570,6 +2570,10 @@ pref("layout.css.background-blend-mode.enabled", true);
// Is support for background-clip:text enabled? // Is support for background-clip:text enabled?
pref("layout.css.background-clip-text.enabled", true); pref("layout.css.background-clip-text.enabled", true);
// Is support for the non-standard offset-* logical property aliases enabled?
// These map to their inset-* equivalents.
pref("layout.css.offset-logical-properties.enabled", true);
// Is support for CSS text-combine-upright (tate-chu-yoko) enabled? // Is support for CSS text-combine-upright (tate-chu-yoko) enabled?
pref("layout.css.text-combine-upright.enabled", true); pref("layout.css.text-combine-upright.enabled", true);
// Is support for CSS text-combine-upright: digits 2-4 enabled? // Is support for CSS text-combine-upright: digits 2-4 enabled?