Opened 11 years ago
Closed 5 years ago
#10674 closed defect (patchwelcome)
marginBox in dojox.charting.Chart2D and multiple render calls with a negative left margin...
Reported by: | MarcusPope | Owned by: | Eugene Lazutkin |
---|---|---|---|
Priority: | high | Milestone: | 1.13 |
Component: | Charting | Version: | 1.4.0 |
Keywords: | marginBox chart2d charting | Cc: | |
Blocked By: | Blocking: |
Description
I have a 2d chart component that I'm rendering and it unfortunately has a negative left margin. The constructor for Chart2D calls the gfx.createSurface method with the results of a marginBox call. In the event of a negative margin the width comes back incorrectly and the chart will shrink on every render call by the amount of the negative margin.
I tried to determine if this was a result of some bug in marginBox, but I didn't have much time to research the root cause. I will say this could be part of the issue related to several bugs that were rendering in custom dojo divs. Regardless, switching to contentBox renders the chart correctly.
The obvious workaround is to put the chart in another div and give the parent div the negavite margin when necessary. But I didn't see that stipulation in the docs, so I figure this is a bug.
Change History (3)
comment:1 Changed 11 years ago by
Component: | General → Charting |
---|---|
Owner: | changed from anonymous to Eugene Lazutkin |
comment:2 Changed 11 years ago by
Milestone: | tbd → future |
---|---|
Status: | new → assigned |
comment:3 Changed 5 years ago by
Milestone: | future → 1.12 |
---|---|
Resolution: | → patchwelcome |
Status: | assigned → closed |
Given that no one has shown interest in creating a patch in the past 5+ years, I'm closing this as patchwelcome.
For now we should document that. But the long term solution should calculate width and height correctly with negative margins.