I found some examples of people inserting tooltips into javafx line-graphs, I tried doing a similar thing for a javafx stackedbarchart and couldn't get it to work.
The mouse event is rarely fired, but even when it is fired the tooltip almost never shows up. Any idea what is wrong?
I'm running this from the initialize() method in my FXcontroller class:
my method for building the charts/graphs data into a series
I couldn't tell you how to make it work in the controllerclass, I can however tell you how to in the fxmlfile. I use my controllerclasses only for the businesslogic and do my layout in fxmlfiles.
but looking at you code I gues the problem is you don't add it to the scene.
Hard to say without the rest of the code.
It's good to be able to use someting, it's better to understand how it works.
how can I do it from fxml? I didn't find any info online about charts with fxml.
My charts are showing in the scene but I'm trying to show data values as a pop-up tooltip when you hover the mouse on the bars in the chart. The handler and tooltips aren't working correctly at all.