2

code:

%!TeX program = pdfLaTeX
\documentclass{article}
\usepackage{CJKutf8,pinyin}
\usepackage[overlap,CJK]{ruby}
\usepackage{setspace}
\usepackage{xpinyin}

% Start Editing Document
\begin{document}

\begin{CJK}{UTF8}{bkai}
\begin{spacing}{2}
\ruby{帀}{Za}
\end{spacing}
\end{CJK}

\begin{CJK}{UTF8}{bkai}
\begin{spacing}{2}
\ruby{體}{Ti}
\end{spacing}
\end{CJK}

\end{document}

The first character 帀 can't be displayed and the second one 體 works.

Any suggestions are appreciated.

2
3

I expect that 帀 is not in the font bkai. It is not in bsmi or gbsn either.

Instead of using pdflatex and 8-bit fonts, it is easier to use xelatex and Unicode system fonts.

za ti

MWE

%!TeX program = XeLaTeX
\documentclass[varwidth,border=6pt]{standalone}
\usepackage{xeCJK}
\setCJKmainfont{Noto Sans CJK SC}
\usepackage[overlap,CJK]{ruby}
\usepackage{setspace}
\usepackage{xpinyin}

% Start Editing Document
\begin{document}
\Large
%\begin{CJK}{UTF8}{bkai}
\begin{spacing}{2}
\ruby{帀}{Za}
\end{spacing}
%\end{CJK}

%\begin{CJK}{UTF8}{bkai}
\begin{spacing}{2}
\ruby{體}{Ti}
\end{spacing}
%\end{CJK}

\end{document}

Edited to add:

Note that CJKutf8 under pdflatex selects missing characters from the specified (unicode) font, so that:

\begin{CJK}{UTF8}{Noto Serif CJK TC}
\begin{spacing}{2}
\ruby{帀}{Za}
\end{spacing}
\end{CJK}

produces

za


Edit2:

ruby is not really required if you have xpinyin.

\xpinyin*{帀}

produces

za pinyin

with the tone mark.

It works in both xelatex and pdflatex, but in pdflatex you will have to load a nice-looking font for the Latin of the pinyin using \usepackage{...} (see the manual: do texdoc xpinyin).


Sample

5e00

MWE

\documentclass{article}%[12pt,varwidth,border=6pt]{standalone}
\usepackage{xcolor}
\pagecolor{red!3}

\usepackage{fontspec}
\newfontface\ffa{BabelStone Han}[Colour=blue]
\newfontface\ffb{CloudSongDaGBK}
\newfontface\ffc{\detokenize{DFKai-SB}}
\newfontface\ffd{GenEi Koburi Mincho TTF}
\newfontface\ffe{Heiti TC}
\newfontface\fff{IPAexMincho}
\newfontface\ffg{KaiTi}
\newfontface\ffh{Kochi Mincho}
\newfontface\ffi{KouzanBrushFont}

\newfontface\fga{MingLiU}
\newfontface\fgb{NemukeMedium}
\newfontface\fgc{Noto Serif JP}
\newfontface\fgd{Noto Serif JP Black}
\newfontface\fge{Noto Serif JP ExtraLight}
\newfontface\fgf{SentyTang}
\newfontface\fgg{SentyWen}
\newfontface\fgh{Source Han Serif}
\newfontface\fgi{Togoshi Mincho}

\setmainfont{Noto Serif}
\newcommand\mfsize{\huge}
\newcommand\theegsym{帀}
\begin{document}
\section*{Sampling {\mfsize\ffa \theegsym }}

\vspace{24pt}

\begin{tabular}{rccl}
BabelStone Han & \mfsize\ffa \theegsym & \mfsize \fga \theegsym &MingLiU \\
\ &\ & \ & \ \\ 
CloudSongDaGBK & \mfsize\ffb \theegsym & \mfsize \fgb \theegsym &NemukeMedium \\
\ &\ & \ & \ \\ 
DFKai-SB & \mfsize\ffc \theegsym & \mfsize \fgc \theegsym &Noto Serif JP \\
\ &\ & \ & \ \\ 
GenEi Koburi Mincho TTF & \mfsize\ffd \theegsym & \mfsize \fgd \theegsym &Noto Serif JP Black \\
\ &\ & \ & \ \\ 
Heiti TC & \mfsize\ffe \theegsym & \mfsize \fge \theegsym &Noto Serif JP ExtraLight \\
\ &\ & \ & \ \\ 
IPAexMincho & \mfsize\fff \theegsym & \mfsize \fgf \theegsym &SentyTang \\
\ &\ & \ & \ \\ 
KaiTi & \mfsize\ffg \theegsym & \mfsize \fgg \theegsym &SentyWen \\
\ &\ & \ & \ \\ 
Kochi Mincho & \mfsize\ffh \theegsym & \mfsize \fgh \theegsym &Source Han Serif \\
\ &\ & \ & \ \\ 
KouzanBrushFont & \mfsize\ffi \theegsym & \mfsize \fgi \theegsym &Togoshi Mincho \\

\end{tabular}


\end{document}
2
  • Thank you, the solution works out greatly. The following question, is there a way to get the bkai-ish style font with the 帀 displayed? Here is a example font list from overleaf, however, bkai-ish style for 帀 is not one of them Feb 9 '20 at 15:44
  • @ZhenshanJin I don't know Overleaf. For font questions, graphicdesign.stackexchange.com/questions/tagged/fonts may be of help. Or else you can look: a utility like BabelPad will list which system fonts have a specified character. See edited answer for example of a random sample of some fonts with U+5E00.
    – Cicada
    Feb 12 '20 at 12:11

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.