Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

JTextPane - HTMLEditorKit new Line(\n) problem  RSS feed

 
Aniruddha Jadhao
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,
I am developing one swing application in which I have used HTMLEditorKit to insert html text inside JTextPane.
I am getting an encoded HTML message from another system like
original message : hi\nhow are you?
Encoded Message : hi new line encoded code how are you?
Now when I insert this message in HTMLEditor in Jtext pane it never decode the new line code & displays the text in single line only.
Please suggest me any work around or the exact solution.

Thanks in advance

Aniruddha
 
Snehanshu Chatterjee
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
bound the message with <html> </html> and use it with java code
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!