-
Bug
-
Resolution: Fixed
-
P4
-
7u6
I discovered some minor bugs, when playing with charts and using dark background colors.
In the caspian.css .root class, I changed the following values to a dark color:
-fx-base: #444444;
-fx-background: #333333;
-fx-control-inner-background: #333333;
Then some parts of my charts weren't displayed in a readable manner.
1. The Labels of the pie-chart (around the chart, not in the legend), were still black.
2. The Legends had white (or bright) background, but their text was also white, therefore unreadable, because there is no ladder applied to the background.
I made the following two changes to my stylesheet, which fix both problems and I suggest to integrate it in the caspian.css:
.chart-legend {
-fx-background-color: ladder(-fx-background, derive(-fx-box-border, -10%) 50%, derive(-fx-box-border, 10%) 51%), ladder(-fx-background, derive(-fx-control-inner-background, 5%) 50%, derive(-fx-control-inner-background, -5%) 51%);
}
.chart-pie-label {
-fx-fill: -fx-text-base-color;
}
Of course you can choose other colors/ladders for the chart-legend.
In the caspian.css .root class, I changed the following values to a dark color:
-fx-base: #444444;
-fx-background: #333333;
-fx-control-inner-background: #333333;
Then some parts of my charts weren't displayed in a readable manner.
1. The Labels of the pie-chart (around the chart, not in the legend), were still black.
2. The Legends had white (or bright) background, but their text was also white, therefore unreadable, because there is no ladder applied to the background.
I made the following two changes to my stylesheet, which fix both problems and I suggest to integrate it in the caspian.css:
.chart-legend {
-fx-background-color: ladder(-fx-background, derive(-fx-box-border, -10%) 50%, derive(-fx-box-border, 10%) 51%), ladder(-fx-background, derive(-fx-control-inner-background, 5%) 50%, derive(-fx-control-inner-background, -5%) 51%);
}
.chart-pie-label {
-fx-fill: -fx-text-base-color;
}
Of course you can choose other colors/ladders for the chart-legend.