--- RatioRat <
janjoopjansen@...> wrote:
>
> Hello. My swing textfield formats really weird. When i setText in a square
> textfield it centers the string and after "\n" it doesn't start on a new
> line but gives a space plus the appended string. Can anyone help out?
> --
> View this message in context:
>
http://www.nabble.com/Swing-TextField-formats-weirdly-tp17159971p17159971.html> Sent from the Netbeans - UI mailing list archive at Nabble.com.
>
Please notice the description for this mailing list/forum reads "Recommended for : People
interested in the usability of the IDE and helping to improve it - discussions on the graphical
appearance of the IDE, its key bindings, workflow issues ... Note this is not a support forum."
Please use nbusers for general questions related to NB.
This is a standard Java question actually. JTextField is not a multi-line text component. It is
synonymous to the html <input type="text"/>. You need one of JTextArea or JEditPane. JEditPane
will let you install your own special editor kit which can color text specially and do special
things if you ever need to do it or just look like a regular multi-line text component. I use it
mostly in case I ever have to make upgrades to my application.
Wade
==================
Wade Chandler, CCE
Software Engineer and Developer, Certified Forensic Computer Examiner, NetBeans Dream Team Member, and NetBeans Board Member
http://www.certified-computer-examiner.comhttp://wiki.netbeans.org/wiki/view/NetBeansDreamTeamhttp://www.netbeans.org