Hi Jerome,
Unluckily, ChartDirector does not have a built-in method to put the labels on the bubble
chart so that they are clear and do not overlap in all cases. It is because the unlike sectors
in a pie chart, the bubbles can overlap in arbitrary ways. Two bubbles can even 100%
overlap (this is, the two bubbles can be identical) or almost 100% overlap. A bubble can be
surrounded by other bubbles at all sides to make pointing to it difficult or hard to read
(especially if the bubble is small in size).
If in your case, you are sure you only have a few bubbles, you may consider to use
different colors for the bubbles and add a legend box to map the colors to labels.
If you can determine with your own code where to position the labels, you may use
Layer.addCustomDataLabel to add the label. This method will return a TextBox object, and
you can use TextBox.setPos to adjust the position of the labels. Another method is to use
BaseChart.addText to add labels at any place you want. If lines are needed, they can be
added using BaseChart.addLine.
Regards
Peter Kwan |