I am searching for the commands to change the String for X and Y Axis at runtime. I have language menu on my gui. As soon as the button for a specific language is pressed I invoke following methods:
public void resetLanguage(Locale locale)
{
displayLanguage = locale;
resources = ResourceBundle.getBundle("DTTUI-Text", displayLanguage);
chart.setTitle(resources.getString("GUI_CHART_TITLE"));
measurement.setDescription(resources.getString("GUI_CHART_GRAPH_NAME"));
}
chart is a JFreeChart and measurement is a XYSeries. Anyone knows how to find the setter methods for the axis labels? Thanks in advance!
I created my chart like this:
XYSeriesCollection collection = new XYSeriesCollection();
XYSeries series = new XYSeries("Title");
series.add(0, 0);
series.add(10,10);
collection.addSeries(series);
JFreeChart chart = ChartFactory.createXYLineChart("Title", "x",
"y", collection);