diff options
author | Oriol Brufau <obrufau@igalia.com> | 2024-04-29 12:40:44 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-04-29 10:40:44 +0000 |
commit | d490fdf83c84871ecf92f6ba9ca4216e41e0a977 (patch) | |
tree | 618b25534ece883913cf09fb8c4fb037651c7a16 /python/servo/platform/base.py | |
parent | a1f8c19355f7e0e673511c24feeae60d47f19c1c (diff) | |
download | servo-d490fdf83c84871ecf92f6ba9ca4216e41e0a977.tar.gz servo-d490fdf83c84871ecf92f6ba9ca4216e41e0a977.zip |
Turn white-space into a shorthand (#32146)
Bumps Stylo to servo/stylo#37
`white-space` is split into `white-space-collapse` and `text-wrap-mode`:
| white-space | white-space-collapse | text-wrap-mode |
| ----------- | -------------------- | -------------- |
| normal | collapse | wrap |
| nowrap | collapse | nowrap |
| pre-wrap | preserve | wrap |
| pre | preserve | nowrap |
| pre-line | preserve-breaks | wrap |
| - | preserve-breaks | nowrap |
Note this introduces a combination that wasn't previously possible,
but I think the existing logic can handle it well enough.
The old `allow_wrap()` is replaced by checking whether `text-wrap-mode`
is set to `wrap`.
The old `preserve_newlines()` is replaced by checking whether
`white-space-collapse` is *not* set to `collapse`.
The old `preserve_spaces()` is replaced by checking whether
`white-space-collapse` is set to `preserve`.
Diffstat (limited to 'python/servo/platform/base.py')
0 files changed, 0 insertions, 0 deletions