Added daring, ifdaring, "Advisor(s):" and bumped to v0.11. 0.11
authorW. Trevor King <wking@drexel.edu>
Fri, 4 Jun 2010 19:43:48 +0000 (15:43 -0400)
committerW. Trevor King <wking@drexel.edu>
Fri, 4 Jun 2010 19:43:48 +0000 (15:43 -0400)
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

index b6ecea11700411ddd34d4571dfb45564d7a099d6..e4612e4f8f540b333a99f49f6ce5cb794ec852f1 100644 (file)
@@ -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}
 %</driver>
 %<*class|driver>
-\def\fileversion{0.10}
-\def\filedate{2010/05/21}
+\def\fileversion{0.11}
+\def\filedate{2010/06/04}
 %</class|driver>
 %
 % Copyright (C) 2010  C.Y. Ip
 % \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}
 %
 %   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}
 %
 \newif\if@mydraftwatermark
 \newif\if@indentfirst
 \newif\if@final
+\newif\if@daring
 %    \end{macrocode}
 %
 % \begin{macro}{\iffinal}
 %    \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}
 %    \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.
       \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}%