You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After #745, importing a control that uses its own user agent stylesheet fails, because Modena.css overwrites it.
Expected Behavior
Importing ControlsFX Rating control should show:
Current Behavior
Importing ControlsFX Rating control shows:
Steps to Reproduce
Add ControlsFX to the custom library, open a new FXML file, add an AnchorPane and a Rating control. The size is wrong, because button's padding defaults to modena's padding:
Actually, there was an underlying bug in Scene Builder, and this bug was already happening before #745, but after #720, with other themes.
For instance, High contrast Black and White + Rating, :
The problem: before #745, modena.bss was used in EditorPlatform Theme.MODENA. That was converted to css with Deprecation::getThemeTextStylesheet, but
try {
return new URL(textCssUrlStr);
} catch (MalformedURLException ex) {
// should never happen
return null;
}
was always returning null, since this exception was totally ignored:
java.net.MalformedURLException: no protocol: com/sun/javafx/scene/control/skin/modena/modena.css
at java.base/java.net.URL.<init>(URL.java:772)
at java.base/java.net.URL.<init>(URL.java:654)
at java.base/java.net.URL.<init>(URL.java:590)
at com.gluonhq.scenebuilder.kit@24.0.0-SNAPSHOT/com.oracle.javafx.scenebuilder.kit.util.Deprecation.getThemeTextStylesheet(Deprecation.java:189)
Therefore, the default Modena theme wasn't adding any style classes at all, while other modena themes that imported directly modena.css were, and the user agent stylesheets from custom controls were also overwritten.
After #745, importing a control that uses its own user agent stylesheet fails, because Modena.css overwrites it.
Expected Behavior
Importing ControlsFX Rating control should show:
Current Behavior
Importing ControlsFX Rating control shows:
Steps to Reproduce
Add ControlsFX to the custom library, open a new FXML file, add an AnchorPane and a Rating control. The size is wrong, because button's padding defaults to modena's padding:
instead of 16 (from its rating.css)
Rating uses:
Your Environment
Screenshots
The text was updated successfully, but these errors were encountered: