JavaFX: can you define max width/height for a TextField using CSS?


Question

I want to specify preferred and max width and height for a TextField. Can I do it in CSS?

1
2
10/23/2014 3:08:40 PM

Yes you can. The Region class in JavaFX supports for example the following CSS attributes: -fx-min-width, -fx-pref-width, -fx-max-width You can find a complete CSS overview for JavaFX here: http://docs.oracle.com/javase/8/javafx/api/javafx/scene/doc-files/cssref.html

4
10/23/2014 3:22:58 PM

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