layout: Add initial support for text-transform (#31396)

This adds basic support for `text-transform` in a way that is more
complete than legacy layout. There are still many missing elements of
proper `text-transform` support such as:

1. Support for `full-width` and `full-size-kana`
2. Support for grapheme based uppercasing, lowercasing, and
   capitalization. These are all done per-code point right now.
3. Support for the language-specific `SpecialCasing.txt` cases for case
   mapping such as the ones for Irish and Turkish.

Co-authored-by: Rakhi Sharma <atbrakhi@igalia.com>
This commit is contained in:
Martin Robinson 2024-02-22 15:15:59 +01:00 committed by GitHub
parent f60e5e767b
commit d8b326528b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
105 changed files with 181 additions and 292 deletions

View file

@ -41,12 +41,6 @@
[Property overflow-wrap inherits]
expected: FAIL
[Property text-transform has initial value none]
expected: FAIL
[Property text-transform inherits]
expected: FAIL
[Property word-break has initial value normal]
expected: FAIL

View file

@ -1,30 +1,3 @@
[text-transform-computed.html]
[Property text-transform value 'none']
expected: FAIL
[Property text-transform value 'capitalize']
expected: FAIL
[Property text-transform value 'uppercase']
expected: FAIL
[Property text-transform value 'lowercase']
expected: FAIL
[Property text-transform value 'full-width']
expected: FAIL
[Property text-transform value 'full-size-kana']
expected: FAIL
[Property text-transform value 'capitalize full-width']
expected: FAIL
[Property text-transform value 'full-width full-size-kana']
expected: FAIL
[Property text-transform value 'uppercase full-width full-size-kana']
expected: FAIL
[Property text-transform value 'math-auto']
expected: FAIL

View file

@ -1,57 +1,3 @@
[text-transform-valid.html]
[e.style['text-transform'\] = "none" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "capitalize" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "uppercase" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "lowercase" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "full-width" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "full-size-kana" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "capitalize full-width" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "uppercase full-size-kana" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "full-width full-size-kana" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "full-width lowercase" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "full-size-kana capitalize" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "full-size-kana full-width" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "capitalize full-width full-size-kana" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "full-width full-size-kana uppercase" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "full-size-kana lowercase full-width" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "lowercase full-size-kana full-width" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "full-width uppercase full-size-kana" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "full-size-kana full-width capitalize" should set the property value]
expected: FAIL
[e.style['text-transform'\] = "math-auto" should set the property value]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-capitalize-001.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-capitalize-003.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-capitalize-005.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-capitalize-009.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-capitalize-010.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-capitalize-014.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-capitalize-018.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-capitalize-020.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-capitalize-022.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-capitalize-024.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-capitalize-028.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-capitalize-030.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-capitalize-031.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-capitalize-032.xht]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-capitalize-034.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-capitalize-035.html]
expected: FAIL

View file

@ -0,0 +1,2 @@
[text-transform-full-size-kana-001.html]
expected: FAIL

View file

@ -0,0 +1,2 @@
[text-transform-full-size-kana-002.html]
expected: FAIL

View file

@ -0,0 +1,2 @@
[text-transform-full-size-kana-003.html]
expected: FAIL

View file

@ -0,0 +1,2 @@
[text-transform-full-size-kana-004.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-lowercase-101.xht]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-lowercase-102.xht]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-tailoring-004.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-uppercase-101.xht]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-001.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-002.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-003.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-004.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-005.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-006.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-007.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-008.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-009.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-010.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-014.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-015.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-017.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-018.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-019.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-020.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-021.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-022.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-023.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-024.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-025.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-028.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-029.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-030.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-031.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-032.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-033.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-034.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-035.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-101.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-102.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-103.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-104.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-transform-upperlower-105.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[writing-system-text-transform-001.html]
expected: FAIL