How to set alignment in a JavaFX TextField?
-
28-10-2019 - |
Frage
I need to set allignment of the text in a TextField to right. There is no such under TextField. Anybody knows how to set alignment in a textfield in javaFX 2.0 ?
Thanks
Lösung
Currently It does not have a support on text field alignment. I reported this issue to javafx jira team and this feature will be added in version 2.1.
Here is the link. http://javafx-jira.kenai.com/browse/RT-18410?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
Andere Tipps
In JavaFX 2.0, it may not have been possible, but it is in JavaFX 2.1 and ownward using the alignment property.
textField.setAlignment(Pos.CENTER_RIGHT);
Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow