Closed
Bug 739804
Opened 13 years ago
Closed 12 years ago
⇓ character entity and similar symbols cause excessive line-spacing under GDI
Categories
(Core :: Layout: Text and Fonts, defect)
Tracking
()
VERIFIED
FIXED
mozilla14
People
(Reporter: kiddm_mozilla, Assigned: jtd)
References
(Depends on 1 open bug, )
Details
(Keywords: regression)
Attachments
(11 files)
(deleted),
image/png
|
Details | |
(deleted),
text/plain
|
Details | |
(deleted),
image/png
|
Details | |
(deleted),
image/png
|
Details | |
(deleted),
image/png
|
Details | |
(deleted),
text/html
|
Details | |
(deleted),
image/png
|
Details | |
(deleted),
text/html
|
Details | |
(deleted),
patch
|
jfkthame
:
review+
akeybl
:
approval-mozilla-aurora+
akeybl
:
approval-mozilla-beta+
|
Details | Diff | Splinter Review |
(deleted),
patch
|
smontagu
:
review+
akeybl
:
approval-mozilla-aurora+
akeybl
:
approval-mozilla-beta+
|
Details | Diff | Splinter Review |
(deleted),
image/jpeg
|
Details |
User Agent: Mozilla/5.0 (Windows NT 5.1; rv:14.0) Gecko/20120327 Firefox/14.0a1
Build ID: 20120327031149
Steps to reproduce:
Viewed Version History table on http://lajollabridge.com/Software/ACBLmerge/ACBLmergeAbout.htm
Actual results:
Left column (version numbers) <td> contents do not appear aligned to the top of the cell despite CSS specifying such. Actually the CSS seems to be handled correctly but when the downward arrow (⇓) entity is highlighted, its bounding box is seen to extend far above and below the glyph, leading to the apparent alignment issue.
Expected results:
⇓ should have correct bounding box (as it does in Firefox 11) which then results in the correct rendering.
Comment 1•13 years ago
|
||
Don't see the issue, or don't understand the issue, with Mozilla/5.0 (Windows NT 5.1; rv:14.0) Gecko/20120328 Firefox/14.0a1 ID:20120328031211
Can you attach a screenshot highlighting the issue?
Keywords: fonts
Reporter | ||
Comment 2•13 years ago
|
||
Comment 3•13 years ago
|
||
Thanks for the quick reply with the screenshot Matthew.
WFM - Mozilla/5.0 (Windows NT 5.1; rv:14.0) Gecko/20120328 Firefox/14.0a1 ID:20120328031211
Does the issue still occur if you start Firefox in Safe Mode? http://support.mozilla.com/en-US/kb/Safe+Mode
How about with a new, empty profile? http://support.mozilla.com/en-US/kb/Basic%20Troubleshooting#w_8-make-a-new-profile
Reporter | ||
Comment 4•13 years ago
|
||
Yes, both in Safe Mode and with a new profile.
Comment 5•13 years ago
|
||
Please post the contents of about:support as a text attachment to this bug
Reporter | ||
Comment 6•13 years ago
|
||
Reporter | ||
Comment 7•13 years ago
|
||
I have observed another difference between Firefox 11 and Firefox 14 that may have some relevance for the current issue. The solid star (★) character entity seems too small in Firefox 11 relative to other character sizes. In Firefox 14 it seems to have the "right" size and incidentally a size that is identical to or at least very close to the size it has in IE8 and late versions of Chrome. I wonder if the change for that had some indirect impact on the ↓ bounding box.
Here is a URL that shows the star size issue:
http://www.lajollabridge.com/Events/2012/120311A.htm
Look for the part that says "* * * Masterpoint Winners * * *" near the top of the page. I'll attach a screenshot that shows it too.
Reporter | ||
Comment 8•13 years ago
|
||
Reporter | ||
Comment 9•13 years ago
|
||
Comment 10•13 years ago
|
||
I too can reproduce on a WinXP nightly (although not on Mac) with the page from comment 0 or this:
data:text/html,<div style="border:solid green 1px"><span style="font-size: 16px; border: solid red 1px">⇓</span></div>
(There's a much larger vertical space between the <span>'s border and the <div>'s on the nightly.)
I probably won't get to it, but finding a regression window would help with figuring this problem out. See https://quality.mozilla.org/docs/bugzilla/guide-to-triaging-bugs-for-firefox/finding-a-regression-window/
Status: UNCONFIRMED → NEW
Component: Untriaged → Layout
Ever confirmed: true
Keywords: regression,
regressionwindow-wanted
Product: Firefox → Core
QA Contact: untriaged → layout
Version: 14 Branch → Trunk
Reporter | ||
Comment 11•13 years ago
|
||
I can try to narrow the regression date down though I might not have time this week. I am pretty sure the I did not see the problem in Firefox 13 (when it was Nightly) and I think I saw the problem in Firefox 14 about a week before reporting the bug, deciding at that point that it wasn't one of those little Nightly glitches that gets cleaned up a few days later.
Updated•13 years ago
|
tracking-firefox14:
--- → ?
Comment 12•13 years ago
|
||
Cautiously marking this as tracked for FF14 since there could be unexpected web regressions caused by this bug.
Updated•13 years ago
|
Component: Layout → Layout: Text
QA Contact: layout → layout.fonts-and-text
Comment 13•13 years ago
|
||
I'm guessing this is a result of the font fallback optimizations in bug 705594, resulting in a STIX font with huge ascent/descent getting used for the ⇓ character, where previously a different font was being found.
Blocks: 705594
Comment 14•13 years ago
|
||
Errr, I didn't mean a STIX font; it's most likely Cambria Math that's being chosen.
Assignee | ||
Updated•13 years ago
|
Assignee: nobody → jdaggett
Comment 15•13 years ago
|
||
Regression window(m-c)
Good:
http://hg.mozilla.org/mozilla-central/rev/85ba09eada58
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:13.0) Gecko/20120308 Firefox/13.0a1 ID:20120308231132
Bad:
http://hg.mozilla.org/mozilla-central/rev/ead9016b4102
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:13.0) Gecko/20120309 Firefox/13.0a1 ID:20120309043532
Pushlog:
http://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=85ba09eada58&tochange=ead9016b4102
Regression window(m-c)
Good:
http://hg.mozilla.org/integration/mozilla-inbound/rev/63dce6d751c6
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:13.0) Gecko/20120308 Firefox/13.0a1 ID:20120308171833
Bad:
http://hg.mozilla.org/integration/mozilla-inbound/rev/d5483dc18285
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:13.0) Gecko/20120308 Firefox/13.0a1 ID:20120308180833
Pushlog:
http://hg.mozilla.org/integration/mozilla-inbound/pushloghtml?fromchange=63dce6d751c6&tochange=d5483dc18285
Assignee | ||
Comment 16•13 years ago
|
||
This specifies the list of fallback fonts that were added in bug 705594. See fallback code here:
http://mxr.mozilla.org/mozilla-central/source/gfx/thebes/gfxWindowsPlatform.cpp#921
Assignee | ||
Comment 17•13 years ago
|
||
Testcase rendering with GDI and DirectWrite rendering
Mozilla/5.0 (Windows NT 6.1; rv:14.0) Gecko/20120415 Firefox/14.0a1
with and w/o DirectWrite enabled
There have been past bugs related to the metrics used for Cambria Math, this appears to be related to that.
Comment 18•13 years ago
|
||
I guess you're thinking of bug 598900, among others, which remains an open issue.
The font fallback changes appear as a regression here because they're causing Cambria Math to be used on pages where it wasn't previously occurring.
Depends on: 598900
Assignee | ||
Comment 19•13 years ago
|
||
(In reply to Jonathan Kew (:jfkthame) from comment #18)
> The font fallback changes appear as a regression here because they're
> causing Cambria Math to be used on pages where it wasn't previously
> occurring.
I'm not arguing it's not a regression. The question is whether to yank Cambria Math out of the list of hard-coded fonts (at least for the GDI case) or to fix the underlying problem with the metrics.
Comment 20•13 years ago
|
||
Well... I do think we should fix the underlying metrics problem, which manifests itself in a number of ways (we end up with surprisingly different metrics across platforms for the same font), but that's a more extensive issue and will almost certainly cause a bunch of fragile test breakage, etc., that we'll have to look at carefully.
If we want a quick/safe fix here to reduce the immediate pain, adjusting the hard-coded font list is probably the way to go.
(I still wish the fallback list for each platform was a pref rather than compiled-in....)
Assignee | ||
Comment 21•13 years ago
|
||
Shows default rendering at font-size: 100px along with rendering for all Windows 7 fonts that contain a glyph for the down arrow.
Assignee | ||
Comment 22•13 years ago
|
||
The "bug" here has to do with the handling of Cambria Math in GDI-mode only (i.e. XP or Win7 with old drivers). Under Windows 7 normal DirectWrite rendering of Cambria Math is fine. It will be dependent upon the environment to some degree, Segoe UI Symbols cannot be installed but Cambria Math must be installed.
The fact that the default font for this character changed is not in itself a "bug", only the handling of Cambria Math under GDI (note that Chrome shows the same problem for Cambria Math).
Steps to hopefully reproduce:
1. Run in GDI mode (if on Win7/Vista, explicitly enable 'gfx.direct2d.disable')
2. Load the "show all possible..." testcase
Result: default case uses Cambria Math (line height should match that of the Cambria Math line).
Expected result: the fallback case displays without the huge line height.
Assignee | ||
Comment 23•13 years ago
|
||
Take out Cambria Math from fallback list covering symbols, lower its priority for non-BMP characters, add in Lucida Sans Unicode for symbol fallback.
Attachment #627076 -
Flags: review?(jfkthame)
Comment 24•13 years ago
|
||
Comment on attachment 627076 [details] [diff] [review]
patch, don't use Cambria Math for symbol fallback
Fine, I guess. (I still wish these fallback lists were loaded from prefs rather than compiled in to the code, though....)
Attachment #627076 -
Flags: review?(jfkthame) → review+
Assignee | ||
Comment 25•13 years ago
|
||
(In reply to Jonathan Kew (:jfkthame) from comment #24)
> Fine, I guess. (I still wish these fallback lists were loaded from
> prefs rather than compiled in to the code, though....)
The hardcoded fontlists are there to try and speed the system fallback
process by checking specific platform-specific fonts for certain
ranges, based on testing to determine when system fallback occurs
given default fonts on each platform. The goal is to try a few select
fonts to eliminate the need to do a global search, either via scanning
all cmaps or via a platform-supported method. As such it's not really
a "preference", nor is it a simple list to derive, since it's based on
analyzing when *system* fallback occurs (i.e. beyond the set of fonts
in the prefs list).
It might make sense to have a single, global fallback list for those
who desire to tweak but I think exposing a slew of range-specific
fallback lists is not a great idea.
Keywords: regressionwindow-wanted
Assignee | ||
Comment 26•13 years ago
|
||
Pushed to inbound
https://hg.mozilla.org/integration/mozilla-inbound/rev/36f327aaffa5
Comment 27•13 years ago
|
||
reftests/bidi/729047-1.html and reftests/bugs/427730-1.html say they'd rather you didn't do that without consulting them. Backed out in https://hg.mozilla.org/integration/mozilla-inbound/rev/c29e42966d59
Comment 28•13 years ago
|
||
Looks like the addition of Lucida Sans Unicode to the fallbacks for the symbol ranges is causing a change in the rendering of U+200B (zero width space), such that it affects the line height.
Assignee | ||
Comment 29•13 years ago
|
||
Both of these tests are making assumptions about the line-height being the same indpendent of the default font. Both these tests fail on a WinXP ja-jp locale with Nightly, they need an explicit line-height setting. A lot of these bidi tests suffer from locale dependency, I guess I need to bite the bullet and fix these, grumble, grumble.
Updated•12 years ago
|
Summary: ⇓ character entity has incorrect bounding box → ⇓ character entity and similar symbols cause excessive line-spacing under GDI
Comment 32•12 years ago
|
||
Is this patch low risk enough to consider for aurora/beta approval?
Assignee | ||
Comment 33•12 years ago
|
||
Set the line height on these tests so that the difference in characters used between the test and ref don't affect the linebox placement.
Attachment #633044 -
Flags: review?(smontagu)
Updated•12 years ago
|
Attachment #633044 -
Flags: review?(smontagu) → review+
Assignee | ||
Comment 34•12 years ago
|
||
Pushed to inbound, with reftest fix:
https://hg.mozilla.org/integration/mozilla-inbound/rev/15679f8718cf
https://hg.mozilla.org/integration/mozilla-inbound/rev/62cc5a6c3069
Assignee | ||
Comment 35•12 years ago
|
||
(In reply to Alex Keybl [:akeybl] from comment #32)
> Is this patch low risk enough to consider for aurora/beta approval?
Yes, assuming the patch sticks this time, we should definitely try to get this into aurora/beta, it's a minor tweak that fixes an annoyance for those viewing pages with these characters on XP.
Comment 36•12 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/15679f8718cf
https://hg.mozilla.org/mozilla-central/rev/62cc5a6c3069
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla16
Comment 37•12 years ago
|
||
Please nominate for Aurora/Beta when ready, along with a risk/reward evaluation.
Assignee | ||
Comment 38•12 years ago
|
||
Comment on attachment 627076 [details] [diff] [review]
patch, don't use Cambria Math for symbol fallback
[Approval Request Comment]
Bug caused by (feature/regressing bug #): 705594
User impact if declined: line spacing problems for certain symbols in the Windows GDI case (XP/Win7 w/o hw accel)
Testing completed (on m-c, etc.): landed couple weeks ago
Risk to taking this patch (and alternatives if risky): Very low, this is really unlikely to have a negative impact.
String or UUID changes made by this patch: None
Note: the reftest changes are required to workaround font dependencies in the reftests
Attachment #627076 -
Flags: approval-mozilla-beta?
Attachment #627076 -
Flags: approval-mozilla-aurora?
Assignee | ||
Comment 39•12 years ago
|
||
Comment on attachment 633044 [details] [diff] [review]
patch, fix the reftests that depended upon previous fallback behavior
[Approval Request Comment]
-- see above --
Attachment #633044 -
Flags: approval-mozilla-beta?
Attachment #633044 -
Flags: approval-mozilla-aurora?
Comment 40•12 years ago
|
||
Comment on attachment 627076 [details] [diff] [review]
patch, don't use Cambria Math for symbol fallback
[Triage Comment]
New regression in FF13, with a low risk fix. Let's get this on Aurora 15 and Beta 14.
Attachment #627076 -
Flags: approval-mozilla-beta?
Attachment #627076 -
Flags: approval-mozilla-beta+
Attachment #627076 -
Flags: approval-mozilla-aurora?
Attachment #627076 -
Flags: approval-mozilla-aurora+
Updated•12 years ago
|
Attachment #633044 -
Flags: approval-mozilla-beta?
Attachment #633044 -
Flags: approval-mozilla-beta+
Attachment #633044 -
Flags: approval-mozilla-aurora?
Attachment #633044 -
Flags: approval-mozilla-aurora+
Assignee | ||
Comment 41•12 years ago
|
||
Comment 43•12 years ago
|
||
Comment 44•12 years ago
|
||
Does that machine exhibit the issue in FF13? I'm guessing you don't have Cambria Math installed on that XP machine, and so the problem wouldn't have shown up there.
Comment 45•12 years ago
|
||
Thanks Jonathan. I'm able to see the issue now on FF 13.0.1 loading the test cases from comment 0 and comment 21.
Verified fixed on Mozilla/5.0 (Windows NT 5.1; rv:14.0) Gecko/20100101 Firefox/14.0b11.
Comment 46•12 years ago
|
||
Verified fixed on Mozilla/5.0 (Windows NT 5.1; rv:15.0) Gecko/20100101 Firefox/15.0b2.
Status: RESOLVED → VERIFIED
You need to log in
before you can comment on or make changes to this bug.
Description
•