Using JFreeChart, add a ChartMouseListener
to your ChartPanel
, as outlined here. In your implementation of chartMouseClicked()
invoke Desktop#browse()
, as illustrated here. In outline,
chartPanel.addChartMouseListener(new ChartMouseListener() {
public void chartMouseClicked(ChartMouseEvent e) {
// construct a URI based the result from e.getEntity()
desktop.browse(uri);
}
public void chartMouseMoved(ChartMouseEvent e) {}
});