From a99b5814a273c055a8d1e1e17eceaadceeddeca5 Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Fri, 4 Jun 2010 15:43:48 -0400 Subject: [PATCH] Added daring, ifdaring, "Advisor(s):" and bumped to v0.11. I'm all for optionally breaking rules, so here's a new switch to control this sort of thing. I imagine there will be more daring hacks in the future... From: Evan Sultanik Subject: Advisors in the Thesis Abstract Date: Fri, 04 Jun 2010 14:49:12 -0400 how the advisors are listed in the abstract. "Shouldn't there be the word 'Advisor:' or something before the names to differentiate the advisor(s) from the student?" I assured him that this was done to conform to the official Drexel thesis manual. However... I took a look at how I typeset my MS thesis (back in 2006) and I did put the word "Advisor: " before listing my advisor. Perhaps I broke the rules then, and I am probably going to break them again for my Ph.D. Here's what I did: On line 195 of drexel-thesis.cls, right before "\newcounter{advisor@loop}", I added the following: Advisor\ifnum\c@advisors>1s\fi: % That seemed to do the trick. I am not sure how you feel about breaking such rules, but I would highly recommend merging it into the master :-) - Evan --- drexel-thesis.dtx | 52 +++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 48 insertions(+), 4 deletions(-) diff --git a/drexel-thesis.dtx b/drexel-thesis.dtx index b6ecea1..e4612e4 100644 --- a/drexel-thesis.dtx +++ b/drexel-thesis.dtx @@ -1,13 +1,13 @@ -% \def\fileversion{0.10} -% \def\filedate{2010/05/21} +% \def\fileversion{0.11} +% \def\filedate{2010/06/04} % \iffalse meta-comment %<*driver> \ProvidesFile{drexel-thesis.dtx} \documentclass{ltxdoc} % %<*class|driver> -\def\fileversion{0.10} -\def\filedate{2010/05/21} +\def\fileversion{0.11} +\def\filedate{2010/06/04} % % % Copyright (C) 2010 C.Y. Ip @@ -276,6 +276,10 @@ % \Lopt{fleqn} typesets displayed formulae left-aligned instead of % centered. % +% \DescribeOption{daring} +% \Lopt{daring} breaks the official thesis rules in pursuit of a nicer +% layout. +% % % \subsection{Macros} % @@ -462,6 +466,16 @@ % We're in \iffinal{final}{draft} mode! % \end{example} % +% \begin{command} +% `\cs{ifdaring}\marg{daring-action}\marg{wimpy-action}' +% \end{command} +% \DescribeMacro{\ifdaring} +% \DescribeMacro{\DUTifdaring} +% Include \Lopt{daring}-specific code, with wimpy fallbacks. +% \begin{example} +% \ifdaring{\singlespacing Muahahahaha!}{mumble mumble}. +% \end{example} +% % % \subsection{Environments} % @@ -726,6 +740,7 @@ \newif\if@mydraftwatermark \newif\if@indentfirst \newif\if@final +\newif\if@daring % \end{macrocode} % % \begin{macro}{\iffinal} @@ -737,6 +752,15 @@ % \end{macrocode} % \end{macro} % +% \begin{macro}{\ifdaring} +% Setup a user-friendly means for including \Lopt{daring}-specific +% code. +% \changes{0.11}{2010/06/04}{W.~Trevor King added macro.} +% \begin{macrocode} +\newcommand\ifdaring[2]{\if@daring #1\else #2\fi} +% \end{macrocode} +% \end{macro} +% % \begin{option}{subfig} % Set \Lopt{subfig} flag % \begin{macrocode} @@ -877,6 +901,14 @@ % \end{macrocode} % \end{option} % +% \begin{option}{daring} +% \begin{macrocode} +\DeclareOptionX{daring}{ + \@daringtrue +} +% \end{macrocode} +% \end{option} +% % Use the default \cls{book} implementation for any remaining options % including \Lopt{oneside}, \Lopt{twoside}, \Lopt{leqno}, \Lopt{fleqn}, % \ldots. @@ -2447,6 +2479,18 @@ \setstretch{\@ssp}% \@DUT@title\\ \@DUT@author\\ +% \end{macrocode} +% If you're feeling daring, break the rules and add ``Advisor(s):'' to +% set off your list of advisor names. +% \changes{0.11}{2010/06/04}{W.~Trevor King added ``Advisor(s):'' for +% daring users.} +% \begin{macrocode} + \ifdaring{% + \ifnum\c@@DUT@advisors=\@ne% + Advisor: + \else% + Advisors: + \fi}{} \@DUT@advisor\\ \end{center} \blanklines{4}% -- 2.26.2