JavaFX ScrollPane border and background <p>I'm having some problem regarding the default background and border of the ScrollPane. Using this style made the problem clearer to see.</p> <pre><code>setStyle("-fx-background-color:blue; -fx-border-color:crimson;"); </code></pre> <p><img src="https://i.stack.imgur.com/TvoFy.png" alt="Image show the background and the border"></p> <p>I've tried this style and got no luck only the red border gone and left me with the blue one.</p> <pre><code>setStyle("-fx-background-color:blue; -fx-background-insets:0; -fx-border-color:crimson; -fx-border-width:0; -fx-border-insets:0;"); </code></pre> <p><img src="https://i.stack.imgur.com/vAlTh.png" alt="Image show the background and the border after my best work around"></p> <p>I've looked at this old post <a href="http://stackoverflow.com/questions/12899788/javafx-hide-scrollpane-gray-border">JavaFX Hide ScrollPane gray border</a> and <a href="http://docs.oracle.com/javafx/2/ui_controls/editor.htm" rel="nofollow noreferrer">http://docs.oracle.com/javafx/2/ui_controls/editor.htm</a></p> <p>This line of code doesn't work neither</p> <pre><code>scrollPane.getStyleClass().add("noborder-scroll-pane"); </code></pre> <p>Thanks</p>