Fork doc into readme and example.

This commit is contained in:
Casper Ti. Vector 2014-04-11 17:13:28 +08:00
parent 265042fdf0
commit 0fd8f01108
42 changed files with 2161 additions and 0 deletions

View File

@ -0,0 +1,63 @@
2011/12/21ver 1.3(包括前面所有 alpha、beta 和 rc 版本):
--- 进一步重构,
将核心设置集中于 pkuthss 文档类中,
常见的额外设置集中于 pkuthss-extra 宏包中。
--- 统一宏的命名规则。
--- 支持使用 key=val 语法进行文档信息的设置,使文档结构更加清晰。
--- 设定 pdf 元数据时使用英文的文档信息,绕过字符编码的问题。
--- 在文档中加入一份代码的 listing
以尽量避免不断有人抱怨的文档类代码“乱码”的问题。
--- 去掉了 FAQ 部分,
因为其中内容或是比较陈旧,或是已经在前面提到。
--- 重新选择 license尽量减少对用户不必要的约束。
2010/11/30ver 1.2(包括前面所有 beta 版本):
--- 支持 UTF-8 和 GBK 编码。
支持 XeLaTeX但不可和 GBK 同用)。
--- 较大规模重构:
定义了一些新命令以实现一些重复的代码的功能,
删除了冗余代码和一些用处不大的旧命令,调整了目录结构。
--- 将部分重复代码统一,
并把一些将来可能引起不兼容的命令以标准 LaTeX 命令代替。
--- 考虑到现在的 ctex 宏包已经对中文排版的格式做出了较好的设定,
并且已经较好地支持了 hyperref
删除了类文件中规定排版格式的部分代码,
且去除了对 ifpdf 宏包的直接依赖。
--- 统一各处的长度单位,均使用 pt 或 em以免引起困惑。
--- 从美的角度调整了部分排版格式,
特别是去掉了所有用 poor man's bold 实现的“粗宋体”。
2008/03/13ver 1.1
--- 更正了“geometry”将纸张大小设为“a4paper”。
--- 更新了 chaps/mydefs.tex将“colorlinks”设为“false”
因为带颜色的链接在黑白打印机上打出来往往颜色很浅。
--- 更正了 chaps/sample.bib将“SOURCE”改为“URL”。
这样 BibTeX 虽然又会 Warning不过这样概念上更正确
而且结果还不错。
--- 删除了 pkuthss.cls 和 pkuthss.def 的部分内容,
因为最后的两个声明都不必装订到论文中。
2007/12/12ver 1.0 rc4
--- 将“\bibstyle”设为“chinesebst”。
2007/09/05ver 1.0 rc3
--- 封面页作了小的调整,当标题只有一行时也不会产生 Warning。
现在的实现方法使用的是标准的 LaTeX box。
--- 加入了“graphicx”的版本要求。
2007/09/04ver 1.0 rc2
--- 在 preamble 部分现在可使用中文。
--- 更正了版心尺寸即在“geometry”的选项中加入“includeheadfoot”。
--- 改进了 pkulogo.ps ,并提供了 img/Makefile。
2007/09/02ver 1.0 rc1
--- 由于“\ifx\pdfoutput\undefined”在 teTeX-3.0 中不起作用,
改为使用“ifpdf”宏包。
--- sample.tex and chaps/1.tex changed accordingly。
--- Linux/Unix 的默认编译方式改为使用 pdflatex见 Makefile。
--- 消除了运行 BibTeX 时出现的一个 Warning。
2007/09/01ver 1.0 beta
--- 最初的尝试。
# vim:ts=4:sw=4

155
doc/readme/ChangeLog.txt Normal file
View File

@ -0,0 +1,155 @@
2014-04-11, v1.4
* Changes to package code:
- pkuthss.cls: do not disable `\uppercase' in `nouppermark' mode.
* Changes to documentation:
- Remove support for CRLF (except for Windows .bat's), as required by CTAN.
* Misc:
- Minor fixes and improvements.
2013-12-26, v1.4 rc4
* API Changes:
- Add `caption' option to customise caption fonts.
- Remove `\label@cmentorb'; `\label@cmentora' -> `\label@cmentor'.
- Move `[no]uppermark' to pkuthss.cls.
* Changes to package code:
- Consider `oneside' in page style.
* Changes to documentation:
- Add support for 2-dimensional bar code.
- Add and refine lots of hints.
* Misc:
- Minor fixes and improvements.
2013-04-07, v1.4 rc3
* Misc:
- Update copyright notices.
- Minor fixes and improvements.
2013-03-30, v1.4 rc2
* Changes to package code:
- Use the internal hyperref support in ctex 1.02c+.
- Remove usage of etoolbox.
* Changes to documentation:
- Add hint for split sorting with biblatex.
* Misc:
- Minor improvements.
2013-01-10, v1.4 rc1
* Changes to documentation:
- Remove troublesome `hologo' package.
- chap3.tex: add notice about biblatex's `\bibname' issue.
- introduction.tex: update info about location of example source code.
* Misc:
- README: add not-intended-as-documentation notice.
2012-11-12, v1.4 beta3
* Misc:
- Fix incorrect CTAN support.
- utils/dist: Fix date conversion code again.
2012-10-11, v1.4 beta2
* Changes to package code:
- Adjust pkulogo/pkuword typesetting according to
<http://web5.pku.edu.cn/bs/images/cgzs/images1/13.png>
* Changes to documentation:
- Add (more) useful notices and hints.
- Bibliography sanitation.
* Misc:
- Add CTAN support.
- utils/bump: Improve date conversion code.
2012-05-31, v1.4 beta1
* Changes to documentation:
- Use `biber -l zh__pinyin'.
- Add notice for biber in the "compilation" section.
- Recommend users to use standalone TeXLive.
- Minor adjustment to documentation order.
* Misc:
- Minor fixes and improvements.
- Add QA test for biblatex-caspervector version.
- Remove spaces and tabs on blank lines, add related QA check.
2012-05-30, v1.4 alpha3
* API Changes:
- `[no]tocbibind' -> `[no]pdftoc', functionality reduced (see below).
- `[no]upcite' removed since biblatex supports it quite flexibly.
* Changes to package code:
- Remove uses of tocbibind because it crashes with biblatex.
* Changes to documentation:
- Use biblatex for bibliography formatting.
- Add instructions for natbib, remove instructions for natbib.
- (Re)add the FAQ section.
- Use more printer-friendly colours.
- Enhance `doc/Make.bat' with bat's `call'.
- Use the hologo package for TeX logos.
- Use tabs in `pkuthss.bib'.
- Update bib file for Casper's biblatex style.
- `thanks.tex' -> `acknowledge.tex'
- Use better determined format for .bib files.
* Misc:
- Split Makefile functionalities to executable in `utils/'.
- `maintcheck' -> `qa', `revbump' -> `bump'.
- Split encoding and line terminator stuffs to `enclt'.
- `dist' now automatically joins biblatex-caspervector files.
- Update find(1) usage.
- QA script updated.
- Use sed(1)'s `y' instead of python's `str.translate()' in `bump'.
- Add appropriate copyright notices.
- Add indentation modelines.
2012-05-12, v1.4 alpha2
* Changes to package code:
- Fix positioning of boxes on title page.
- Unify code that fill in blanks on the title page.
- Merge ctex-kit updates with minor modifications.
* Changes to documentation:
- Add indication for customising title page by modifying `pkuthss.cls'.
* Misc:
- Add `maintcheck' and `revbump' to root Makefile to ease automation.
2012-04-13, v1.4 alpha1
* API Changes:
- `[no]linkcolor' -> `[no]colorlinks'.
- `[no]pdfmeta' -> `[no]pdfprop'.
- `\setpdfmetadata' -> `\setpdfproperties'.
* Changes to package code:
- Simplify package code with `\@nameuse' and `\@namedef'.
- Use `导\hspace{2em}师:' for title page and `导师:' for abstract.
* Changes to documentation:
- Fix typos: "模板" -> "模版".
- Indicate that `texdoc' requires pkuthss be installed "regular"ly.
- Improve spacing details.
* Misc:
- Update copyright notices.
- Revise Makefiles.
# vim:ts=4:sw=4

48
doc/readme/Make.bat Normal file
View File

@ -0,0 +1,48 @@
@echo off
@rem vim:ts=4:sw=4
@rem
@rem Copyright (c) 2008-2009 solvethis
@rem Copyright (c) 2010-2012 Casper Ti. Vector
@rem Public domain.
set JOBNAME=pkuthss
@rem 这个变量的值可以为 latex 或 pdflatex。
set LATEX=latex
@rem 如果无法使用 biber可以改为“bibtex”。
set BIBTEX=biber -l zh__pinyin
set GBK2UNI=gbk2uni
set DVIPDF=dvipdfmx
if "%LATEX%"=="latex" (set DODVIPDF=%DVIPDF% %JOBNAME%
) else (set DODVIPDF=echo No need to run %DVIPDF%.)
@rem 用 pdflatex 时可能需要使用 gbk2uni 转换 .out 文件编码以防书签乱码。
if "%LATEX%"=="pdflatex" (@rem set DOGBK2UNI=%GBK2UNI% %JOBNAME%
) else (set DOGBK2UNI=echo No need to run %GBK2UNI%.)
if "%1"=="" goto doc
if "%1"=="doc" goto doc
if "%1"=="clear" (goto clear) else (goto usage)
:doc
cd img
call Make.bat
cd ..
%LATEX% %JOBNAME%
%BIBTEX% %JOBNAME%
%DOGBK2UNI%
%LATEX% %JOBNAME%
%LATEX% %JOBNAME%
%DODVIPDF%
goto end
:clear
del *.aux *.bbl *.bcf *.blg *.dvi *.lof *.log *.lot *.run.xml *.toc *.out
del missfont.log chap\*.aux
goto end
:usage
echo %0 [doc] [clear]
goto end
:end

62
doc/readme/Makefile Normal file
View File

@ -0,0 +1,62 @@
# vim:ts=4:sw=4
#
# Copyright (c) 2008-2009 solvethis
# Copyright (c) 2010-2012 Casper Ti. Vector
# Public domain.
# 被编译的主文件的文件名,不包括扩展名。
JOBNAME = pkuthss
# 这个变量的值可以为 latex、pdflatex 或 xelatex。
LATEX = latex
# 如果无法使用 biber可以改为“bibtex”。
BIBTEX = biber -l zh__pinyin
GBK2UNI = gbk2uni
DVIPDF = dvipdfmx
# 如果用 LaTeX 编译,则使用 dvipdfmx 将 dvi 转成 pdf。
ifeq ($(LATEX), latex)
DODVIPDF = $(DVIPDF) $(JOBNAME)
endif
# 使用 GBK 编码和 pdflatex 编译方式时,可能需要使用 gbk2uni 转换 .out
# 文件编码,以防书签乱码。
ifeq ($(LATEX), pdflatex)
# 考虑到可能有用户未安装 gbk2uni且有用户使用 UTF-8 编码,
# 默认用“#”注释掉了 DOGBK2UNI 的定义。
# 用户可以手动取消其注释(去掉下一行中的“#”)。
#DOGBK2UNI = $(GBK2UNI) $(JOBNAME)
endif
# 区分是 Windows 环境还是类 UNIX 环境。
# 如果是后者,则 GNU make 将可以检测到已经定义 PATH 环境变量。
ifdef PATH
MAKE = make
RM = rm -f
else
MAKE = mingw32-make
RM = del
endif
all: img_ doc
img_:
cd img && $(MAKE)
img-clean:
cd img && $(MAKE) clean
doc:
$(LATEX) $(JOBNAME)
$(BIBTEX) $(JOBNAME)
$(DOGBK2UNI)
$(LATEX) $(JOBNAME)
$(LATEX) $(JOBNAME)
$(DODVIPDF)
clean:
$(RM) $(JOBNAME).{aux,bbl,bcf,blg,dvi,lof,log,lot,run.xml,toc,out{,.bak}} \
{missfont,texput}.log chap/*.aux
distclean: clean img-clean
$(RM) $(JOBNAME).pdf

View File

@ -0,0 +1,18 @@
% vim:ts=4:sw=4
%
% Copyright (c) 2008-2009 solvethis
% Copyright (c) 2010-2013 Casper Ti. Vector
% Public domain.
\begin{cabstract}
本文介绍了 pkuthss 文档模版所提供的功能,
并以自身为例演示了该模版的使用。
\end{cabstract}
\begin{eabstract}
This paper describes the the functions provided by
the pkuthss document template,
and provides itself as an example to illustrate
the usage of the document class.
\end{eabstract}

View File

@ -0,0 +1,12 @@
% vim:ts=4:sw=4
%
% Copyright (c) 2008-2009 solvethis
% Copyright (c) 2010-2012 Casper Ti. Vector
% Public domain.
\chapter{致谢}
感谢北大未名 BBS 的 MathTools 版和 Thesis 版诸位同学的支持。
特别感谢 pkuthss 模版的最初创作者 solvethis 网友,
以及不断地对 Casper 提出的诸多问题予以解答的 cauchy 网友 :)

211
doc/readme/chap/chap1.tex Normal file
View File

@ -0,0 +1,211 @@
% vim:ts=4:sw=4
%
% Copyright (c) 2008-2009 solvethis
% Copyright (c) 2010-2013 Casper Ti. Vector
% Public domain.
\chapter{使用介绍}
\section{系统要求}\label{sec:req}
正确编译需要以下几部分:
\begin{itemize}
\item 一个基本的 \TeX{} 发行版。
\item CJK 或 XeCJK供 Xe\LaTeX{} 使用)宏包。
\item ctex 宏包\supercite{ctex,ctex-faq}(提供了 ctexbook 文档类)。
\item 中文字体。
\item 如果要使用 biblatex 进行文献列表和引用的排版的话,
还需要 biblatex 宏包\supercite{biblatex}
\item 如果需要对中文文献进行按汉语拼音的排序的话,
还需要 biber 程序\supercite{biber}
\item 如果默认的文献列表和引用样式的话,
还需要作者编写的 biblatex 样式
biblatex-caspervector\supercite{biblatex-caspervector}
\item 如果需要使用 Makefile 来实现自动编译,还需要 Make 工具;
但如果使用由批处理实现的伪“Makefile”就不用了。
\end{itemize}
\myemph{最新}\myemph{完全版} \TeX{}Live 系统(\myemph{%
注:
某些 Linux 发行版软件仓库中的 \TeX{}Live 有问题,
建议使用独立安装版的 \TeX{}Live%
\footnote{\url{http://www.tug.org/texlive/}.}%
})和 \CTeX{} 套装都已经包含除中文字体和 Make 之外所有要求的项目。%
\myemph{%
为了获得最好的支持,
我们建议用户使用最新完全版的 \TeX{} 系统和各宏包。%
}
中文字体需要用户自行获得。\myemph{%
注:
一些中文字体的字库不全,
只有 GB2312 字符集内字符的字体信息。
这种情况通常会造成编译生成的 pdf 文件中缺少部分字符,
其中一种典型症状是封面的“〇”字显示不出来。
如果要使用中易公司的字体,
则建议使用 Windows Vista 及其以后版本提供的%
宋体、黑体、楷体和仿宋体,
以及 Microsoft Office 2003 及其以后版本提供的隶书和幼圆体,
这些字体是 GB18030 字符集的,不存在上述问题。%
}
Linux 用户可以从软件源获得 GNU 的 make
其它类 UNIX 系统应该也会提供 make 工具,请参阅相应的文档以获得帮助。%
Windows 用户可以从以下地址下载 Windows 下的 GNU make 工具:\\
\hspace*{\parindent}%
\url{http://gnuwin32.sourceforge.net/packages/make.htm}
\section{安装方法}\label{sec:inst}
使用 \TeX{}Live 的用户可以通过在终端中以管理员权限执行
\begin{Verbatim}[frame = single]
tlmgr install pkuthss
\end{Verbatim}
来安装 pkuthss 文档模版。
使用 \CTeX{} 套装的用户可以通过在命令提示符中执行
\begin{Verbatim}[frame = single]
mpm --install=pkuthss
\end{Verbatim}
来安装 pkuthss 文档模版。
\section{模版文件}\label{sec:doc-dir}
在正确安装 pkuthss 文档模版之后,在终端/命令提示符中执行
\begin{Verbatim}[frame = single]
texdoc pkuthss
\end{Verbatim}
所打开的 pdf 所在的同一目录中包含本文档(\verb|pkuthss.pdf|)的源代码%
\verb|utf8/| 和 \verb|gbk/| 两个子目录,
两目录中代码除使用的字符编码基本上完全相同)。
其中,%
\verb|utf8/| 目录下的源代码使用的是 UTF-8 编码,适合类 UNIX 系统用户使用;%
\verb|gbk/| 目录下的源代码使用的是 GBK 编码,适合 Windows 用户使用。%
用户可以试情况将 \verb|utf8/| 或 \verb|gbk/| 中的所有内容复制到合适的目录,
并在此目录中根据模版修改出自己的论文。
\myemph{%
注意:
在 1.4 rc4 之后版本的 pkuthss 文档模版中,除了 \texttt{Make.bat} 之外,
所有文件均是 LF\texttt{\string\n})换行。
在 Windows 下用“记事本”打开这些文件时,
所有的换行会变成某个奇怪的字符,而所有文字会挤在一行上。
这是“记事本”的固有问题,
因此 pkuthss 文档模版的作者建议用户
使用支持 LF 换行的文本编辑器编辑文件。%
}
\verb|utf8/| 和 \verb|gbk/| 目录中的重要文件有:
\begin{itemize}
\item \verb|Makefile|
被 Make 工具调用的 Makefile用于使编译工作自动化。
\item \verb|Make.bat|%
Windows 下的伪“Makefile”用 Windows 批处理实现。
\item \verb|chap/|:目录,包含各章节内容:
\begin{itemize}
\item \verb|copyright.tex|
版权声明部分\footnote{%
本文档中的版权声明并不是%
学校默认要求的形式\supercite{pku-copyright}
符合学校要求的一个版权声明已经放在此文件中,
但用 \texttt{\string\iffalse{} ...\ \string\fi} %
注释掉了,
用户可以考虑使用这个版本。
}
\item \verb|originauth.tex|
原创性声明和使用授权说明部分\supercite{pku-originauth}
\end{itemize}
\myemph{%
注:%
pkuthss 文档模版支持排版学校要求的二维码,
请参考 \texttt{copyright.tex}
\texttt{originauth.tex} 中的相关注释。%
}
\item \verb|img/|:目录,包含论文中所有图片:
\begin{itemize}
\item \verb|Makefile|:图片部分的 Makefile。
\item \verb|Make.bat|%
Windows 下的伪“Makefile”用 Windows 批处理实现。
\item \verb|pkulogo.eps|:北京大学校徽。
\item \verb|pkuword.eps|:“北京大学”字样。
\end{itemize}
\myemph{%
注:%
pdf\LaTeX{} 方式编译(见第 \ref{sec:compile} 节)
可能需要将 eps 图片转换为 pdf 格式,
而使用 Makefile 或伪“Makefile”时这些图片可以自动生成
不使用 Makefile 的用户可以手动运行 %
\texttt{img/} 目录中的 Makefile 或伪“Makefile”
来生成这些图片。%
}
\end{itemize}
\section{编译方式}\label{sec:compile}
pkuthss 文档模版支持三种编译方式,即
\begin{itemize}
\item \LaTeX{} -- dvipdfmx 方式:\\
依次执行 \verb|latex|\verb|biber|(或 \verb|bibtex|%
\verb|latex|\verb|latex| 和 \verb|dvipdfmx|。\\
\myemph{%
注意:除非无法使用 biber否则不建议使用 bibtex。
如果的确要使用 bibtex请将 biblatex 宏包的\texttt{backend}
选项从 \texttt{biber} 改为 \texttt{bibtex}
在 Makefile 中将变量 \texttt{BIBTEX} 的值改为 \texttt{bibtex}
并去掉 biblatex 宏包和 \texttt{\string\printbibliography} 命令
\texttt{sorting} 选项。
以下各编译方式也存在类似的注意事项,不再重复说明。%
}
\item pdf\LaTeX{} 方式:\\
依次执行 \verb|pdflatex|\verb|biber|(或 \verb|bibtex|%
\verb|pdflatex| 和 \verb|pdflatex|。
\item Xe\LaTeX{} 方式:\\
依次执行 \verb|xelatex|\verb|biber|(或 \verb|bibtex|%
\verb|xelatex| 和 \verb|xelatex|。\\
\myemph{%
注意Xe\LaTeX{} 对非 UTF-8 的编码支持不好,
因此 Xe\LaTeX{} 方式的编译不支持 GBK 编码。%
}
\end{itemize}
pkuthss 文档模版附带的 Makefile 中已经对这三种编译方式进行了完整的配置。
用户只需要在 Makefile 中通过设定变量 \verb|JOBNAME| 的值%
指定被编译的主文件名,
并通过设定变量 \verb|LATEX| 的值指定采用哪种编译方式,
即可通过在主文件所在目录调用 Make 工具来实现自动编译:
如果是在类 UNIX 环境下,则用户应该调用的命令名为 \verb|make|
\begin{Verbatim}[frame = single]
cd /path/to/directory/with/pkuthss.tex
make
\end{Verbatim}
而如果是在 Windows 环境下,
则用户应该调用的命令名可能为 \verb|mingw32-make|
\begin{Verbatim}[frame = single]
cd \path\to\directory\with\pkuthss.tex
mingw32-make
\end{Verbatim}
用户如果不想配置 Windows 下的 GNU Make
则也可以使用由 Windows 批处理实现的伪“Makefile”
通过在主文件所在目录调用 \verb|make|\footnote{%
Windows 将批处理文件作为可执行文件,
调用时可以不显式地指出扩展名。%
}
\begin{Verbatim}[frame = single]
cd \path\to\directory\with\pkuthss.tex
make
\end{Verbatim}
\myemph{%
注意:%
Windows 批处理对于 LF\texttt{\string\n})换行的批处理文件支持有问题。
在命令提示符cmd下执行这些批处理文件时没有问题
但双击文件图标执行时就会出错。
作者在 Google Code 和北大未名 BBS 上发布的压缩包中 \texttt{Make.bat}
均是 CRLF\texttt{\string\r\string\n})换行,
\TeX{}Live、\CTeX{} 套装中安装的 \texttt{Make.bat}
CTAN 上提供的压缩包里的 \texttt{Make.bat}
可能是 LF\texttt{\string\n})换行的。%
}

361
doc/readme/chap/chap2.tex Normal file
View File

@ -0,0 +1,361 @@
% vim:ts=4:sw=4
%
% Copyright (c) 2008-2009 solvethis
% Copyright (c) 2010-2013 Casper Ti. Vector
% Public domain.
\chapter{pkuthss 文档模版提供的功能}
\section{pkuthss 文档模版提供的文档类和宏包选项}
\subsection{pkuthss 文档类提供的选项}\label{ssec:options}
\begin{itemize}
\item \textbf{\texttt{[no]extra}}
用于确定是否自动载入 pkuthss-extra 宏包。
在默认情况下pkuthss 文档类将使用 \verb|extra| 选项。
用户如果不需要自动载入 pkuthss-extra 宏包,
则需要在载入 pkuthss 时加上 \verb|noextra| 选项。
\item \textbf{\texttt{[no]uppermark}}
是否在页眉中将章节名中的小写字母转换为大写字母。
就目前而言,
这样的转换存在着一些较为严重的缺陷\footnote{%
准确地说是 \texttt{\string\MakeUppercase} 宏的问题,
其在某些地方的转换不够健壮,
例如 \texttt{\string\cite\string{ctex\string}}
会被转换成 \texttt{\string\cite\string{CTEX\string}}%
}
因此不建议使用。
基于上述考虑,%
\myemph{%
pkuthss 文档类默认启用 \texttt{nouppermark} 选项,
即在不在页眉中使用大写的章节名%
}
\item \textbf{pkuthss-extra 宏包提供的选项}
这些选项将被传递给 pkuthss-extra 宏包
(用户需要启用 \verb|extra| 选项)。
具体说明参见第 \ref{ssec:extra} 小节。
\item \textbf{其余文档类选项}%
pkuthss 文档类以 ctexbook 文档类为基础,
其接受的其余所有文档类选项均被传递给 ctexbook。
其中可能最常用的选项是 \verb|GBK| 和 \verb|UTF8|
它们选择源代码使用的字符编码,默认使用 \verb|GBK|。
\end{itemize}
例如,如果需要使用 UTF-8 编码撰写论文,
则需要在导入 pkuthss 文档类时加上 \verb|UTF8| 选项:
\begin{Verbatim}[frame = single]
\documentclass[UTF8, ...]{pkuthss} % “...”代表其它的选项。
\end{Verbatim}
又例如,文档默认情况下是双面模式,每章都从右页(奇数页)开始。
如果希望改成一章可以从任意页开始,可以这样设置:
\begin{Verbatim}[frame = single]
\documentclass[openany, ...]{pkuthss} % 每章从任意页开始。
\end{Verbatim}
但这样设置时左右(奇偶)页的页眉页脚设置仍然是不同的。
如果需要使左右页的页眉页脚设置一致,可以直接采用单面模式:
\begin{Verbatim}[frame = single]
% 使用 oneside 选项时不需要再指定 openany 选项。
\documentclass[oneside, ...]{pkuthss}
\end{Verbatim}
\subsection{pkuthss-extra 宏包提供的选项}\label{ssec:extra}
除非特别说明,
下面提到的选项中都是不带“\verb|no|”的版本被启用。
\begin{itemize}
\item \textbf{\texttt{[no]spacing}}
是否采用一些常用的对空白进行调整的版式设定。
具体地说,启用 \verb|space| 选项后会进行以下几项设置:
\begin{itemize}
\item 自动忽略 CJK 文字之间的空白而%
保留CJK 文字与英文之间等的)其它空白。
\item 调用 setspace 宏包以使某些细节处的空间安排更美观。
\item 设置页芯居中。
\item 设定行距为 1.41\footnote{%
为什么是 1.41?因为 $\sqrt{2}\approx1.41$%
}
\item 使脚注编号和脚注文本之间默认间隔一个空格。
\end{itemize}
\item \textbf{\texttt{[no]tightlist}}
是否采用比 \LaTeX{} 默认设定更加紧密的枚举环境。
在枚举环境itemize、enumerate 和 description
每个条目的内容较少时,条目往往显得稀疏;
在参考文献列表中也有类似的现象。
启用 \verb|tightlist| 选项后,
将去掉这些环境中额外增加的(垂直)间隔。
\item \textbf{\texttt{[no]caption}}
是否使图表标题使用和正文不同的字体
(此处设为中文楷书、英文斜体,
如图 \ref{fig:example} 所示)。
根据排版中常见的审美原则,
一般应使图表标题的字体、字号轻
(例如楷书之于宋体、五号字之于小四号字)于正文,
图表内容的字体、字号轻于图表标题。
\begin{figure}[htbp!]
\centering
\includegraphics[width = 0.5\textwidth]{img/pkuword}
\caption{示例插图}\label{fig:example}
\end{figure}
\item \textbf{\texttt{[no]pdftoc}}\footnote{%
此选项部分等价于 1.4 alpha2 及以前版本 pkuthss-extra 宏包%
\texttt{[no]tocbibind} 选项。
因为 tocbibind 宏包和 biblatex 宏包冲突,
pkuthss-extra 宏包不再调用 tocbibind 宏包。%
}
启用 \verb|pdftoc| 选项后,
\verb|\tableofcontents| 命令生成目录时%
会自动添加“目录”的 pdf 书签。
\item \textbf{\texttt{[no]spechap}}\footnote{%
“spechap”是“\textbf{spec}ial \textbf{chap}ter”的缩写。%
}
是否启用第 \ref{ssec:misc} 小节中介绍的 %
\verb|\specialchap| 命令。
\item \textbf{\texttt{[no]pdfprop}}
是否自动根据设定的论文文档信息(如作者、标题等)
设置生成的 pdf 文档的相应属性。%
\myemph{%
注意:
该选项实际上是在 \texttt{\string\maketitle} 时生效的,
这是因为考虑到%
通常用户在调用 \texttt{\string\maketitle}%
已经设置好所有的文档信息。
若用户不调用 \texttt{\string\maketitle}
则需在设定完文档信息之后自行调用%
\ref{ssec:misc} 小节中介绍的 %
\texttt{\string\setpdfproperties} 命令以完成
pdf 文档属性的设定。%
}
\item \textbf{\texttt{[no]colorlinks}}\footnote{%
此选项等价于 1.3 及以前版本 pkuthss-extra 宏包%
\texttt{[no]linkcolor} 选项,
但后来发现这会和 hyperref 宏包的一个同名选项冲突,
故改为 \texttt{[no]colorlinks}%
}
是否在生成的 pdf 文档中使用彩色的链接。
\end{itemize}
例如,在提交打印版的论文时,
彩色的链接文字在黑白打印出来之后可能颜色会很浅;
北大图书馆也要求提交的电子版论文目录使用黑色字体。
此时用户\myemph{%
可以启用 pkuthss-extra 宏包的 \texttt{nocolorlinks} 选项,
使所有的链接变为黑色,以免影响打印或提交%
}
\begin{Verbatim}[frame = single]
\documentclass[..., nocolorlinks]{pkuthss} % “...”代表其它的选项。
\end{Verbatim}
用户还可以进一步修改 \verb|img/| 目录中 %
\verb|pkulogo.eps| 和 \verb|pkuword.eps| 两个图片文件,
以使封面上的北京大学图样也变为黑色(详见相应文件中的注释)。
\section{pkuthss 文档模版提供的命令和环境}
\subsection{设定文档信息的命令}
这一类命令的语法为
\begin{Verbatim}[frame = single]
\commandname{具体信息} % commandname 为具体命令的名称。
\end{Verbatim}
这些命令总结如下:
\begin{itemize}
\item \texttt{\bfseries\string\ctitle}:设定论文中文标题;
\item \texttt{\bfseries\string\etitle}:设定论文英文标题;
\item \texttt{\bfseries\string\cauthor}:设定作者的中文名;
\item \texttt{\bfseries\string\eauthor}:设定作者的英文名;
\item \texttt{\bfseries\string\studentid}:设定作者的学号;
\item \texttt{\bfseries\string\date}:设定日期;
\item \texttt{\bfseries\string\school}:设定作者的学院名;
\item \texttt{\bfseries\string\cmajor}:设定作者专业的中文名;
\item \texttt{\bfseries\string\emajor}:设定作者专业的英文名;
\item \texttt{\bfseries\string\direction}:设定作者的研究方向;
\item \texttt{\bfseries\string\cmentor}:设定导师的中文名;
\item \texttt{\bfseries\string\ementor}:设定导师的英文名;
\item \texttt{\bfseries\string\ckeywords}:设定中文关键词;
\item \texttt{\bfseries\string\ekeywords}:设定英文关键词。
\end{itemize}
例如如果要设定专业为“化学”“Chemistry”则可以使用以下命令
\begin{Verbatim}[frame = single]
\cmajor{化学}
\emajor{Chemistry}
\end{Verbatim}
\subsection{自身存储文档信息的命令}
这一类命令的语法为
\begin{Verbatim}[frame = single]
% commandname 为具体的命令名。
\renewcommand{\commandname}{具体信息}
\end{Verbatim}
这些命令总结如下:
\begin{itemize}
\item \texttt{\bfseries\string\cuniversity}:大学的中文名。
\item \texttt{\bfseries\string\euniversity}:大学的英文名。
\item \texttt{\bfseries\string\cthesisname}:论文类别的中文名。
\item \texttt{\bfseries\string\ethesisname}:论文类别的英文名。
\item \texttt{\bfseries\string\cabstractname}:摘要的中文标题。
\item \texttt{\bfseries\string\eabstractname}:摘要的英文标题。
\end{itemize}
例如,
如果要设定论文的类别为“本科生毕业论文”“Undergraduate Thesis”
则可以使用以下命令:
\begin{Verbatim}[frame = single]
\renewcommand{\cthesisname}{本科生毕业论文}
\renewcommand{\ethesisname}{Undergraduate Thesis}
\end{Verbatim}
\subsection{以“key = value”格式设置文档信息}
用户可以通过 \verb|\pkuthssinfo| 命令集中设定文档信息,
其语法为:
\begin{Verbatim}[frame = single]
% key1、key2、value1、value2 等为具体文档信息的项目名和内容。
\pkuthssinfo{key1 = value1, key2 = value2, ...}
\end{Verbatim}
其中文档信息的项目名为前面提到的设定文档信息的命令名%
或自身存储文档信息的命令名(不带反斜杠)。
当文档信息的内容包含了逗号等有干扰的字符时,
可以用大括号将这一项文档信息的全部内容括起来。%
\myemph{%
我们推荐用户总用大括号将文档信息的内容括起来,
以避免很多不必要的麻烦。%
}
例如,前面提到的文档信息的设置可以集中地写成:
\begin{Verbatim}[frame = single, tabsize = 4]
\pkuthssinfo{
..., % “...”代表其它的设定。
cthesisname = {本科生毕业论文},
ethesisname = {Undergraduate Thesis},
cmajor = {化学}, emajor = {Chemistry}
}
\end{Verbatim}
\subsection{pkuthss 文档模版提供的其它命令和环境}\label{ssec:misc}
\texttt{\bfseries cabstract}\texttt{\bfseries eabstract} %
环境用于编写中英文摘要。
用户只需要写摘要的正文;标题、作者、导师、专业等部分会自动生成。
\texttt{\bfseries\string\specialchap} 命令%
用于开始不进行标号但计入目录的一章,
并合理安排其页眉。%
\myemph{%
注意:
需要启用 pkuthss-extra 宏包的 \texttt{spechap} 选项%
才能使用此命令。
另外,在此章内的节或小节等命令应使用带星号的版本,
例如 \texttt{\string\section\string*} 等,
以免造成章节编号混乱。%
}%
例如,本文档中的“绪言”一章就是用 \verb|\specialchap{绪言}| %
这条命令开始的。%
\texttt{\bfseries\string\setpdfproperties} 命令%
用于根据用户设定的文档信息自动设定生成的 pdf 文档的属性。
此命令会在用户调用 \verb|\maketitle| 命令时被自动调用,
因此通常不需要用户自己使用;
但用户有时可能不需要输出标题页,
从而不会调用 \verb|\maketitle| 命令,
此时就需要在设定完文档信息之后调用 \verb|\setpdfproperties|。
\myemph{%
注意:
需要启用 pkuthss-extra 宏包的 \texttt{pdfprop} 选项%
才能使用此命令。%
}
\subsection{从其它文档类和宏包继承的功能}\label{ssec:thirdparty}
pkuthss 文档类建立在 ctexbook\supercite{ctex} 文档类的基础上,
并调用了 CJKfntef、%
graphicx\supercite{graphicx}、geometry\supercite{geometry}%
fancyhdr\supercite{fancyhdr} 等几个宏包。
因此ctexbook 文档类和这些宏包所提供的功能均可以使用。
例如,用户如果想将目录的标题改为“目{\quad\quad}录”,
则可以使用 ctexbook 文档类提供的 \verb|\CTEXoptions| 命令:
\begin{Verbatim}[frame = single]
\CTEXoptions[contentsname = {目{\quad\quad}录}]
\end{Verbatim}
在默认的配置下,%
pkuthss 文档模版使用作者编写的 %
biblatex\supercite{biblatex} 样式\supercite{biblatex-caspervector}%
进行参考文献和引用的排版,
用户可以使用它以及 biblatex 本身所提供的功能。
例如,
用户可以分别使用 \verb|\cite|、\verb|\parencite| 和 \verb|\supercite| %
生成未格式化的、带方括号的和上标且带方括号的引用标记:
\begin{Verbatim}[frame = single]
\cite{ctex}\parencite{ctex}\supercite{ctex}
\end{Verbatim}
在本文中将产生“\cite{ctex}\parencite{ctex}\supercite{ctex}”。
通过更复杂的设置,还可以满足例如被引用的文献按照引用顺序排序,
而未引用的文献按照英文文献在前、中文文献在后排序这样的需求,
详见 biblatex-caspervector 的文档\supercite{biblatex-caspervector}
pkuthss-extra 宏包可能调用以下这些宏包:
\begin{itemize}
\item 启用 \verb|spacing| 选项时会调用 %
setspace 和 footmisc\supercite{footmisc} 宏包。
\item 启用 \verb|tightlist| 选项时会调用 %
enumitem\supercite{enumitem} 宏包。
\item 启用 \verb|caption| 选项时会调用 %
caption\supercite{caption} 宏包。
\end{itemize}
因此在启用相应选项时,用户可以使用对应宏包所提供的功能。
\subsection{不建议更改的设置}
\myemph{%
pkuthss 文档类中有一些一旦改动就有可能破坏预设排版规划的设置,
因此不建议更改这些设置,它们是:
\begin{itemize}
\item 纸张类型A4
\item 页芯尺寸:%
$240\,\mathrm{mm}\times150\,\mathrm{mm}$
包含页眉、页脚;
\item 默认字号:小四号。
\end{itemize}%
}
\section{高级设置}\label{sec:advanced}
pkuthss 文档模版的实现是简洁、清晰、灵活的。
当一些细节的自定义无法通过模版提供的外部接口实现时,
我们鼓励用户(在适当理解相关部分代码的前提下)通过修改模版进行自定义。
一个常见的需求是封面中部分内容(特别是论文的标题、专业和研究方向)太长,
超出了在预设的空间。
此时,
用户可以修改 \verb|pkuthss.cls| 里 \verb|\maketitle| 定义中
\verb|\pkuthss@int@fillinblank| 宏的参数来改变
带下划线的空白的行数和行宽,其语法为:
\begin{Verbatim}[frame = single]
\pkuthss@int@fillinblank{行数}{行宽}{内容}
\end{Verbatim}
例如,如果“研究方向”一栏需要两行的空白,
可以将 \verb|pkuthss.cls| 里的
\begin{Verbatim}[frame = single]
\pkuthss@int@fillinblank{1}{\pkuthss@tmp@len}{\kaishu\@direction}
\end{Verbatim}
改为
\begin{Verbatim}[frame = single]
\pkuthss@int@fillinblank{2}{\pkuthss@tmp@len}{\kaishu\@direction}
\end{Verbatim}
当然,为了美观,可以将多于一行的部分移到封面中作者信息部分的最下方。

143
doc/readme/chap/chap3.tex Normal file
View File

@ -0,0 +1,143 @@
% vim:ts=4:sw=4
%
% Copyright (c) 2008-2009 solvethis
% Copyright (c) 2010-2013 Casper Ti. Vector
% Public domain.
\chapter{问题及其解决}
\section{文档中已经提到的常见问题(按重要性排序)}
北大图书馆要求上传的论文中目录采用黑色字体;
在默认设置(启用 \verb|colorlinks| 选项)下,
黑白打印时文档中的部分彩色链接可能会变成浅灰色,
解决方式见第 \ref{ssec:extra} 小节。
中文字体字库不全(只包含 GB2312 字符集内字符)时,
生成的 pdf 文档中可能缺少部分字符,
解决方式见第 \ref{sec:req} 节。
Windows 批处理对于 LF\texttt{\string\n})换行的批处理文件支持有问题,
解决方式见第 \ref{sec:compile} 节。
\verb|img/| 目录中 eps 图片未转换为 pdf 格式时,%
pdf\LaTeX{} 方式编译可能出错,
解决方式见第 \ref{sec:doc-dir} 节。
Windows 的“记事本”程序在查看 LF\texttt{\string\n}
换行的文本文件时存在着一些问题,
因此建议用户使用支持 LF 换行的文本编辑器编辑文件,
详见第 \ref{sec:doc-dir} 节。
使用过旧的 \TeX{} 系统和各宏包,
或使用某些 Linux 发行版软件仓库所提供的 \TeX{}Live 时,
可能引起一些问题,
详见第 \ref{sec:req} 节。
文档默认情况下是双面模式,章末可能产生空白页,详见第 \ref{ssec:options} 小节。
通过一些设置,还可以满足例如被引用的文献按照引用顺序排序,
而未引用的文献按照英文文献在前、中文文献在后排序这样的需求,
见第 \ref{ssec:thirdparty} 小节。
无法使用 biber 的用户可以使用 bibtex具体设置方式请见第 \ref{sec:compile} 节。
一些高级设置,
如封面中部分内容长度超过预设空间容量时的设置,
见第 \ref{sec:advanced} 节。
\section{其它可能存在的问题}
\subsection{上游宏包可能引起的问题}
biblatex 宏包\supercite{biblatex}会自行设定 \verb|\bibname|
故会覆盖通过 \verb|\CTEXoptions| 设定的参考文献列表标题。
使用 biblatex 的用户可以使用 \verb|\printbibliography| 的
\verb|title| 选项来手动设定参考文献列表的标题,例如:
\begin{Verbatim}[frame = single]
\printbibliography[title = {文献}, ...] % “...”为其它选项。
\end{Verbatim}
hyperref 宏包\supercite{hyperref}和一些宏包可能发生冲突。
关于如何避免这些冲突,
可以参考 hyperref 宏包的 README 文件中的“Package Compatibility”一节。
此文件通常和执行 \verb|texdoc hyperref| %
时打开的 pdf 文件位于同一目录中。
使用 Xe\LaTeX{} 的用户可能在已经安装字体的情况下遇到形如(其中
\verb|xxxxxxxx| 为具体字体名)
\begin{Verbatim}[frame = single, fontsize = {\small}]
! fontspec error: "font-not-found"
! The font "xxxxxxxx" cannot be found.
! See the fontspec documentation for further information.
! For immediate help type H <return>.
\end{Verbatim}
的错误。
这种错误一般是(主要是非 Windows 平台的)用户采用了自定义的(包括大小写
不同于原文件的)字体文件名,
并改动 ctex.cfg 等配置文件之后没有在调用 pkuthss 文档类时加入
\verb|nofonts| 选项,
又使用 Xe\LaTeX{} 编译造成的,使用
\begin{Verbatim}[frame = single]
\documentclass[nofonts, ...]{pkuthss} % “...”代表其它的选项。
\end{Verbatim}
即可解决此问题。
biber 运行时有一定概率出现形如(目录名可能稍有不同)
\begin{Verbatim}[frame = single, fontsize = {\small}]
data source .../par-xxxxxxxx/cache-xxxxxxxx/
inc/lib/Biber/LaTeX/recode_data.xml not found in .
\end{Verbatim}
的错误。
这种错误一般是 biber 在自解压阶段被终止之后,
未删除临时目录 \verb|.../par-xxxxxxxx/| 就重新运行 biber 时出现。
遇到这种情况时,删除掉上述临时目录及其所有内容,
再重新运行 biber 通常便可解决问题。
caption 宏包\supercite{caption}对于其不认识的宏包均会提示
\begin{Verbatim}[frame = single, fontsize = {\small}]
Package caption Warning: Unsupported document class (or package) detected,
(caption) usage of the caption package is not recommended.
See the caption package documentation for explanation.
\end{Verbatim}
pkuthss 文档模版基于 ctexbook 文档类,
而后者基于标准的 book 文档类。
因此,这个警告并不影响用户正常使用\footnote{%
\url{http://bbs.ctex.org/forum.php?mod=redirect&goto=findpost&ptid=63117&pid=402145}.%
}
\subsection{文档格式可能存在的问题}
研究生手册和其电子版\supercite{pku-thesisstyle}要求的论文封面可能并不一致,
这里以电子版为准。
\subsection{其它一些问题}
使用 GBK 编码和 pdf\LaTeX{} 编译方式时需要用户%
运行 \verb|gbk2uni| 程序来转换 \verb|.out| 文件,
否则生成的 pdf 书签可能乱码。
考虑到用户可能没有 \verb|gbk2uni| 程序,且有用户使用 UTF-8 编码,
默认的 \verb|Makefile| 和 \verb|Make.bat| 中将相关代码注释掉了,
用户可以自行去掉相应的注释。
\section{反馈意见和建议}
关于 pkuthss 文档模版的意见和建议,
请在北大未名 BBS 的 MathTools 版或 %
Google Code 上 pkuthss 项目的 issue tracker%
\footnote{\url{http://code.google.com/p/caspervector/issues/list}.}%
上提出,
或通过电子邮件\footnote%
{\href{mailto:CasperVector@gmail.com}{\texttt{CasperVector@gmail.com}}.}%
告知 Casper Ti. Vector。
上述三种反馈方法中,建议用户尽量采用靠前的方法。
在进行反馈时,请尽量确保已经仔细阅读本文档中的说明。
如果是通过 BBS 或电子邮件进行反馈,
请在标题中说明是关于 pkuthss 文档模版的反馈;
如果是通过 Google Code 进行反馈,
请给 issue 加上 \verb|Proj-Pkuthss| 标签。
如果是错误报告,
请说明所使用 pkuthss 模版的版本、
自己使用的操作系统和 \TeX{} 系统的类型和版本;
同时强烈建议附上一个出错的最小例子及其相应的编译日志(\verb|.log| 文件),
在文件较长时请使用附件。

View File

@ -0,0 +1,11 @@
% vim:ts=4:sw=4
%
% Copyright (c) 2008-2009 solvethis
% Copyright (c) 2010-2012 Casper Ti. Vector
% Public domain.
\specialchap{结论}
pkuthss 文档模版结构较为简洁、清晰、灵活,较为易于学习和使用。
希望它能为各位需要使用 \LaTeX{} 撰写学位论文的同学提供一些帮助。

View File

@ -0,0 +1,67 @@
% vim:ts=4:sw=4
%
% Copyright (c) 2008-2009 solvethis
% Copyright (c) 2010-2013 Casper Ti. Vector
% All rights reserved.
%
% Redistribution and use in source and binary forms, with or without
% modification, are permitted provided that the following conditions are
% met:
%
% * Redistributions of source code must retain the above copyright notice,
% this list of conditions and the following disclaimer.
% * Redistributions in binary form must reproduce the above copyright
% notice, this list of conditions and the following disclaimer in the
% documentation and/or other materials provided with the distribution.
% * Neither the name of Peking University nor the names of its contributors
% may be used to endorse or promote products derived from this software
% without specific prior written permission.
%
% THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
% IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
% THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
% PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
% CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
% EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
% PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
% PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
% LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
% NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
% SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\chapter*{版权声明}
{
\zihao{3}\linespread{1.5}\selectfont
\iffalse
任何收存和保管本论文各种版本的单位和个人,
未经本论文作者同意,不得将本论文转借他人,
亦不得随意复制、抄录、拍照或以任何方式传播。
否则一旦引起有碍作者著作权之问题,将可能承担法律责任。
\par
% 若需排版二维码请将二维码图片重命名为“barcode”
% 转为合适的图片格式,并放在 img/ 目录中,然后去掉下面 3 行的注释。
%\vfill\noindent
%\includegraphics[height = 5em]{img/barcode}
%\par
\fi
版权所有 \copyright\ 2008--2009 solvethis
\par
版权所有 \copyright\ 2010--2013 Casper Ti. Vector
\vskip 1em
pkuthss 文档类和 pkuthss-extra 宏包以 %
\LaTeX{} Project Public License 发布。
本说明(示例)文档的源代码中,除以下文件
\begin{itemize}
\item \verb|img/pkulogo.eps|
\item \verb|img/pkuword.eps|
\item \verb|chap/copyright.tex|
\item \verb|chap/originauth.tex|
\end{itemize}
以 New BSD License 发布,
以及参考文献和引用使用的样式文件版权声明见相应文件中说明以外,
其余部分文件发布在公有领域public domain
\par
}

48
doc/readme/chap/encl1.tex Normal file
View File

@ -0,0 +1,48 @@
% vim:ts=4:sw=4
%
% Copyright (c) 2008-2009 solvethis
% Copyright (c) 2010-2012 Casper Ti. Vector
% Public domain.
\chapter{pkuthss 文档模版的实现}
\raggedbottom % 避免某些奇怪的“Underfull \vbox”警告。
\section{pkuthss 文档类和 pkuthss-extra 宏包的实现}
\subsection{共用文件头部}
\VerbatimInput[
frame = lines, fontsize = {\footnotesize}, tabsize = 2,
baselinestretch = 1, lastline = 23, numbers = left
]{pkuthss.cls}
\subsection{\texttt{pkuthss.cls}}
\VerbatimInput[
frame = lines, fontsize = {\footnotesize}, tabsize = 2,
baselinestretch = 1, firstline = 25, numbers = left
]{pkuthss.cls}
\subsection{\texttt{pkuthss-utf8.def}\texttt{pkuthss-gbk.def}}
\VerbatimInput[
frame = lines, fontsize = {\footnotesize}, tabsize = 2,
baselinestretch = 1, firstline = 25, numbers = left
]{pkuthss-utf8.def}
\subsection{\texttt{pkuthss-extra.sty}}
\VerbatimInput[
frame = lines, fontsize = {\footnotesize}, tabsize = 2,
baselinestretch = 1, firstline = 25, numbers = left
]{pkuthss-extra.sty}
\section{pkuthss 说明(示例)文档的源代码}
本文档的源代码中大部分已经有了较为详细的注释,
故请直接参照相应文件中的注释。
\myemph{%
注:%
\texttt{img/} 目录中的 \texttt{Makefile}%
两个 PostScript\texttt{.eps})文件(都是文本文件)中%
也有详细的注释哦 :)%
}
\flushbottom % 取消 \raggedbottom 的作用。

21
doc/readme/chap/encl2.tex Normal file
View File

@ -0,0 +1,21 @@
% vim:ts=4:sw=4
%
% Copyright (c) 2008-2009 solvethis
% Copyright (c) 2010-2012 Casper Ti. Vector
% Public domain.
\chapter{更新记录}
\raggedbottom % 避免某些奇怪的“Underfull \vbox”警告。
\section{1.3 版以后的更新记录}
\VerbatimInput[
tabsize = 4, fontsize = {\small}, baselinestretch = 1
]{ChangeLog.txt}
\section{1.3 及其以前版本的更新记录}
\VerbatimInput[
tabsize = 4, fontsize = {\small}, baselinestretch = 1.1
]{ChangeLog-upto-1.3.txt}
\flushbottom % 取消 \raggedbottom 的作用。

View File

@ -0,0 +1,46 @@
% vim:ts=4:sw=4
%
% Copyright (c) 2008-2009 solvethis
% Copyright (c) 2010-2012 Casper Ti. Vector
% Public domain.
\specialchap{绪言}
本文档是“北京大学论文文档模版”的说明文档,
同时也是使用模版的一个示例。
pkuthss 文档模版由三部分构成:
\begin{itemize}
\item \textbf{pkuthss 文档类}
其中进行了学位论文所需要的一些基本的设定,
主要包括对基本排版格式的设定和提供设置论文信息的命令。
\item \textbf{pkuthss-extra 宏包}
其中实现了学位论文中用户可能较多用到的一些额外功能,
例如自动在目录中加入参考文献和索引的条目和%
自动根据用户设定的文档信息对所生成 pdf 的作者、标题等属性进行设置等。
\item \textbf{说明(示例)文档}
说明文档即本文档,
在安装(见第 \ref{sec:inst} 节)之后应该可以用 \TeX{} 系统提供的
\verb|texdoc| 命令调出:
\begin{Verbatim}[frame=single]
texdoc pkuthss
\end{Verbatim}
同时,
本文档的源代码(位和本文档的 pdf 文件处于同一目录下)%
也正是用户撰写自己的学位论文时的一个模版:
用户只需按照模版中的框架修改代码,
即可写出自己的论文。
\end{itemize}
在此之前,包括 dypang\supercite{dypang}、FerretL\supercite{FerretL}%
lwolf\supercite{lwolf}、Langpku\supercite{Langpku}%
solvethis\supercite{solvethis} 等的数位网友均做过学位论文模版的工作。
本论文模版是 solvethis 的 pkuthss 模版的更新版本,
更新的重点是重构和对新文档类、宏包的支持。
pkuthss 文档模版现在的维护者是 Casper Ti. Vector\footnote%
{\href{mailto:CasperVector@gmail.com}{\texttt{CasperVector@gmail.com}}}%
pkuthss 文档模版目前托管在 Google Code 上,
其项目主页是:\\
\hspace*{\parindent}\url{http://code.google.com/p/caspervector/}

View File

@ -0,0 +1,88 @@
% vim:ts=4:sw=4
%
% Copyright (c) 2008-2009 solvethis
% Copyright (c) 2010-2013 Casper Ti. Vector
% All rights reserved.
%
% Redistribution and use in source and binary forms, with or without
% modification, are permitted provided that the following conditions are
% met:
%
% * Redistributions of source code must retain the above copyright notice,
% this list of conditions and the following disclaimer.
% * Redistributions in binary form must reproduce the above copyright
% notice, this list of conditions and the following disclaimer in the
% documentation and/or other materials provided with the distribution.
% * Neither the name of Peking University nor the names of its contributors
% may be used to endorse or promote products derived from this software
% without specific prior written permission.
%
% THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
% IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
% THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
% PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
% CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
% EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
% PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
% PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
% LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
% NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
% SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
% 原创性声明和使用授权说明页不需要装订到论文中,故不显示页码。
\cleardoublepage\thispagestyle{empty}
\newgeometry{height = 240mm, width = 150mm, ignoreheadfoot, vcentering}
{
\vspace*{\fill}\linespread{1.5}\selectfont
\centerline{\bfseries\Large 北京大学学位论文原创性声明和使用授权说明}
\vskip 4em
\centerline{\bfseries\Large 原创性声明}
\vskip 1em
本人郑重声明:
所呈交的学位论文,是本人在导师的指导下,独立进行研究工作所取得的成果。
除文中已经注明引用的内容外,
本论文不含任何其他个人或集体已经发表或撰写过的作品或成果。
对本文的研究做出重要贡献的个人和集体,均已在文中以明确方式标明。
本声明的法律结果由本人承担。
\vskip 1em
\rightline
{%
论文作者签名:\hspace{5em}%
日期:\hspace{2em}\hspace{2em}\hspace{2em}%
}
\vskip 4em
\centerline{\bfseries\Large 学位论文使用授权说明}
\centerline{\zihao{-4}(必须装订在提交学校图书馆的印刷本)}
\vskip 1em
本人完全了解北京大学关于收集、保存、使用学位论文的规定,即:
\begin{itemize}
\item 按照学校要求提交学位论文的印刷本和电子版本;
\item 学校有权保存学位论文的印刷本和电子版,
并提供目录检索与阅览服务,在校园网上提供服务;
\item 学校可以采用影印、缩印、数字化或其它复制手段保存论文;
\item 因某种特殊原因需要延迟发布学位论文电子版,
授权学校在 $\square$\nobreakspace{}一年 / %
$\square$\nobreakspace{}两年 / %
$\square$\nobreakspace{}三年以后在校园网上全文发布。
\end{itemize}
\par(保密论文在解密后遵守此规定)
\vskip 1em
\rightline
{%
论文作者签名:\hspace{5em}导师签名:\hspace{5em}%
日期:\hspace{2em}\hspace{2em}\hspace{2em}%
}
% 若需排版二维码请将二维码图片重命名为“barcode”
% 转为合适的图片格式,并放在 img/ 目录中,然后去掉下面 2 行的注释。
%\vskip 4em \noindent
%\includegraphics[height = 5em]{img/barcode}
\vspace*{\fill}\par
}
\restoregeometry

31
doc/readme/img/Make.bat Normal file
View File

@ -0,0 +1,31 @@
@echo off
@rem vim:ts=4:sw=4
@rem
@rem Copyright (c) 2008-2009 solvethis
@rem Copyright (c) 2010-2012 Casper Ti. Vector
@rem Public domain.
set GS=gswin32c
set GSOPTS=-q -dSAFER -dNOPAUSE -dBATCH -sDEVICE=pdfwrite
set WIDTHOPT=-dDEVICEWIDTHPOINTS=
set HEIGHTOPT=-dDEVICEHEIGHTPOINTS=
set OUTPUTOPT=-sOutputFile=
if "%1"=="" goto pdf
if "%1"=="clean" (goto clean) else (goto usage)
:pdf
%GS% %GSOPTS% %WIDTHOPT%400 %HEIGHTOPT%400 %OUTPUTOPT%pkulogo.pdf -f pkulogo.eps
%GS% %GSOPTS% %WIDTHOPT%525 %HEIGHTOPT%150 %OUTPUTOPT%pkuword.pdf -f pkuword.eps
goto end
:clean
del pkulogo.pdf pkuword.pdf
goto end
:usage
echo %0 [pdf] [clean]
:end

37
doc/readme/img/Makefile Normal file
View File

@ -0,0 +1,37 @@
# vim:ts=4:sw=4
#
# Copyright (c) 2008-2009 solvethis
# Copyright (c) 2010-2012 Casper Ti. Vector
# Public domain.
# 直接使用 pkulogo.eps 作为论文封面图片也是可行的,
# 因为它使用的 Times-Bold 字体一般操作系统都有。
# 这样用 LaTeX + dvipdfm 或 XeLaTeX 方式是可以编译成功的。
# 可以使用 ghostscript 将 eps 文件转换为 和 pdf 格式,
# 则 pdfLaTeX 方式也可以编译成功。
OPTS = -q -dSAFER -dNOPAUSE -dBATCH -sDEVICE=pdfwrite
WIDTHOPT = -dDEVICEWIDTHPOINTS=
HEIGHTOPT = -dDEVICEHEIGHTPOINTS=
OUTPUTOPT = -sOutputFile=
# 区分是 Windows 环境还是类 UNIX 环境。
ifdef PATH
GS = gs
RM = rm -f
else
GS = gswin32c
RM = del
endif
all: pkulogo.pdf pkuword.pdf
pkulogo.pdf: pkulogo.eps
$(GS) $(OPTS) $(WIDTHOPT)400 $(HEIGHTOPT)400 $(OUTPUTOPT)$@ -f $<
pkuword.pdf: pkuword.eps
$(GS) $(OPTS) $(WIDTHOPT)525 $(HEIGHTOPT)150 $(OUTPUTOPT)$@ -f $<
clean:
$(RM) pkulogo.pdf pkuword.pdf

146
doc/readme/img/pkulogo.eps Normal file
View File

@ -0,0 +1,146 @@
%!PS
%%BoundingBox: 0 0 400 400
%%Pages: 1
%%Page: 1 1
% Copyright (c) 2008-2009 solvethis
% Copyright (c) 2010-2012 Casper Ti. Vector
% All rights reserved.
%
% Redistribution and use in source and binary forms, with or without
% modification, are permitted provided that the following conditions are
% met:
%
% * Redistributions of source code must retain the above copyright notice,
% this list of conditions and the following disclaimer.
% * Redistributions in binary form must reproduce the above copyright
% notice, this list of conditions and the following disclaimer in the
% documentation and/or other materials provided with the distribution.
% * Neither the name of Peking University nor the names of its contributors
% may be used to endorse or promote products derived from this software
% without specific prior written permission.
%
% THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
% IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
% THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
% PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
% CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
% EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
% PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
% PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
% LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
% NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
% SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
% 设置北大红的色值http://web5.pku.edu.cn/bs/cjwt/,问题 5
% 要想将颜色改为黑色只需将下面一行改为“0 setgray
0.0 1.0 1.0 0.45 setcmykcolor
% 线
1 setlinecap
1 setlinejoin
%
200 200 translate
%
newpath
6 setlinewidth
0 0 195 0 360 arc
stroke
%
newpath
5 setlinewidth
0 0 143 0 360 arc
stroke
%
newpath
0 setlinewidth
-10 101 moveto
-10 101 -10 38 lineto
-10 35 -14 29 -19 28 curveto
-30 28 -60 15 -89 -26 curveto
-104 -39 -108 -24 -105 -16 curveto
-76 27 -36 45 -32 45 curveto
-30 46 -29 47 -29 49 curveto
-29 49 -29 68 lineto
-29 69 -30 69 -31 69 curveto
-38 67 -58 63 -83 42 curveto
-95 35 -103 49 -94 57 curveto
-72 74 -53 83 -31 88 curveto
-30 88 -29 89 -29 90 curveto
-29 90 -29 102 lineto
-29 111 -10 111 -10 101 curveto
10 101 moveto
10 101 10 38 lineto
10 35 14 29 19 28 curveto
30 28 60 15 89 -26 curveto
104 -39 108 -24 105 -16 curveto
76 27 36 45 32 45 curveto
30 46 29 47 29 49 curveto
29 49 29 68 lineto
29 69 30 69 31 69 curveto
38 67 58 63 83 42 curveto
95 35 103 49 94 57 curveto
72 74 53 83 31 88 curveto
30 88 29 89 29 90 curveto
29 90 29 102 lineto
29 111 10 111 10 101 curveto
-11 5 moveto
-11 4 -11 4 -12 4 curveto
-33 2 -65 -25 -80 -58 curveto
-82 -71 -70 -74 -63 -64 curveto
-45 -32 -27 -17 -12 -15 curveto
-11 -15 -11 -15 -11 -16 curveto
-11 -16 -11 -35 lineto
-11 -38 -11 -38 -13 -40 curveto
-28 -48 -34 -57 -45 -85 curveto
-48 -97 -32 -103 -28 -94 curveto
-15 -44 15 -44 28 -94 curveto
32 -103 48 -97 45 -85 curveto
34 -57 28 -48 13 -40 curveto
11 -38 11 -38 11 -35 curveto
11 -35 11 -16 lineto
11 -15 11 -15 12 -15 curveto
27 -17 45 -32 63 -64 curveto
70 -74 82 -71 80 -58 curveto
65 -25 33 2 12 4 curveto
11 4 11 4 11 5 curveto
11 5 11 12 lineto
11 25 -11 25 -11 12 curveto
-11 12 -11 5 lineto
133 0 moveto
0 0 133 0 360 arc
% 线使
% 使
eofill
% 添加文字“PEKING UNIVERSITY 1898
/Times-Bold findfont 40 scalefont setfont
/offset { dup stringwidth pop 2 div neg 155 moveto show } def
gsave 112 rotate (P) offset grestore
gsave 98 rotate (E) offset grestore
gsave 84 rotate (K) offset grestore
gsave 70 rotate (I) offset grestore
gsave 56 rotate (N) offset grestore
gsave 41 rotate (G) offset grestore
gsave 15 rotate (U) offset grestore
gsave (N) offset grestore
gsave -14 rotate (I) offset grestore
gsave -28 rotate (V) offset grestore
gsave -42 rotate (E) offset grestore
gsave -56 rotate (R) offset grestore
gsave -70 rotate (S) offset grestore
gsave -84 rotate (I) offset grestore
gsave -98 rotate (T) offset grestore
gsave -112 rotate (Y) offset grestore
/onset { dup stringwidth pop 2 div neg -182 moveto show } def
gsave -24 rotate (1) onset grestore
gsave -8 rotate (8) onset grestore
gsave 8 rotate (9) onset grestore
gsave 24 rotate (8) onset grestore
showpage
%%EOF

273
doc/readme/img/pkuword.eps Normal file
View File

@ -0,0 +1,273 @@
%!PS
%%BoundingBox: 0 0 525 150
%%Pages: 1
%%Page: 1 1
% Copyright (c) 2008-2009 solvethis
% Copyright (c) 2010-2012 Casper Ti. Vector
% All rights reserved.
%
% Redistribution and use in source and binary forms, with or without
% modification, are permitted provided that the following conditions are
% met:
%
% * Redistributions of source code must retain the above copyright notice,
% this list of conditions and the following disclaimer.
% * Redistributions in binary form must reproduce the above copyright
% notice, this list of conditions and the following disclaimer in the
% documentation and/or other materials provided with the distribution.
% * Neither the name of Peking University nor the names of its contributors
% may be used to endorse or promote products derived from this software
% without specific prior written permission.
%
% THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
% IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
% THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
% PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
% CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
% EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
% PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
% PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
% LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
% NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
% SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
% 设置北大红的色值http://web5.pku.edu.cn/bs/cjwt/,问题 5
% 要想将颜色改为黑色只需将下面一行改为“0 setgray
0.0 1.0 1.0 0.45 setcmykcolor
%
0.702957 0.602957 scale
-30 -9 translate
%
newpath
74 224 moveto
85.9 214.1 110.4 207.3 105 187 curveto
106 176.3 111.5 166.3 108 155 curveto
112.3 125.8 104.7 99 103 71 curveto
100.3 59.5 96.9 47.3 91 38 curveto
81.8 36 87.7 47.3 86 52 curveto
88.3 56.7 86.2 62 84 66 curveto
83 66 82 66 81 66 curveto
70.7 51.3 53.5 42.7 41 31 curveto
37.6 31.1 33.9 30.3 32 34 curveto
32.6 40.3 30.8 46.8 32 52 curveto
30.2 54 31.3 57.3 31 60 curveto
43.6 65.3 42.7 79.6 47 90 curveto
59 103.5 50 123.3 47 138 curveto
54.7 135.5 63.5 135.7 69 128 curveto
74.1 126.1 81.7 125.9 83 119 curveto
84.9 118.4 85.8 119.9 87 121 curveto
87 133.3 87 145.7 87 158 curveto
86.2 176.4 91.3 203.1 71 215 curveto
67.6 220.4 61.6 223.4 64 230 curveto
68.7 231.2 70.2 224.9 74 224 curveto
85 102 moveto
87.3 94.7 85.2 86.7 83 80 curveto
73.4 67.6 58.4 63.9 46 56 curveto
42.7 55.1 40.4 57.1 40 60 curveto
46 74 57.7 85.7 63 100 curveto
65.7 103 69.7 102.6 73 104 curveto
78.5 106.2 80.1 113.5 85 115 curveto
88 110.7 83.5 107 85 102 curveto
eofill
newpath
176 176 moveto
184.2 165.9 175.8 148 187 140 curveto
192.6 149.1 209.4 149.9 205 164 curveto
206 165.1 202.5 172.3 208 171 curveto
206.9 159.6 220 161 226 156 curveto
231.2 157.2 228.8 148.7 228 146 curveto
223.7 140 223 131.6 215 128 curveto
205 124.2 195.7 127.8 187 121 curveto
187 115 187 109 187 103 curveto
181.5 99.2 175.8 93.7 175 87 curveto
188.7 76.3 201.5 91.8 216 91 curveto
221.9 93 226.5 97.9 234 96 curveto
235.1 91.6 232.3 91.4 231 88 curveto
230 76.1 218.3 77.6 211 72 curveto
200.8 70.8 188.8 71.6 183 62 curveto
175.5 63.2 167.5 63 162 69 curveto
150.9 87.6 151.2 111 146 132 curveto
141.1 158 154 179.1 157 203 curveto
161.7 194.2 176.5 188.7 176 176 curveto
closepath
fill
%
newpath
351 221 moveto
349.4 215.9 349.3 209.3 343 207 curveto
332.9 217.2 312.8 180.1 322 206 curveto
322.3 218.3 314.3 227.2 311 238 curveto
309.3 244.7 315.9 244.8 320 243 curveto
329.3 239.7 338.7 234.2 346 228 curveto
346.6 225.2 350.4 223.8 351 221 curveto
closepath
fill
newpath
361 183 moveto
352.3 176.8 341.6 170.9 333 162 curveto
329.4 152.3 319 150.7 312 145 curveto
300.2 142.3 291.2 148.7 284 155 curveto
282.8 159.1 287.7 161.1 290 163 curveto
303.2 171.4 320.3 170.3 333 180 curveto
341.8 183.3 351 185.6 361 186 curveto
361 185 361 184 361 183 curveto
closepath
fill
newpath
357 135 moveto
361.8 126.8 349.9 127.4 347 122 curveto
341.4 114.9 332.9 110.9 329 104 curveto
327.3 101.3 322.5 100 324 96 curveto
326.1 92.8 330.4 96.3 333 98 curveto
337.3 100.7 341.7 97.3 346 97 curveto
343.8 86.8 332.7 85.7 326 80 curveto
322.5 79.3 318.3 77.9 317 74 curveto
312.2 64.9 322.3 60.7 321 52 curveto
323.8 41 328.2 28 325 17 curveto
317.4 16.8 319.5 25.8 314 29 curveto
311.8 32.7 304.6 30.9 306 37 curveto
309.5 37.7 313.7 39.1 315 43 curveto
314.3 48.7 316.7 55.6 313 60 curveto
311.1 60.3 309.6 59.5 308 59 curveto
293.5 46.9 284.8 31.5 271 20 curveto
264.2 18.7 260.4 24.7 259 30 curveto
257.8 32.6 258 35.9 258 39 curveto
276.8 39.2 288.7 56.3 304 65 curveto
307.5 64.9 309.3 69 312 71 curveto
313.3 74.6 309.9 76.3 309 79 curveto
308.3 85.9 319.3 93.8 311 98 curveto
306.6 97.1 300.6 97.6 299 92 curveto
304.1 80.4 294.9 72.3 289 64 curveto
287.6 63.3 287.4 65.7 286 65 curveto
277.5 80.5 281 99.7 283 117 curveto
287.1 115.7 290.3 112.3 294 110 curveto
309.9 114.8 321.3 130.8 337 136 curveto
343 134.2 351.6 135.3 357 135 curveto
closepath
fill
newpath
374 62 moveto
374 57.7 374 53.3 374 49 curveto
368.6 46.4 362.1 40.9 357 48 curveto
351.7 57.8 341.8 69.4 350 81 curveto
359.3 77.8 371.6 73.3 374 62 curveto
closepath
fill
%
newpath
501 224 moveto
507.6 216 519.8 213 519 202 curveto
510.5 194.5 518.5 184 516 174 curveto
513.8 166.3 516.2 156.7 514 149 curveto
514.3 146.1 517.5 145.7 520 146 curveto
537.1 151 538.8 182.5 560 171 curveto
557.7 161.3 549.5 155.7 542 149 curveto
533.4 140.8 521.6 133.8 514 123 curveto
512.2 101.2 508.4 78.4 488 66 curveto
476 57.9 463 52.2 449 49 curveto
447.3 51.2 438.3 44.3 442 51 curveto
450.7 56.3 458.9 62.7 468 67 curveto
482.2 77.4 486.1 93.8 491 109 curveto
484.7 113.3 478.3 105.7 472 104 curveto
456.1 97.9 445.1 86.2 430 78 curveto
424.8 75.9 419.1 72.1 413 75 curveto
406.8 81.8 408.2 93 408 101 curveto
411.9 101.9 410.9 97.2 414 96 curveto
436.6 97.6 452.7 115.2 474 120 curveto
480.7 125.8 491.4 124.2 496 133 curveto
500.2 163 498.3 195.4 486 221 curveto
487.2 223.7 488.1 229.2 493 227 curveto
495 224.5 497.7 223.5 501 224 curveto
closepath
fill
newpath
557 86 moveto
564 76.3 578.2 71.9 574 58 curveto
568.3 51.9 560.3 51.5 552 52 curveto
550.3 54.4 550.8 58.5 552 61 curveto
548.5 71.2 540.4 81.9 545 93 curveto
548.4 91.3 552.1 86.2 557 86 curveto
closepath
fill
%
newpath
640 130 moveto
639.8 124 641.2 115.7 635 114 curveto
628.1 111.5 630.1 119.8 626 122 curveto
625.8 131.8 626.8 139.7 624 148 curveto
634.8 146.6 632.8 135.8 640 130 curveto
closepath
fill
newpath
733 248 moveto
738 233.7 720.5 224.5 721 210 curveto
728.7 202 735.5 214.1 744 213 curveto
753.3 220.2 762.3 213.3 773 214 curveto
768.4 191.6 756.7 169.5 737 156 curveto
736.5 154.6 736.3 153.1 735 152 curveto
740.1 145.1 758.1 154.4 754 140 curveto
746.5 116.3 724.8 109.9 705 101 curveto
715.3 113.3 728.2 123.7 736 138 curveto
733 143.2 726.9 137.7 723 136 curveto
703.9 117.4 683.8 101.3 660 94 curveto
652.2 91.7 644 90.4 635 91 curveto
635.9 98.4 645.4 97.9 650 103 curveto
673.8 121.1 701.1 130.5 726 146 curveto
726.6 147.9 725.1 148.8 724 150 curveto
716.7 151.2 712 146 706 144 curveto
705.5 149.3 711 153.3 709 158 curveto
704 160 699.6 166.5 694 164 curveto
686.8 160.8 686.1 147.6 677 150 curveto
677.2 159.5 697.7 166.9 684 176 curveto
694.5 171.8 700.6 182.7 705 189 curveto
705.8 191.9 705.5 193 703 195 curveto
699.4 194.7 696.9 191.6 693 192 curveto
693.6 196.3 699.8 198.2 699 203 curveto
694.9 208.7 686.3 203.7 684 212 curveto
684.1 216.3 689.1 212.2 692 213 curveto
695.3 212 699.5 214.5 703 216 curveto
718.6 222.2 724.8 240.5 726 255 curveto
729.2 254.8 729.6 249.9 733 248 curveto
748 193 moveto
743.7 180.6 733.5 168.9 725 160 curveto
724.5 167.3 722.5 174 719 180 curveto
710.8 180.5 719.2 163.3 708 168 curveto
696.3 179.3 716.2 187.4 718 198 curveto
728 202.3 738 194.7 748 193 curveto
eofill
newpath
640 195 moveto
643.7 193 646.5 188.9 651 189 curveto
661.3 177.5 670.8 165.7 671 150 curveto
667.8 144.8 662.5 140.5 657 139 curveto
653.4 161.3 643.8 182 627 198 curveto
625.5 199.7 625.5 203.3 627 205 curveto
632.2 203.8 635.2 197.3 640 195 curveto
closepath
fill
newpath
732 82 moveto
727.7 76.8 729.2 66.5 720 66 curveto
713.6 65.1 703.7 68.2 702 60 curveto
702.4 47.8 712 38.2 707 25 curveto
704 12.5 688.9 12 678 10 curveto
675.5 16.8 666.3 14.1 663 19 curveto
675.2 21.9 691.3 19.6 697 34 curveto
692.9 41.6 697.4 53.6 690 59 curveto
670.3 53.8 653.1 42.5 636 31 curveto
631.1 29.7 626.4 25.1 621 28 curveto
620.2 35.6 610.3 39.5 614 49 curveto
617.7 54.2 624 53 629 55 curveto
654.8 67.1 680.6 79.3 709 85 curveto
711.4 88.3 717 87.2 720 86 curveto
723.4 86.2 729.3 86.3 732 82 curveto
closepath
fill
showpage
%%EOF

197
doc/readme/pkuthss.bib Normal file
View File

@ -0,0 +1,197 @@
vim:ts=4:sw=4
@online{biber,
author = {Kime, Philip and Charette, Fran\c{c}ois},
title = {Biber: A backend bibliography processor for biblatex (Version 0.9.9)},
type = {M/OL},
date = {2012-03-29},
url = {http://mirror.ctan.org/biblio/biber/},
urldate = {2012-08-01},
}
@online{biblatex,
author = {Lehman, Philipp},
title = {The biblatex Package: Programmable Bibliographies and Citations (Version 1.7)},
type = {M/OL},
date = {2011-11-13},
url = {http://mirror.ctan.org/macros/latex/exptl/biblatex/},
urldate = {2012-08-01},
}
@online{biblatex-caspervector,
author = {Vector, Casper Ti.},
title = {biblatex 参考文献和引用样式caspervector v0.1.9},
type = {M/OL},
date = {2013-12-27},
url = {https://caspervector.googlecode.com/files/biblatex-caspervector-0.1.9.zip},
urldate = {2013-12-27},
userf = {zh},
}
@online{caption,
author = {Sommerfeldt, Alex},
title = {Customizing captions of floating environments},
type = {M/OL},
date = {2011-11-02},
url = {http://mirror.ctan.org/macros/latex/contrib/caption},
urldate = {2013-06-03},
}
@online{ctex,
author = {{ctex.org}},
title = {ctex 宏包说明v1.02c},
type = {M/OL},
date = {2011-03-11},
url = {http://mirror.ctan.org/language/chinese/ctex/},
urldate = {2012-08-01},
userf = {zh},
}
@online{ctex-faq,
author = {吴凌云},
title = {\CTeX{} FAQ常见问题集0.4 beta (89) 版},
type = {M/OL},
date = {2007-01-30},
url = {http://mirror.ctan.org/info/ctex-faq/},
urldate = {2012-08-01},
userf = {zh},
}
@online{enumitem,
author = {Bezos, Javier},
title = {Customizing lists with the enumitem package (Version 3.5.2)},
type = {M/OL},
date = {2011-09-28},
url = {http://mirror.ctan.org/macros/latex/contrib/enumitem/},
urldate = {2012-08-01},
}
@online{fancyhdr,
author = {van Oostrum, Piet},
title = {Page layout in \LaTeX{}},
type = {M/OL},
date = {2004-03-02},
url = {http://mirror.ctan.org/macros/latex/contrib/fancyhdr/},
urldate = {2012-08-01},
}
@online{footmisc,
author = {Fairbairns, Robin},
title = {footmisc --- a portmanteau package for customising footnotes in \LaTeX{}},
type = {M/OL},
date = {2011-07-06},
url = {http://mirror.ctan.org/macros/latex/contrib/footmisc/},
urldate = {2012-08-01},
}
@online{geometry,
author = {Umeki, Hideo},
title = {The geometry package (v5.6)},
type = {M/OL},
date = {2010-09-12},
url = {http://mirror.ctan.org/macros/latex/contrib/geometry/},
urldate = {2012-08-01},
}
@online{graphicx,
author = {Carlisle, D. P.},
title = {Packages in the `graphics' bundle},
type = {M/OL},
date = {2005-11-14},
url = {http://mirror.ctan.org/macros/latex/required/graphics/},
urldate = {2012-08-01},
}
@online{hyperref,
author = {Rahtz, Sebastian and Oberdiek, Heiko},
title = {Hypertext marks in \LaTeX{}: a manual for hyperref (v6.82q)},
type = {M/OL},
date = {2012-05-13},
url = {http://mirror.ctan.org/macros/latex/contrib/hyperref/},
urldate = {2012-08-01},
}
@online{dypang,
author = {dypang},
title = {北京大学硕博论文模版(测试版)},
type = {EB/OL},
date = {2005-04-05},
url = {http://bdwm.net/a.php?b/Thesis/M.1112645491.A/D10F612.rar},
urldate = {2012-08-01},
userf = {zh},
}
@online{FerretL,
author = {FerretL},
title = {新的 pku 博士论文模板},
type = {EB/OL},
date = {2007-03-27},
url = {http://bdwm.net/a.php?b/Thesis/M.1174982168.A/4270722.rar},
urldate = {2012-08-01},
userf = {zh},
}
@online{lwolf,
author = {lwolf},
title = {学士(硕/博)毕业论文模板 [基于 dypang 的模板]},
type = {EB/OL},
date = {2007-05-15},
url = {http://bdwm.net/a.php?b/MathTools/M.1179239165.A/5A2D5A2.rar},
urldate = {2012-08-01},
userf = {zh},
}
@online{Langpku,
author = {Langpku},
title = {Re: 关于置底模版的问题和一些修改},
type = {EB/OL},
date = {2007-06-01},
url = {http://bdwm.net/a.php?b/MathTools/M.1180676700.A/DBB7810.zip},
urldate = {2012-08-01},
userf = {zh},
}
@online{solvethis,
author = {solvethis},
title = {Re: 学位论文模板更新},
type = {EB/OL},
date = {2008-03-13},
url = {http://bdwm.net/a.php?b/Thesis/M.1205377509.A/9413ED2.rar},
urldate = {2012-08-01},
userf = {zh},
}
@online{pku-copyright,
author = {北京大学研究生院},
title = {北京大学学位论文版权声明(首页)},
type = {M/OL},
year = {2010},
url = {http://grs.pku.edu.cn/document/20101110143928832634.doc},
urldate = {2012-08-01},
userf = {zh},
}
@online{pku-originauth,
author = {北京大学研究生院},
title = {北京大学学位论文原创性声明和使用授权说明(末页)},
type = {M/OL},
year = {2010},
url = {http://grs.pku.edu.cn/document/20101110143844053593.doc},
urldate = {2012-08-01},
userf = {zh},
}
@incollection{pku-thesisstyle,
author = {北京大学研究生院},
title = {北京大学研究生学位论文的基本要求与书写格式},
type = {M/OL},
bookauthor = {北京大学研究生院},
booktitle = {北京大学研究生手册},
publisher = {北京大学},
year = {2011},
pages = {27-31},
url = {http://grs.pku.edu.cn/document/20110829160841775796.doc},
urldate = {2012-08-01},
userf = {zh},
}

123
doc/readme/pkuthss.tex Normal file
View File

@ -0,0 +1,123 @@
% vim:ts=4:sw=4
%
% Copyright (c) 2008-2009 solvethis
% Copyright (c) 2010-2014 Casper Ti. Vector
% Public domain.
%
% 使用前请先仔细阅读 pkuthss 和 biblatex-caspervector 的文档,
% 特别是其中的 FAQ 部分和用红色强调的部分。
% 两者可在终端/命令提示符中用
% texdoc pkuthss
% texdoc biblatex-caspervector
% 调出。
% 在黑白打印时彩色链接可能变成浅灰色此时可将“colorlinks”改为“nocolorlinks”。
% 北大图书馆要求上传的电子版论文中目录采用黑色字体,可以用同样的方法处理。
%
% 采用了自定义的(包括大小写不同于原文件的)字体文件名,
% 并改动 ctex.cfg 等配置文件的用户请自行加入 nofonts 选项;
% 其它用户不用加入 nofonts 选项,加入之后反而会产生错误。
\documentclass[UTF8, colorlinks]{pkuthss}
% 使用 biblatex 排版参考文献,并规定其格式。
%
% 如果无法使用 biber可以把“backend = biber”改为“backend = bibtex”
% 并改用 bibtex 产生参考文献,详见 pkuthss 的文档。
% 使用 biber 时,请去掉所有的 sorting 选项,否则会出错。
%
% 默认按照引用顺序排序“sorting = none”详见 biblatex-caspervector 的文档
% (因为是默认设置所以其实不用写,不过出于完备性的考虑仍然在这里列出)。
% 若需要按照英文文献在前中文文献在后排序请设置“sorting = ecnty”
% 若需要按照中文文献在前英文文献在后排序请设置“sorting = centy”。
\usepackage[backend = biber, style = caspervector, utf8, sorting = none]{biblatex}
% 使得打字机粗体可以被使用。
\usepackage{lmodern}
% 产生 originauth.tex 里的 \square
\usepackage{amssymb}
% 提供 Verbatim 环境和 \VerbatimInput 命令。
\usepackage{fancyvrb}
% 使被强调的内容为红色。hyperref 宏包在设置了 colorlinks 时会引入 color 宏包,
% 后者定义了 \textcolor 命令,故不用单独引入宏包。
\newcommand{\myemph}[1]{\emph{\textcolor{red}{#1}}}
% pkuthss 文档模版的版本。
\newcommand{\docversion}{v1.4}
% 设定文档的基本信息。
\pkuthssinfo{
cthesisname = {本科生毕业论文}, ethesisname = {Undergraduate Thesis},
ctitle = {北京大学论文文档模版\\pkuthss \docversion},
%\\”在设定 pdf 属性时会被自动过滤掉,于是得到的 pdf 属性中标题为
% The PKU dissertation document classpkuthss [版本号]
% 此处指定其被替换为“: ”,以使之为
% The PKU dissertation document class: pkuthss [版本号]
etitle = {%
The PKU dissertation document class\texorpdfstring{\\}{: }%
pkuthss \docversion%
},
cauthor = {盖茨波 $\cdot$$\cdot$ 维克托},
eauthor = {Casper Ti.\ Vector},
studentid = {00910???},
date = {二〇一四年四月},
school = {化学与分子工程学院},
cmajor = {化学(?)}, emajor = {Chemistry ... ?},
direction = {据说 Casper 自己也不知道},
cmentor = {XX 教授}, ementor = {Prof.\ XX},
ckeywords = {\LaTeX2e{},排版,文档类,\CTeX{}},
ekeywords = {\LaTeX2e{}, typesetting, document class, \CTeX{}}
}
% 导入参考文献数据库(注意不要省略“.bib”
\addbibresource{pkuthss.bib}
\begin{document}
% 以下为正文之前的部分。
\frontmatter
% 自动生成标题页。
\maketitle
% 版权声明。
\include{chap/copyright}
% 中英文摘要。
\include{chap/abstract}
% 自动生成目录。
\tableofcontents
% 以下为正文。
\mainmatter
% 绪言。
\include{chap/introduction}
% 各章节。
\include{chap/chap1}
\include{chap/chap2}
\include{chap/chap3}
% 结论。
\include{chap/conclusion}
% 正文中的附录部分。
\appendix
% 排版参考文献列表。
\printbibliography[
% 使“参考文献”出现在目录中;如果同时要使参考文献列表参与章节编号,
% 可将“bibintoc”改为“bibnumbered”。
heading = bibintoc,
% 单独设定排序方案。此设定会局部覆盖之前的全局设置。
% 注:只有同时使用 2.x 或之后版本的 biblatex 和相应兼容版本的 biber
% 才能对每个 \printbibliography 命令采用不同的排序方案,
% 否则只能在导入 biblatex 宏包时就(全局)指定排序方案。
% 在这样的情况下,请去掉所有的 sorting 选项,否则可能出错。
sorting = ecnty
]
% 各附录。
\include{chap/encl1}
\include{chap/encl2}
% 以下为正文之后的部分。
\backmatter
% 致谢。
\include{chap/acknowledge}
% 原创性声明和使用授权说明。
\include{chap/originauth}
\end{document}