faulty to unicode mapping of chars encoded with surrogate pairs?
![](https://secure.gravatar.com/avatar/d4bd34a45c928e8356f38323ff84763e.jpg?s=120&d=mm&r=g)
when I compile the following with context \pdfvariable compresslevel=0 \starttext $f$ \stoptext I get in the pdf 1 beginbfchar <0515> <D875DC53> endbfchar D875DC53 is according to http://www.russellcottrell.com/greek/utilities/surrogatepaircalculator.htm the codepoint 2D453 and this is not a valid unicode point. As a result copy& paste doesn't work correctly. A similar example with xelatex writes D835DC53 (remark the 3 instead of the 7) instead in the pdf which gives the correct code point 1D453 and copies fine. lualatex gives the faulty value too. -- Ulrike Fischer http://www.troubleshooting-tex.de/
![](https://secure.gravatar.com/avatar/46562c7d27388490d62e8d7a5bc960dd.jpg?s=120&d=mm&r=g)
when I compile the following with context
\pdfvariable compresslevel=0 \starttext $f$ \stoptext
I get in the pdf
1 beginbfchar <0515> <D875DC53> endbfchar
D875DC53 is according to http://www.russellcottrell.com/greek/utilities/surrogatepaircalculator.htm the codepoint 2D453 and this is not a valid unicode point. As a result copy& paste doesn't work correctly.
A similar example with xelatex writes D835DC53 (remark the 3 instead of the 7) instead in the pdf which gives the correct code point 1D453 and copies fine.
lualatex gives the faulty value too.
On 8/8/2018 12:13 PM, Ulrike Fischer wrote: line 228 in font-map should be: k = k - 0x10000 (not v = ...) Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl -----------------------------------------------------------------
![](https://secure.gravatar.com/avatar/d4bd34a45c928e8356f38323ff84763e.jpg?s=120&d=mm&r=g)
Am Wed, 8 Aug 2018 14:15:41 +0200 schrieb Hans Hagen:
line 228 in font-map should be:
k = k - 0x10000
(not v = ...)
Thanks, that corrects the problem. -- Ulrike Fischer http://www.troubleshooting-tex.de/
participants (2)
-
Hans Hagen
-
Ulrike Fischer