Closed
Bug 93168
Opened 23 years ago
Closed 20 years ago
'text-transform: capitalize' causes collapsed/expanded letter spacing
Categories
(Core :: Layout: Text and Fonts, defect, P3)
Core
Layout: Text and Fonts
Tracking
()
RESOLVED
FIXED
Future
People
(Reporter: Eric.Zurcher, Assigned: rbs)
References
()
Details
(Keywords: css1, testcase, Whiteboard: [CSS1-5.4.5])
Attachments
(3 files)
206 bytes,
text/html
|
Details | |
326 bytes,
text/html
|
Details | |
709 bytes,
patch
|
bzbarsky
:
review+
bzbarsky
:
superreview+
asa
:
approval1.8b2+
|
Details | Diff | Splinter Review |
When the "capitalize" text transform is active, any <span> or </span> tags embedded within a word are expanded into spaces. Consider the document at http://www.w3.org/Style/CSS/Test/current/sec545.htm - at the end of the third text paragraph, the word "Letter" is rendered as "Lett er". The following small document also illustrates the problem: <html> <head> <style type="text/css"> .cap {text-transform: capitalize;} </style> </head> <body> abc<span>def<span class="cap">ghi<span>jkl</span>mno</span>pqr</span>stu </body> </html> This is rendered as "abcdefghi jkl mno pqrstu", rather than as "abcdefghijklmnopqrstu"
Comment 1•23 years ago
|
||
I am seeing this too. It seems that when mozilla applies the capitalize style, it inserts a space after the span if one is not already there. Therefore, you cannot do something like <span style="text-transform:capitalize;">l<span>oo</span>k</span>. This will produce "L ook" instead of "Look".
Status: UNCONFIRMED → NEW
Ever confirmed: true
Comment 2•23 years ago
|
||
->Style System. FYI, DOM Style is for dynamic modification of CSS and stylesheets.
Assignee: jst → dbaron
Component: DOM Style → Style System
I'm seeing compression rather than expansion between o and p. In any case, this is a layout bug.
Assignee: dbaron → karnaze
Component: Style System → Layout
Keywords: css1
QA Contact: ian → petersen
Summary: <span> and </span> tags result in spaces inserted within words when the "capitalize" text-transform is applied. → 'text-transform: capitalize' causes collapsed/expanded letter spacing
i see an expansion, not a compression between the o and the p. not table specific, over tot he core owner.
Assignee: karnaze → attinasi
Updated•23 years ago
|
Target Milestone: --- → mozilla1.2
Updated•23 years ago
|
Whiteboard: [CSS1-5.4.5]
Reconfirmed using FizzillaCFM/2002070913. Extra space seen between "i" and "j" in testcase attachment. Setting All/All.
OS: Windows NT → All
Hardware: PC → All
Comment 7•22 years ago
|
||
.
Assignee: attinasi → font
Component: Layout → Layout: Fonts and Text
QA Contact: cpetersen0953 → ian
Target Milestone: mozilla1.2alpha → ---
Updated•22 years ago
|
Priority: -- → P3
Target Milestone: --- → Future
Comment 8•20 years ago
|
||
Due to different code paths, the bug arises from the fact that the text is measured in capitalized form and rendered as uncapitalized ('S' is wider than 's'). The patch gets the capitalization right (i.e., as |gCaseConv->ToTitle()| does).
Assignee: layout.fonts-and-text → rbs
Status: NEW → ASSIGNED
Attachment #179949 -
Flags: superreview?(bzbarsky)
Attachment #179949 -
Flags: review?(bzbarsky)
Comment 10•20 years ago
|
||
Comment on attachment 179949 [details] [diff] [review] fix Nice catch! r+sr=bzbarsky
Attachment #179949 -
Flags: superreview?(bzbarsky)
Attachment #179949 -
Flags: superreview+
Attachment #179949 -
Flags: review?(bzbarsky)
Attachment #179949 -
Flags: review+
Assignee | ||
Comment 11•20 years ago
|
||
Comment on attachment 179949 [details] [diff] [review] fix Asking approval for 1.8b2. A simple fix that was however hard to get.
Attachment #179949 -
Flags: approval1.8b2?
Comment 12•20 years ago
|
||
Comment on attachment 179949 [details] [diff] [review] fix a=asa
Attachment #179949 -
Flags: approval1.8b2? → approval1.8b2+
Assignee | ||
Comment 13•20 years ago
|
||
Checked in.
Status: ASSIGNED → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•