合は、dvipdfmxかdvipsでPDF化しなくてはいけない。
\documentclass[dvipdfm]{beamer} \AtBeginDvi{\special{pdf:tounicode EUC-UCS2}} % navi. symbolsは目立たないが,dvipdfmxを使うと機能しないので非表示に \setbeamertemplate{navigation symbols}{} \usepackage{graphicx}
しおりは文字化けせず、フォントも GothicBBB-Medium
が意図通りにPDFに埋
め込まれていない。
$ pdffonts beamer-test.pdf name type emb sub uni object ID ------------------------------------ ------------ --- --- --- --------- GothicBBB-Medium-Identity-H CID Type 0 no no no 8 0 GZIMOK+CMSS17 Type 1C yes yes yes 9 0 GMNIEF+CMSS10 Type 1C yes yes yes 10 0 PFKMBR+CMSSBX10 Type 1C yes yes yes 31 0
しかし、タイトルページがぐちゃぐちゃになった。
解決策が見つからない
\documentclass[dvips]{beamer} \usepackage{graphicx}
このままでは日本語しおりが文字化けするので、松本隆太郎さんの hyperrefと日本語 のconvert-euc.txt を使う。
$ dvips -Ppdf -G0 -o tmp.ps beamer-test.dvi
This is dvips(k) p1.7a Copyright 2005 ASCII Corp.(www-ptex@ascii.co.jp)
based on dvips(k) 5.95b Copyright 2005 Radical Eye Software (www.radicaleye.com)
' TeX output 2008.03.19:2148' -> tmp.ps
<tex.pro><alt-rule.pro><texps.pro><special.pro><color.pro>. <cmssbx10.pfb>
<cmss17.pfb><cmss10.pfb>[1] [2] [3] [4] [5] [6] [7]
[umusus@shakan5 tmp]$ perl convert-euc.txt < tmp.ps > beamer-test.ps
[umusus@shakan5 tmp]$ ps2pdf14 beamer-test.ps
[umusus@shakan5 tmp]$ pdffonts beamer-test.pdf
name type emb sub uni object ID
------------------------------------ ------------ --- --- --- ---------
[none] Type 3 yes no no 33 0
FDBHWC+CMSS10 Type 1C yes yes no 64 0
OIKHHA+CMSS17 Type 1C yes yes no 61 0
TPECUP+CMSS17~5c Type 1C yes yes no 93 0
JDFCIV+CMSSBX10 Type 1C yes yes no 225 0
DFVZNS+CMSSBX10~fe Type 1C yes yes no 255 0
Type 3のフォントが強制的に埋め込まれている。このフォントが汚いので何と かならないかと思うが、今のところ解決策なし。Ghostscript 8.11 だと、 NoEmbedで埋め込まないようにできるかも知れないという情報もあるが、現在 のGhostscriptのバージョンは、7.07なので、苦しい。
日本語フォントが埋め込まれてしまっている
\begin{frame}[オプション] で指定するオプションでは、次のようなものがあります。
XeLaTeXを使うと、すんなりとbeamerで日本語スライドが出来た(2010年6月7日月曜日)
%#!xelatex tmp1 \documentclass[xetex,xcolor=pdftex,dvipsnames,table]{beamer} \usepackage[cm-default]{fontspec} \setsansfont[Mapping=tex-text]{IPA Pゴシック} \usepackage{xunicode} \usepackage{xltxtra} \usepackage{booktabs} \XeTeXlinebreaklocale "ja" \XeTeXlinebreakskip=0em plus 0.1em minus 0.01em \XeTeXlinebreakpenalty=0 \def\<{\@ifstar{\zx@hwback\nobreak}{\zx@hwback\relax}} \def\zx@hwback#1{\leavevmode#1\hskip-.5em\relax} \begin{document} \begin{frame} 日本語 \begin{itemize} \item これは1段目 \item これは2段目 \end{itemize} \[ s=\sum^n_{i=1}k_i \] \end{frame} \begin{frame} \begin{tabular}{lll}\toprule hoge & fuga & 日本語\\\midrule 韓国語 & 中国語 & 西語\\\bottomrule \end{tabular} \end{frame} \end{document}
コンパイルするとそのままpdfが作成される
$ pdfinfo tmp1.pdf Creator: LaTeX with beamer class version 3.07 Producer: xdvipdfmx (0.6) CreationDate: Mon Jun 7 13:49:10 2010 Tagged: no Pages: 2 Encrypted: no Page size: 362.83 x 272.13 pts File size: 14586 bytes Optimized: no PDF version: 1.4 $ pdffonts tmp1.pdf name type emb sub uni object ID ------------------------------------ ----------------- --- --- --- --------- KUAGDV+IPAPGothic CID TrueType yes yes yes 5 0 [none] Type 3 yes no no 9 0 PSNYHZ+CMR10 Type 1C yes yes yes 10 0 OPGPRN+CMEX10 Type 1C yes yes yes 11 0 MEKPKN+CMR8 Type 1C yes yes yes 12 0