[css-logical] Implement logical property groups
In order to have proper CSSOM support for logical properties, we will need to determine whether two properties belong to the same logical property group but with a different mapping logic. Before this patch, we only knew the physical properties belonging to the same logical property group as a given logical property. But given a physical property, we didn't know if there were logical properties that could map to it. Therefore this patch adds: - CSSProperty::IsInLogicalPropertyGroup, which returns true for logical properties and for their corresponding physical ones. - CSSProperty::IsInSameLogicalPropertyGroupWithDifferentMappingLogic which checks what the name says, given a CSSPropertyID. - CSSDirectionAwareResolver::LogicalMapping and PhysicalMapping, representing the properties of a logical property group with a flow- relative or a physical mapping logic, respectively. In css_properties.json5, the terminology becomes closer to the spec: - direction_aware_options becomes logical_property_group, and physical properties have it too. - direction_aware_options.physical_group becomes logical_property_group.name - direction_aware_options.resolver accepts physical axis and box sides (horizontal, vertical, top, right, bottom, left). This patch should have no effect in practice. Bug: 1155858 Change-Id: I1a01e80a2405315d9caaf057e6bfd465f3615cce Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2574940 Commit-Queue: Oriol Brufau <obrufau@igalia.com> Reviewed-by:Anders Hartvoll Ruud <andruud@chromium.org> Cr-Commit-Position: refs/heads/master@{#834200}
Showing
This diff is collapsed.
This diff is collapsed.
Please register or sign in to comment