Positioning all data tips in Flex PlotChart

277 Views Asked by At

I'm working on a Flex application showing a timeline of events. I have set the PlotChart's showAllDataTips property to true, so that the DataTips are always visible.

I don't seem to have access to the algorithm that sets the locations of the DataTips and draws the lines back to the corresponding item. The algorithm seems to group the DataTips together, drawing them further away from their corresponding items, as demonstrated by the points to the right and left of the center point in the following image. The center point is demonstrating the kind of placement I want.

data tips sparse

The algorithm DOES place the DataTips in an acceptable fashion when the points are close together, which is often the case, and I want it to continue functioning in that fashion:

data tips dense

Is there some property I can set to make the chart try and place each DataTip as close to its item as possible without overlapping other DataTips?

What I have already tried (without success):

  • I tried overriding the function move(x,y) in my custom DataTip class, which did allow me to move every DataTip some static amount in any direction, but it did not contain information about the location of the associated PlotSeriesItem, and it did not re-draw the line that connects the DataTip to its item.
  • I tried overriding the function updateDisplayList(width, height), which had no effect on DataTips rendered by the showAllDataTips property instead of the mouse over event.
0

There are 0 best solutions below