Opened 4 years ago

Closed 4 years ago

Last modified 4 years ago

#18570 closed defect (fixed)

dojox/charting/plot2d/Inidicator.js label position broken

Reported by: Arunas Ruksnaitis Owned by: Eugene Lazutkin
Priority: low Milestone: 1.11
Component: Charting Version: 1.10.4
Keywords: Cc:
Blocked By: Blocking:

Description

Line 455: text position "middle". Should be this.opt.start ? "start":"end"

At the moment the label is clipped at the start or at the end, depending on positioning, unless offset is specified, in which case one has to manually calculate the offset, and the labels still look rubbish because they are rendered aligned to the middle.

The above patch makes the labels hug the left or the right margin respectively, and they auto-size nicely.

Change History (4)

comment:1 Changed 4 years ago by Arunas Ruksnaitis

Pull request #176 submitted. Note that the comment at the top references #11299, which is allegedly implemented. I have tried to use label.getBoundingBox() instead of getBoundingBox(label); it is broken on MSIE so I had to reinstate the original code. Also note that getBoundingBox() returns zeroes if the chart is rendered in a hidden node, so a) the background box is not rendered until the chart is refreshed while visible, and b) top labels in vertical indicator are half-clipped initially regardless of the compensating offset I have added.

comment:2 Changed 4 years ago by dylans <dylan@…>

Resolution: fixed
Status: newclosed

In 265915bd86a1f290494e8d47b655682bc51c4a4b/dojox:

Error: Processor CommitTicketReference failed
Unsupported version control system "git": Can't find an appropriate component, maybe the corresponding plugin was not enabled? 

comment:3 Changed 4 years ago by dylan

Milestone: tbd1.11
Priority: undecidedlow

Note that because it changes behavior a bit, I'm not sure if this should be backported.

comment:4 Changed 4 years ago by Arunas Ruksnaitis

Perhaps no backporting. If people had used offset option to compensate for this defect, their code will no longer work as expected.

Note: See TracTickets for help on using tickets.