how to hide a Pannable scrollbar in javaFX?


Question

I created a Pannable ScrollPane . now i want to hide the bar in the right side of my scrollbar i use this but nothing happen

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

any ideas?

1
7
7/11/2014 2:59:47 PM

Accepted Answer

I found my answer:

scrollPane.setHbarPolicy(ScrollBarPolicy.NEVER);
scrollPane.setVbarPolicy(ScrollBarPolicy.NEVER);
13
2/20/2017 3:37:23 PM

Licensed under: CC-BY-SA with attribution
Not affiliated with: Stack Overflow
Icon