<div dir="ltr"><div><div><div><div><div><div><div>Hi all,<br><br></div>several years ago I did some texts with pdflatex and the devnag package (XeTeX did not exist at that time), it is still here: <a href="http://icebearsoft.euweb.cz/dvngpdf/">http://icebearsoft.euweb.cz/dvngpdf/</a><br><br></div>The situation in the Indic scripts are much more complex and cannot be solved by a ToUnicode map. Half-consonants can be mapped to a consonant followed by a virama. Conjuncts as ksha can be mapped to ka + virama + sha. The problem is with reordering. I will make examples in Hindi only because I do not know other Indic languages.<br><br></div>Take a word kitaab (= किताब, meaning a book). The correct character order is ka + i-matra + ta + aa-matra + ba but in the vizual representattion the glyphs are ordered as i-matra + ka + ta + aa-matra + ba. You cannot blindly move the i-matra behond the following consonant. Word shakti (= सहक्ति, force) is sha + ka + virama + ta + i-matra in the character order but sha + i-matra + {kta-conjunct | half-ka + ta} where the second form is usually preferred in nowadays Hindi. Even more weird reorderings exist, marzii is ma + ra + virama + za + ii-matra in character order but vizually ma + za + ii-matra + hook-repha.<br><br></div>The case of two-part vowels in some scripts is difficult two. You have generally the following scheme:<br><br></div>vowel-part-1 + consonant-group or conjunct + vowel-part-2<br><br></div>Both parts exist as a separate glyphs mapped to other characters so you must know whether the glyph represents a character or whether two glyphs compose a two-part vowel.<br><br></div>These are not things that could be solved by simple ToUnicode maps. On the contrary, it is not necessary to put ActualText to each word but certainly to a great many words.<br><br></div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature">Zdeněk Wagner<br><a href="http://ttsm.icpf.cas.cz/team/wagner.shtml" target="_blank">http://ttsm.icpf.cas.cz/team/wagner.shtml</a><br><a href="http://icebearsoft.euweb.cz" target="_blank">http://icebearsoft.euweb.cz</a></div></div>
<br><div class="gmail_quote">2016-02-23 6:21 GMT+01:00 Andrew Cunningham <span dir="ltr"><<a href="mailto:lang.support@gmail.com" target="_blank">lang.support@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Simon,<br><div><div class="gmail_extra"><br><div class="gmail_quote"><span class="">On 23 February 2016 at 14:12, Simon Cozens <span dir="ltr"><<a href="mailto:simon@simon-cozens.org" target="_blank">simon@simon-cozens.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span>On 23/02/2016 13:54, Andrew Cunningham wrote:<br>
> PDF/UA for instance leaves the question deliberately ambigious.<br>
> ActualText is the way to make the content accessible, but developers<br>
> creating tools for PDF do not actually have to process the ActualText.<br>
<br>
</span>Yeah. (Sorry to keep banging the drum but) I've just done some tests<br>
with SILE, which includes some support for tagged/accessible PDFs. Even<br>
when the ActualText includes the correct Devanagari, I am still seeing<br>
the same problems with cut-and-paste. I'm not sure what needs to be done<br>
to get it right.<div dir="ltr"><div><div dir="ltr"><br></div></div></div></blockquote><div><br></div></span><div>In terms of SILE ... supporting generation of other formats like XPS as an alternative to PDF is probably the only way forward for complex script languages.<br><br></div><div>If SILE is tagging the PDFs and adding ActualText attributes , then it is doing everything it should be doing. The problems are with the PDF specification itself, what it was originally designed to be (a pre-print format based on the Postscript language) and the limitations placed on it by the developers of the spec.<span class="HOEnZb"><font color="#888888"><br><br></font></span></div><span class="HOEnZb"><font color="#888888"><div>Andrew <br></div></font></span></div>
</div></div></div>
<br><br>
<br>
--------------------------------------------------<br>
Subscriptions, Archive, and List information, etc.:<br>
  <a href="http://tug.org/mailman/listinfo/xetex" rel="noreferrer" target="_blank">http://tug.org/mailman/listinfo/xetex</a><br>
<br></blockquote></div><br></div>