title: JtextPane of one Line
body: <p>I want to implement a JTextField with custom fonts.I came to know that we cannot do that in JTextField.  Now I am using JtextPane i have a problem How to make sure the carat doesn't go to the next line when the user press enter.  ? </p>