Java Code Examples for javafx.scene.chart.NumberAxis#setTickLabelGap()
The following examples show how to use
javafx.scene.chart.NumberAxis#setTickLabelGap() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: SupplyView.java From bisq with GNU Affero General Public License v3.0 | 5 votes |
private void configureYAxis(NumberAxis axis) { configureAxis(axis); axis.setForceZeroInRange(true); axis.setTickLabelGap(5); axis.setSide(Side.RIGHT); }
Example 2
Source File: SupplyView.java From bisq with GNU Affero General Public License v3.0 | 5 votes |
private void configureAxis(NumberAxis axis) { axis.setForceZeroInRange(false); axis.setAutoRanging(true); axis.setTickMarkVisible(false); axis.setMinorTickVisible(false); axis.setTickLabelGap(6); }
Example 3
Source File: OfferBookChartView.java From bisq with GNU Affero General Public License v3.0 | 5 votes |
private void createChart() { xAxis = new NumberAxis(); xAxis.setForceZeroInRange(false); xAxis.setAutoRanging(false); xAxis.setTickLabelGap(6); xAxis.setTickMarkVisible(false); xAxis.setMinorTickVisible(false); NumberAxis yAxis = new NumberAxis(); yAxis.setForceZeroInRange(false); yAxis.setSide(Side.RIGHT); yAxis.setAutoRanging(true); yAxis.setTickMarkVisible(false); yAxis.setMinorTickVisible(false); yAxis.setTickLabelGap(5); yAxis.setTickLabelFormatter(new NumberAxis.DefaultFormatter(yAxis, "", " " + Res.getBaseCurrencyCode())); seriesBuy = new XYChart.Series<>(); seriesSell = new XYChart.Series<>(); areaChart = new AreaChart<>(xAxis, yAxis); areaChart.setLegendVisible(false); areaChart.setAnimated(false); areaChart.setId("charts"); areaChart.setMinHeight(270); areaChart.setPrefHeight(270); areaChart.setCreateSymbols(true); areaChart.setPadding(new Insets(0, 10, 0, 10)); areaChart.getData().addAll(List.of(seriesBuy, seriesSell)); chartPane = new AnchorPane(); chartPane.getStyleClass().add("chart-pane"); AnchorPane.setTopAnchor(areaChart, 15d); AnchorPane.setBottomAnchor(areaChart, 10d); AnchorPane.setLeftAnchor(areaChart, 10d); AnchorPane.setRightAnchor(areaChart, 0d); chartPane.getChildren().add(areaChart); }