1 \documentclass[11pt,a4paper]{article} 2 \usepackage{fontspec,xltxtra,xunicode} 3 \usepackage[slantfont,boldfont]{xeCJK} 4 \setCJKmainfont[BoldFont=Adobe Heiti Std,ItalicFont=Adobe Kaiti Std]{Adobe Song Std} 5 \setCJKsansfont{Adobe Heiti Std} 6 \setCJKmonofont{Adobe Fangsong Std} 7 \setCJKfamilyfont{song}{Adobe Song Std} 8 \setCJKfamilyfont{hei}{Adobe Heiti Std} 9 \setCJKfamilyfont{fangsong}{Adobe Fangsong Std} 10 \setCJKfamilyfont{kai}{Adobe Kaiti Std} 11 \title{\LaTeX中文博客模板} 12 \author{wangl393} 13 \date{\today} 14 \begin{document} 15 \maketitle 16 {默认效果 宋体}\\ 17 {\bfseries 粗体效果 设置成黑体}\\ 18 {\itshape 斜体效果 设置成楷体}\\ 19 \CJKfamily{kai} CJKfamily为楷体效果\\ 20 \CJKfamily{fangsong} CJKfamily为仿宋效果\\ 21 \CJKfamily{hei} CJKfamily为黑体效果\\ 22 \end{document}
还有很多细节的地方需要琢磨。现把模板放这。写个博客试试看