oupablo
oupablo

Reputation: 95

How to set listview border in JavaFX

I've tried digging through the JavaFX CSS reference and googling but have been unsuccessful in figuring out how to remove the border on a listview in JavaFX.

I've tried setting the border and stroke widths to 0px. I've tried setting the border/stroke colors to transparent. No matter what I do, there is what looks to be a 1px solid black border around the listview.

Any ideas on how to get rid of it?

Upvotes: 7

Views: 5660

Answers (1)

James_D
James_D

Reputation: 209684

Try

list.setStyle("-fx-background-insets: 0 ;");

Upvotes: 15

Related Questions