Closed
Bug 389707
Opened 18 years ago
Closed 17 years ago
text-transform: capitalize doesn't capitalize all words
Categories
(Core :: Layout: Text and Fonts, defect, P2)
Tracking
()
VERIFIED
FIXED
People
(Reporter: ispiked, Assigned: roc)
References
Details
(Keywords: regression, testcase, Whiteboard: [dbaron-1.9:RwCt])
Attachments
(4 files, 1 obsolete file)
394 bytes,
text/html
|
Details | |
413 bytes,
text/html
|
Details | |
33.73 KB,
patch
|
Details | Diff | Splinter Review | |
2.11 KB,
patch
|
Details | Diff | Splinter Review |
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a7pre) Gecko/2007072605 Minefield/3.0a7pre
First seen in the navigational menu on amazon.com.
Steps to reproduce:
1. Load the testcase.
Actual results:
Not all the first letters of the words are capitalized.
Expected results:
All the first letters of the words are capitalized.
This is a regression from bug 367177.
Reporter | ||
Updated•18 years ago
|
Summary: text-transform: capitalize is doesn't capitalize all words → text-transform: capitalize doesn't capitalize all words
Assignee | ||
Comment 1•18 years ago
|
||
D'oh, I should have thought of that! Hmm.
Assignee | ||
Comment 3•17 years ago
|
||
Yeah, I think this should block.
Assignee | ||
Updated•17 years ago
|
Assignee: nobody → roc
Assignee | ||
Updated•17 years ago
|
Flags: blocking1.9? → blocking1.9+
Assignee | ||
Comment 4•17 years ago
|
||
The right way to implement capitalization seems to be to capitalize any letter that's preceded by the start of the block or white-space, followed by zero or more Ps, Pi, Po, Pf, Pe characters.
I think I'll do this by adding support to nsLineBreaker to return capitalization hints. But I can't do that until the patch in bug 393096 lands.
Depends on: 393096
Assignee | ||
Updated•17 years ago
|
Whiteboard: [depends on 393096]
Whiteboard: [depends on 393096] → [depends on 393096][dbaron-1.9:RwCt]
Assignee | ||
Updated•17 years ago
|
Whiteboard: [depends on 393096][dbaron-1.9:RwCt] → [dbaron-1.9:RwCt]
Assignee | ||
Comment 5•17 years ago
|
||
This is more or less what I said I was going to do.
We add functionality to nsLineBreaker to determine which characters should be capitalized. This is the right place because it has all necessary context. This requires moving the punctuation CCmap to nsContentUtils.
Then we hook that up with nsTextRunTransformations to store in nsTransformedTextRun which characters should be capitalized.
Attachment #285646 -
Flags: review?(smontagu)
Assignee | ||
Comment 6•17 years ago
|
||
This testcase tests punctuation and I'll check it in as a reftest.
Assignee | ||
Updated•17 years ago
|
Whiteboard: [dbaron-1.9:RwCt] → [dbaron-1.9:RwCt][need review]
Comment 7•17 years ago
|
||
Comment on attachment 285646 [details] [diff] [review]
fix capitalization
I tried this with various funky characters, and it doesn't capitalize after ZWJ ZWNJ LRM hyphen and SHY (even when breaking the line at the hyphen or SHY), but does capitalize after ZWSP, all of which seems correct to me.
Attachment #285646 -
Flags: review?(smontagu) → review+
Assignee | ||
Updated•17 years ago
|
Whiteboard: [dbaron-1.9:RwCt][need review] → [dbaron-1.9:RwCt][need landing]
Assignee | ||
Updated•17 years ago
|
Priority: -- → P1
Assignee | ||
Updated•17 years ago
|
Priority: P1 → P2
Comment 8•17 years ago
|
||
The second hunk of the layout/generic/nsTextFrameThebes.cpp changes is completely bitrot. Needs new patch.
Whiteboard: [dbaron-1.9:RwCt][need landing] → [dbaron-1.9:RwCt][needs new patch]
Assignee | ||
Comment 9•17 years ago
|
||
Attachment #285646 -
Attachment is obsolete: true
Assignee | ||
Updated•17 years ago
|
Whiteboard: [dbaron-1.9:RwCt][needs new patch] → [dbaron-1.9:RwCt][needs landing]
Assignee | ||
Comment 10•17 years ago
|
||
Assignee | ||
Comment 11•17 years ago
|
||
Checked in.
Status: NEW → RESOLVED
Closed: 17 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Comment 12•17 years ago
|
||
this bug might break the Japanese line-breaking. the Japanese text is sometimes broken at shortly even when the right side has space. (open parentheses sometimes force breaking the lines.) I'll check it ASAP.
Comment 13•17 years ago
|
||
er, please ignore comment 12. the bug is older than this fix. (bug 404087)
Updated•17 years ago
|
Whiteboard: [dbaron-1.9:RwCt][needs landing] → [dbaron-1.9:RwCt]
Comment 14•17 years ago
|
||
Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9pre) Gecko/2008050810 Minefield/3.0pre
Verified.
Status: RESOLVED → VERIFIED
You need to log in
before you can comment on or make changes to this bug.
Description
•