From 397faa7716268ec40f7184c7e09695bdf734653f Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Sun, 20 Nov 2016 22:11:24 +0000 Subject: hustthesis (20nov16) git-svn-id: svn://tug.org/texlive/trunk@42547 c570f23f-e606-0410-a88d-b1316a301751 --- .../doc/latex/hustthesis/hustthesis-en-example.pdf | Bin 201861 -> 201843 bytes .../doc/latex/hustthesis/hustthesis-zh-example.pdf | Bin 237192 -> 237148 bytes .../texmf-dist/doc/latex/hustthesis/hustthesis.pdf | Bin 430064 -> 417324 bytes .../source/latex/hustthesis/hustthesis.dtx | 68 ++++++++++++++++----- .../texmf-dist/tex/latex/hustthesis/hustthesis.cls | 25 ++++++-- 5 files changed, 74 insertions(+), 19 deletions(-) diff --git a/Master/texmf-dist/doc/latex/hustthesis/hustthesis-en-example.pdf b/Master/texmf-dist/doc/latex/hustthesis/hustthesis-en-example.pdf index ddb01608fb4..cf2fddf7624 100644 Binary files a/Master/texmf-dist/doc/latex/hustthesis/hustthesis-en-example.pdf and b/Master/texmf-dist/doc/latex/hustthesis/hustthesis-en-example.pdf differ diff --git a/Master/texmf-dist/doc/latex/hustthesis/hustthesis-zh-example.pdf b/Master/texmf-dist/doc/latex/hustthesis/hustthesis-zh-example.pdf index 41c379345ad..2d97c27d73f 100644 Binary files a/Master/texmf-dist/doc/latex/hustthesis/hustthesis-zh-example.pdf and b/Master/texmf-dist/doc/latex/hustthesis/hustthesis-zh-example.pdf differ diff --git a/Master/texmf-dist/doc/latex/hustthesis/hustthesis.pdf b/Master/texmf-dist/doc/latex/hustthesis/hustthesis.pdf index 0ef95e70de2..f0bda4f9c7d 100644 Binary files a/Master/texmf-dist/doc/latex/hustthesis/hustthesis.pdf and b/Master/texmf-dist/doc/latex/hustthesis/hustthesis.pdf differ diff --git a/Master/texmf-dist/source/latex/hustthesis/hustthesis.dtx b/Master/texmf-dist/source/latex/hustthesis/hustthesis.dtx index 0ceccd1b789..bd2d8d690f8 100644 --- a/Master/texmf-dist/source/latex/hustthesis/hustthesis.dtx +++ b/Master/texmf-dist/source/latex/hustthesis/hustthesis.dtx @@ -31,7 +31,7 @@ %\NeedsTeXFormat{LaTeX2e}[1999/12/01] %\ProvidesClass{hustthesis} %<*class> -[2016/06/01 v1.2 A Thesis Template for Huazhong University of Science and Technology] +[2016/11/17 v1.4 A Thesis Template for Huazhong University of Science and Technology] % % %<*driver> @@ -198,7 +198,7 @@ % % \fi % -% \CheckSum{1547} +% \CheckSum{1568} % % \iffalse %<*!(example-bib)> @@ -226,6 +226,9 @@ % \changes{v1.1}{2013/07/01}{Pack template using dtx and ins file} % \changes{v1.1}{2013/07/01}{Add language option} % \changes{v1.2}{2016/06/01}{Fix for TeXLive 2016. Remove \texttt{interfaces} and other problematic package} +% \changes{v1.3}{2016/07/05}{Fix for \XeLaTeX} +% \changes{v1.4}{2016/11/17}{Minor update to fulfill school requirement.} +% \changes{v1.4}{2016/11/17}{Add command to custom apply name field.} % % \GetFileInfo{hustthesis.dtx} % @@ -240,7 +243,7 @@ % \title{A Thesis Template for Huazhong University of Science and Technology: the \textsf{hustthesis} class % \thanks{This document corresponds to \textsf{hustthesis.cls}~\fileversion, dated \filedate.}} % \author{Xu Cheng \\ \email{xucheng@me.com}} -% \date{2013/07/01} +% \date{\today} % % \begingroup % \hypersetup{allcolors=black} @@ -344,7 +347,7 @@ % \begin{syntax} % degree = \meta{\textbf{none}\orvar{}fyp\orvar{}bachelor\orvar{}master\orvar{}phd} % \end{syntax} -% 指定论文种类,它将通过设置字段\verb+\HUST@zhapplyname+和\verb+\HUST@enapplyname+来影响中英文封面处的标题和正文处的页眉(如果\verb+format+设为\verb+draft+)。各个不同的选项产生的效果见表\ref{tab:optdegree-zh}。如果不指定,默认设置为\verb+none+。 +% 指定论文种类,它将通过设置字段\verb+\HUST@zhapplyname+和\verb+\HUST@enapplyname+来影响中英文封面处的标题和正文处的页眉(如果\verb+format+设为\verb+draft+)。各个不同的选项产生的效果见表\ref{tab:optdegree-zh}。如果不指定,默认设置为\verb+none+。如有需要,这两个字段可以通过\href{doc/function//applyname}{\texttt{\textbackslash{}zhapplyname},\texttt{\textbackslash{}enapplyname},\texttt{\textbackslash{}applyname}}命令进一步修改。 % \end{function} % % \begin{function}[updated=2013-07-01]{language} @@ -365,7 +368,7 @@ % \verb+fyp+ & 毕业论文 & A Thesis Submitted in Partial Fulfillment of the Requirements for Final Year Project \\ \hline % \verb+bachelor+ & 学士学位论文 & A Thesis Submitted in Partial Fulfillment of the Requirements for the Degree of Bachelor \\ \hline % \verb+master+ & 硕士学位论文 & A Thesis Submitted in Partial Fulfillment of the Requirements for the Degree of Master \\ \hline -% \verb+phd+ & 博士学位论文 & A Thesis Submitted in Partial Fulfillment of the Requirements for the Ph.D \\ \hline +% \verb+phd+ & 博士学位论文 & A Thesis Submitted in Partial Fulfillment of the Requirements for the Degree of Philosophy \\ \hline % \end{tabularx} % \end{table} % @@ -400,9 +403,9 @@ % % \begin{function}{\zhschoolname,\enschoolname,\schoolname} % \begin{syntax} -% \cs{zhschoolname}\Arg{Chinese schoolname} -% \cs{enschoolname}\Arg{English schoolname} -% \cs{schoolname}\Arg{Chinese schoolname}\Arg{English schoolname} +% \cs{zhschoolname}\Arg{Chinese school name} +% \cs{enschoolname}\Arg{English school name} +% \cs{schoolname}\Arg{Chinese school name}\Arg{English school name} % \end{syntax} % 这一组命令用于设定论文的中英文学校名。该字段在模板中已默认设置为\verb+\schoolname{华中科技大学}{Huazhong University of Science \& Technology}+。所以除非需更改学校名,无需使用该命令。 % \end{function} @@ -416,6 +419,15 @@ % 这一组命令用于设定论文的中英文学校地址。该字段在模板中已默认设置为\verb+\address{中国,武汉,430074}{Wuhan~430074, P.~R.~China}+。所以除非需更改学校地址,无需使用该命令。 % \end{function} % +% \begin{function}[updated=2016-11-17]{\zhapplyname,\enapplyname,\applyname} +% \begin{syntax} +% \cs{zhapplyname}\Arg{Chinese apply name} +% \cs{enapplyname}\Arg{English apply name} +% \cs{applyname}\Arg{Chinese apply name}\Arg{English apply name} +% \end{syntax} +% 这一组命令用于自定义中英文封面处的标题和正文处的页眉。详情见~\href{doc/function//degree}{\texttt{degree} 文档类型选项}。 +% \end{function} +% % \begin{function}{\zhmajor,\enmajor,\major} % \begin{syntax} % \cs{zhmajor}\Arg{Chinese major} @@ -777,7 +789,7 @@ % \begin{syntax} % degree = \meta{\textbf{none}\orvar{}fyp\orvar{}bachelor\orvar{}master\orvar{}phd} % \end{syntax} -% Set the category of thesis. It will influence the title of document, see Table~\ref{tab:optdegree-en}. The default value is \verb+none+. +% Set the category of thesis. It will influence the title of document, see Table~\ref{tab:optdegree-en}. The default value is \verb+none+. Noted that the apply name field in the title page can be further customized through \href{doc/function//applyname}{\texttt{\textbackslash{}applyname}} command. % \end{function} % % \begin{table}[ht] @@ -791,7 +803,7 @@ % \verb+fyp+ & A Thesis Submitted in Partial Fulfillment of the Requirements for Final Year Project \\ \hline % \verb+bachelor+ & A Thesis Submitted in Partial Fulfillment of the Requirements for the Degree of Bachelor \\ \hline % \verb+master+ & A Thesis Submitted in Partial Fulfillment of the Requirements for the Degree of Master \\ \hline -% \verb+phd+ & A Thesis Submitted in Partial Fulfillment of the Requirements for the Ph.D \\ \hline +% \verb+phd+ & A Thesis Submitted in Partial Fulfillment of the Requirements for the Degree of Philosophy \\ \hline % \end{tabularx} % \end{table} % @@ -834,6 +846,13 @@ % Set the address of school which has been set as \\*\hbox{\verb+\address{Wuhan~430074, P.~R.~China}+} by default. So unless you want to change the address, you don't need to use this command. % \end{function} % +% \begin{function}[updated=2016-11-17]{\applyname} +% \begin{syntax} +% \cs{applyname}\Arg{apply name} +% \end{syntax} +% Custom the apply name which affects English title page. See more detail at~\href{doc/function//degree}{\texttt{degree} option}. +% \end{function} +% % \begin{function}{\major} % \begin{syntax} % \cs{major}\Arg{major} @@ -1285,13 +1304,18 @@ \RequirePackage{geometry} \geometry{ top=1.77in, - bottom=1.1in, + bottom=0.8in, left=1.1in, right=1.1in, includefoot } -\pagewidth=\paperwidth -\pageheight=\paperheight +\ifthenelse{\isundefined{\pagewidth}}{ + \pdfpagewidth=\paperwidth + \pdfpageheight=\paperheight +}{ + \pagewidth=\paperwidth + \pageheight=\paperheight +} % \end{macrocode} % % Indent of paragraph and skip between paragraphs. @@ -1459,6 +1483,22 @@ % \end{macrocode} % \end{macro} % +% \begin{macro}{\zhapplyname,\enapplyname,\applyname} +% Commands to custom apply name. +% \begin{macrocode} +\def\zhapplyname#1{\def\HUST@zhapplyname{#1}} +\def\enapplyname#1{\def\HUST@enapplyname{#1}} +\DeclareDocumentCommand\applyname{m g} +{ + \IfNoValueTF{#2}{ + \enapplyname{#1} + }{ + \zhapplyname{#1}\enapplyname{#2} + } +} +% \end{macrocode} +% \end{macro} +% % \begin{macro}{\zhmajor,\enmajor,\major} % Commands to set the major. % \begin{macrocode} @@ -1732,7 +1772,7 @@ \ifthenelse{\equal{\HUST@degree}{phd}}{ \def\HUST@zhapplyname{博士学位论文} - \def\HUST@enapplyname{A Thesis Submitted in Partial Fulfillment of the Requirements for the Ph.D} + \def\HUST@enapplyname{A Thesis Submitted in Partial Fulfillment of the Requirements for the Degree of Philosophy} }{} \ifthenelse{\equal{\HUST@language}{chinese}}{ diff --git a/Master/texmf-dist/tex/latex/hustthesis/hustthesis.cls b/Master/texmf-dist/tex/latex/hustthesis/hustthesis.cls index 266ad7f6f9d..606aa29d7e2 100644 --- a/Master/texmf-dist/tex/latex/hustthesis/hustthesis.cls +++ b/Master/texmf-dist/tex/latex/hustthesis/hustthesis.cls @@ -29,7 +29,7 @@ %% \NeedsTeXFormat{LaTeX2e}[1999/12/01] \ProvidesClass{hustthesis} -[2016/06/01 v1.2 A Thesis Template for Huazhong University of Science and Technology] +[2016/11/17 v1.4 A Thesis Template for Huazhong University of Science and Technology] %% \CharacterTable %% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z %% Lower-case \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z @@ -180,13 +180,18 @@ \RequirePackage{geometry} \geometry{ top=1.77in, - bottom=1.1in, + bottom=0.8in, left=1.1in, right=1.1in, includefoot } -\pagewidth=\paperwidth -\pageheight=\paperheight +\ifthenelse{\isundefined{\pagewidth}}{ + \pdfpagewidth=\paperwidth + \pdfpageheight=\paperheight +}{ + \pagewidth=\paperwidth + \pageheight=\paperheight +} \RequirePackage{indentfirst} \setlength{\parindent}{2em} \setlength{\parskip}{0pt plus 2pt minus 1pt} @@ -284,6 +289,16 @@ } } \address{中国,武汉,430074}{Wuhan~430074, P.~R.~China} +\def\zhapplyname#1{\def\HUST@zhapplyname{#1}} +\def\enapplyname#1{\def\HUST@enapplyname{#1}} +\DeclareDocumentCommand\applyname{m g} +{ + \IfNoValueTF{#2}{ + \enapplyname{#1} + }{ + \zhapplyname{#1}\enapplyname{#2} + } +} \def\zhmajor#1{\gdef\HUST@zhmajor{#1}} \def\enmajor#1{\gdef\HUST@enmajor{#1}} \DeclareDocumentCommand\major{m g} @@ -491,7 +506,7 @@ \ifthenelse{\equal{\HUST@degree}{phd}}{ \def\HUST@zhapplyname{博士学位论文} - \def\HUST@enapplyname{A Thesis Submitted in Partial Fulfillment of the Requirements for the Ph.D} + \def\HUST@enapplyname{A Thesis Submitted in Partial Fulfillment of the Requirements for the Degree of Philosophy} }{} \ifthenelse{\equal{\HUST@language}{chinese}}{ -- cgit v1.2.3