Hi, If the input string contains new line character, then TextField replaces it with space character. This is not documented at java docs,
https://docs.oracle.com/javase/8/docs/api/index.html?java/awt/TextField.html Could you please provide views on whether to update the awt.TextField documentation with above behavior ? Some more information: The behavior was corrected for Windows with bug fix https://bugs.openjdk.java.net/browse/JDK-8055197 After this bug fix, This behavior is common across platforms. Thanks, Ambarish