You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by Manisha Sathe <ma...@yahoo.com> on 2005/02/17 08:27:19 UTC

Escape problem ?

I am generating XML  - which is having some unicodes and these r writen as 
 
&amp;#x2206;  (for &#x2206; )
 
When i render pdf  using xsl it does not show me actual unicode character but shows me &#x2206. I tried using disable-output-escaping="yes" inside xsl but no use. 
 
How can i get proper display in pdf ?
 
regards
Manisha
 
 

		
---------------------------------
Do you Yahoo!?
 Yahoo! Search presents - Jib Jab's 'Second Term'

Re: Escape problem ?

Posted by Jeremias Maerki <de...@greenmail.ch>.
Aha. Since Java internally uses Unicode you should be able to simply
pass in the normal Unicode character, not the already escaped character
because DOM will think that you want to output text ("&#x2205;") not the
character. Once you pass in the Unicode character the serializer should
handle the Unicode character for you automatically. The whole thing is
probably easier than you think. :-)

On 17.02.2005 09:54:51 Manisha Sathe wrote:
> I am using DOM to generate xml file. And the chinese character string
> is a hardcoded one
>  
> i.e. when i am setting value to xml node i am passing it string as
> "&#x2206;"  but DOM automatically converts this string and store into
> xml file as "&amp;#x2206", 
>  
> Can DOM take care of this ? I think i am asking Java related question
> but in case u know, pls let me know. I will also post it on Java forum.



Jeremias Maerki


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-user-help@xml.apache.org


Re: Escape problem ?

Posted by "J.Pietschmann" <j3...@yahoo.de>.
Manisha Sathe wrote:
> I am using DOM to generate xml file. And the chinese character string is 
> a hardcoded one
>  
> i.e. when i am setting value to xml node i am passing 
> it string as "&#x2206;"  but DOM automatically converts this string and 
> store into xml file as "&amp;#x2206",

Use Java Unicode escapes (like '\u2206') for non-ASCII/characters in
Java strings. Use XML characcter references (like '&#x2206;') *only*
in XML files.

J.Pietschmann

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-user-help@xml.apache.org


Re: Escape problem ?

Posted by Manisha Sathe <ma...@yahoo.com>.
I am using DOM to generate xml file. And the chinese character string is a hardcoded one
 
i.e. when i am setting value to xml node i am passing it string as "&#x2206;"  but DOM automatically converts this string and store into xml file as "&amp;#x2206", 
 
Can DOM take care of this ? I think i am asking Java related question but in case u know, pls let me know. I will also post it on Java forum.
 
regards
Manisha
 
 


Jeremias Maerki <de...@greenmail.ch> wrote:
You simply have to make sure that in the XML you generate you see
"&@x2205;" and not "&#x2206;". Then it should work. Can't say more
without seeing a code snippet showing how you generate this codes.

On 17.02.2005 08:27:19 Manisha Sathe wrote:
> I am generating XML - which is having some unicodes and these r writen as 
> 
> &#x2206; (for #8710; )
> 
> When i render pdf using xsl it does not show me actual unicode
> character but shows me #8710;. I tried using
> disable-output-escaping="yes" inside xsl but no use. 
> 
> How can i get proper display in pdf ?



Jeremias Maerki


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-user-help@xml.apache.org


		
---------------------------------
Do you Yahoo!?
 Yahoo! Search presents - Jib Jab's 'Second Term'

Re: Escape problem ?

Posted by Jeremias Maerki <de...@greenmail.ch>.
You simply have to make sure that in the XML you generate you see
"&@x2205;" and not "&amp;#x2206;". Then it should work. Can't say more
without seeing a code snippet showing how you generate this codes.

On 17.02.2005 08:27:19 Manisha Sathe wrote:
> I am generating XML  - which is having some unicodes and these r writen as 
>  
> &amp;#x2206;  (for &#x2206; )
>  
> When i render pdf  using xsl it does not show me actual unicode
> character but shows me &#x2206. I tried using
> disable-output-escaping="yes" inside xsl but no use. 
>  
> How can i get proper display in pdf ?



Jeremias Maerki


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-user-help@xml.apache.org