Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

styledoc to html conversion

 
hita
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi
i have made one application which reads a styled document and converts it in to html tags. my problem is when using syyleeditorkit.boldaction to make text bold it takes whole line as a bold when converted to html . so my final html format shows whole line bold not the selected bold portion.
hita
 
Nathan Pruett
Bartender
Posts: 4121
IntelliJ IDE Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hita -

Please read the official JavaRanch naming policy and re-register. Your user name needs to consist of a first name, a space, and a last name. First and last names have to be at least one character.

I'm not sure how much we can help you out with your problem without some code... it sounds like you are writing out the HTML bold tags at the wrong time, or in the wrong location in your output string...

Perhaps you could change your program to output whatever portion of the line it has read in as soon as it hits a bold portion, then read the bold portion, output it with bold tags surrounding it, and then continue to read...

-Nate
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic