diff options
Diffstat (limited to 'Master/texmf-dist/tex/latex')
-rw-r--r-- | Master/texmf-dist/tex/latex/mitthesis/mitthesis.cls | 99 |
1 files changed, 56 insertions, 43 deletions
diff --git a/Master/texmf-dist/tex/latex/mitthesis/mitthesis.cls b/Master/texmf-dist/tex/latex/mitthesis/mitthesis.cls index 0ae67092834..1a59a39d14d 100644 --- a/Master/texmf-dist/tex/latex/mitthesis/mitthesis.cls +++ b/Master/texmf-dist/tex/latex/mitthesis/mitthesis.cls @@ -7,8 +7,8 @@ %% MIT Libraries' requirements as of 2023. %% %% This file's version and date: - \def\versionno{1.01} - \def\versiondate{2023/06/19\space} + \def\versionno{1.02} + \def\versiondate{2023/06/23\space} %% %% Author: John H. Lienhard, V %% Department of Mechanical Engineering @@ -348,7 +348,7 @@ \newcounter{authorno} \setcounter{authorno}{0} -\NewDocumentCommand\@AuthorBlock{}{% +\NewDocumentCommand\@AuthorBlock{}{% Revised 2023/06/23 \setcounter{authorno}{1}% \ifnum\value{authorcnt}=0 \ClassError{\ClassName}{Missing author! You must issue the \Author{name}{department} command}{% @@ -358,18 +358,18 @@ \whiledo{\value{authorno}<\value{authorcnt}}{% \ignorespaces\csname aut@\theauthorno\endcsname\par \ifcsundef{prevdegree@\theauthorno}{\relax}{\normalsize\csname prevdegree@\theauthorno\endcsname}% - \ifcsundef{secondprevdegree@\theauthorno}{\relax}{\\ \normalsize\csname secondprevdegree@\theauthorno\endcsname}% - \ifcsundef{thirdprevdegree@\theauthorno}{\relax}{\\ \normalsize\csname thirdprevdegree@\theauthorno\endcsname}% - \ifcsundef{fourthprevdegree@\theauthorno}{\relax}{\\ \normalsize\csname fourthprevdegree@\theauthorno\endcsname}% + \ifcsundef{secondprevdegree@\theauthorno}{\relax}{\linebreak\normalsize\csname secondprevdegree@\theauthorno\endcsname}% + \ifcsundef{thirdprevdegree@\theauthorno}{\relax}{\linebreak\normalsize\csname thirdprevdegree@\theauthorno\endcsname}% + \ifcsundef{fourthprevdegree@\theauthorno}{\relax}{\linebreak\normalsize\csname fourthprevdegree@\theauthorno\endcsname}% \par and\par \addtocounter{authorno}{1}% }% \ignorespaces\csname aut@\theauthorno\endcsname \ifcsundef{prevdegree@\theauthorno}{\relax}{\par\normalsize\csname prevdegree@\theauthorno\endcsname}% - \ifcsundef{secondprevdegree@\theauthorno}{\relax}{\\ \normalsize\csname secondprevdegree@\theauthorno\endcsname}% - \ifcsundef{thirdprevdegree@\theauthorno}{\relax}{\\ \normalsize\csname thirdprevdegree@\theauthorno\endcsname}% - \ifcsundef{fourthprevdegree@\theauthorno}{\relax}{\\ \normalsize\csname fourthprevdegree@\theauthorno\endcsname}% - \\[1em]% + \ifcsundef{secondprevdegree@\theauthorno}{\relax}{\linebreak \normalsize\csname secondprevdegree@\theauthorno\endcsname}% + \ifcsundef{thirdprevdegree@\theauthorno}{\relax}{\linebreak \normalsize\csname thirdprevdegree@\theauthorno\endcsname}% + \ifcsundef{fourthprevdegree@\theauthorno}{\relax}{\linebreak \normalsize\csname fourthprevdegree@\theauthorno\endcsname}% + \par\medskip }% } @@ -391,8 +391,9 @@ \newcounter{degcnt} \setcounter{degcnt}{0} - -\NewDocumentCommand\Degree{mm}{% +\newcounter{depflag} +\setcounter{depflag}{0} +\NewDocumentCommand\Degree{mm}{% Revised 2023/06/23 \ifblank{#1}{% \ClassError{\ClassName}{Missing degree name, check for blank \Degree{name}{department} command}{% Check for blank name \Degree{name}{department} command.}% @@ -401,34 +402,39 @@ \expandafter\xdef\csname deg@\thedegcnt\endcsname{\ignorespaces#1}% \expandafter\xdef\csname degdep@\thedegcnt\endcsname{\ignorespaces#2}% }% - \ifblank{#2}{\ClassError{\ClassName}{Missing degree department, check for blank in \Degree{name}{department} command}{% - Check for blank department \Degree{name}{department} command.}}{}% + \ifblank{#2}{% + \setcounter{depflag}{\value{degcnt}}% + \ClassWarning{\ClassName}{Missing degree department for Degree command number \thedegcnt. Assuming to be a duplicate of previous department}}{}% }% defines \deg@degcnt as Name #1 and \degdep@degcnt as associated dept. \newcounter{degno} \newcounter{depno} - -\NewDocumentCommand\@DegreeBlock{}{% +\NewDocumentCommand\@DegreeBlock{}{% extensive revision 2023/06/23 \ifnum\value{degcnt}=0 \ClassError{\ClassName}{Missing degree! You must issue the \Degree{name}{department} command}{% You MUST issue the \Degree{name}{department} command after \begin{document} and before \maketitle. You do want the degree, don't you?}% \fi \setcounter{degno}{1} \setcounter{depno}{1} - Submitted to the% + \newcommand*\PrevDept{\csname degdep@\thedepno\endcsname} + \newcommand*\CurrDept{} + Submitted to the \mbox{\PrevDept}% \whiledo{\value{depno}<\value{degcnt}}{% - \space\csname degdep@\thedegno\endcsname{} and the% \addtocounter{depno}{1}% + \renewcommand*\CurrDept{\csname degdep@\thedepno\endcsname}% + \ifnum\value{depflag}=\value{depno}\relax\else + \space and the\linebreak + \mbox{\CurrDept}% + \fi% }% - \space\csname degdep@\thedepno\endcsname\space - in partial fulfillment of the requirements for the\space - \ifnum\value{degcnt}>1 degrees\else degree\fi\space of% - \par + \linebreak \mbox{in partial fulfillment of the requirements for the\space + \ifnum\value{degcnt}>1 degrees\else degree\fi\space of}% + \par\medskip \whiledo{\value{degno}<\value{degcnt}}{% \MakeUppercase{\ignorespaces\csname deg@\thedegno\endcsname}\par and\par \addtocounter{degno}{1}% }% - \MakeUppercase{\ignorespaces\csname deg@\thedegno\endcsname}\par + \MakeUppercase{\ignorespaces\csname deg@\thedegno\endcsname}\par\medskip } \newcounter{supcnt} @@ -453,9 +459,10 @@ \setcounter{acccnt}{0} \newcounter{accno} \setcounter{accno}{0} +\newif\ifmit@noacctitle\mit@noacctitlefalse % Revised 2023/06/23 \NewDocumentCommand\Acceptor{mmm}{% \ifblank{#1}{% - \ClassWarning{\ClassName}{Missing acceptor name, check for blank \Acceptor{name}{department} command}% + \ClassWarning{\ClassName}{Missing acceptor name, check for blank in \Acceptor{name}{department}{title} command}% }{% \addtocounter{acccnt}{1}% \expandafter\xdef\csname acc@\theacccnt\endcsname{#1}% @@ -463,15 +470,18 @@ \expandafter\xdef\csname acctitle@\theacccnt\endcsname{#3}% }% \ifblank{#2}{\ClassWarning{\ClassName}{Missing acceptor department, check for blank in \Acceptor{name}{department}{title} command.}}{}% - \ifblank{#3}{\ClassWarning{\ClassName}{Missing acceptor title, check for blank in \Acceptor{name}{department}{title} command.}}{}% + \ifblank{#3}{% + \mit@noacctitletrue + \ClassWarning{\ClassName}{Missing acceptor title (blank in \Acceptor{name}{department}{title} command). Perhaps you are trying to save vertical space? You can put the acceptor title into department field instead. For consistency, I will omit titles of ALL acceptors.}% + }{}% }% defines \acc@acccnt as Name #1, \accdep@accccnt as associated dept, and \acctitle@acccnt as title of acceptor -\def\@SigSize{\relax} -\NewDocumentCommand\SignatureBlockSize{m}{\let\@SigSize\ignorespaces#1} +\newcommand*\@SigSize{\relax} +\NewDocumentCommand\SignatureBlockSize{m}{\renewcommand\@SigSize{\ignorespaces#1}}% revised 2023/06/23 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\NewDocumentCommand\@SetSignatureBlock{}{% +\NewDocumentCommand\@SetSignatureBlock{}{% Revised 2023/06/23 \ifnum\value{supcnt}=0 \ClassError{\ClassName}{Missing supervisor! You must issue the \Supervisor{name}{department} command}{% You MUST issue the \Supervisor{name}{department} command after \begin{document} and before \maketitle.}% @@ -491,33 +501,37 @@ \hspace{1.35in}\=\hspace{1in}\kill \whiledo{\value{authorno}<\value{authorcnt}}{% starting with authorno = 0 ensures we reach authorcnt with +1 \addtocounter{authorno}{1}% - Authored by: \> \csname aut@\theauthorno\endcsname\ignorespaces \\ - \> \csname autdep@\theauthorno\endcsname\ignorespaces \\ + Authored by: \> \csname aut@\theauthorno\endcsname\\% remove \ignorespaces x9, 2023/06/23 + \> \csname autdep@\theauthorno\endcsname\\ \> \@ThesisDate \\[1em] }% end whiledo \whiledo{\value{supno}<\value{supcnt}}{% \addtocounter{supno}{1}% - Certified by: \> \csname sup@\thesupno\endcsname\ignorespaces \\ - \> \csname supdep@\thesupno\endcsname\ignorespaces, Thesis Supervisor\\[1em] + Certified by: \> \csname sup@\thesupno\endcsname\\ + \> \csname supdep@\thesupno\endcsname, Thesis Supervisor\\[1em] }% end whiledo \whiledo{\value{accno}<\value{acccnt}}{% \addtocounter{accno}{1}% - Accepted by: \> \csname acc@\theaccno\endcsname\ignorespaces \\ - \> \csname accdep@\theaccno\endcsname\ignorespaces \\ - \> \csname acctitle@\theaccno\endcsname\ignorespaces \\[1em] + Accepted by: \> \csname acc@\theaccno\endcsname\\ + \> \csname accdep@\theaccno\endcsname + \ifmit@noacctitle\else %<=== 2023/06/23 + \\ + \> \csname acctitle@\theaccno\endcsname + \fi + \\[1em] }% end whiledo \end{tabbing} } -\NewDocumentCommand\@SetAbstractSupervisorBlock{}{% +\NewDocumentCommand\@SetAbstractSupervisorBlock{}{% revised 2023/06/23 \setcounter{supno}{1} -% \\[1em]% dislikes a trailing blank line in abstract + \setlength{\parindent}{0pt} \par\bigskip\noindent \whiledo{\value{supno}<\value{supcnt}}{% - Thesis supervisor: \csname sup@\thesupno\endcsname\ignorespaces\\ - Title: \csname supdep@\thesupno\endcsname\ignorespaces\\[1em] + Thesis supervisor: \csname sup@\thesupno\endcsname\par + Title: \csname supdep@\thesupno\endcsname\par\medskip \addtocounter{supno}{1}% }% end whiledo - Thesis supervisor: \csname sup@\thesupno\endcsname\ignorespaces\\ + Thesis supervisor: \csname sup@\thesupno\endcsname\par Title: \csname supdep@\thesupno\endcsname\ignorespaces } @@ -544,7 +558,7 @@ \fi % \ifmit@cclicense - \def\CopyrightLicense{This work is licensed under a \CClicensetext\ license.\par\MITpermission} + \def\CopyrightLicense{This work is licensed under a \mbox{\CClicensetext} license.\par\MITpermission}% add mbox 2023/06/23 \typeout{^^JUsing Creative Commons License \CCname^^J} \def\PDFRightsText{This work is licensed under a \CCname\ license. \MITpermission}% for use in metadata \else @@ -561,7 +575,6 @@ \thispagestyle{empty}% \phantomsection\addcontentsline{toc}{chapter}{\protect\textbf{Title page}}% {\centering\vbox to \vsize{% vbox to prevent signature block from breaking across page. Remove if necessary. - %\ifmit@lineno\internallinenumbers\fi % lineno does not work in tabbing environment, as in signature block \setlength{\parskip}{0.5\baselineskip plus 2pt minus 2pt}\setlength{\parindent}{0pt}% {\Large\textbf{\@title}\par}% \@AuthorBlock @@ -577,7 +590,7 @@ \par \copyright\space\@DegreeYear\space\@CopyrightAuthor. \CopyrightLicense \par - \vskip 1.5\baselineskip + \vskip\baselineskip % \@SetSignatureBlock \vfill |