How to hide the horizontal Scrollbar of a ListView in JavaFX

LOstBrOkenKeY picture LOstBrOkenKeY · Oct 1, 2012 · Viewed 14.8k times · Source

How can I hide the horizontal scrollbar of a ListView? I tried it in different ways and probably it's totally easy, but I just can't get it to run.

Answer

Dmitry Kotenko picture Dmitry Kotenko · May 4, 2013

Try this in the CSS:

.list-view .scroll-bar:horizontal .increment-arrow,
.list-view .scroll-bar:horizontal .decrement-arrow,
.list-view .scroll-bar:horizontal .increment-button,
.list-view .scroll-bar:horizontal .decrement-button {
    -fx-padding:0;
}