Small Caps font too small

VERIFIED INVALID

Status

()

Core
CSS Parsing and Computation
P3
normal
VERIFIED INVALID
18 years ago
2 years ago

People

(Reporter: Jerry Baker, Assigned: Pierre Saslawsky)

Tracking

Trunk
x86
Windows 2000
Points:
---

Firefox Tracking Flags

(blocking-b2g:2.2?, b2g-v2.1S ?)

Details

Attachments

(3 attachments)

(Reporter)

Description

18 years ago
This simple HTML/CSS is rendered way too small by Mozilla:

<p style="font-family: Verdana, Arial, sans-serif; font-size: 
x-small;font-weight: bold;font-variant: small-caps;">Here is some text</p>

I will attach a screenshot comparing IE5, NC 4.x and Mozilla's rendering of 
this.

Comment 1

18 years ago
Sounds more like a style system issue.
Assignee: troy → pierre
Component: Layout → Style System
QA Contact: petersen → chrisd
(Reporter)

Comment 2

18 years ago
Created attachment 6641 [details]
Same HTML/CSS for each
(Assignee)

Comment 3

18 years ago
IE doesn't support small-caps: it displays everything in caps.
Nav doesn't support small-caps either: it displays the string as-is.
Moz renders correctly:
- The upper-case letters (A-CNC-P-S) are identical to what we have in IE and Nav.
- The lower-case letter are scaled and rendered as small upper-case letters. If 
you think these letters are too small, increase the font-size: according to your 
code snippet, you are using 'x-small' which by definition isn't very big, 
especially when you shrink it even more. Closed as Invalid.
Status: NEW → RESOLVED
Last Resolved: 18 years ago
Resolution: --- → INVALID
(Reporter)

Comment 4

18 years ago
Umm. This is a problem. Are you suggesting that any sites that use this should 
now have to sniff browsers because Mozilla's "correctness" overrides the need to 
be somewhat compatible? If I set the font larger, it is going to be HUGE in IE5 
and NC 4.X. That is not acceptable.
(Reporter)

Comment 5

18 years ago
You are apparently mistaken about IE5. I have created an attachment showing how 
IE5 renders small-caps versus letters actually typed IN ALL CAPS. Both 
paragraphs were defined to have the same text size. This is the code used to 
produce the picture in the attachment:

-----HTML-----
<html>
<head>
<style type="text/css">
.test {  font-family: Verdana, Arial, Helvetica, sans-serif; font-size: small; 
font-weight: bold}
</style>
</head>

<body>
<p class="test" style="font-variant: small-caps;">this is some text </p>
<p class="test">THIS IS SOME TEXT</p>
<p>Theoretically P1 will be identical to P2.</p>
</body>
</html>
-----HTML-----
(Reporter)

Comment 6

18 years ago
Created attachment 6648 [details]
Alas, IE does support small-caps
(Assignee)

Comment 7

18 years ago
It depends on the platform and the version number. The beta version of IE5 on 
Macintosh is the only one which supports small-caps correctly, like Mozilla and 
according to the spec (see http://www.w3.org/TR/REC-CSS2/fonts.html#propdef-font-
variant). As a summary, the spec says for small-caps:
- Display upper-case as usual.
- Display lower-case as upper-case but smaller than normal upper-case (it doesn't 
say how much smaller).

IE5 on Windows converts lower-case letters to upper-case and displays the 
resulting string one size smaller than the normal size. Both things are wrong:
1) You cannot tell upper-case letters from lower-case anymore.
2) Upper-case letters shouldn't be smaller than normal text.

IE4.5 on Mac simply convert lower-case to upper-case.

Nav4x doesn't support small-caps at all. The attribute is ignored.

Since the behaviors of currently available browsers are all different and all 
wrong in their own way, we can't do a quirk that satisfies everybody and we just 
follow the spec. However I agree that Moz small-caps are a bit too small. I 
changed the ratio from 0.7 to 0.8, the same as MacIE5.
(Assignee)

Comment 8

18 years ago
Created attachment 6692 [details]
A better testcase to try with WinIE5, Nav4x, MacIE4.5, MacIE5 and Moz
(Assignee)

Comment 9

18 years ago
FYI with the fix above, Moz and MacIE5 have the exact same display for small-caps 
which is not surprising since they share Todd Fahrner's font sizing algorithm. 
Hopefully WinIE5.5 will support it too.

Comment 10

18 years ago
Verified invalid
Status: RESOLVED → VERIFIED
(Assignee)

Comment 11

18 years ago
*** Bug 1516 has been marked as a duplicate of this bug. ***
(Assignee)

Comment 12

18 years ago
*** Bug 1516 has been marked as a duplicate of this bug. ***
(Reporter)

Comment 13

16 years ago
Mass removing self from CC list.
(Reporter)

Comment 14

16 years ago
Now I feel sumb because I have to add back. Sorry for the spam.

Comment 15

2 years ago
[Tracking Requested - why for this release]:
blocking-b2g: --- → 2.2?
status-b2g-v2.1S: --- → ?
You need to log in before you can comment on or make changes to this bug.