Hi,
Currently the ChartViewer node cannot be used in FXML. I think the only reason is because it does not have a constructor without arguments (when I extended the ChartViewer class and added a simple constructor without arguments, I could add my wrapper class into FXML and it works).
By the way, the contextMenuEnabled parameter in the ChartViewer constructor seems to be completely ignored.
Another strange thing is that ChartViewer defines a private contextMenu field. Since ChartViewer extends Control, Control already has a contextMenu property, so I think there is no need to add a new one.
Tomas
Using ChartViewer in FXML
-
- JFreeChart Project Leader
- Posts: 11734
- Joined: Fri Mar 14, 2003 10:29 am
- antibot: No, of course not.
- Contact:
Re: Using ChartViewer in FXML
Thanks Tomas, good feedback. I will make those improvements to the ChartViewer class for the 1.0.20 release. I'm currently working on getting FXGraphics2D released, and once that is done I will do new releases of JFreeChart and Orson Charts.
David Gilbert
JFreeChart Project Leader
Read my blog
Support JFree via the Github sponsorship program
JFreeChart Project Leader
Read my blog
Support JFree via the Github sponsorship program