diff options
author | Norbert Preining <norbert@preining.info> | 2019-09-02 13:46:59 +0900 |
---|---|---|
committer | Norbert Preining <norbert@preining.info> | 2019-09-02 13:46:59 +0900 |
commit | e0c6872cf40896c7be36b11dcc744620f10adf1d (patch) | |
tree | 60335e10d2f4354b0674ec22d7b53f0f8abee672 /macros/latex/contrib/pkuthss/tex |
Initial commit
Diffstat (limited to 'macros/latex/contrib/pkuthss/tex')
-rw-r--r-- | macros/latex/contrib/pkuthss/tex/pkulogo.eps | 140 | ||||
-rw-r--r-- | macros/latex/contrib/pkuthss/tex/pkulogo.pdf | bin | 0 -> 3641 bytes | |||
-rw-r--r-- | macros/latex/contrib/pkuthss/tex/pkuthss-gbk.def | 48 | ||||
-rw-r--r-- | macros/latex/contrib/pkuthss/tex/pkuthss-utf8.def | 48 | ||||
-rw-r--r-- | macros/latex/contrib/pkuthss/tex/pkuthss.cls | 407 | ||||
-rw-r--r-- | macros/latex/contrib/pkuthss/tex/pkuword.eps | 267 | ||||
-rw-r--r-- | macros/latex/contrib/pkuthss/tex/pkuword.pdf | bin | 0 -> 6392 bytes |
7 files changed, 910 insertions, 0 deletions
diff --git a/macros/latex/contrib/pkuthss/tex/pkulogo.eps b/macros/latex/contrib/pkuthss/tex/pkulogo.eps new file mode 100644 index 0000000000..35c1a90dfb --- /dev/null +++ b/macros/latex/contrib/pkuthss/tex/pkulogo.eps @@ -0,0 +1,140 @@ +%!PS-Adobe-2.0 EPSF-2.0 +%%BoundingBox: 0 0 400 400 +%%Pages: 1 +%%Page: 1 1 + +% Peking University dissertation document class +% +% Copyright (c) 2008-2009 solvethis +% Copyright (c) 2010-2012,2014 Casper Ti. Vector +% +% This work may be distributed and/or modified under the conditions of the +% LaTeX Project Public License, either version 1.3 of this license or (at +% your option) any later version. +% The latest version of this license is in +% https://www.latex-project.org/lppl.txt +% and version 1.3 or later is part of all distributions of LaTeX version +% 2005/12/01 or later. +% +% This work has the LPPL maintenance status `maintained'. +% The current maintainer of this work is Casper Ti. Vector. +% +% This work consists of the following files: +% pkuthss.cls +% pkuthss-gbk.def +% pkuthss-utf8.def +% pkulogo.eps +% pkuword.eps + +% 设置北大红的色值(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 diff --git a/macros/latex/contrib/pkuthss/tex/pkulogo.pdf b/macros/latex/contrib/pkuthss/tex/pkulogo.pdf Binary files differnew file mode 100644 index 0000000000..4d4fd3a58a --- /dev/null +++ b/macros/latex/contrib/pkuthss/tex/pkulogo.pdf diff --git a/macros/latex/contrib/pkuthss/tex/pkuthss-gbk.def b/macros/latex/contrib/pkuthss/tex/pkuthss-gbk.def new file mode 100644 index 0000000000..8c39301e69 --- /dev/null +++ b/macros/latex/contrib/pkuthss/tex/pkuthss-gbk.def @@ -0,0 +1,48 @@ +% Peking University dissertation document class +% +% Copyright (c) 2008-2009 solvethis +% Copyright (c) 2010-2013,2015 Casper Ti. Vector +% +% This work may be distributed and/or modified under the conditions of the +% LaTeX Project Public License, either version 1.3 of this license or (at +% your option) any later version. +% The latest version of this license is in +% https://www.latex-project.org/lppl.txt +% and version 1.3 or later is part of all distributions of LaTeX version +% 2005/12/01 or later. +% +% This work has the LPPL maintenance status `maintained'. +% The current maintainer of this work is Casper Ti. Vector. +% +% This work consists of the following files: +% pkuthss.cls +% pkuthss-gbk.def +% pkuthss-utf8.def +% pkulogo.eps +% pkuword.eps + +\ProvidesFile{pkuthss-gbk.def} + [2018/07/02 v1.8.0 Labels and captions in GBK encoding + for the pkuthss document class] + +\def\label@ctitle{Ŀ} +\def\label@cauthor{\hphantom{}} +\def\label@studentid{ѧ\hphantom{}ţ} +\def\label@school{Ժ\hphantom{}ϵ} +\def\label@cmajor{ר\hphantom{}ҵ} +\def\label@direction{о} +\def\label@cmentor{\hphantom{}ʦ} +\def\label@ementor{Directed by\ } +\def\label@ckeywords{ؼʣ} +\def\label@ekeywords{KEYWORDS:\ } + +\def\titlepagename{} +\def\cuniversity{ѧ} +\def\euniversity{Peking University} +\def\cthesisname{ʿоѧλ} +\def\ethesisname{Doctor Thesis} +\def\cabstractname{ժҪ} +\def\eabstractname{ABSTRACT} + +\endinput +% vim:ft=tex:ts=2:sw=2 diff --git a/macros/latex/contrib/pkuthss/tex/pkuthss-utf8.def b/macros/latex/contrib/pkuthss/tex/pkuthss-utf8.def new file mode 100644 index 0000000000..b6996850e4 --- /dev/null +++ b/macros/latex/contrib/pkuthss/tex/pkuthss-utf8.def @@ -0,0 +1,48 @@ +% Peking University dissertation document class +% +% Copyright (c) 2008-2009 solvethis +% Copyright (c) 2010-2013,2015 Casper Ti. Vector +% +% This work may be distributed and/or modified under the conditions of the +% LaTeX Project Public License, either version 1.3 of this license or (at +% your option) any later version. +% The latest version of this license is in +% https://www.latex-project.org/lppl.txt +% and version 1.3 or later is part of all distributions of LaTeX version +% 2005/12/01 or later. +% +% This work has the LPPL maintenance status `maintained'. +% The current maintainer of this work is Casper Ti. Vector. +% +% This work consists of the following files: +% pkuthss.cls +% pkuthss-gbk.def +% pkuthss-utf8.def +% pkulogo.eps +% pkuword.eps + +\ProvidesFile{pkuthss-utf8.def} + [2018/07/02 v1.8.0 Labels and captions in UTF-8 encoding + for the pkuthss document class] + +\def\label@ctitle{题目:} +\def\label@cauthor{姓\hphantom{汉字}名:} +\def\label@studentid{学\hphantom{汉字}号:} +\def\label@school{院\hphantom{汉字}系:} +\def\label@cmajor{专\hphantom{汉字}业:} +\def\label@direction{研究方向:} +\def\label@cmentor{导\hphantom{汉字}师:} +\def\label@ementor{Directed by\ } +\def\label@ckeywords{关键词:} +\def\label@ekeywords{KEYWORDS:\ } + +\def\titlepagename{封面} +\def\cuniversity{北京大学} +\def\euniversity{Peking University} +\def\cthesisname{博士研究生学位论文} +\def\ethesisname{Doctor Thesis} +\def\cabstractname{摘要} +\def\eabstractname{ABSTRACT} + +\endinput +% vim:ft=tex:ts=2:sw=2 diff --git a/macros/latex/contrib/pkuthss/tex/pkuthss.cls b/macros/latex/contrib/pkuthss/tex/pkuthss.cls new file mode 100644 index 0000000000..9e68dc3585 --- /dev/null +++ b/macros/latex/contrib/pkuthss/tex/pkuthss.cls @@ -0,0 +1,407 @@ +% Peking University dissertation document class +% +% Copyright (c) 2008-2009 solvethis +% Copyright (c) 2010-2018 Casper Ti. Vector +% +% This work may be distributed and/or modified under the conditions of the +% LaTeX Project Public License, either version 1.3 of this license or (at +% your option) any later version. +% The latest version of this license is in +% https://www.latex-project.org/lppl.txt +% and version 1.3 or later is part of all distributions of LaTeX version +% 2005/12/01 or later. +% +% This work has the LPPL maintenance status `maintained'. +% The current maintainer of this work is Casper Ti. Vector. +% +% This work consists of the following files: +% pkuthss.cls +% pkuthss-gbk.def +% pkuthss-utf8.def +% pkulogo.eps +% pkuword.eps + +\NeedsTeXFormat{LaTeX2e}[1995/12/01] +\ProvidesClass{pkuthss} + [2018/07/02 v1.8.0 Peking University dissertation document class] + +% eg. `\thss@int@boolopt{spacing}{true}' will expand to: +% \newif\ifthss@opt@spacing \thss@opt@spacingtrue +% \DeclareOption{spacing}{\thss@opt@spacingtrue} +% \DeclareOption{nospacing}{\thss@opt@spacingfalse} +\def\thss@int@boolopt#1#2{ + \expandafter\newif\csname ifthss@opt@#1\endcsname + \@nameuse{thss@opt@#1#2} + \DeclareOption{#1}{\@nameuse{thss@opt@#1true}} + \DeclareOption{no#1}{\@nameuse{thss@opt@#1false}} +} +% Process the encoding options. +\newif\ifthss@opt@gbk \thss@opt@gbktrue +\DeclareOption{GBK}{\thss@opt@gbktrue\PassOptionsToClass{GBK}{ctexbook}} +\DeclareOption{UTF8}{\thss@opt@gbkfalse\PassOptionsToClass{UTF8}{ctexbook}} +% Whether to enable `\Uppercase' (works problematically) in heading marks. +\thss@int@boolopt{uppermark}{false} +% Whether to modify fonts according to school regulation. +\thss@int@boolopt{pkufont}{true} +% Whether to modify footnote format according to school regulation. +\thss@int@boolopt{pkufoot}{true} +% Whether to modify spacing according to school regulation. +\thss@int@boolopt{pkuspace}{true} +% Whether to use some common settings for adjusting spacing. +\thss@int@boolopt{spacing}{true} +% Add PDF bookmark for table of contents. +\thss@int@boolopt{pdftoc}{true} +% Whether to enable the `\spacialchap' command. +\thss@int@boolopt{spechap}{true} +% Whether to automatically set up properties for generated PDF from user +% defined document information (author, title, etc.). +\thss@int@boolopt{pdfprop}{true} +% Whether to disable some infractions intended to make the style less ugly. +\thss@int@boolopt{ugly}{false} +% Pass all other options to `ctexbook' document class. +\DeclareOption*{\PassOptionsToClass{\CurrentOption}{ctexbook}} +% Process all class options now. +\ProcessOptions\relax + +% Prevent fontspec (loaded by xeCJK) from interfering with newtxmath. +\ifthss@opt@pkufont\PassOptionsToPackage{no-math}{fontspec}\fi +% pkuthss is based on ctexbook; we use `xiao 4' as default font size. +\LoadClass[zihao = -4]{ctexbook}[2014/03/06] +% ctex 2.x no longer loads ifpdf and ifxetex by itself. +\RequirePackage{ifpdf, ifxetex} +% Provides support for `key = val' grammar. +\RequirePackage{keyval} +% Graphics support. +\RequirePackage{graphicx}[1999/02/16] +% Provides utilities for setting up page layout. +\RequirePackage{geometry} +% fancyhdr provides utilities for setting up headers and footers. +\RequirePackage{fancyhdr} +% Provides `\uline' used in `\maketitle'. +\RequirePackage{ulem} +% `\AtEndOfClass' used to avoid `PDF destination not defined' with setspace. +\AtEndOfClass{\RequirePackage{hyperref}} + +\ifthss@opt@gbk + \input{pkuthss-gbk.def} + \ifxetex + % No support for XeLaTeX compilation in non-unicode encoding, i.e. GBK. + \ClassError{pkuthss}% + {XeLaTeX compilation is not supported without UTF-8}% + {% + XeLaTeX compilation without UTF-8 is very problematic.\MessageBreak + Therefore please use UTF-8 encoding for the LaTeX code.% + } + \fi +\else + \input{pkuthss-utf8.def} +\fi + +\ifthss@opt@pkufont + % Use Times New Roman / Arial according to school regulation. + % Option used to prevent newtxtext from manipulating footnote marks. + \RequirePackage[defaultsups]{newtxtext} + \RequirePackage[cmintegrals, varg]{newtxmath} +\else + % Provides `\Box' for originauth.tex if newtx is absent. + \RequirePackage{latexsym} +\fi + +\ifthss@opt@pkufoot + % Handle the `Unparsed material' issue with latex/dvipdfmx compilation. + \unless\ifxetex\unless\ifpdf + \newcommand*\pgfsysdriver{pgfsys-dvipdfm.def} + \fi\fi + % Circled text, cf. <https://tex.stackexchange.com/questions/7032/>. + \RequirePackage{tikz} + \newcommand*\thss@int@circled[1]{% + \scalebox{0.8}{\tikz[baseline = (char.base)]{ + \node[ + shape = circle, draw = black, minimum size = 1.25em, inner sep = 0pt + ] (char) {#1}; + }}% + } + % Use circled numbers as footnote symbols. Does not affect title page, but + % footnote is rarely used in dissertation covers ;) + \renewcommand\thefootnote% + {\protect\thss@int@circled{\arabic{footnote}}} + % Provides utility to modify footnote spacing. + % Option used to make sure it does not render interleaf pages totally blank. + \RequirePackage[cleardoublepage = current]{scrextend} + % Set up footnote spacing: whole paragraph indent 2 ccwd, 0.5 ccwd after mark. + \deffootnote{2\ccwd}{0pt}{\thefootnotemark\hspace{0.5\ccwd}} +\fi + +\ifthss@opt@pkuspace + % lineskip / baselineskip = 20 bp / (12 bp * (6 / 5)). + \linespread{1.39}\selectfont + % Provides utilities for setting TOC format; `titles' applied to avoid + % interfering with LaTeX's own title mechanism. + \RequirePackage[titles]{tocloft} + \setlength{\cftbeforechapskip}{6bp plus 1bp} + \setlength{\cftsecindent}{\ccwd} + \setlength{\cftsubsecindent}{2\ccwd} + \setlength{\cftsubsubsecindent}{4\ccwd} + % `caption' modifies font size and separator of captions. `subcaption' + % provides functions similar to `subfigure'/`subfig' but does not clash with + % `tocloft'; it clashes with `subfigure'/`subfig', but the error message will + % say they cannot be used simultaneously. + \RequirePackage{caption, subcaption} + \DeclareCaptionFont{cfive}{\zihao{5}} + \DeclareCaptionLabelSeparator{quad}{\quad} + \captionsetup{font = cfive, labelsep = quad} +\fi + +\ifthss@opt@spacing + % Make spacing nicer in some situations (eg. footnotes and verbatims). + \RequirePackage{setspace} + % Remove superfluous spacing between footnotes. + \setlength{\footnotesep}{0pt} + % Lists often appear to be too sparse when items are just one or two lines + % long. Here we cancel the extra vertical spacing between list items. + % The list margin is adjusted due to Chinese typesetting traditions. + \RequirePackage{enumitem} + \setlist{nolistsep, leftmargin = 1.5\parindent} +\fi + +\ifthss@opt@spechap + % This command is used to start a chapter without numbering, and correctly set + % up the headers and footers in the chapter. + \newcommand\specialchap[1]{% + \chapter*{#1}\addcontentsline{toc}{chapter}{#1} + \markboth{#1}{}\phantomsection% + } +\fi + +\AtBeginDocument{ + % Set up spacing for displayed formulae. + \setlength{\abovedisplayskip}{\belowdisplayshortskip} + \setlength{\belowdisplayskip}{\abovedisplayskip} + + \ifthss@opt@pdftoc + % Add PDF bookmark for table of contents. + \let\thss@tmp@tableofcontents\tableofcontents + \renewcommand{\tableofcontents}{% + \thss@int@pdfmark{\contentsname}{contents} + \thss@tmp@tableofcontents% + } + \fi + + \ifthss@opt@pdfprop + % Automatically generate properties for generated PDF. + % Use English properties to avoid problems with character encodings. + \newcommand*{\setpdfproperties}{% + \hypersetup{ + pdfauthor = {\@eauthor}, pdftitle = {\@etitle}, + pdfsubject = {\euniversity\ \ethesisname}, pdfkeywords = {\@ekeywords} + }% + } + % Set up the properties when generating the title page because the document + % information should have been all defined before this. + \let\thss@tmp@maketitle\maketitle + % NOTE: `\hypersetup' must appear before `\maketitle', otherwise it might + % not act as expected. + \renewcommand\maketitle{\setpdfproperties\thss@tmp@maketitle} + \fi +} + +% eg. `\thss@int@infoitema{ctitle}' will expand to: +% \def\ctitle#1{\def\@ctitle{#1}} +% \define@key{thss@info}{ctitle}{\ctitle{#1}} +\def\thss@int@infoitema#1{ + \@namedef{#1}##1{\@namedef{@#1}{##1}} + \define@key{thss@info}{#1}{\@nameuse{#1}{##1}} +} +% eg. `\thss@int@infoitemb{cuniversity}' will expand to: +% \define@key{thss@info}{cuniversity}{\def\cuniversity{#1}} +\def\thss@int@infoitemb#1{ + \define@key{thss@info}{#1}{\@namedef{#1}{##1}} +} +% Set up document information entries. +\thss@int@infoitema{ctitle} +\thss@int@infoitema{etitle} +\thss@int@infoitema{cauthor} +\thss@int@infoitema{eauthor} +\thss@int@infoitema{studentid} +\thss@int@infoitema{date} +\thss@int@infoitema{school} +\thss@int@infoitema{cmajor} +\thss@int@infoitema{emajor} +\thss@int@infoitema{direction} +\thss@int@infoitema{cmentor} +\thss@int@infoitema{ementor} +\thss@int@infoitema{ckeywords} +\thss@int@infoitema{ekeywords} +\thss@int@infoitemb{cuniversity} +\thss@int@infoitemb{euniversity} +\thss@int@infoitemb{cthesisname} +\thss@int@infoitemb{ethesisname} +\thss@int@infoitemb{cabstractname} +\thss@int@infoitemb{eabstractname} +% Set up document information using the `key = value' grammar. +\newcommand*{\pkuthssinfo}[1]{\setkeys{thss@info}{#1}} + +% Set up page layout. +\geometry{ + a4paper, hmargin = 2.6cm, top = 2.92cm, bottom = 3.03cm, + headheight = 0.45cm, headsep = 0.55cm, footskip = 1.05cm +} + +% Set up chapter/section/... captions. +% The `*skip' values are not supposed to be modified by the `ugly' option: +% the actual style of the school's guide and Word template seem to be different +% from the written specification (when applied verbatim in LaTeX), and here the +% actual style is used. +\setcounter{secnumdepth}{3} +\setcounter{tocdepth}{2} +\ctexset{ + chapter = { + beforeskip = {0bp}, afterskip = {18bp plus 0.2ex}, + nameformat = {}, titleformat = {} + }, section = + {beforeskip = {20bp plus 1ex minus 0.2ex}, afterskip = {6bp plus 0.2ex}}, + subsection = + {beforeskip = {12bp plus 1ex minus 0.2ex}, afterskip = {6bp plus 0.2ex}}, + subsubsection = + {beforeskip = {12bp plus 1ex minus 0.2ex}, afterskip = {6bp plus 0.2ex}} +} +\ifthss@opt@ugly + \ctexset{ + chapter = {format = {\zihao{3}\bfseries\centering}}, + section = {format = {\zihao{4}\bfseries}}, + subsection = {format = {\fontsize{13bp}{15.6bp}\selectfont\bfseries}}, + subsubsection = {format = {\zihao{-4}\bfseries}} + } +\else + \ctexset{ + chapter = {format = {\zihao{-2}\bfseries\centering}}, + section = {format = {\zihao{-3}\bfseries}}, + subsection = {format = {\zihao{4}\bfseries}}, + subsubsection = {format = {\bfseries}} + } +\fi + +% `\MakeUppercase' works problematically. +% eg. it converts `\cite{ctex}' into `\cite{CTEX}'. +% This option can disable `\MakeUppercase' in left/right heading marks. +\ifthss@opt@uppermark + \def\thss@int@setcase#1{#1} +\else + % Code copied from fancyhdr's `\nouppercase', with the redefinition of + % `\uppercase' dropped to avoid disrupting CJKutf8. + % cf. <https://code.google.com/p/ctex-kit/issues/detail?id=147>. + \def\thss@int@setcase#1{% + \let\MakeUppercase\relax% + \expandafter\let\csname MakeUppercase \endcsname\relax% + #1% + } +\fi +% The actual page style setup. +\fancypagestyle{plain}{ + \fancyhf{}\renewcommand*{\headrulewidth}{0.75bp} + \fancyfoot[C]{\zihao{5}\normalfont{\thepage}} + \if@twoside + \fancyhead[CE]{\zihao{5}\normalfont{\cuniversity\cthesisname}} + \fancyhead[CO]{\zihao{5}\normalfont\thss@int@setcase{\leftmark}} + \else + \fancyhead[C]{\zihao{5}\normalfont\thss@int@setcase{\leftmark}} + \fi +} +\pagestyle{plain} + +% This places a bookmark pointing to somewhere near the page header; +% Result of simple `\chapter{...} \pdfbookmark{...}' does not look nice, +% because the bookmark will point to somewhere below the chapter mark. +\def\thss@int@pdfmark#1#2{% + \if@openright\cleardoublepage\else\clearpage\fi + \pdfbookmark[0]{#1}{#2}% +} + +% Usage: \thss@int@fillinblank{(number of lines)}{(line width)}{(contents)} +\def\thss@int@fillinblank#1#2#3{% + \makebox[0pt][l]{\parbox[t]{#2}{\centering{#3}}}\mbox{}% + \parbox[t]{#2}{% + \newcount\thss@tmp@linecount + \thss@tmp@linecount=#1 + \loop\ifnum\thss@tmp@linecount>0 + % Fill specified space with underline on the bottom line. `\underline' + % draws line on the baseline (not the bottom line), and this is why + % `\uline' is used here instead. + \ifnum\thss@tmp@linecount=1 + \uline{\makebox[#2]{}} + \else + \uline{\makebox[#2]{}}\\ + \fi + \advance\thss@tmp@linecount by -1\relax + \repeat% + }% +} + +% Set up format of the title page (cover). +\renewcommand{\maketitle}{% + \thss@int@pdfmark{\titlepagename}{titlepage} + % Make the title page centered. + \begin{titlepage}\begin{center} + % Emblem and inscription of the university, and type of thesis. + {% + \zihao{1}% + \includegraphics[height = 2.4em]{pkulogo}\hspace{0.4em}% + \raisebox{0.4em}{\includegraphics[height = 1.6em]{pkuword}}\\[0.8em] + {\bfseries{\cthesisname}}% + } + \vfill + % Title of the thesis. + {% + \zihao{2}{\label@ctitle}\linespread{1.6}\selectfont% + \thss@int@fillinblank{2}{0.64\textwidth}{\textbf{\@ctitle}}% + } + \vfill + % Information about the author. + {% + % Slightly adjust the line skip when using new font size. + \zihao{3}\linespread{1.75}\selectfont + \def\thss@tmp@len{0.56\textwidth} + \begin{tabular}{l@{\extracolsep{0.2em}}c} + {\bfseries\label@cauthor} & + \thss@int@fillinblank{1}{\thss@tmp@len}{\fangsong\@cauthor} \\ + {\bfseries\label@studentid} & + \thss@int@fillinblank{1}{\thss@tmp@len}{\fangsong\@studentid} \\ + {\bfseries\label@school} & + \thss@int@fillinblank{1}{\thss@tmp@len}{\fangsong\@school} \\ + {\bfseries\label@cmajor} & + \thss@int@fillinblank{1}{\thss@tmp@len}{\fangsong\@cmajor} \\ + {\bfseries\label@direction} & + \thss@int@fillinblank{1}{\thss@tmp@len}{\fangsong\@direction} \\ + {\bfseries\label@cmentor} & + \thss@int@fillinblank{1}{\thss@tmp@len}{\fangsong\@cmentor} \\ + \end{tabular}% + } + \vfill + % Date. + {\zihao{-2}\@date} + \end{center}\end{titlepage}% +} + +% Typeset the Chinese abstract. +\newenvironment{cabstract}{% + \thss@int@pdfmark{\cabstractname}{cabstract} + \chapter*{\cabstractname}\markboth{\cabstractname}{}% +}{% Keywords at the bottom of the page. + \vfill\noindent\textbf{\label@ckeywords}{\@ckeywords}% +} + +% Typeset the English abstract. +\newenvironment{eabstract}{% + \thss@int@pdfmark{\eabstractname}{eabstract} + \chapter*{\sffamily\@etitle}\markboth{\eabstractname}{} + \begin{center} + {\@eauthor} ({\@emajor})\\ + {\label@ementor}{\@ementor}\\[2em] + \textbf{\sffamily\eabstractname} + \end{center}\par% +}{% Keywords at the bottom of the page. + \vfill\noindent\textbf{\label@ekeywords}{\@ekeywords}% +} + +\endinput +% vim:ft=tex:ts=2:sw=2 diff --git a/macros/latex/contrib/pkuthss/tex/pkuword.eps b/macros/latex/contrib/pkuthss/tex/pkuword.eps new file mode 100644 index 0000000000..88bbca5d12 --- /dev/null +++ b/macros/latex/contrib/pkuthss/tex/pkuword.eps @@ -0,0 +1,267 @@ +%!PS-Adobe-2.0 EPSF-2.0 +%%BoundingBox: 0 0 525 150 +%%Pages: 1 +%%Page: 1 1 + +% Peking University dissertation document class +% +% Copyright (c) 2008-2009 solvethis +% Copyright (c) 2010-2012,2014 Casper Ti. Vector +% +% This work may be distributed and/or modified under the conditions of the +% LaTeX Project Public License, either version 1.3 of this license or (at +% your option) any later version. +% The latest version of this license is in +% https://www.latex-project.org/lppl.txt +% and version 1.3 or later is part of all distributions of LaTeX version +% 2005/12/01 or later. +% +% This work has the LPPL maintenance status `maintained'. +% The current maintainer of this work is Casper Ti. Vector. +% +% This work consists of the following files: +% pkuthss.cls +% pkuthss-gbk.def +% pkuthss-utf8.def +% pkulogo.eps +% pkuword.eps + +% 设置北大红的色值(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 diff --git a/macros/latex/contrib/pkuthss/tex/pkuword.pdf b/macros/latex/contrib/pkuthss/tex/pkuword.pdf Binary files differnew file mode 100644 index 0000000000..d8bfa5fd17 --- /dev/null +++ b/macros/latex/contrib/pkuthss/tex/pkuword.pdf |