<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 14 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p.MsoAcetate, li.MsoAcetate, div.MsoAcetate
        {mso-style-priority:99;
        mso-style-link:"Balloon Text Char";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:8.0pt;
        font-family:"Tahoma","sans-serif";}
p.MsoNoSpacing, li.MsoNoSpacing, div.MsoNoSpacing
        {mso-style-priority:1;
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Arial","sans-serif";}
span.BalloonTextChar
        {mso-style-name:"Balloon Text Char";
        mso-style-priority:99;
        mso-style-link:"Balloon Text";
        font-family:"Tahoma","sans-serif";}
span.EmailStyle20
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
span.EmailStyle21
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.EmailStyle22
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.EmailStyle23
        {mso-style-type:personal-reply;
        font-family:"Arial","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="DE-CH" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#1F497D">Hi Darren,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#1F497D">the font selection can be configured in your XSL:FO:&nbsp;
<a href="http://www.w3.org/TR/xsl/#font-selection-strategy">http://www.w3..org/TR/xsl/#font-selection-strategy</a><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#1F497D">If you set the value to &#8220;</span><span lang="EN-US">character-by-character</span><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#1F497D">&#8221;
 then only Chinese characters will be replaced by Sim Sum and the Latin/Western ones will all be in Arial<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#1F497D">Best Regards,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#1F497D">Ramon<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;">From:</span></b><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;"> xep-support-bounces@renderx.com [mailto:xep-support-bounces@renderx.com]
<b>On Behalf Of </b>Darren Munt<br>
<b>Sent:</b> Dienstag, 4. Dezember 2012 04:49<br>
<b>To:</b> 'RenderX Community Support List'<br>
<b>Subject:</b> [xep-support] Re: Mixed languages in a single PDF<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
<p class="MsoNormal"><span lang="EN-AU" style="color:#1F497D">Thanks for this Kevin. We&#8217;re producing and downloading these on the fly, so we need to be mindful of processing time and file size..<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU" style="color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU" style="color:#1F497D">The most recent example of the issue was when a Chinese client set up the records from which the reports are derived, they entered people&#8217;s names using Chinese characters. They then wanted to produce
 the reports in English for their head office in Australia. Because we don&#8217;t know that they&#8217;ve entered text that&#8217;s not displayable in our default font for the English report, they got the reports in English but without the names. The names could just as easily
 have been in English or Greek or any other language, so it makes it diff icult to plan a font stack for the documents in advance.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU" style="color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU" style="color:#1F497D">With the method you suggest, does the font selection take place at document, block or character level?<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU" style="color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU" style="color:#1F497D">For example if I specified something like font-family=&#8221;Arial, Sim Sum&#8221;, would XEP be able to display just the Chinese characters in Sim Sum, or would it select Sim Sum for the entire document?<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU" style="color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;">From:</span></b><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;"> xep-support-bounces@renderx.com [mailto:xep-support-bounces@renderx.com]
<b>On Behalf Of </b>Kevin Brown<br>
<b>Sent:</b> Tuesday, 4 December 2012 2:18 PM<br>
<b>To:</b> 'RenderX Community Support List'<br>
<b>Subject:</b> [xep-support] Re: Mixed languages in a single PDF<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D">You could do something like this:<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D">font-family=&#8221;Helvetica, Arial, Arial Unicode&#8221;<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D">make sure all of these are mapped in your xep.xml. it&#8217;s a font selection strategy that will select the appropriate font for something based on whether the character is in the font list.&nbsp; This would
 choose a font for the text in order --- Helvetica first (no impact), Arial second (would be embedded and hopefully subsetted) and Arial Unicode last (you of course have to have the font and license to use it, it is huge and has many, many glyphs).<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D">Now, I would give this as a solution if you are formatting a few documents, occasionally. If you are looking for high performance formatting then no way would I do this &#8211; Arial Unicode is a 14MB-27MB
 font (depends on which version you have) and the prolog for the font itself which must be embedded in the PDF is 512KB (we honor the wishes of copyright holders and embed their copyrights into documents when their fonts are used unlike other formatting engines
 which ignore them). If you are looking for performance then you need to plan your system accordingly and select fonts or a list of fonts that have the glyphs you need.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D">Kevin Brown<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D">RenderX<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;">From:</span></b><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;">
<a href="mailto:xep-support-bo%0d%0a%20unces@renderx.com">xep-support-bounces@renderx.com</a> [<a href="mailto:xep-support-bounces@renderx.com">mailto:xep-support-bounces@renderx.com</a>]
<b>On Behalf Of </b>Darren Munt<br>
<b>Sent:</b> Monday, December 03, 2012 6:14 PM<br>
<b>To:</b> 'xep-support@renderx.com'<br>
<b>Subject:</b> [xep-support] Mixed languages in a single PDF<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><span lang="EN-US"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU">We have a particular problem with some of our documents, which combine system-generated text with user input. We produce the same report in many different languages and sometimes we have an issue whereby user input is
 in a different character set to the main document language. For example we produce a report in English but some of the user text has been entered in Chinese. There is no way of telling what language the user text might be in, apart from either asking them
 when they enter it or doing some sort of language-detection (wh ich is how I understand the web browser does it for example).<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU">When the report is generated in English, we use the Arial font to display text and it does not have character mapping for the Chinese characters, so they do not appear. When we generate the report in Chinese, we use the
 Sim Sum font, which does display Chinese, but any English text appears in the same font and it&#8217;s not a great looking font for Latin characters.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU">Using Sim Sum by default is not an option because of the appearance of the Latin text and also we support many other languages, including Greek and Arabic, so we really need to be able to specify the font based on the
 language selected for the report. It&#8217;s quite possible in our system for a report to contain any number of different languages in a multi-national or multicultural scenario.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU">I&#8217;ve told the client I don&#8217;t think there is a way of being able to support ad hoc language changes within the document this way, but I thought I would throw it out there in case there&#8217;s something XEP can do that I don&#8217;t
 know about. Any suggestions gratefully accepted.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU" style="font-size:12.0pt;font-family:&quot;Times New Roman&quot;,&quot;serif&quot;"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU" style="font-size:12.0pt;font-family:&quot;Times New Roman&quot;,&quot;serif&quot;">
<o:p></o:p></span></p>
</div>

!DSPAM:87,50bdb0df63731353711319!

</body>
</html>