Reputation:
How do I set a global css style sheet ? I'm using fxml and scene builder. I added it to resources directory in my project and
<BorderPane fx:id="mainBorder" onDragDetected="#minimize" prefHeight="400.0" prefWidth="700.0"
style="-fx-background-color: white;" stylesheets="../../../../../../resources/css/JTheme.css"
xmlns="http://javafx.com/javafx/8" xmlns:fx="http://javafx.com/fxml/1"
fx:controller="com.s.c.desktop.template.RootLayoutController">
But it doesn't work :(.
Upvotes: 0
Views: 1311
Reputation: 36742
You are missing a @
in your url.
Try to replace your stylesheets with :
stylesheets="@../../../../../../resources/css/JTheme.css"
Upvotes: 1