When i build a pie chart in javafx, the boundary lines are always white.( I can set default slice colors with css). how can i set custom colors to boundary lines?
Applying some css to the standard chart sample:
.chart-pie {
-fx-border-color: derive(-fx-pie-color, -40%);
-fx-border-width: 3px;
}
You can play around with other css settings to get the different effects you want.
I won't answer further questions on this, but instead read the Region specification in the JavaFX CSS Reference Guide (as chart pies are styled regions) and review the modena.css stylesheet to learn how this can be done.
Here is the output with the css above applied:
Compared to the standard output with no additional CSS (using the default JavaFX 8 modena style):