0

I installed the “Language-specific OTFs” version of Source Han Sans from Adobe Font’s Release page, e.g., SourceHanSansSC-Regular.otf, which sets the default ideographs suitable under Simplified Chinese convention but still provides “full character coverage or the ability to language-tag text to use glyphs that are appropriate for the other languages”.

When I create a PDF via

\documentclass{article}
\usepackage{fontspec}
\setmainfont{SourceHanSansSC-Regular.otf}
\newcommand\test{\char"8FD4 E567F\par}
\begin{document}
\test
\addfontfeatures{Script=CJK Ideographic,Language=Chinese Simplified}
\test
\addfontfeatures{Script=CJK Ideographic,Language=Chinese Traditional}
\test
\addfontfeatures{Script=CJK Ideographic,Language=Chinese Hong Kong}
\test
\addfontfeatures{Script=CJK Ideographic,Language=Japanese}
\test
\addfontfeatures{Script=CJK Ideographic,Language=Korean}
\test
\end{document}

The output looks fine, with the ideograph U+8FD4 in its five different forms. Also, notice that the digit height is slightly lower than the cap height in Latin/Default Script while the two are equal in CJK Script. This is desirable design in different scripts.

Source Han Sans test

But copying/pasting from the PDF has problem:

From XeLaTeX    From LuaLaTeX
返EF        返E567F
返E567F          返E567F
E567F          返E567F
E567F          返E567F
E567F          返E567F
E567F          返E567F

Observe that both engines have problem with digits under Latin Script: XeTeX thinks they are “tofu” while LuaTeX thinks they are “fullwidth”-variants (U+FF10U+FF19). Furthermore, XeTeX fails to embed the ideograph info U+8FD4 for languages other than Simplified Chinese into the PDF.

  • My OS: Windows 8 and the fonts are installed system-wise.
  • My TeX Distribution: MiKTeX 2.9.7000 with everything up to date (as of 2019/04/30).
  • My PDF Viewer: Adobe Acrobat Reader where I did the copying/pasting.

Maybe related posts:


Added: It appears that issuing \XeTeXgenerateactualtext=1 in the preamble fixes the copying/pasting problem for XeTeX, see also Who changed my Chinese character?. Any ideas about LuaTeX?

I also found many CMap files in the Resources folder of the Release branch. Should I use UniSourceHanSansCN-UTF16-H and, if so, how?

Ruixi Zhang
  • 9,553

0 Answers0