Skip to content

Commit e54b132

Browse files
committed
StyledTextField initial height fix
1 parent 586404c commit e54b132

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

richtextfx/src/main/java/org/fxmisc/richtext/StyledTextField.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ public abstract class StyledTextField<PS, S> extends StyledTextArea<PS, S>
7979
// Ugly hack to get a TextFields default height :(
8080
// as it differs between Caspian, Modena, etc.
8181
TextField tf = new TextField( "GetHeight" );
82-
new Scene(tf); tf.applyCss(); tf.layout();
82+
new Scene(tf).snapshot( null );
8383
HEIGHT = tf.getHeight();
8484
}
8585

0 commit comments

Comments
 (0)