• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

EditorKit with xml as model

 
Ranch Hand
Posts: 367
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I have some questions in how to create an editorkit and have an xml document as the model.
I have used HTMLEditorKit before and parsed the generated html in a wysiwyg editor to text or xml ( this is later used in creating indesign document and other documents )

Can anyone point me to the right direction in how to use an xml document as the model and have more control over it so that I don't have to
transform the html to my required data. I would like to have it done right away in the editor.
 
Author
Posts: 976
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Mathias Nilsson wrote:

I have some questions in how to create an editorkit and have an xml document as the model.
I have used HTMLEditorKit before and parsed the generated html in a wysiwyg editor to text or xml ( this is later used in creating indesign document and other documents )



You haven't said what you want the kit to do with the xml. Do you want it interpreted as something (XHTML, say) and shown WYSIWYG, or do you want it just to appear as text and muck with indentation and such. Please explain.
 
Mathias Nilsson
Ranch Hand
Posts: 367
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I want to show it to the user as wysiwyg. If the user inserts a list then I would like to show bullits with indent but the model may look something like this.

<paragraph>
<list>
<list-item>Some text<c-style color="red">alert</c-style></list-item>
</list>
</paragraph>

 
Yeah, but is it art? What do you think tiny ad?
Free, earth friendly heat - from the CodeRanch trailboss
https://www.kickstarter.com/projects/paulwheaton/free-heat
reply
    Bookmark Topic Watch Topic
  • New Topic