Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to hide a Pannable scrollbar in javaFX?

Tags:

javafx

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?

like image 586
Saeed Masoumi Avatar asked Jul 11 '14 14:07

Saeed Masoumi


1 Answers

I found my answer:

scrollPane.setHbarPolicy(ScrollBarPolicy.NEVER);
scrollPane.setVbarPolicy(ScrollBarPolicy.NEVER);
like image 182
Saeed Masoumi Avatar answered Oct 14 '22 16:10

Saeed Masoumi