0

Why does the following not work

\section{ \begin{CJK}{UTF8}{gbsn}
白居易
\end{CJK}}

It works when I use it in the main text, but does not work within \section{xxx}.

Same applies to the following case \section{ \includegraphics[]{image.png}}

Any advise on how to force the chinese characters in the section using the CJK package and pdflatex ? (I don't want to use xelatex or luatex since they mess up my other settings).

  • 1
    Welcome to TeX.SX! Please add a minimal working example (MWE) that illustrates your problem. It will be much easier for us to reproduce your situation and find out what the issue is when we see compilable code, starting with \documentclass{...} and ending with \end{document}. – Mensch Aug 3 '13 at 11:17
4

You should use CJK environment gloally.

\documentclass{article}
\usepackage{CJKutf8}
\usepackage[T1]{fontenc}

\begin{document}
\begin{CJK}{UTF8}{gbsn}

\section{About 白居易}

some text

\clearpage\end{CJK}
\end{document}

Don't forget \clearpage at the end of CJK environment. It is about a bug of CJK package.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.