filmov
tv
JavaFX Tutorial 19 StackedAreaChart Java GUI

Показать описание
JavaFX Tutorial 19 StackedAreaChart Java GUI
@Override
public void start(Stage primaryStage) {
NumberAxis xAxis = new NumberAxis();
NumberAxis yAxis = new NumberAxis();
StackedAreaChart stackedAreaChart = new StackedAreaChart(xAxis, yAxis);
XYChart.Series dataSeries1 = new XYChart.Series();
XYChart.Series dataSeries2 = new XYChart.Series();
VBox vbox = new VBox(stackedAreaChart);
Scene scene = new Scene(vbox, 800, 600);
A JavaFX StackedAreaChart component is capable of drawing stacked area charts inside your JavaFX applications. A stacked area chart is similar to an area chart with multiple data series, except a stacked area chart displays the data series (and thus areas) stacked on top of each other, where the normal area chart would overlap them.
@Override
public void start(Stage primaryStage) {
NumberAxis xAxis = new NumberAxis();
NumberAxis yAxis = new NumberAxis();
StackedAreaChart stackedAreaChart = new StackedAreaChart(xAxis, yAxis);
XYChart.Series dataSeries1 = new XYChart.Series();
XYChart.Series dataSeries2 = new XYChart.Series();
VBox vbox = new VBox(stackedAreaChart);
Scene scene = new Scene(vbox, 800, 600);
A JavaFX StackedAreaChart component is capable of drawing stacked area charts inside your JavaFX applications. A stacked area chart is similar to an area chart with multiple data series, except a stacked area chart displays the data series (and thus areas) stacked on top of each other, where the normal area chart would overlap them.