Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » RichText,QTF,RTF... » QTF question -how to insert a QTF string into an XML file?
QTF question -how to insert a QTF string into an XML file? [message #30567] Sun, 09 January 2011 01:17 Go to next message
mubeta is currently offline  mubeta
Messages: 77
Registered: October 2006
Member
Hi guys,
There is some problem to insert a QTF string in an XML file, as a text part of the node ?

QTF does not include information about page setup and margins, and i am developing a my file type based on XML where the QTF will be stored as a text of a node. I just hope that there is no conflict problem when opening and parsing the XML file.

Thanks.

[Updated on: Mon, 10 January 2011 01:57] by Moderator

Report message to a moderator

Re: QTF question [message #30568 is a reply to message #30567] Sun, 09 January 2011 13:01 Go to previous messageGo to next message
dolik.rce is currently offline  dolik.rce
Messages: 1789
Registered: August 2008
Location: Czech Republic
Ultimate Contributor

mubeta wrote on Sun, 09 January 2011 01:17

Hi guys,
There is some problem to insert a QTF string in an XML file, as a text part of the node ?

QTF does not include information about page setup and margins, and i am developing a my file type based on XML where the QTF will be stored as a text of a node. I just hope that there is no conflict problem when opening and parsing the XML file.

Thanks.

Hi Mubeta,

QTF can contain characters that are illegal in XML text, namely < and &, so those must be replaced by entities &lt; and &amp;. If you are using U++ to create the XML than the replacement is automatic, so you don't have to worry about that. There should be no other problems, I believe.

Best regards,
Honza
Re: QTF question [message #30573 is a reply to message #30568] Sun, 09 January 2011 21:09 Go to previous messageGo to next message
chickenk is currently offline  chickenk
Messages: 169
Registered: May 2007
Location: Grenoble, France
Experienced Member
Or another cleaner solution to keep the QTF as-is is to enclose the QTF content in a CDATA block. I believe the core Upp XML classes handle them correctly, i.e. don't apply any transformations on them.

Lionel
Re: QTF question [message #30574 is a reply to message #30573] Sun, 09 January 2011 22:10 Go to previous messageGo to next message
dolik.rce is currently offline  dolik.rce
Messages: 1789
Registered: August 2008
Location: Czech Republic
Ultimate Contributor

chickenk wrote on Sun, 09 January 2011 21:09

Or another cleaner solution to keep the QTF as-is is to enclose the QTF content in a CDATA block. I believe the core Upp XML classes handle them correctly, i.e. don't apply any transformations on them.

Lionel

Hi Lionel,

I actually didn't mention that on purpose Smile CDATA section can't contain "]]>", but this string can appear legally in QTF.

Honza
Re: QTF question [message #30578 is a reply to message #30574] Mon, 10 January 2011 09:48 Go to previous message
mubeta is currently offline  mubeta
Messages: 77
Registered: October 2006
Member
Well, thanks for all replies. I do it, and is is working fine, without any transformation of the qtf, included images.
Previous Topic: (Basic) error inheriting RichEditWithToolbar
Next Topic: QTF editors and styles
Goto Forum:
  


Current Time: Fri Mar 29 00:30:18 CET 2024

Total time taken to generate the page: 0.02272 seconds