Opened 9 years ago

Closed 8 years ago

Last modified 8 years ago

#12885 closed defect (fixed)

Pie Chart omits some labels

Reported by: Eric Pokriefke Owned by: cjolif
Priority: high Milestone: 1.8
Component: Charting Version: 1.6.1
Keywords: pie chart label columns omit Cc: cjolif
Blocked By: Blocking:

Description

dojox.charting.plot2d.Pie offers a very useful option: 'labelStyle: "columns"'

However, if you use this mode instead of the default one, labels will be omitted, if the slice is too small.

dojox.charting.plot2d.Pie line: 395

labeledSlices.push({
	angle: labelAngle,
	left: Math.cos(labelAngle) < 0,
	theme: themes[i],
	index: i,
	omit: end - start < 0.001
});

If you look at my test page, you might think there are only 3 different slices, but there are 6! [www.teamspace.de/ts/test/pietest.html]

Pie charts become very unclear because of this.

Change History (4)

comment:1 Changed 8 years ago by cjolif

Cc: cjolif added

Some people might want this "feature" even if indeed this might be misleading. What I would propose is a new API on Pie that enable or disable this for both columns and default style labels. With a default value of showing all labels. That way it will be consistent between the two modes (columns & default) and user will be able to pick the choice they want (all labels or just labels with non small slices).

comment:2 Changed 8 years ago by cjolif

Owner: changed from Eugene Lazutkin to cjolif

adding omitLabels property.

comment:3 Changed 8 years ago by cjolif

Resolution: fixed
Status: newclosed

In [27005]:

adding omitLabels property to choose whether to omit labels on small pie or not. Fixes #12885. !strict.

comment:4 Changed 8 years ago by cjolif

Milestone: tbd1.8
Note: See TracTickets for help on using tickets.