chart label shortening feature
Long label always cause the x axis tick labels intersected with each other, this patch will do label shortening work with two provided parameters:
1> maxLabelWordCount: set the max word(character) count for each label
2> maxLabelSize: set the max length in pixel for each label
the truncated label will end with "..." and there will be a tooltip which will show the whole label text when you hover on the label
This patch also separated an independent tooltip(dojox.charting.MasterTooltip?) from the "dojox.charting.action2d.Tooltip", so as to use the tooltip anywhere
Attachments (2)
-
chart_labelshortening.png (4.1 KB) - added by JayZ(zhouxiang) 12 years ago.
-
snapshot of label shortening feature
-
label_shortening.patch (32.8 KB) - added by Adam Peller 12 years ago.
-
update from xiang zhou (IBM, CCLA): Add customize trailing symbols and rename the "maxLabelWordCount" to "maxLabelCharCount", there will be a tooltip when you hover on the truncated labels. About "add a general way to provide already abbreviated tick labels", seems there is no rule to follow, even the month of the year: "Sep" for "September", the day of the week: "Mon" for "Monday", user can also abbreviate "September" to "Sept", "Monday" to "MD". I suppose it's better to let user customize it in "labelFunc".
Download all attachments as: .zip
Change History (4)
Resolution: |
→ fixed
|
Status: |
new →
closed
|
snapshot of label shortening feature