This was seen on StackOverflow:
https://stackoverflow.com/questions/79768663/is-possible-write-multiple-nodes-in-new-media-query-in-css-in-javafx-25
Given the following stylesheet:
.label {
-fx-text-fill: black;
}
.border-pane {
-fx-background-color: white;
}
@media (prefers-color-scheme: dark) {
.border-pane {
-fx-background-color: black;
}
.label {
-fx-text-fill: white;
}
}
The following CSS parser error is encountered:
D:\JDKs\JDK_samples>runDemo.bat
Sep 19, 2025 9:26:46 AM javafx.css.CssParser consumeRBrace
WARNING: CSS Error parsing file:/D:/JDKs/JDK_samples/test.css: Expected RBRACE at [13,1]
https://stackoverflow.com/questions/79768663/is-possible-write-multiple-nodes-in-new-media-query-in-css-in-javafx-25
Given the following stylesheet:
.label {
-fx-text-fill: black;
}
.border-pane {
-fx-background-color: white;
}
@media (prefers-color-scheme: dark) {
.border-pane {
-fx-background-color: black;
}
.label {
-fx-text-fill: white;
}
}
The following CSS parser error is encountered:
D:\JDKs\JDK_samples>runDemo.bat
Sep 19, 2025 9:26:46 AM javafx.css.CssParser consumeRBrace
WARNING: CSS Error parsing file:/D:/JDKs/JDK_samples/test.css: Expected RBRACE at [13,1]
- links to
-
Review(master) openjdk/jfx/1915