diff --git a/tex/pkuthss.cls b/tex/pkuthss.cls index 54e7f46..5369fcb 100644 --- a/tex/pkuthss.cls +++ b/tex/pkuthss.cls @@ -38,9 +38,9 @@ \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}} +\newif\ifthss@opt@gbk \thss@opt@gbkfalse +\DeclareOption{GBK}{\thss@opt@gbktrue} +\DeclareOption{UTF8}{\thss@opt@gbkfalse} % Whether to enable `\Uppercase' (works problematically) in heading marks. \thss@int@boolopt{uppermark}{false} % Whether to modify fonts according to school regulation. @@ -65,9 +65,6 @@ % Process all class options now. \ProcessOptions\relax -% Work around the `\lvert already defined' error. -% cf. . -\ifthss@opt@pkufont\RequirePackage{amsmath}\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. @@ -83,10 +80,11 @@ % Provides `\uline' used in `\maketitle' (but do not mess with `\emph'). \RequirePackage[normalem]{ulem} % `\AtEndOfClass' used to avoid `PDF destination not defined' with setspace. -\AtEndOfClass{\RequirePackage{hyperref}} +\AtEndOfClass{\RequirePackage[bookmarksnumbered, unicode]{hyperref}} \input{pkuthss.def} \ifthss@opt@pkufont + \RequirePackage{amsmath} % Use Times New Roman / Arial according to school regulation. \ifxetex \RequirePackage{unicode-math} @@ -218,8 +216,8 @@ % information does not leak into the blind version. \newcommand*{\setpdfproperties}{% \hypersetup{ - pdfauthor = {\@eauthor}, pdftitle = {\@etitle}, - pdfsubject = {\euniversity\ \ethesisname}, pdfkeywords = {\@ekeywords} + pdfauthor = {\@cauthor}, pdftitle = {\@ctitle}, + pdfsubject = {\cuniversity\cthesisname}, pdfkeywords = {\@ckeywords} }% } % Set up the properties when generating the title page because the document @@ -277,7 +275,7 @@ % Set up page layout. \geometry{a4paper, hmargin = 2.6cm, headheight = 0.5cm, headsep = 0.6cm} \ifthss@opt@ugly - \geometry{top = 3.1cm, bottom = 3.0cm, footskip = 0.8cm} + \geometry{top = 3.1cm, bottom = 2.5cm, footskip = 0.8cm} \else \geometry{top = 3.0cm, bottom = 3.1cm, footskip = 1.1cm} \fi diff --git a/tex/pkuthss.def b/tex/pkuthss.def index 72c62de..e987b19 100644 --- a/tex/pkuthss.def +++ b/tex/pkuthss.def @@ -25,18 +25,13 @@ \ProvidesFile{pkuthss.def} [2024/03/07 v1.9.4 Labels and captions for the pkuthss document class] -\def\label@ementor{Directed by\ } \def\euniversity{Peking University} \def\ethesisname{Doctor Thesis} \def\thesiscover{} \def\mentorlines{1} \def\eabstractname{ABSTRACT} - -\ifthss@opt@ugly - \def\label@ekeywords{KEY WORDS:\ } -\else - \def\label@ekeywords{KEYWORDS:\ } -\fi +\def\label@ementor{Supervised by\ } +\def\label@ekeywords{KEY WORDS:\ } \ifthss@opt@gbk \input{pkuthss-gbk.def}