Opened 13 years ago
Closed 13 years ago
#9357 closed defect (fixed)
[patch] [cla] DataChart output is screwed/courrupted with htmlLabels: false in 1.4.X
Reported by: | Jared Jurkiewicz | Owned by: | Jared Jurkiewicz |
---|---|---|---|
Priority: | blocker | Milestone: | 1.4 |
Component: | Charting | Version: | 1.3.1 |
Keywords: | Cc: | Mike Wilcox, Karl Tiedt | |
Blocked By: | Blocking: |
Description (last modified by )
DataChart? output is screwed/corrupted with htmlLabels: false in 1.4.X
The same problem does not occur in 1.3.1.
Using a modified version of the DataChart? test produces it. Will attach shortly along with screenshot of damaged output:
Attachments (4)
Change History (30)
Changed 13 years ago by
Attachment: | test_DataChart.html added |
---|
comment:2 Changed 13 years ago by
severity: | critical → blocker |
---|
Raising severity. We should not ship 1.4 without this fixed.
comment:3 Changed 13 years ago by
Description: | modified (diff) |
---|---|
Summary: | DataChart output is screwed/courrupted with htmlLabels: true in 1.4.X → DataChart output is screwed/courrupted with htmlLabels: false in 1.4.X |
comment:4 Changed 13 years ago by
Cc: | Mike Wilcox added |
---|
This happened after the performance refactor of the charting labels soon after the 1.3 release. If someone gives me some clues as to what's broken and where to look, I can try to help.
comment:5 Changed 13 years ago by
Cc: | Karl Tiedt added |
---|
This appears to be the problem I am running into... thanks Jared! Mike, I can add this tibit of data from my tests trying to track down this issue.
My charts appear extremely NARROW and ignore the CSS width's set on the chart's div however if I give my charts x axis a large min/max variance... the chart begins to render more and more normal... understanding of this is that its only taking into account the # of data items for each series * step sizes in determining the width of a chart... (speculation but seems pretty sound)
comment:6 Changed 13 years ago by
This is probably the changeset you want to look at: http://bugs.dojotoolkit.org/browser/dojox/trunk/charting/axis2d/common.js?rev=17224
comment:7 Changed 13 years ago by
Owner: | changed from Eugene Lazutkin to alex |
---|
comment:8 Changed 13 years ago by
Missplaced blame!
http://bugs.dojotoolkit.org/changeset/17597
Alex's code does *not* break this test :)
Liucougars however.... *sigh*
comment:9 Changed 13 years ago by
comment:10 Changed 13 years ago by
http://ktiedt.dojotoolkit.org/dojo/test_DataChart.html is running trunk - [17597] and yes it works :)
comment:11 Changed 13 years ago by
according to IE getBoundingClientRect MSDN doc, width/height is not in the returned object (TextRectangle? object)
according to FF getBoundingClientRect doc, width/height is added to FF 3.5 (not in 3.0 either)
could you try to modify _getTextBox in gfx._base to just do return { w: undefined, h: undefined };
does that fix your test?
comment:13 Changed 13 years ago by
Any status on this? It's still ugly as crap in 1.4 with htmlLabels: false.
comment:14 Changed 13 years ago by
Owner: | changed from alex to liucougar |
---|
I confirm if I revert [17597], the problem goes away. It's definitely related to that checkin.
Assigning over to Liu to look further at, since it is his change that is breaking it.
Changed 13 years ago by
Attachment: | 9357.patch added |
---|
comment:15 follow-up: 16 Changed 13 years ago by
Owner: | changed from liucougar to Eugene Lazutkin |
---|
[17597] is correct, afaict, something is broken in dojox.charting when htmlLabel=false, here is a patch to fix it, but I don't know why it fixes this bug, pass it to elazutkin
comment:16 Changed 13 years ago by
Replying to liucougar:
[17597] is correct, afaict, something is broken in dojox.charting when htmlLabel=false, here is a patch to fix it, but I don't know why it fixes this bug, pass it to elazutkin
Correct me if I'm wrong, but if a bug is fixed, shouldn't the underlying code that uses it be checked for a) functionality and b) corrections needed because of the bug that was fixed?
If we keep passing this around, its never going to get fixed... [17597] should have included any changes for GFX based code (particularly for something like Charting that is one of our *big* dojox attractions)... just my 2cents...
comment:17 Changed 13 years ago by
Summary: | DataChart output is screwed/courrupted with htmlLabels: false in 1.4.X → [patch] [cla] DataChart output is screwed/courrupted with htmlLabels: false in 1.4.X |
---|
comment:18 Changed 13 years ago by
Priority: | normal → high |
---|
Followup. Any word on this? The corruption is really, really bad/ugly.
comment:20 Changed 13 years ago by
Priority: | high → highest |
---|
comment:21 Changed 13 years ago by
Milestone: | tbd → 1.4 |
---|
comment:22 follow-up: 23 Changed 13 years ago by
comment:23 Changed 13 years ago by
Owner: | changed from Eugene Lazutkin to Jared Jurkiewicz |
---|
For the record: liucougar's patch was right (there was one more place where it should be applied), all effects were related to the original speed-up patch (it looks like a simple oversight).
!getBoundingClientRect returns left, right, top, bottom values following the original Microsoft spec, but newer implementations (see http://www.w3.org/TR/cssom-view/#clientrect for details) return width and height as well. That's why that code worked on some browsers and didn't work on others.
I fixed another bug introduced by the speed-up patch: wrongly positioned pie chart labels.
Jared, please re-test with whatever code you have to confirm that it fixed all problems.
comment:26 Changed 13 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
The fix works nicely now! No more wonky charts with htmlLabels: false.
Export SVG works very nicely with charting using such labels.
Closing.
Testcase