When I created two line series, x labels from the 1st series are missing. ex)
Code: Select all
public static void main(String[] args) {
JFrame frame = new JFrame();
JPanel panel = new JPanel();
panel.setSize(600, 600);
TChart chart = new TChart();
panel.add(chart);
Line line1 = new Line(chart.getChart());
line1.add(1, 4, "D"); //index, value, label
line1.add(3, 2, "C");
Line line2 = new Line(chart.getChart());
line2.add(0, 1, "A");
line2.add(2, 2, "B");
frame.add(panel);
frame.setSize(600, 600);
frame.setVisible(true);
}
(Interesting note: while the 1st code displayed all index values, the 2nd code doesn't displayed all text labels)
Code: Select all
chart.getAxes().getBottom().getLabels().setStyle(AxisLabelStyle.VALUE);
Code: Select all
chart.getAxes().getBottom().getLabels().setStyle(AxisLabelStyle.TEXT);