# [Cjk] CJKutf8 in TeXLive2011 cannot generate copy-and-paste PDF with other CJK fonts

Nien-Po Chen npchen at saturn.yzu.edu.tw
Tue Jul 17 05:12:41 CEST 2012

Dear LaTeX CJK listers,

Werner's <Unicode Support in the CJK Package> in
The Asian Journal of TEX, Volume 2, No. 1, April 2008
that using CJKutf8 and cmap packages along with pdflatex can generate a PDF where we can successfully copy texts and paste them somewhere else. I didn't pay attention to the copy-and-paste problem because I usually use latex + dvipdfmx work flow (using TeXLive2009 on a Mac), which can solve the problem using cid-x.map mechanism.

Recently, one of my colleauge (using TeXLive 2011 on a MS-Window-PC) encounters such problem using pdflatex work flow. It seems that only bsmi and bkai (pre-installed in TeXLive distribution) have such capability. Other CJK fonts don't.

I would like to make other CJK fonts to have the same capability, but I don't know where to start.

The following is a minimal LaTeX code to have a successful PDF (using pdflatex).

------ begin >>>>>
\documentclass[12pt]{article}
\usepackage{cmap}
\usepackage[T1]{fontenc}
\usepackage{CJKutf8}
\begin{document}
\begin{CJK}{UTF8}{bsmi}
This is a test.

\end{CJK}
\end{document}

<<<<< end ---------

If I attempt to use  Type 1 fonts of cw family (available at <ftp://cle.linux.org.tw/tex/cjk/fonts/cwt1/>), say 'cwkb', in the example above, the resultant PDF looks fine but its copy-and-paste text has garbled Chinese text. This is obviously a sympton that ToUnicode map is not set properly for this font.

I notice that the file c70bsmi.fdx has some code to deal with ToUnicode stuff, whereas cwkb does not even have c70cwkb.fdx. Is this the right place to work with? creating a c70cwkb.fdx file with similar code in it?

Any suggestion and input is welcome. Thanks in advance.
------
Nien-Po Chen