Closed
Bug 424586
Opened 16 years ago
Closed 16 years ago
Gradients and Patterns on transformed text do not display correctly
Categories
(Core :: SVG, defect, P2)
Tracking
()
VERIFIED
FIXED
People
(Reporter: codedread, Assigned: longsonr)
References
()
Details
(Keywords: regression, testcase)
Attachments
(4 files, 1 obsolete file)
1.65 KB,
application/xhtml+xml
|
Details | |
534 bytes,
image/svg+xml
|
Details | |
9.78 KB,
patch
|
roc
:
review+
roc
:
superreview+
|
Details | Diff | Splinter Review |
2.98 KB,
patch
|
Details | Diff | Splinter Review |
This was working on the trunk no more than a week ago, but it's busted now. See the 'codedread' logo on this page: http://www.codedread.com/about.php The top one should have a darkblue-lightblue-darkblue gradient on it. The 'reflection' should fade away in typical Web2.0 logo style. To see how it's supposed to render, please see Opera 9.5 or Safari 3.1
Assignee | ||
Comment 1•16 years ago
|
||
Testsuite gradients work for me so I wonder what's special about codedread? A regression range would be useful as would a testcase that is as simple as possible.
Updated•16 years ago
|
Flags: blocking1.9?
Reporter | ||
Comment 2•16 years ago
|
||
I don't have a regression range other than "about a week", sorry. I am attaching a test case that illustrates the problem. It is being caused by the viewBox attribute, ultimately. The lower portion of the document should not be showing any red. This makes me suspect it's related to the recent changes that jwatt mentioned on the svg-developer list for overriding SVG sizes. Is this possibly Bug 321531 or 294086 ? I don't understand why the viewBox of "0 0 100 100" causes the SVG 'frame' to be sized the way it is. The div has a width of 100%. Note that if you shrink the width of the browser window, the text does eventually show a little of the gradient on the left side of the text just as it is pushed off the edge of the window.
Reporter | ||
Comment 3•16 years ago
|
||
Comment 4•16 years ago
|
||
Regression window is http://bonsai.mozilla.org/cvsquery.cgi?module=PhoenixTinderbox&date=explicit&mindate=1205864220&maxdate=1205870099 where bug 392233 is the only SVG bug.
Blocks: 392233
Version: unspecified → Trunk
Assignee | ||
Comment 5•16 years ago
|
||
The text does have a gradient on it but the gradient is in the wrong place somehow. If you move the text or make the example font much bigger you can sometimes see the gradient. Removing the viewBox attribute on the outer SVG also fixes the gradient although the text and rect are no longer in the same place then.
Assignee | ||
Comment 6•16 years ago
|
||
(In reply to comment #4) > Regression window is > http://bonsai.mozilla.org/cvsquery.cgi?module=PhoenixTinderbox&date=explicit&mindate=1205864220&maxdate=1205870099 > where bug 392233 is the only SVG bug. > Thanks Kia.
Reporter | ||
Comment 7•16 years ago
|
||
Robert, do you think my test case shows two bugs? One problem is with the gradient, but the other problem is with the sizing of the SVG frame.
Assignee | ||
Comment 8•16 years ago
|
||
If you think there are two bugs then it's probably best to create another one to track your frame sizing issues. Perhaps you could create a testcase for that without gradients to avoid confusion.
Comment 9•16 years ago
|
||
Robert do you have time to take this?
Flags: blocking1.9? → blocking1.9+
Priority: -- → P2
Assignee | ||
Comment 10•16 years ago
|
||
Erm, did you mean me or Roc? I can kind of see what's happening. We're scaling and translating the glyphs into place which works OK if they have neither patterns nor gradients. Not quite so sure how to fix it. I tried messing about with the pattern scaling but so far I'm either barking up the wrong tree or not doing it right.
Comment 11•16 years ago
|
||
(In reply to comment #10) > Erm, did you mean me or Roc? You :-)
Assignee | ||
Updated•16 years ago
|
Assignee: nobody → longsonr
Assignee | ||
Comment 12•16 years ago
|
||
We need to set the global transform prior to calling SetupCairoFill or SetupCairoStroke in order to get patterns and gradients drawn correctly.
Attachment #312547 -
Flags: superreview?(roc)
Attachment #312547 -
Flags: review?(roc)
Assignee | ||
Comment 13•16 years ago
|
||
I just noticed that I also need to change nsSVGGlyphFrame::GetGlobalTransform so that it always gives the correct output even for singular matrices so that the test in SetInitialMatrix works. nsSVGGlyphFrame::GetGlobalTransform(gfxMatrix *aMatrix) { ... *aMatrix = nsSVGUtils::ConvertSVGMatrixToThebes(ctm); return !aMatrix->IsSingular(); }
Assignee | ||
Comment 14•16 years ago
|
||
Comment on attachment 312547 [details] [diff] [review] patch needs work for fill and stroke on same text.
Attachment #312547 -
Attachment is obsolete: true
Attachment #312547 -
Flags: superreview?(roc)
Attachment #312547 -
Flags: review?(roc)
Assignee | ||
Comment 15•16 years ago
|
||
Attachment #312622 -
Flags: superreview?(roc)
Attachment #312622 -
Flags: review?(roc)
Comment on attachment 312622 [details] [diff] [review] stroke in correct place reftest please?
Attachment #312622 -
Flags: superreview?(roc)
Attachment #312622 -
Flags: superreview+
Attachment #312622 -
Flags: review?(roc)
Attachment #312622 -
Flags: review+
Assignee | ||
Comment 17•16 years ago
|
||
Assignee | ||
Updated•16 years ago
|
Summary: Fx3 Regression: SVG Gradients → Gradients and Patterns on transformed text do not display correctly
Assignee | ||
Comment 18•16 years ago
|
||
Checked in. Checked in reftest: http://lxr.mozilla.org/seamonkey/source/layout/reftests/svg/text-gradient-01.svg
Status: NEW → RESOLVED
Closed: 16 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Comment 19•16 years ago
|
||
verified fixed using the testcase from comment #5 and Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9pre) Gecko/2008041217 Minefield/3.0pre ID:2008041217 -> Verified fixed
Status: RESOLVED → VERIFIED
You need to log in
before you can comment on or make changes to this bug.
Description
•