Example usage for javafx.scene.chart PieChart getLabelsVisible

List of usage examples for javafx.scene.chart PieChart getLabelsVisible

Introduction

In this page you can find the example usage for javafx.scene.chart PieChart getLabelsVisible.

Prototype

public final boolean getLabelsVisible() 

Source Link

Document

Indicates whether pie slice labels are drawn or not

Usage

From source file:Main.java

@Override
public void start(Stage primaryStage) {
    PieChart pieChart = new PieChart();
    pieChart.setData(getChartData());//from w  ww  .  ja  va 2s .c  o  m

    System.out.println(pieChart.getLabelsVisible());

    pieChart.setTitle("Title");
    pieChart.setLegendSide(Side.LEFT);
    pieChart.setClockwise(false);
    pieChart.setLabelsVisible(false);

    StackPane root = new StackPane();
    root.getChildren().add(pieChart);
    primaryStage.setScene(new Scene(root, 300, 250));
    primaryStage.show();
}