wood burning stoves 2.0*
The moose likes Swing / AWT / SWT and the fly likes JTextArea, JEditorPane or JTextPane: which is better suited for my application? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "JTextArea, JEditorPane or JTextPane: which is better suited for my application?" Watch "JTextArea, JEditorPane or JTextPane: which is better suited for my application?" New topic
Author

JTextArea, JEditorPane or JTextPane: which is better suited for my application?

Isuru Sampath
Ranch Hand

Joined: Jun 26, 2003
Posts: 57
Thanks for reading my post.

I need a component to create an application which has a simple text editor functions. Intended functions include adding, deleting and inserting characters. No need to bold, Italics, Underlining or any other fancy formatting since I'm writing the outpt to a text file. Which of the following is ideal for this purpose:

  • JTextArea
  • JEditorPane
  • JTextPane


  • Can you kindly explain any advantages of using the either component.
    [ November 03, 2006: Message edited by: Isuru Sampath ]

    No Winds No Waves
    Michael Dunn
    Ranch Hand

    Joined: Jun 09, 2003
    Posts: 4632
    > Can you kindly explain any advantages of using the either component.

    this would probably explain it better for you

    http://java.sun.com/docs/books/tutorial/uiswing/components/text.html
     
     
    subject: JTextArea, JEditorPane or JTextPane: which is better suited for my application?