Add compiled versions of the examples along with our useful files built
authorW. Trevor King <wking@tremily.us>
Tue, 21 Oct 2014 04:47:16 +0000 (21:47 -0700)
committerW. Trevor King <wking@tremily.us>
Tue, 21 Oct 2014 04:56:50 +0000 (21:56 -0700)
With:

  $ make all dist
  $ git add .
  $ git commit

The useful files are copied from the dependencies of my Gentoo package
[1].  Upstream source for each of them is on the Gentoo mirrors.  The
actual packages used for this particular commit are:

  dev-texlive/texlive-latexrecommended-2012-r1
  dev-texlive/texlive-latexextra-2012
  dev-tex/draftmark-9999 (also from my overlay [2,3])
  dev-tex/xcolor-2.11

[1]: http://git.tremily.us/?p=wtk-overlay.git;a=blob;f=drexel-thesis-9999.ebuild;h=9a240faefabc57e5c385865e997a85f264e7f9d7;hb=8b7591f2cd7a3917ff95c338c389dd983e3f2d55#l26
[2]: http://git.tremily.us/?p=wtk-overlay.git;a=blob;f=draftmark-9999.ebuild;h=3b6b29efec10843930dec952841fc5726d4d6897;hb=6eb4b9b2c9145dcaf26a3b8ca5641c966b2831cd
[3]: http://mirror.ctan.org/macros/latex/contrib/draftmark.zip

23 files changed:
blindtext.sty [new file with mode: 0644]
draftmark.sty [new file with mode: 0644]
drexel-thesis.cls [new file with mode: 0644]
drexel-thesis.pdf [new file with mode: 0644]
drexel-thesis.tar.gz [new file with mode: 0644]
etextools.sty [new file with mode: 0644]
etoolbox.sty [new file with mode: 0644]
example-1.tex [new file with mode: 0644]
example-a.tex [new file with mode: 0644]
example-draft.pdf [new file with mode: 0644]
example-draft.tex [new file with mode: 0644]
example-ref.bib [new file with mode: 0644]
example.pdf [new file with mode: 0644]
example.tex [new file with mode: 0644]
floatrow.sty [new file with mode: 0644]
forloop.sty [new file with mode: 0644]
fr-subfig.sty [new file with mode: 0644]
lastpage.sty [new file with mode: 0644]
ltxnew.sty [new file with mode: 0644]
pagerange.sty [new file with mode: 0644]
template.tex [new file with mode: 0644]
tocloft.sty [new file with mode: 0644]
xifthen.sty [new file with mode: 0644]

diff --git a/blindtext.sty b/blindtext.sty
new file mode 100644 (file)
index 0000000..69ade59
--- /dev/null
@@ -0,0 +1,1213 @@
+%%
+%% This is file `blindtext.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% blindtext.dtx  (with options: `package')
+%% blindtext_american.dtx  (with options: `package')
+%% blindtext_catalan.dtx  (with options: `package')
+%% blindtext_english.dtx  (with options: `package')
+%% blindtext_french.dtx  (with options: `package')
+%% blindtext_german.dtx  (with options: `package')
+%% blindtext_latin.dtx  (with options: `package')
+%% blindtext_ngerman.dtx  (with options: `package')
+%% blindtext.dtx  (with options: `packageend')
+%% ----------------------------------------------------------------------
+%% The original file is loadable from CTAN on:
+%% tex-archive/latex/contrib/blindtext
+%% 
+%% Name of contribution: blindtext
+%% Name and email:       Knut Lickert <knut@lickert.net>
+%% Location on CTAN:     tex-archive/macros/latex/contrib/blindtext
+%% Summary description:  Package for writing text
+%% License type:         Free
+%% 
+%% Announcement text:
+%% blindtext.sty:
+%%     Style to create text.
+%%     Can be used to create examples with a lot text to become a feeling
+%%     for the look of classes, packages...
+%% 
+%%     There are macros to create dummy text, dummy lists and
+%%     dummy documents with sections, text and lists.
+%% 
+%% For more information visit
+%%     http://tex.lickert.net/packages/blindtext/index.html
+%% ----------------------------------------------------------------------
+\def\blindfileversion{V2.0}
+\def\blindfiledate{2012/01/06}
+%%
+%% \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
+%%   Digits        \0\1\2\3\4\5\6\7\8\9
+%%   Exclamation   \!     Double quote  \"     Hash (number) \#
+%%   Dollar        \$     Percent       \%     Ampersand     \&
+%%   Acute accent  \'     Left paren    \(     Right paren   \)
+%%   Asterisk      \*     Plus          \+     Comma         \,
+%%   Minus         \-     Point         \.     Solidus       \/
+%%   Colon         \:     Semicolon     \;     Less than     \<
+%%   Equals        \=     Greater than  \>     Question mark \?
+%%   Commercial at \@     Left bracket  \[     Backslash     \\
+%%   Right bracket \]     Circumflex    \^     Underscore    \_
+%%   Grave accent  \`     Left brace    \{     Vertical bar  \|
+%%   Right brace   \}     Tilde         \~}
+%%
+
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesPackage{blindtext}[\blindfiledate\space\blindfileversion\space%
+                 blindtext-Package]
+\RequirePackage{xspace}
+\providecommand{\grqq}{}
+\providecommand{\glqq}{}
+\newcommand{\blind@checklanguage}{%
+  \@ifundefined{blindtext@\languagename}{%
+    \PackageWarning{blindtext}{\languagename\space not
+      defined, using English instead.\MessageBreak
+    }%
+  }{}%
+}
+\newcounter{blindtext}\setcounter{blindtext}{1}
+\newcounter{Blindtext}\setcounter{Blindtext}{5}
+\newcounter{blind@countparstart}
+\newcount\blind@countxx
+\newcommand{\blindtext}[1][\value{blindtext}]{%
+  \blind@checklanguage
+  \setcounter{blind@randommax}{#1}%for option random
+  \setcounter{blind@pangrammax}{#1}%for option pangram
+  \blind@countxx=1 %
+  \loop
+    \blindtext@text\
+  \ifnum\blind@countxx<#1\advance\blind@countxx by 1 %
+  \repeat
+}
+\newcount\blindtext@numBlindtext
+\newcommand{\Blindtext}[1][\value{Blindtext}]{%
+  \blind@checklanguage
+  \blindtext@numBlindtext=#1\relax
+  \blind@Blindtext
+}
+\newcount\blind@countyy
+\newcommand{\blind@Blindtext}[1][\value{blindtext}]{%
+  \blind@countyy=1 %
+  \loop
+    {\blindtext@parstart\blindtext[{#1}]\blindtext@parend\par}%
+  \ifnum\blind@countyy<\blindtext@numBlindtext\advance\blind@countyy by 1 %
+  \repeat
+}
+\newcommand{\blindtext@parstart}{}   % Text at start of paragraph
+\newcommand{\blindtext@parend}{}     % Text at end   of paragraph
+\newcommand{\parstart}[1]{\renewcommand{\blindtext@parstart}{#1}}
+\newcommand{\parend}[1]{\renewcommand{\blindtext@parend}{#1}}
+\newif\ifblind@long\blind@longfalse
+\newif\ifblind@optional\blind@optionalfalse
+\newcounter{blindlist}
+\newcounter{blindlistlevel}% Up tu X level
+\newcounter{blindlist@level}% internal counter
+\newcount\blind@listitem
+%% ^^A-----------------------------------------------------------
+\newcommand{\blindlist}[1]{%
+  \blind@checklanguage
+  \def\blind@listtype{#1}%
+  \setcounter{blind@levelcount}{1}%
+  \blind@list
+}
+\newcommand{\blind@list}[1][5]{%
+  \setcounter{blindlist}{#1}%
+  \stepcounter{blindlist@level}% depth of list
+  \blind@listitem=1 %
+  \begin{\blind@listtype}%
+    \blind@items
+  \end{\blind@listtype}%
+  \blind@longfalse
+  \blind@optionalfalse
+}
+\newcommand{\blindlistlist}[2][4]{%
+  \setcounter{blindlistlevel}{#1}%
+  \setcounter{blindlist@level}{0}% deepest reached level
+  \setcounter{blind@levelcount}{1}% actual level for printout
+  \def\blind@listtype{#2}%
+  \blind@list
+}
+\newcommand{\blindlistlistoptional}{%
+  \blind@optionaltrue
+  \blindlistlist
+}
+\newcommand{\blinditemize}{\blindlist{itemize}}
+\newcommand{\blindenumerate}{\blindlist{enumerate}}
+\newcommand{\Blindlist}[1]{%
+  \blind@longtrue
+  \blindlist{#1}%
+}
+\newcommand{\Blinditemize}{\Blindlist{itemize}}
+\newcommand{\Blindenumerate}{\Blindlist{enumerate}}
+\newcommand{\blindlistoptional}[1]{%
+  \blind@optionaltrue
+  \blindlist{#1}%
+}
+\newcommand{\Blindlistoptional}[1]{%
+  \blind@optionaltrue
+  \blind@longtrue
+  \blindlist{#1}%
+}
+\newcommand{\blinddescription}{\blindlistoptional{description}}
+\newcommand{\Blinddescription}{\Blindlistoptional{description}}
+\newcounter{blind@listcount}
+\newcounter{blind@levelcount}
+\newcommand{\blind@items}{%
+  \setcounter{blind@listcount}{1}%
+  \loop
+  \ifblind@optional
+    \ifblind@long
+      \item[\blindtext@countitem] \blindtext@text
+    \else
+      \item[\blindtext@count] \blindtext@item
+    \fi
+    \else % \blind@optionalfalse
+      \ifblind@long
+        \item \blindtext@text
+      \else
+        \item \blindtext@countitem
+      \fi
+    \fi % \ifblind@optional
+    {%
+      \loop
+      \ifnum\value{blindlistlevel}>\value{blindlist@level}%
+        \stepcounter{blind@levelcount}%
+        \blind@list[\value{blindlist}]\relax
+        \addtocounter{blind@levelcount}{-1}%
+        \setcounter{blind@listcount}{1}%
+      \repeat
+    }%
+  \ifnum\value{blind@listcount}<\value{blindlist}%
+    \stepcounter{blind@listcount}%
+  \repeat
+}
+%% ^^A-----------------------------------------------------------
+\newcommand{\blindmarkup}[1]{#1}
+%% ^^A-----------------------------------------------------------
+  \def\blindtext@endsentence{.\xspace}%
+  \newcount{\blind@mathformula}\blind@mathformula=0%
+\newif\ifblindmath
+\let\oldblindmathtrue\blindmathtrue
+\renewcommand{\blindmathtrue}{
+    \oldblindmathtrue
+  \def\blindtext@endsentence{%
+    \advance\blind@mathformula by 1%
+    \ifcase\blind@mathformula%
+    \or. \(\sin^2(\alpha) + \cos^2(\beta) = 1\)%
+    \or\xspace\(E = mc^2\)%
+    \or. \(\sqrt[n]{a} \cdot \sqrt[n]{b} =  \sqrt[n]{ab}\)%
+    \or. \(\frac{\sqrt[n]{a}}{\sqrt[n]{b}} =  \sqrt[n]{\frac{a}{b}}\)%
+    \or. \(a\sqrt[n]{b} = \sqrt[n]{a^n b}\)%
+    \or. \(\mathrm{d}\Omega = \sin \vartheta \mathrm{d} \vartheta \mathrm{d}\varphi\)%
+    \else\global\blind@mathformula=0%
+    \fi%
+    .\xspace}%
+  }%\blindmathtrue
+\let\oldblindmathfalse\blindmathfalse
+\renewcommand{\blindmathfalse}{
+    \oldblindmathfalse
+  \def\blindtext@endsentence{.\xspace}%
+}%\includemath
+  \newcount{\blind@Mathformula}
+  \blind@Mathformula=0%
+  \def\blindtext@formula{%
+    \advance\blind@Mathformula by 1%
+    \ifcase\blind@Mathformula%
+        \[\bar x = \frac{1}{n}\sum_{i=1}^{i=n} x_i = \frac{x_1 + x_2 + \dots{} + x_n}{n}\]
+    \or \[ \int_0^\infty e^{-\alpha x^2} \mathrm{d}x =
+            \frac12\sqrt{\int_{-\infty}^\infty e^{-\alpha x^2}}
+            \mathrm{d}x\int_{-\infty}^\infty e^{-\alpha y^2}\mathrm{d}y =
+            \frac12\sqrt{\frac{\pi}{\alpha}} \]
+    \or \[ \sum_{k=0}^\infty a_0q^k = \lim_{n\to\infty}\sum_{k=0}^n a_0q^k =
+            \lim_{n\to\infty} a_0\frac{1-q^{n+1}}{1-q} = \frac{a_0}{1-q}
+        \]
+    \or \[x_{1,2}=\frac{-b \pm \sqrt{b^2-4ac}}{2a} = \frac{-p \pm \sqrt{p^2-4q}}{2}\]
+    \or \[ \frac{\partial^2 \Phi}{\partial x^2} + \frac{\partial^2 \Phi}{\partial y^2} +
+            \frac{\partial^2 \Phi}{\partial z^2} =
+            \frac{1}{c^2}\frac{\partial^2\Phi}{\partial t^2}
+        \]
+    \or \[\sqrt[n]{a} \cdot \sqrt[n]{b} =  \sqrt[n]{ab}\]
+    \or \[\frac{\sqrt[n]{a}}{\sqrt[n]{b}} =  \sqrt[n]{\frac{a}{b}}\]
+    \or \[a\sqrt[n]{b} = \sqrt[n]{a^n b}\]
+    \global\blind@Mathformula=0%
+    \fi%
+}%
+%% ^^A-----------------------------------------------------------
+\newif\ifblindtoc
+\blindtocfalse
+\newcommand{\blinddocument}{%
+  \ifblindtoc\tableofcontents\fi
+  \@ifundefined{chapter}{}{%
+    \chapter{\blindtext@heading 0 (chapter)}%
+    \blindtext
+  }%
+  \section{\blindtext@heading 1 (section)}%
+    \blindtext
+  \subsection{\blindtext@heading 2 (subsection)}%
+    \blindtext
+  \subsubsection{\blindtext@heading 3 (subsubsection)}%
+    \blindtext
+  \paragraph{\blindtext@heading 4 (paragraph)}%
+    \blindtext
+  \section{\blindtext@list}%
+  \subsection{\blindtext@listEx (itemize)}%
+    \blinditemize
+  \subsubsection{\blindtext@listEx (4*itemize)}%
+    \blindlistlist{itemize}[2]%
+  \subsection{\blindtext@listEx (enumerate)}%
+    \blindenumerate
+  \subsubsection{\blindtext@listEx (4*enumerate)}%
+    \blindlistlist{enumerate}[2]%
+  \subsection{\blindtext@listEx (description)}%
+    \blinddescription
+  \subsubsection{\blindtext@listEx (4*description)}%
+    \blindlistlistoptional{description}[2]%
+}
+\newcommand{\Blinddocument}{%
+  \ifblindtoc\tableofcontents\fi
+  \@ifundefined{chapter}{}{%
+    \chapter{\blindtext@heading 0 (chapter)}%
+    \blindtext
+  }%
+  \section{\blindtext@heading 1 (section)}%
+    \Blindtext
+  \subsection{\blindtext@heading 2 (subsection)}%
+    \Blindtext
+  \subsubsection{\blindtext@heading 3 (subsection)}%
+    \Blindtext
+  \paragraph{\blindtext@heading 4 (paragraph)}%
+    \Blindtext
+  \section{\blindtext@list}%
+  \subsection{\blindtext@listEx (itemize)}%
+    \Blinditemize
+  \subsubsection{\blindtext@listEx (4*itemize)}%
+    \blind@longtrue
+    \blindlistlist{itemize}[2]%
+  \subsection{\blindtext@listEx (enumerate)}%
+    \Blindenumerate
+  \subsubsection{\blindtext@listEx (4*enumerate)}%
+    \blind@longtrue
+    \blindlistlist{enumerate}[2]%
+  \subsection{\blindtext@listEx (description)}%
+    \Blinddescription
+  \subsubsection{\blindtext@listEx (4*description)}%
+    \blind@longtrue
+  \blindlistlistoptional{description}[2]%
+  %
+  \ifblindmath
+      \section{\blindtext@blindmath}%
+      \blindmathpaper%
+  \fi%
+}
+\newcommand{\blindmathpaper}{
+\blindtext
+\blindtext@formula
+\blindtext
+\blindtext@formula
+\blindtext
+\blindtext@formula
+\blindtext
+\blindtext@formula
+\blindtext
+\blindtext@formula
+\blindtext\relax%
+}%\blindmathpaper
+\newif\ifblindbible
+\DeclareOption{bible}{
+  \blindbibletrue
+}
+\newif\ifblindrandom
+\newcounter{blind@randomcount}\setcounter{blind@randomcount}{0}
+\newcounter{blind@randommax}
+\DeclareOption{random}{
+\blindrandomtrue
+}
+\newif\ifblindpangram
+\newcounter{blind@pangramcount}\setcounter{blind@pangramcount}{0}
+\newcounter{blind@pangrammax}
+\DeclareOption{pangram}{
+\blindpangramtrue
+}
+\DeclareOption{math}{
+    \blindmathtrue
+}
+\DeclareOption{toc}{
+    \blindtoctrue
+}
+\ProcessOptions\relax
+%% ^^A-----------------------------------------------------------
+\newcommand{\blind@addtext}[2]{%
+    \@ifpackageloaded{babel}{
+        \expandafter\addto\csname extras#1\endcsname{#2}
+    }{}%
+    \@ifpackageloaded{polyglossia}{
+        \expandafter\gappto\csname captions#1\endcsname {#2}
+    }{}%
+    \@ifpackageloaded{ngerman}{
+        \expandafter\g@addto@macro\csname captions#1\endcsname {#2}
+    }{}%
+    \@ifpackageloaded{german}{
+        \expandafter\g@addto@macro\csname captions#1\endcsname {#2}
+    }{}%
+}%\blind@addtext
+\def\blindtext@text{%
+    Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Etiam
+    lobortis facilisis sem. Nullam nec mi et neque pharetra
+    sollicitudin. Praesent imperdiet mi nec ante. Donec ullamcorper,
+    felis non sodales commodo, lectus velit ultrices augue, a
+    dignissim nibh lectus placerat pede. Vivamus nunc nunc, molestie
+    ut, ultricies vel, semper in, velit. Ut porttitor. Praesent in
+    sapien. Lorem ipsum dolor sit amet, consectetuer adipiscing elit.
+    Duis fringilla tristique neque. Sed interdum libero ut metus.
+    Pellentesque placerat. Nam rutrum augue a leo. Morbi sed elit sit
+    amet ante lobortis sollicitudin. Praesent blandit blandit mauris.
+    Praesent lectus tellus, aliquet aliquam, luctus a, egestas a,
+    turpis. Mauris lacinia lorem sit amet ipsum. Nunc quis urna dictum
+    turpis accumsan semper.%
+}
+\def\blindtext@count{%
+  \ifcase\blind@listitem\or
+    First\or Second%...
+  \else
+    Last%
+    \blind@listitem=0 %
+  \fi
+  \global\advance\blind@listitem by 1 %
+}% \blindtext@count
+\def\blindtext@item{itemtext}
+\def\blindtext@countitem{\blindtext@count\ \blindtext@item}
+\def\blindtext@heading{Heading on level\xspace}
+\def\blindtext@list{Lists}
+\def\blindtext@listEx{Example for list\xspace}
+\def\blindtext@blindmath{Some blind text with math formulas}
+\def\blindtext@american{}
+\blind@addtext{american}{%
+  \def\blindtext@text{%
+    Hello, here is some text without a meaning\blindtext@endsentence
+    This text should show what a printed text will look like at this
+    place\blindtext@endsentence If you read this text, you will get no
+    information\blindtext@endsentence Really? Is there no information?
+    Is there a difference between this text and some nonsense like
+    ``Huardest gefburn''? Kjift -- not at all! A blind text
+    \blindmarkup{like this} gives you information  about the selected
+    font, how the letters are written and an impression  of the
+    look\blindtext@endsentence This text should contain \blindmarkup{all
+    letters of the alphabet} and it should be written in of the original
+    language\blindtext@endsentence There is no need for special
+    contents, but the length of words should match the
+    language\blindtext@endsentence%
+  }% \blindtext@text
+}
+\blind@addtext{american}{%
+  \def\blindtext@parstart{%
+      \ifcase\value{blind@countparstart}\or
+This is the second paragraph.\or
+And after the second paragraph follows the third paragraph.\or
+After this fourth paragraph, we start a new paragraph sequence.\or
+        \setcounter{blind@countparstart}{0}
+      \fi
+      \stepcounter{blind@countparstart}
+  }% \blindtext@parstart
+}
+\blind@addtext{american}{%
+  \def\blindtext@count{%
+    \ifcase\value{blind@listcount}\or
+      First\or Second\or Third\or Fourth\or Fifth\or
+      Sixth\or Seventh\or Eighth\or Ninth\or Tenth\or
+      Eleventh\or Twelfth%
+    \else
+      Another%
+    \fi
+  }% \blindtext@count
+  \def\blindtext@item{item in a list}%
+}%\addto\extrasamerican
+\blind@addtext{american}{%
+  \def\blindtext@heading{Heading on level\xspace}%
+  \def\blindtext@list{Lists}%
+  \def\blindtext@listEx{Example for list\xspace}%
+}%\addto\extrasamerican
+\blind@addtext{american}{%
+    \def\blindtext@blindmath{Some blind text with math formulas}%
+}%\addto\extrasamerican
+\ifblindbible
+\blind@addtext{american}{%
+  \def\blindtext@text{%
+    And the Lord God said unto the serpent, Because thou hast done this,
+    thou art cursed above all cattle, and above every beast of the
+    field; upon thy belly shalt thou go, and dust shalt thou eat all the
+    days of thy life:
+    And God said unto Moses, `I am that I am': and he said, Thus shalt
+    thou say unto the children of Israel, `I am' hath sent me unto you.
+    And he shall offer thereof his offering, even an offering made by
+    fire unto the Lord; the fat that covereth the inwards, and all the
+    fat that is upon the inwards,\ldots
+    And the Lord spake unto Moses in the wilderness of Sinai,
+    saying,\ldots
+    Jair the son of Manasseh took all the country of Argob unto the
+    coasts of Geshuri and Maachathi; and called them after his own name,
+    Bashanhavothjair, unto this day.%
+  }% \blindtext@text
+  \def\blindtext@parstart{}%no change for bible option
+}
+\fi %\ifbible
+\ifblindrandom
+  \PackageWarning{blindtext}{Option random not defined for american\MessageBreak}%
+  \blind@addtext{american}{%
+    \setcounter{blindtext}{1}
+  }
+\fi %option random
+\ifblindpangram
+\blind@addtext{american}{%
+    \setcounter{blindtext}{5}
+    \def\blindtext@text{%
+    \blind@countxx=1 %
+    \loop
+      \ifcase\value{blind@pangramcount}%
+The quick brown fox jumps over the lazy dog\blindtext@endsentence
+\or Jackdaws love my big Sphinx of Quartz\blindtext@endsentence
+\or Pack my box with five dozen liquor jugs\blindtext@endsentence
+\or The five boxing wizards jump quickly\blindtext@endsentence
+\or Sympathizing would fix Quaker objectives\blindtext@endsentence
+\or Many-wived Jack laughs at probes of sex quiz\blindtext@endsentence
+\or Turgid saxophones blew over Mick's jazzy quaff\blindtext@endsentence
+\or Playing jazz vibe chords quickly excites my
+wife\blindtext@endsentence
+\or A large fawn jumped quickly over white zinc
+boxes\blindtext@endsentence
+\or Exquisite farm wench gives body jolt to prize
+stinker\blindtext@endsentence
+\or Jack amazed a few girls by dropping the antique onyx vase!\xspace%
+    \setcounter{blind@pangramcount}{-1}%
+    \fi%
+    \refstepcounter{blind@pangramcount}%
+  \ifnum\blind@countxx<\value{blind@pangrammax}\advance\blind@countxx by 1 %
+  \repeat%
+  \setcounter{blind@pangrammax}{\value{blindtext}}%
+  }% \blindtext@text
+  \def\blindtext@parstart{}%no change for pangram option
+}
+\fi %option pangram
+\def\blindtext@catalan{}
+\blind@addtext{catalan}{%
+  \def\blindtext@text{%
+    Qu\`{e} \'es aix\`{o}?\blindtext@endsentence \'Es la meva primera
+    frase des de fa anys: Lorem ipsum dolor sit amet, consectetuer
+    adipiscing elit\blindtext@endsentence Etiam lobortis facilisis
+    sem\blindtext@endsentence Nullam nec mi et neque pharetra
+    sollicitudin\blindtext@endsentence Praesent imperdiet mi nec
+    ante\blindtext@endsentence  Donec ullamcorper, \blindmarkup{felis
+    non sodales commodo}, lectus velit ultrices augue, a dignissim nibh
+    lectus placerat pede\blindtext@endsentence Vivamus nunc nunc,
+    molestie ut, ultricies vel, \blindmarkup{semper in},
+    velit\blindtext@endsentence  Ut porttitor\blindtext@endsentence
+    Praesent in sapien\blindtext@endsentence%
+  }% \blindtext@text
+}
+\blind@addtext{catalan}{%
+  \def\blindtext@parstart{%
+      \ifcase\value{blind@countparstart}\or
+Aquest \'es el segon par\`agraf\blindtext@endsentence\or
+I despr\'es del segon ve el tercer par\`agraf\blindtext@endsentence\or
+Despr\'es del quart par\`agraf comencem una nova tanda de nous par\`agrafs\blindtext@endsentence\or
+        \setcounter{blind@countparstart}{0}
+      \fi
+      \stepcounter{blind@countparstart}
+  }% \blindtext@parstart
+}
+\blind@addtext{catalan}{%
+  \def\blindtext@count{%
+    \ifcase\value{blind@listcount}\or
+      Primer\or Segon\or Tercer\or Quart\or Cinqu\`e\or
+      Sis\`e\or Set\`e\or Vuit\`e\or Nov\`e\or Des\`e\or
+      Onz\`e\or Dotuz\`e%
+    \else
+      Altres%
+    \fi
+  }% \blindtext@count
+  \def\blindtext@item{punt d'una llista}%
+}%\addto\extrascatalan
+\blind@addtext{catalan}{%
+  \def\blindtext@heading{T\'itol de nivell\xspace}%
+  \def\blindtext@list{Llistes}%
+  \def\blindtext@listEx{Exemple de llista\xspace}%
+}%\addto\extrascatalan
+\blind@addtext{catalan}{%
+    \def\blindtext@blindmath{Alguns textos amb f\'ormules matem\`atiques.}%
+}%\addto\extrascatalan
+\ifblindbible
+\blind@addtext{catalan}{%
+  \def\blindtext@text{%
+    Jahv\`e D\'eu digu\'e a la serp16 : \flqq Perqu\`e has fet aix\`o,
+    ser\`as male\"{i}da entre totes les b\`esties i tots els animals
+    salvatges. T'arrossegar\`as damunt del ventre i menjar\`as pols tot
+    el temps de la teva vida.
+    Llavors D\'eu digu\'e a Mois\`es: \flqq Jo s\'ec, el qui s\'ec.\frqq
+    I afeg\'i: \flqq Aix\'i parlar\`as als israelites: Jo s\'ec m'ha
+    enviat a vosaltres\frqq
+    Com a combusti\'e per a Jahv\`e, n'oferir\`a el greix que cobreix
+    les entranyes i tot el greix de damunt les entranyes;\ldots
+    Jahv\`e va dir a Mois\`es, a la muntanya del Sina\'i: 1\ldots
+    Ja\"{i}r, fill de Manas\'es, s'apoder\`a de tota la regi\'e d'Argob
+    fins a la frontera dels guesurites i dels macatites, i don\`a a
+    Basan el seu nom d'Havot-Ja\"{i}r, que ha quedat fins avu\'i.%
+  }% \blindtext@text
+  \def\blindtext@parstart{}%no change for bible option
+}
+\fi %\ifbible
+\ifblindrandom
+  \PackageWarning{blindtext}{Option random not defined for catalan\MessageBreak}%
+  \blind@addtext{catalan}{%
+    \setcounter{blindtext}{1}
+  }
+\fi %option random
+\ifblindpangram
+\blind@addtext{catalan}{%
+    \setcounter{blindtext}{5}
+    \def\blindtext@text{%
+    \blind@countxx=1 %
+    \loop
+      \ifcase\value{blind@pangramcount}%
+Jove xef, porti whisky amb quinze gla\c{c}ons d'hidrogen, coi!
+\or Aqueix betzol, Jan, comprava whisky de figa\blindtext@endsentence
+\or Zel de grum: quetxup, whisky, caf\`e, bon vi; ja!
+\or Coi! quinze jans golafres de X\`ativa, beuen whisky a
+pams\blindtext@endsentence%
+    \setcounter{blind@pangramcount}{-1}%
+    \fi%
+    \refstepcounter{blind@pangramcount}%
+  \ifnum\blind@countxx<\value{blind@pangrammax}\advance\blind@countxx by 1 %
+  \repeat%
+  \setcounter{blind@pangrammax}{\value{blindtext}}%
+  }% \blindtext@text
+  \def\blindtext@parstart{}%no change for pangram option
+}
+\fi %option pangram
+\def\blindtext@english{}
+\blind@addtext{english}{%
+  \def\blindtext@text{%
+    Hello, here is some text without a meaning\blindtext@endsentence
+    This text should show what a printed text will look like at this
+    place\blindtext@endsentence If you read this text, you will get no
+    information\blindtext@endsentence Really? Is there no information?
+    Is there a difference between this text and some nonsense like
+    ``Huardest gefburn''? Kjift -- not at all! A blind text
+    \blindmarkup{like this} gives you information  about the selected
+    font, how the letters are written and an impression  of the
+    look\blindtext@endsentence This text should contain \blindmarkup{all
+    letters of the alphabet} and it should be written in of the original
+    language\blindtext@endsentence There is no need for  special
+    content, but the length of words should match the
+    language\blindtext@endsentence%
+  }% \blindtext@text
+}
+\blind@addtext{english}{%
+  \def\blindtext@parstart{%
+      \ifcase\value{blind@countparstart}\or
+This is the second paragraph.\or
+And after the second paragraph follows the third paragraph.\or
+After this fourth paragraph, we start a new paragraph sequence.\or
+        \setcounter{blind@countparstart}{0}
+      \fi
+      \stepcounter{blind@countparstart}
+  }% \blindtext@parstart
+}
+\blind@addtext{english}{%
+  \def\blindtext@count{%
+    \ifcase\value{blind@listcount}\or
+      First\or Second\or Third\or Fourth\or Fifth\or
+      Sixth\or Seventh\or Eighth\or Ninth\or Tenth\or
+      Eleventh\or Twelfth%
+    \else
+      Another%
+    \fi
+  }% \blindtext@count
+  \def\blindtext@item{item in a list}%
+}%\addto\extrasenglish
+\blind@addtext{english}{%
+  \def\blindtext@heading{Heading on Level\xspace}%
+  \def\blindtext@list{Lists}%
+  \def\blindtext@listEx{Example for list\xspace}%
+}%\addto\extrasenglish
+\blind@addtext{english}{%
+    \def\blindtext@blindmath{Some blind text with math formulas}%
+}%\addto\extrasenglish
+\ifblindbible
+\blind@addtext{english}{%
+  \def\blindtext@text{%
+    And the Lord God said unto the serpent, Because thou hast done this,
+    thou art cursed above all cattle, and above every beast of the
+    field; upon thy belly shalt thou go, and dust shalt thou eat all the
+    days of thy life:
+    And God said unto Moses, `I am that I am': and he said, Thus shalt
+    thou say unto the children of Israel, `I am' hath sent me unto you.
+    And he shall offer thereof his offering, even an offering made by
+    fire unto the Lord; the fat that covereth the inwards, and all the
+    fat that is upon the inwards,\ldots
+    And the Lord spake unto Moses in the wilderness of Sinai,
+    saying,\ldots
+    Jair the son of Manasseh took all the country of Argob unto the
+    coasts of Geshuri and Maachathi; and called them after his own name,
+    Bashanhavothjair, unto this day.%
+  }% \blindtext@text
+  \def\blindtext@parstart{}%no change for bible option
+}
+\fi %\ifbible
+\ifblindrandom
+  \PackageWarning{blindtext}{Option random not defined for english\MessageBreak}%
+  \blind@addtext{english}{%
+    \setcounter{blindtext}{1}
+  }
+\fi %option random
+\ifblindpangram
+\blind@addtext{english}{%
+    \setcounter{blindtext}{5}
+    \def\blindtext@text{%
+    \blind@countxx=1 %
+    \loop
+      \ifcase\value{blind@pangramcount}%
+The quick brown fox jumps over the lazy dog\blindtext@endsentence
+\or Jackdaws love my big Sphinx of Quartz\blindtext@endsentence
+\or Pack my box with five dozen liquor jugs\blindtext@endsentence
+\or The five boxing wizards jump quickly\blindtext@endsentence
+\or Sympathizing would fix Quaker objectives\blindtext@endsentence
+\or Many-wived Jack laughs at probes of sex quiz\blindtext@endsentence
+\or Turgid saxophones blew over Mick's jazzy quaff\blindtext@endsentence
+\or Playing jazz vibe chords quickly excites my
+wife\blindtext@endsentence
+\or A large fawn jumped quickly over white zinc
+boxes\blindtext@endsentence
+\or Exquisite farm wench gives body jolt to prize
+stinker\blindtext@endsentence
+\or Jack amazed a few girls by dropping the antique onyx vase!\xspace%
+    \setcounter{blind@pangramcount}{-1}%
+    \fi%
+    \refstepcounter{blind@pangramcount}%
+  \ifnum\blind@countxx<\value{blind@pangrammax}\advance\blind@countxx by 1 %
+  \repeat%
+  \setcounter{blind@pangrammax}{\value{blindtext}}%
+  }% \blindtext@text
+  \def\blindtext@parstart{}%no change for pangram option
+}
+\fi %option pangram
+\def\blindtext@french{}
+\blind@addtext{french}{%
+  \def\blindtext@text{%
+    Qu'est que c'est?\blindtext@endsentence  C'est une phrase
+    fran\c{c}ais \blindmarkup{avant le lorem
+    ipsum}\blindtext@endsentence   Lorem ipsum dolor sit amet,
+    consectetuer adipiscing elit. Etiam lobortis facilisis sem. Nullam
+    nec mi et neque pharetra sollicitudin. Praesent imperdiet mi nec
+    ante. Donec ullamcorper, felis non sodales commodo, lectus velit
+    ultrices augue, a dignissim nibh lectus placerat pede. Vivamus nunc
+    nunc, molestie ut, ultricies vel, semper in, velit. Ut porttitor.
+    Praesent in sapien. \blindmarkup{Lorem ipsum} dolor sit amet,
+    consectetuer adipiscing elit. Duis fringilla tristique neque. Sed
+    interdum libero ut metus. Pellentesque placerat. Nam rutrum augue a
+    leo. Morbi sed elit sit amet ante lobortis sollicitudin. Praesent
+    blandit blandit mauris. Praesent lectus tellus, \blindmarkup{aliquet
+    aliquam}, luctus a, egestas a, turpis. Mauris lacinia lorem sit amet
+    ipsum. Nunc quis urna dictum turpis accumsan semper.%
+  }% \blindtext@text
+}
+\blind@addtext{french}{%
+  \def\blindtext@count{%
+    \ifcase\value{blind@listcount}\or
+      Premier\or Deuxi\`eme\or Troisi\`eme\or Quatri\`eme\or Cinqui\`eme\or
+      Sixi\`eme\or Septi\`eme\or Huiti\`eme\or Neuvi\`eme\or Dixi\`eme\or
+      Onzi\`eme\or Douzi\`eme%
+    \else
+      L'autres%
+    \fi
+  }% \blindtext@count
+  \def\blindtext@item{point dans une list}%
+}%\addto\extrasfrench
+\blind@addtext{french}{%
+  \def\blindtext@heading{Titres de niveau\xspace}%
+  \def\blindtext@list{Lists}%
+  \def\blindtext@listEx{Example pour une list\xspace}%
+}%\addto\extrasfrench
+\blind@addtext{french}{%
+    \def\blindtext@blindmath{Quelques textes avec des formules math\'ematiques.}%
+}%\addto\extrasfrench
+\ifblindbible
+\blind@addtext{french}{%
+  \def\blindtext@text{%
+    L'\'Eternel Dieu dit au serpent: Puisque tu as fait cela, tu seras
+    maudit entre tout le b\'etail et entre tous les animaux des champs,
+    tu marcheras sur ton ventre, et tu mangeras de la poussi\`ere tous
+    les jours de ta vie.
+    Dieu dit \`a Mo\"ise: Je suis celui qui suis. Et il ajouta: C'est
+    ainsi que tu r\'epondras aux enfants d'Isra\"el: Celui qui s'appelle
+    'je suis'm'a envoy\'e vers vous.
+    De la victime, il offrira en sacrifice consum\'e par le feu devant
+    l'\'eternel: la graisse qui couvre les entrailles et toute celle qui
+    y est attach\'ee,\ldots
+    L'\'eternel parla \`a Mo\"ise, dans le d\'esert de Sina\"i, et dit:
+    Ja\"ir, fils de Manass\'e, prit toute la contr\'ee d'Argob jusqu'\`a
+    la fronti\`ere des Gueschuriens et des Maacathiens, et il donna son
+    nom aux bourgs de Basan, appel\'es encore aujourd'hui bourgs de
+    Ja\"ir.%
+  }% \blindtext@text
+  \def\blindtext@parstart{}%no change for bible option
+}
+\fi %\ifbible
+\ifblindrandom
+  \PackageWarning{blindtext}{Option random not defined for french\MessageBreak}%
+  \blind@addtext{french}{%
+    \setcounter{blindtext}{1}
+  }
+\fi %option random
+\ifblindpangram
+\blind@addtext{french}{%
+    \setcounter{blindtext}{5}
+    \def\blindtext@text{%
+    \blind@countxx=1 %
+    \loop
+      \ifcase\value{blind@pangramcount}%
+Voyez le brick g\'eant que j'examine pr\`es du
+wharf\blindtext@endsentence
+\or Portez ce vieux whisky au juge blond qui fume\blindtext@endsentence
+\or Buvez de ce whisky que le patron juge fameux
+\or B\^achez la queue du wagon-taxi avec les pyjamas du
+fakir\blindtext@endsentence
+\or Voix ambigu\"e d'un c\oe ur qui au z\'ephyr pr\'ef\`ere les jattes
+de kiwi\blindtext@endsentence
+\or Monsieur Jack, vous dactylographiez bien mieux que votre ami
+Wolf\blindtext@endsentence%
+    \setcounter{blind@pangramcount}{-1}%
+    \fi%
+    \refstepcounter{blind@pangramcount}%
+  \ifnum\blind@countxx<\value{blind@pangrammax}\advance\blind@countxx by 1 %
+  \repeat%
+  \setcounter{blind@pangrammax}{\value{blindtext}}%
+  }% \blindtext@text
+  \def\blindtext@parstart{}%no change for pangram option
+}
+\fi %option pangram
+\def\blindtext@german{}
+\blind@addtext{german}{%
+  \def\blindtext@text{%
+    Dies hier ist ein Blindtext zum Testen von
+    Textausgaben\blindtext@endsentence Wer diesen Text liest, ist selbst
+    schuld\blindtext@endsentence Der Text gibt lediglich den Grauwert
+    der Schrift an\blindtext@endsentence Ist das wirklich so? Ist es
+    gleich\-g\"ul\-tig, ob ich schreibe: \glqq Dies ist ein
+    Blindtext\grqq\ oder \glqq Huardest gefburn\grqq ? Kjift --
+    mitnichten! Ein Blindtext bietet mir wichtige
+    Informationen\blindtext@endsentence An ihm messe ich die
+    \blindmarkup{Lesbarkeit einer Schrift}, ihre Anmutung, wie
+    harmonisch die Figuren zueinander stehen und pr\"u\-fe, wie breit
+    oder schmal sie l\"auft\blindtext@endsentence Ein Blindtext sollte
+    m\"og\-lichst \blindmarkup{viele verschiedene Buchstaben} enthalten
+    und in der Originalsprache gesetzt sein\blindtext@endsentence Er
+    mu\ss\ keinen Sinn ergeben, sollte aber lesbar
+    sein\blindtext@endsentence Fremdsprachige Texte wie \glqq Lorem
+    ipsum\grqq\ dienen nicht dem eigentlichen Zweck, da sie eine falsche
+    Anmutung vermitteln\blindtext@endsentence%
+  }% \blindtext@text
+}
+\blind@addtext{german}{%
+  \def\blindtext@parstart{%
+      \ifcase\value{blind@countparstart}\or
+Das hier ist der zweite Absatz.\or
+Und nun folgt -- ob man es glaubt oder nicht --  der dritte Absatz.\or
+Nach diesem vierten Absatz beginnen wir eine neue Z\"ahlung.\or
+        \setcounter{blind@countparstart}{0}
+      \fi
+      \stepcounter{blind@countparstart}
+  }% \blindtext@parstart
+}
+\blind@addtext{german}{%
+  \def\blindtext@count{%
+    \ifcase\value{blind@listcount}\or
+      Erster\or Zweiter\or Dritter\or Vierter\or F{\"u}nfter\or
+      Sechster\or Siebter\or Achter\or Neunter\or Zehnter\or
+      Elfter\or Zw{\"o}lfter\or Dreizehnter\or Vierzehnter%
+    \else
+      Noch ein%
+    \fi
+  }% \blindtext@count
+  \def\blindtext@item{Listenpunkt, Stufe~\arabic{blind@levelcount}}%
+}%\addto\extrasgerman
+\blind@addtext{german}{%
+  \def\blindtext@heading{{\"U}berschrift auf Ebene
+\xspace}%
+  \def\blindtext@list{Listen}%
+  \def\blindtext@listEx{Beispiel einer Liste\xspace}%
+}%\addto\extrasgerman
+\blind@addtext{german}{%
+    \def\blindtext@blindmath{Blindtext mit mathematischen Formeln}%
+}%\addto\extrasgerman
+\ifblindbible
+\blind@addtext{german}{%
+  \def\blindtext@text{%
+    Da sprach Gott der Herr zu der Schlange: Weil du solches getan hast,
+    seist du verflucht vor allem Vieh und vor allen Tieren auf dem
+    Felde. Auf deinem Bauche sollst du gehen und Erde essen dein Leben
+    lang.
+    Gott sprach zu Mose: \glqq Ich werde sein, der Ich sein werde.\grqq\
+    Und sprach: Also sollst du den Kindern Israel sagen: \glqq Ich werde
+    sein\grqq\ hat mich zu euch gesandt\ldots
+    und er soll davon opfern ein Opfer dem Herrn, n\"amlich das Fett,
+    welches die Eingeweide bedeckt, und alles Fett am Eingeweide,\ldots
+    Und der HERR redete mit Mose in der W\"uste Sinai und sprach:
+    Jair, der Sohn Manasses, nahm die ganze Gegend Argob bis an die
+    Grenze der Gessuriter und Maachathiter und hiess das Basan nach
+    seinem Namen D\"orfer Jairs bis auf den heutigen Tag.%
+  }% \blindtext@text
+  \def\blindtext@parstart{}%no change for bible option
+}
+\fi %\ifbible
+\ifblindrandom
+  \blind@addtext{german}{%
+      \setcounter{blindtext}{17}
+      \def\blindtext@text{%
+      \blind@countxx=1 %
+      \loop
+        \ifcase\value{blind@randomcount}%
+Dies hier ist ein Blindtext zum Testen von
+Textausgaben\blindtext@endsentence
+\or Gerne werden Pangramme als Blindtexte
+verwendet\blindtext@endsentence
+\or Das griechische Wort Pangramm (oder holoalphabetischer Satz)
+bezeichnet einen Satz, der alle Buchstaben des Alphabets
+enth\"alt\blindtext@endsentence
+\or Wobei man \glqq alle Buchstaben\grqq\ mit und ohne Umlaute z\"ahlen
+kann\blindtext@endsentence
+\or Aber das soll uns hier nicht k\"ummern, eigentlich wollen wir doch
+eine Geschichte erz\"ahlen\blindtext@endsentence
+\or Aber wozu wollen wir eine Geschichte erz\"ahlen?\xspace
+\or Ach ja, wir brauchen Text um das Layout dieses Textes zu p\"ufen --
+dazu nimmt man meist einen Blindtext\blindtext@endsentence%
+      \setcounter{blind@randomcount}{-1}%
+      \fi%
+      \refstepcounter{blind@randomcount}%
+    \ifnum\blind@countxx<\value{blind@randommax}\advance\blind@countxx by 1 %
+    \repeat%
+    \setcounter{blind@randommax}{\value{blindtext}}%
+    }% \blindtext@text
+    \def\blindtext@parstart{}%no change for random option
+  }
+\fi %option random
+\ifblindpangram
+\blind@addtext{german}{%
+    \setcounter{blindtext}{5}
+    \def\blindtext@text{%
+    \blind@countxx=1 %
+    \loop
+      \ifcase\value{blind@pangramcount}%
+Franz jagt im komplett verwahrlosten Taxi quer durch
+Bayern\blindtext@endsentence
+\or Zw\"olf Boxk\"ampfer jagen Viktor quer \"uber den gro{\ss}en Sylter
+Deich\blindtext@endsentence
+\or Vogel Quax zwickt Johnys Pferd Bim\blindtext@endsentence
+\or Sylvia wagt quick den Jux bei Pforzheim\blindtext@endsentence
+\or Prall vom Whisky flog Quax den Jet zu Bruch\blindtext@endsentence
+\or Jeder wackere Bayer vertilgt bequem zwo Pfund
+Kalbshaxen\blindtext@endsentence
+\or Stanleys Expeditionszug quer durch Afrika wird von jedermann
+bewundert\blindtext@endsentence%
+    \setcounter{blind@pangramcount}{-1}%
+    \fi%
+    \refstepcounter{blind@pangramcount}%
+  \ifnum\blind@countxx<\value{blind@pangrammax}\advance\blind@countxx by 1 %
+  \repeat%
+  \setcounter{blind@pangrammax}{\value{blindtext}}%
+  }% \blindtext@text
+  \def\blindtext@parstart{}%no change for pangram option
+}
+\fi %option pangram
+\@ifpackageloaded{german}{\selectlanguage{german}}{}
+\def\blindtext@latin{}
+\blind@addtext{latin}{%
+  \def\blindtext@text{%
+    Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Etiam
+    lobortis facilisis sem. Nullam nec mi et neque pharetra
+    sollicitudin. Praesent imperdiet mi nec ante. Donec ullamcorper,
+    felis non sodales commodo, lectus velit ultrices augue, a dignissim
+    nibh lectus placerat pede. Vivamus nunc nunc, molestie ut, ultricies
+    vel, semper in, velit. Ut porttitor. Praesent in sapien.
+    \blindmarkup{Lorem ipsum} dolor sit amet, consectetuer adipiscing
+    elit. Duis fringilla tristique neque. Sed interdum libero ut metus.
+    Pellentesque placerat. Nam rutrum augue a leo. Morbi sed elit sit
+    amet ante lobortis sollicitudin. Praesent blandit blandit mauris.
+    Praesent lectus tellus, \blindmarkup{aliquet aliquam}, luctus a,
+    egestas a, turpis. Mauris lacinia lorem sit amet ipsum. Nunc quis
+    urna dictum turpis accumsan semper.%
+  }% \blindtext@text
+}
+\blind@addtext{latin}{%
+  \def\blindtext@count{%
+    \ifcase\value{blind@listcount}\or
+      Primus\or Duo\or Tres\or Quattuor\or Quinque\or
+      Sex\or Septem\or Octo\or Novem\or Decem\\or
+      Undecim\or Duodecim%
+    \else
+      Nova%
+    \fi
+  }% \blindtext@count
+  \def\blindtext@item{, altum~\arabic{blind@levelcount}}%
+}%\addto\extraslatin
+\blind@addtext{latin}{%
+  \def\blindtext@heading{Sectio\xspace}%
+  \def\blindtext@list{Caudex}%
+  \def\blindtext@listEx{Exemplum caudex\xspace}%
+}%\addto\extraslatin
+\blind@addtext{latin}{%
+    \def\blindtext@blindmath{Mathematica}%
+}%\addto\extraslatin
+\ifblindbible
+\blind@addtext{latin}{%
+  \def\blindtext@text{%
+    et ait Dominus Deus ad serpentem quia fecisti hoc maledictus es
+    inter omnia animantia et bestias terrae super pectus tuum gradieris
+    et terram comedes cunctis diebus vitae tuae
+    dixit Deus ad Mosen ego sum qui sum ait sic dices filiis Israhel qui
+    est misit me ad vos
+    tollentque ex ea in pastum ignis dominici adipem qui operit ventrem
+    et qui tegit universa vitalia
+    Iocutus est Dominus ad Mosen in deserto Sinai dicens
+    Iair filius Manasse possedit omnem regionem Argob usque ad terminos
+    Gesuri et Machathi vocavitque ex nomine suo Basan Avothiair id est
+    villas Iair usque in praesentem diem%
+  }% \blindtext@text
+  \def\blindtext@parstart{}%no change for bible option
+}
+\fi %\ifbible
+\ifblindrandom
+  \blind@addtext{latin}{%
+      \setcounter{blindtext}{17}
+      \def\blindtext@text{%
+      \blind@countxx=1 %
+      \loop
+        \ifcase\value{blind@randomcount}%
+Ab imo pectore\blindtext@endsentence
+\or Acta est fabula\blindtext@endsentence
+\or Ad augusta per angusta!\xspace
+\or Ad gladios!\xspace
+\or Alea iacta est\blindtext@endsentence
+\or Argumentum baculinum!\xspace
+\or Audaces fortuna juvat!\xspace
+\or Auri sacra fames!\xspace
+\or Aut Caesar, aut nihil!\xspace
+\or Ave C\"asar, lucrifacturi te salutant!\xspace
+\or Beati Asterixem possidentes!\xspace
+\or Beati pauperes spiritu\blindtext@endsentence
+\or Bis repetita non placent\blindtext@endsentence
+\or Carpe diem\blindtext@endsentence
+\or Cautela abundans non nocet\blindtext@endsentence
+\or Cogito, ergo sum\blindtext@endsentence
+\or Concursu!\xspace
+\or Condicio sine qua non\blindtext@endsentence
+\or Contraria contrariis curantur!\xspace
+\or Similia similibus curantur\blindtext@endsentence
+\or Da capo!\xspace
+\or Ceterum censeo Carthaginem esse delendam\blindtext@endsentence
+\or Desinit in piscem mulier formosa superne!\xspace
+\or Diem perdidi!\xspace
+\or Dignus est intrare\blindtext@endsentence
+\or Donec eris felix, multos numerabis amicos\blindtext@endsentence
+\or Tempora si fuerint nubila, solus eris\blindtext@endsentence
+\or Dulce et decorum est pro patria mori\blindtext@endsentence
+\or Errare humanum est\blindtext@endsentence
+\or Et nunc reges, intelligite erudimini qui judicatis
+terram\blindtext@endsentence
+\or Exegi monumentum aere perennius\blindtext@endsentence
+\or Felix, qui potuit rerum cognoscere\blindtext@endsentence
+\or Felix qui potuit rerum cognocscere causas!\xspace
+\or Fluctuat nec mergitur!\xspace
+\or Ipso facto!\xspace
+\or Ira furor brevis est\blindtext@endsentence
+\or Ita deis placuit!\xspace
+\or Ita est!\xspace
+\or Legio expedita!\xspace
+\or Leontes te devorant \blindtext@endsentence
+\or Major e longinquo reverentia\blindtext@endsentence
+\or Mens sana in corpore sano\blindtext@endsentence
+\or Morituri te salutant!\xspace
+\or Nihil conveniens decretis ejus!\xspace
+\or Non licet omnibus adire Brivatum\blindtext@endsentence
+\or Non licet omnibus adire Corinthum\blindtext@endsentence
+\or Non omnia possumus omnes!\xspace
+\or O fortunatos nimium, sua si bona norint, agricolas!\xspace
+\or Qui habet aures audiendi, audiat!\xspace
+\or Quod erat demonstrandum\blindtext@endsentence
+\or Quot capita tot census!\xspace
+\or Sic transit gloria mundi\blindtext@endsentence
+\or Summum jus, summa injuria!\xspace
+\or Ubi solitudinem faciunt, pacem appellant\blindtext@endsentence
+\or Vanitas vanitatum et omnia vanitas\blindtext@endsentence
+\or Victrix causa diis placuit, sed victa Catoni\blindtext@endsentence
+\or Video meliora proboque deteriora sequor\blindtext@endsentence
+\or Vinum et musica laetificant cor\blindtext@endsentence%
+      \setcounter{blind@randomcount}{-1}%
+      \fi%
+      \refstepcounter{blind@randomcount}%
+    \ifnum\blind@countxx<\value{blind@randommax}\advance\blind@countxx by 1 %
+    \repeat%
+    \setcounter{blind@randommax}{\value{blindtext}}%
+    }% \blindtext@text
+    \def\blindtext@parstart{}%no change for random option
+  }
+\fi %option random
+\ifblindpangram
+\blind@addtext{latin}{%
+    \setcounter{blindtext}{5}
+    \def\blindtext@text{%
+    \blind@countxx=1 %
+    \loop
+      \ifcase\value{blind@pangramcount}%
+Sic fugiens, dux, zelotypos quam karus haberis\blindtext@endsentence
+\or Duc zephire exurgens currum cum flatibus
+\ae{}quor\blindtext@endsentence
+\or Vix phlegeton zephiri qu\ae{}rens modo flabra
+mycillo\blindtext@endsentence%
+    \setcounter{blind@pangramcount}{-1}%
+    \fi%
+    \refstepcounter{blind@pangramcount}%
+  \ifnum\blind@countxx<\value{blind@pangrammax}\advance\blind@countxx by 1 %
+  \repeat%
+  \setcounter{blind@pangrammax}{\value{blindtext}}%
+  }% \blindtext@text
+  \def\blindtext@parstart{}%no change for pangram option
+}
+\fi %option pangram
+\def\blindtext@ngerman{}
+\blind@addtext{ngerman}{%
+  \def\blindtext@text{%
+    Dies hier ist ein Blindtext zum Testen von
+    Textausgaben\blindtext@endsentence Wer diesen Text liest, ist selbst
+    schuld\blindtext@endsentence Der Text gibt lediglich den Grauwert
+    der Schrift an\blindtext@endsentence Ist das wirklich so? Ist es
+    gleich\-g\"ul\-tig, ob ich schreibe: \glqq Dies ist ein
+    Blindtext\grqq\ oder \glqq Huardest gefburn\grqq ? Kjift --
+    mitnichten! Ein Blindtext bietet mir wichtige
+    Informationen\blindtext@endsentence An ihm messe ich die
+    \blindmarkup{Lesbarkeit einer Schrift}, ihre Anmutung, wie
+    harmonisch die Figuren zueinander stehen und pr\"u\-fe, wie breit
+    oder schmal sie l\"auft\blindtext@endsentence Ein Blindtext sollte
+    m\"og\-lichst viele \blindmarkup{verschiedene Buchstaben} enthalten
+    und in der Originalsprache gesetzt sein\blindtext@endsentence Er
+    muss keinen Sinn ergeben, sollte aber lesbar
+    sein\blindtext@endsentence Fremdsprachige Texte wie \glqq Lorem
+    ipsum\grqq\ dienen nicht dem eigentlichen Zweck, da sie eine falsche
+    Anmutung vermitteln\blindtext@endsentence%
+  }% \blindtext@text
+}
+\blind@addtext{ngerman}{%
+  \def\blindtext@parstart{%
+      \ifcase\value{blind@countparstart}\or
+Das hier ist der zweite Absatz.\or
+Und nun folgt -- ob man es glaubt oder nicht --  der dritte Absatz.\or
+Nach diesem vierten Absatz beginnen wir eine neue Z\"ahlung.\or
+        \setcounter{blind@countparstart}{0}
+      \fi
+      \stepcounter{blind@countparstart}
+  }% \blindtext@parstart
+}
+\blind@addtext{ngerman}{%
+  \def\blindtext@count{%
+    \ifcase\value{blind@listcount}\or
+      Erster\or Zweiter\or Dritter\or Vierter\or F{\"u}nfter\or
+      Sechster\or Siebter\or Achter\or Neunter\or Zehnter\or
+      Elfter\or Zw{\"o}lfter\or Dreizehnter\or Vierzehnter%
+    \else
+      Noch ein%
+    \fi
+  }% \blindtext@count
+  \def\blindtext@item{Listenpunkt, Stufe~\arabic{blind@levelcount}}%
+}%\addto\extrasngerman
+\blind@addtext{ngerman}{%
+  \def\blindtext@heading{{\"U}berschrift auf Ebene\xspace}%
+  \def\blindtext@list{Listen}%
+  \def\blindtext@listEx{Beispiel einer Liste\xspace}%
+}%\addto\extrasngerman
+\blind@addtext{ngerman}{%
+    \def\blindtext@blindmath{Blindtext mit mathematischen Formeln}%
+}%\addto\extrasngerman
+\ifblindbible
+\blind@addtext{ngerman}{%
+  \def\blindtext@text{%
+    Da sprach Gott der Herr zu der Schlange: Weil du solches getan hast,
+    seist du verflucht vor allem Vieh und vor allen Tieren auf dem
+    Felde. Auf deinem Bauche sollst du gehen und Erde essen dein Leben
+    lang.
+    Gott sprach zu Mose: \glqq Ich werde sein, der Ich sein werde.\grqq\
+    Und sprach: Also sollst du den Kindern Israel sagen: \glqq Ich werde
+    sein\grqq\ hat mich zu euch gesandt\ldots
+    und er soll davon opfern ein Opfer dem Herrn, n\"amlich das Fett,
+    welches die Eingeweide bedeckt, und alles Fett am Eingeweide,\ldots
+    Und der HERR redete mit Mose in der W\"uste Sinai und sprach:
+    Jair, der Sohn Manasses, nahm die ganze Gegend Argob bis an die
+    Grenze der Gessuriter und Maachathiter und hiess das Basan nach
+    seinem Namen D\"orfer Jairs bis auf den heutigen Tag.%
+  }% \blindtext@text
+  \def\blindtext@parstart{}%no change for bible option
+}
+\fi %\ifbible
+\ifblindrandom
+  \blind@addtext{ngerman}{%
+      \setcounter{blindtext}{17}
+      \def\blindtext@text{%
+      \blind@countxx=1 %
+      \loop
+        \ifcase\value{blind@randomcount}%
+Dies hier ist ein Blindtext zum Testen von
+Textausgaben\blindtext@endsentence
+\or Gerne werden Pangramme als Blindtexte
+verwendet\blindtext@endsentence
+\or Das griechische Wort Pangramm (oder holoalphabetischer Satz)
+bezeichnet einen Satz, der alle Buchstaben des Alphabets
+enth\"alt\blindtext@endsentence
+\or Wobei man \glqq alle Buchstaben\grqq\ mit und ohne Umlaute z\"ahlen
+kann\blindtext@endsentence
+\or Aber das soll uns hier nicht k\"ummern, eigentlich wollen wir doch
+eine Geschichte erz\"ahlen\blindtext@endsentence
+\or Aber wozu wollen wir eine Geschichte erz\"ahlen?\xspace
+\or Ach ja, wir brauchen Text um das Layout dieses Textes zu p\"ufen --
+dazu nimmt man meist einen Blindtext\blindtext@endsentence%
+      \setcounter{blind@randomcount}{-1}%
+      \fi%
+      \refstepcounter{blind@randomcount}%
+    \ifnum\blind@countxx<\value{blind@randommax}\advance\blind@countxx by 1 %
+    \repeat%
+    \setcounter{blind@randommax}{\value{blindtext}}%
+    }% \blindtext@text
+    \def\blindtext@parstart{}%no change for random option
+  }
+\fi %option random
+\ifblindpangram
+\blind@addtext{ngerman}{%
+    \setcounter{blindtext}{5}
+    \def\blindtext@text{%
+    \blind@countxx=1 %
+    \loop
+      \ifcase\value{blind@pangramcount}%
+Franz jagt im komplett verwahrlosten Taxi quer durch
+Bayern\blindtext@endsentence
+\or Zw\"olf Boxk\"ampfer jagen Viktor quer \"uber den gro{\ss}en Sylter
+Deich\blindtext@endsentence
+\or Vogel Quax zwickt Johnys Pferd Bim\blindtext@endsentence
+\or Sylvia wagt quick den Jux bei Pforzheim\blindtext@endsentence
+\or Prall vom Whisky flog Quax den Jet zu Bruch\blindtext@endsentence
+\or Jeder wackere Bayer vertilgt bequem zwo Pfund
+Kalbshaxen\blindtext@endsentence
+\or Stanleys Expeditionszug quer durch Afrika wird von jedermann
+bewundert\blindtext@endsentence%
+    \setcounter{blind@pangramcount}{-1}%
+    \fi%
+    \refstepcounter{blind@pangramcount}%
+  \ifnum\blind@countxx<\value{blind@pangrammax}\advance\blind@countxx by 1 %
+  \repeat%
+  \setcounter{blind@pangrammax}{\value{blindtext}}%
+  }% \blindtext@text
+  \def\blindtext@parstart{}%no change for pangram option
+}
+\fi %option pangram
+\@ifpackageloaded{ngerman}{\selectlanguage{ngerman}}{}
+\endinput
+%%
+%% End of file `blindtext.sty'.
diff --git a/draftmark.sty b/draftmark.sty
new file mode 100644 (file)
index 0000000..ea89305
--- /dev/null
@@ -0,0 +1,222 @@
+%++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++%
+% This is file 'draftmark.sty'.                                            %
+%                                                                          %
+% This package puts a user-specified draftmark and arbitrary texts on      %
+% select pages of documents. It is more general than the 'draftwatermark'  %
+% package by Sergio Callegari and 'draftcopy' by J\"{u}rgen Vollmer. The   %
+% advantages of this package over 'draftwatermark' include: the user can   %
+% specify his/her own draftmark and color, the draftmark position and      %
+% orientation, the page (all pages, odd pages, even pages, a particular    %
+% page number, and a range of pages) on which the draftmark should appear, %
+% and all the options are passed directly to package instead of being      %
+% defined by user-macros. There is also the provision to use the macro     %
+% \draftmarksetup, which can be utilized to dynamically specify draftmark  %
+% properties for each page or range of pages. With the 'xcolor' package    %
+% (loaded by this package), all colors can be passed to this package. The  %
+% code of this package is very much shorter than that of the 'draftcopy'   %
+% package by Jurgen Vollmer (2002) because it capitalizes on dvi hooks     %
+% from Heiko Oberdiek's 'atbegshi' package.                                %
+%                                                                          %
+% With the \includegraphics command, this package can be used to insert    %
+% graphic watermarks.                                                      %
+%                                                                          %
+% This work may be distributed and/or modified under the conditions        %
+% of the LaTeX Project Public License, either version 1.3 of this          %
+% license or any later version. The latest version of this license         %
+% is in http://www.latex-project.org/lppl.txt and version 1.3 or later     %
+% is part of all distributions of LaTeX version 2005/12/01 or later.       %
+%                                                                          %
+% Copyright (c) 2009 Ahmed Musa (a.musa@rocketmail.com).                   %
+%                                                                          %
+%++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++%
+\begingroup
+\catcode064=11% @
+\catcode123=01% {
+\catcode125=02% }
+\def\x{\endgroup
+  \edef\dmark@restorecodeatend{%
+    \catcode035=\the\catcode035\relax
+    \catcode064=\the\catcode064\relax
+    \catcode123=\the\catcode123\relax
+    \catcode125=\the\catcode125\relax
+  }%
+}
+\x
+\catcode035=06% #
+\catcode064=11% @
+\catcode123=01% {
+\catcode125=02% }
+\def\dmark@ensurecode#1#2{%
+  \edef\dmark@restorecodeatend{%
+    \dmark@restorecodeatend
+    \catcode#1=\the\catcode#1\relax
+  }%
+  \catcode#1=#2\relax
+}
+\dmark@ensurecode{010}{12}% ^^J
+\dmark@ensurecode{033}{12}% !
+\dmark@ensurecode{039}{12}% '
+\dmark@ensurecode{040}{12}% (
+\dmark@ensurecode{041}{12}% )
+\dmark@ensurecode{042}{12}% *
+\dmark@ensurecode{044}{12}% ,
+\dmark@ensurecode{045}{12}% -
+\dmark@ensurecode{046}{12}% .
+\dmark@ensurecode{047}{12}% /
+\dmark@ensurecode{058}{12}% :
+\dmark@ensurecode{060}{12}% <
+\dmark@ensurecode{061}{12}% =
+\dmark@ensurecode{062}{12}% >
+\dmark@ensurecode{094}{07}% ^ (superscript)
+\dmark@ensurecode{096}{12}% `
+\dmark@ensurecode{254}{12}% ^^fe
+\dmark@ensurecode{255}{12}% ^^ff
+\dmark@ensurecode{126}{13}% ~ (active)
+\AtEndOfPackage{\dmark@restorecodeatend}
+\def\readRCS$#1 #2 #3 #4 #5 #6 #7 #8 ${%
+  \def\filedate{#4}%
+  \def\fileversion{v#3}%
+  \def\filetime{#5}%
+  \def\fileauthor{#6\space#7}
+}
+\def\filedesc{%
+  Puts user-specified watermarks on select document pages (\fileauthor)}
+\readRCS
+$Id: draftmark.sty,v 1.2 2009/10/07 09:00:00 Ahmed Musa Exp $
+\ProvidesPackage{draftmark}[\filedate\space\fileversion\space\filedesc]
+\NeedsTeXFormat{LaTeX2e}[1996/12/01]
+\RequirePackage{fix-cm}
+\RequirePackage{graphicx}
+\RequirePackage{xkeyval}[2008/08/13]
+\RequirePackage{etextools}[2009/09/30]
+\RequirePackage{atbegshi}
+\RequirePackage{picture}
+\RequirePackage{xcolor}
+\RequirePackage{xifthen}[2009/04/17]
+\RequirePackage{ltxnew}
+\newrobustcmd\dmark@info[1]{\PackageInfo{draftmark}{#1\@gobble}}
+\newrobustcmd\dmark@warn[1]{\PackageWarningNoLine{draftmark}{#1}}
+\newrobustcmd\dmark@err[1]{\PackageError{draftmark}{#1}{\@ehc}}
+\def\dmark@numexpr#1#2{\xifblank{#2}{%
+    \expandafter\dmark@err{Blank argument for number}}{}
+  \ifundef{#1}{\new\count#1\relax #1=\numexpr#2\relax}{#1=\numexpr#2\relax}
+}
+\def\dmark@dimexpr#1#2{\xifblank{#2}{%
+  \expandafter\dmark@err{Blank argument for dimension}}{}
+  \ifundef{#1}{\new\dimen#1\relax #1=\dimexpr#2\relax}{#1=\dimexpr#2\relax}
+}
+\new\let\dmark@papercenter\relax
+\dmark@numexpr{\c@dmark@page}{\z@}
+\define@boolkey[KV]{draftmark}[dmark@]{draft}[true]{%
+  \ifdmark@draft\global\dmark@finalfalse\fi}
+\define@boolkey[KV]{draftmark}[dmark@]{final}[true]{%
+  \ifdmark@final\global\dmark@draftfalse\fi}
+\define@boolkeys[KV]{draftmark}[dmark@]{particularpage,
+  pagerange,showcenter,acceptrange}[true]
+\define@boolkey[KV]{draftmark}[dmark@]{firstpage}[true]{%
+  \ifdmark@firstpage\c@dmark@page=\@ne\fi}
+\define@boolkey[KV]{draftmark}[dmark@]{allpages}[true]{%
+  \ifdmark@allpages\c@dmark@page=\@ne\fi}
+\define@boolkey[KV]{draftmark}[dmark@]{oddpages}[true]{%
+  \ifdmark@oddpages\c@dmark@page=\@ne\fi}
+\define@boolkey[KV]{draftmark}[dmark@]{evenpages}[true]{%
+  \ifdmark@evenpages\c@dmark@page=\@ne\fi}
+\define@cmdkey[KV]{draftmark}[dmark@]{page}[1]{%
+  \dmark@particularpagetrue\c@dmark@page=\@ne\relax
+}
+\new\def\dmark@papercenter{\color{red}%
+  \put(0,-0.5\paperheight){\line(1,0){\paperwidth}}
+  \put(0.5\paperwidth,0){\line(0,-1){\paperheight}}
+  \put(0.5\paperwidth,-0.5\paperheight){\circle{10}}
+}
+\define@cmdkey[KV]{draftmark}[dmark@]{pages}[1-1]{%
+  \dmark@pagerangetrue\c@dmark@page=\@ne\relax
+}
+\define@cmdkey[KV]{draftmark}[dmark@]{fontfamily}[cmr]{}
+\define@cmdkey[KV]{draftmark}[dmark@]{fontsize}[5cm]{}
+\define@cmdkey[KV]{draftmark}[dmark@]{mark}[DRAFT]{}
+\define@key[KV]{draftmark}{color}[gray]{%
+  \xifstrequal{#1}{gray}{%
+    \def\dmark@color{\color[gray]{\dmark@grayness}}%
+  }{\def\dmark@color{\color{#1}}}
+}
+\define@cmdkey[KV]{draftmark}[dmark@]{grayness}[0.8]{}
+\define@cmdkey[KV]{draftmark}[dmark@]{angle}[45]{}
+\define@cmdkey[KV]{draftmark}[dmark@]{scale}[1]{}
+\define@cmdkey[KV]{draftmark}[dmark@]{coordunit}[mm]{}
+\define@key[KV]{draftmark}{xcoord}[0]{%
+  \dmark@dimexpr{\dmark@xcoord}{0.5\paperwidth+#1\dmark@coordunit}%
+}
+\define@key[KV]{draftmark}{ycoord}[0]{%
+  \dmark@dimexpr{\dmark@ycoord}{-0.5\paperheight+#1\dmark@coordunit}%
+}
+\DeclareOptionX*{\dmark@warn{Unknown option '\CurrentOption' ignored}}
+\ExecuteOptionsX[KV]<draftmark>{angle,scale,mark,color,grayness,
+  fontfamily,fontsize,coordunit,xcoord,ycoord,final}
+\ProcessOptionsX*[KV]<draftmark>\relax
+\new\gdef\draftmarksetup#1{\setkeys[KV]{draftmark}{#1}}
+\ifbool{dmark@acceptrange}{\RequirePackage[acceptempty]{pagerange}}{%
+  \RequirePackage[acceptempty=false]{pagerange}}
+\ifdmark@final
+  \dmark@info{Option 'final': no draftmark printed}
+  \expandafter\endinput
+\fi
+\newcommand\dmark@draftmark{%
+  \begingroup
+  \makebox(0,0){\rotatebox{\dmark@angle}{\scalebox{\dmark@scale}{%
+  \parbox[c]{\paperheight}{\dmark@color\centering
+    \fontfamily{\dmark@fontfamily}\fontseries{b}%
+    \fontsize{\dmark@fontsize}{1.2\dmark@fontsize}\selectfont
+    \dmark@mark
+  }}}}%
+  \endgroup
+}
+\newrobustcmd\dmark@tempa{%
+  \put(\dmark@xcoord,\dmark@ycoord){\dmark@draftmark}%
+  \ifdmark@showcenter\dmark@papercenter\fi
+}
+\newrobustcmd\dmark@printdraftmark{%
+  \ifnum\c@dmark@page=\z@
+    \ifnum\c@page=\@ne
+      \dmark@tempa%
+    \fi
+  \else\ifnum\c@dmark@page=\@ne
+    \ifdmark@allpages
+      \dmark@tempa%
+    \else\ifdmark@firstpage
+      \ifnum\c@page=\@ne
+        \dmark@tempa%
+      \fi
+    \else\ifdmark@oddpages
+      \ifodd\c@page
+        \dmark@tempa%
+      \fi
+    \else\ifdmark@evenpages
+      \unless\ifodd\c@page
+        \dmark@tempa%
+      \fi
+    \else\ifdmark@particularpage
+      \ifnum\c@page=\dmark@page
+        \dmark@tempa%
+      \fi
+    \else\ifdmark@pagerange
+      \pagerange{\dmark@pages}%
+      \dmark@numexpr{\dmark@pagestart}{\pagestart}%
+      \dmark@numexpr{\dmark@pageend}{\pageend}%
+      \ifthenelse{\(\c@page=\dmark@pagestart\OR\c@page=\dmark@pageend\)
+        \OR \(\c@page>\dmark@pagestart\AND\c@page<\dmark@pageend\)}{%
+        \dmark@tempa}{}
+    \fi\fi\fi\fi\fi\fi
+  \fi\fi
+}
+\ifdmark@draft
+  \AtBeginShipout{\AtBeginShipoutUpperLeft{\dmark@printdraftmark}}%
+  \dmark@info{Option 'draft': draftmark printed}
+  \ifnum\c@dmark@page=\z@
+    \dmark@warn{Draftmark printed on page 1 only:\MessageBreak
+      No page option ('allpages', 'firstpage',\MessageBreak
+      'oddpages', 'evenpages', 'page=value'\MessageBreak
+      or 'pages=x-x') has been passed to package}
+\fi\fi
+
+\endinput
diff --git a/drexel-thesis.cls b/drexel-thesis.cls
new file mode 100644 (file)
index 0000000..b9f6269
--- /dev/null
@@ -0,0 +1,1180 @@
+%%
+%% This is file `drexel-thesis.cls',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% drexel-thesis.dtx  (with options: `class')
+%% 
+%% This is a generated file.
+%% 
+%% Copyright (C) 2010-2012 W. Trevor King
+%% 
+%% This file may be distributed and/or modified under the conditions of
+%% the LaTeX Project Public License, either version 1.3 of this license
+%% or (at your option) any later version.  The latest version of this
+%% license is in:
+%% 
+%%    http://www.latex-project.org/lppl.txt
+%% 
+%% and version 1.3 or later is part of all distributions of LaTeX version
+%% 2003/06/01 or later.
+%% 
+\def\fileversion{0.15}
+\def\filedate{2013/05/21}
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesClass{drexel-thesis}
+ [\filedate\ \fileversion\ Drexel Thesis]
+\RequirePackage{xkeyval}
+\newif\if@mainmatter \@mainmattertrue
+\newif\if@DUT@subfigopt
+\newif\if@DUT@pagebreak
+\newif\if@dottedchapter
+\newif\if@boldchapter
+\newif\if@boldpart
+\newif\if@dottedpart
+\newif\if@indenttoc
+\newif\if@blackref
+\newif\if@draftwatermark
+\newif\if@xdraftwatermark
+\newif\if@indentfirst
+\newif\if@final
+\newif\if@daring
+\newif\if@approvalform
+\newcommand\iffinal[2]{\if@final #1\else #2\fi}
+\let\DUTiffinal\iffinal
+\newcommand\ifdraftwatermark[2]{\if@draftwatermark #1\else #2\fi}
+\let\DUTifdraftwatermark\ifdraftwatermark
+\newcommand\ifdaring[2]{\if@daring #1\else #2\fi}
+\let\DUTifdaring\ifdaring
+\newcommand\DUT@makeapprovalform{
+  \thispagestyle{empty}
+  \begingroup
+  \newlength{\tempskipa}
+  \newlength{\tempskipb}
+  \parindent \z@
+  \settowidth{\tempskipa}{\drexellogobw}
+  \addtolength{\tempskipa}{1em}
+  \setlength{\tempskipb}{\textwidth}
+  \addtolength{\tempskipb}{-\tempskipa}
+  \addtolength{\tempskipb}{-1em}
+  \begin{minipage}[c]{\tempskipa}
+    \raisebox{-0.5\height}{\drexellogobw}
+  \end{minipage}
+  \hfill
+  \begin{minipage}[c]{\tempskipb}
+    \textbf{\Huge Office of Graduate Studies} \linebreak
+    \vskip 0.1\baselineskip
+    \textbf{\LARGE Dissertation / Thesis Approval Form} \linebreak
+  \end{minipage}
+
+  \vskip 2\baselineskip
+
+  This form is for use by all doctoral and master's students with a
+  dissertation/thesis requirement.  Please print clearly as the
+  library will bind a copy of this form with each copy of the
+  dissertation/thesis.  All doctoral dissertations must conform to
+  university format requirements, which is the responsibility of the
+  student and supervising professor.  Students should obtain a copy of
+  the Thesis Manual located on the library website.
+
+  \vspace*{\fill}
+  \settowidth{\tempskipb}{Dissertation/Thesis Title:}
+  \setlength{\tempskipa}{\textwidth}
+  \addtolength{\tempskipa}{-\tempskipb}
+  \addtolength{\tempskipa}{-4em}
+  \begin{spacing}{2}
+    \begin{tabular*}{\textwidth}{@{\extracolsep{\fill}} l p{\tempskipa}}
+      \textbf{Dissertation/Thesis Title:} & \@DUT@title \\
+      \textbf{Author:} & \@DUT@author
+    \end{tabular*}
+
+    \vspace*{\fill}
+
+    \begin{center}
+      \textbf{This dissertation/thesis is hereby accepted and approved.}
+    \end{center}
+
+    \vspace*{\fill}
+
+    \textbf{Signatures:} \\
+    Examining Committee \\
+    \begin{tabular*}{\textwidth}{@{\extracolsep{\fill}} p{0pt} l p{\tempskipa}}
+      & Chair            & \hrulefill \\
+      & Members          & \hrulefill \\
+      &                  & \hrulefill \\
+      &                  & \hrulefill \\
+      &                  & \hrulefill \\
+      &                  & \hrulefill \\
+      & Academic Advisor & \hrulefill \\
+      & Department Head  & \hrulefill
+    \end{tabular*}
+
+    \vspace*{\fill}
+  \end{spacing}
+
+  \begin{center}\scriptsize
+    Office of Graduate Studies
+    $\bullet$ 3141 Chestnut St.
+    $\bullet$ Randell Hall 240
+    $\bullet$ Philadelphia, PA 19104 \\
+    \textbf{Tel.}: 215-895-0366
+    $\bullet$ \textbf{Fax}: 215-895-0495
+    $\bullet$ \textbf{Email}:
+      \href{mailto:graduate@drexel.edu}{graduate@drexel.edu}
+    $\bullet$ \textbf{Web}:
+      \href{http://www.drexel.edu/provost/graduatestudies/}{%
+                   www.drexel.edu/provost/graduatestudies}
+  \end{center}
+  \endgroup
+  \pagebreak
+}
+\newcommand\drexellogobw{
+  \begin{tikzpicture}[y=0.8pt, x=0.8pt,yscale=-1, inner sep=0pt, outer sep=0pt]
+  \begin{scope}[cm={{1.25,0.0,0.0,-1.25,(-332.5,550.73629)}},]
+    \path[fill=black,nonzero rule] (266.0000,367.4100) -- (338.0000,367.4100) --
+      (338.0000,440.5890) -- (266.0000,440.5890) -- (266.0000,367.4100) -- cycle;
+    \path[fill=white,nonzero rule] (269.3171,377.0107) -- (334.8469,377.0107) --
+      (334.8469,438.7106) -- (269.3171,438.7106) -- (269.3171,377.0107) -- cycle;
+    \path[fill=black,nonzero rule] (330.2168,398.2540) .. controls
+      (328.9195,397.9603) and (327.1082,397.5687) .. (326.0555,397.4220) --
+      (326.0555,396.7855) .. controls (327.6468,396.6388) and (327.6956,396.6388) ..
+      (327.6956,395.1942) -- (327.6956,383.2000) .. controls (327.6956,381.8537) and
+      (327.5489,381.7070) .. (326.0313,381.5600) -- (326.0313,380.8747) --
+      (331.9060,380.8747) -- (331.9060,381.5600) .. controls (330.3147,381.7070) and
+      (330.2168,381.8537) .. (330.2168,383.2000) -- (330.2168,398.2540) --
+      cycle(319.4750,387.8511) .. controls (319.6711,389.6870) and
+      (320.6989,390.8372) .. (321.7273,390.8372) .. controls (322.8042,390.8372) and
+      (323.5629,389.5642) .. (323.5629,388.5852) .. controls (323.5629,388.0466) and
+      (323.4650,387.8999) .. (323.1225,387.8999) -- (319.4750,387.8511) --
+      cycle(325.6436,383.5183) .. controls (324.6889,382.7839) and
+      (323.9057,382.4902) .. (323.0734,382.4902) .. controls (321.2375,382.4902) and
+      (319.3037,383.7632) .. (319.3528,386.8472) .. controls (322.0207,386.9454) and
+      (325.1787,387.1900) .. (325.5215,387.2391) .. controls (325.9865,387.3367) and
+      (326.0352,387.3858) .. (326.0352,388.2915) .. controls (326.0352,390.0540) and
+      (324.4443,391.7920) .. (322.3881,391.7920) .. controls (319.1570,391.7920) and
+      (316.8805,388.7813) .. (316.9296,385.7212) .. controls (316.9784,382.8575) and
+      (318.8630,380.5809) .. (322.0698,380.5809) .. controls (322.7551,380.5809) and
+      (324.5910,381.0704) .. (325.9865,383.1021) -- (325.6436,383.5183) --
+      cycle(312.6069,391.4983) -- (312.6069,390.8130) -- (313.2434,390.7393) ..
+      controls (313.7084,390.6659) and (313.5859,390.3968) .. (313.2188,389.7848) ..
+      controls (312.8518,389.1729) and (312.4111,388.5118) .. (311.9216,387.8265) --
+      (310.5019,389.9561) .. controls (310.1836,390.4210) and (310.2327,390.6659) ..
+      (310.6485,390.7147) -- (311.2851,390.8129) -- (311.2851,391.4982) --
+      (305.8754,391.4982) -- (305.8754,390.8129) .. controls (307.1972,390.6659) and
+      (307.3684,390.5680) .. (308.1762,389.3195) -- (310.4527,385.7948) .. controls
+      (309.6938,384.7667) and (308.9839,383.8365) .. (308.4211,383.1021) .. controls
+      (307.3930,381.7803) and (307.0259,381.7557) .. (305.6304,381.5599) --
+      (305.6304,380.8746) -- (310.2327,380.8746) -- (310.2327,381.5599) --
+      (309.5225,381.6824) .. controls (309.1309,381.7557) and (309.0576,381.9027) ..
+      (309.4492,382.5635) .. controls (309.9142,383.3470) and (310.4528,384.1547) ..
+      (310.9914,384.9379) -- (312.5824,382.5147) .. controls (312.9006,382.0252) and
+      (312.8761,381.7069) .. (312.4353,381.6581) -- (311.7258,381.5599) --
+      (311.7258,380.8746) -- (317.5271,380.8746) -- (317.5271,381.5599) .. controls
+      (316.2053,381.7069) and (315.8867,381.8048) .. (314.9323,383.2491) --
+      (312.4599,386.9942) .. controls (313.3168,388.1693) and (314.0021,389.0259) ..
+      (314.2715,389.3683) .. controls (315.2997,390.6168) and (315.5934,390.6659) ..
+      (317.1355,390.8129) -- (317.1355,391.4982) -- (312.6069,391.4982) --
+      cycle(299.3927,387.8511) .. controls (299.5885,389.6870) and
+      (300.6166,390.8372) .. (301.6447,390.8372) .. controls (302.7220,390.8372) and
+      (303.4806,389.5642) .. (303.4806,388.5852) .. controls (303.4806,388.0466) and
+      (303.3827,387.8999) .. (303.0402,387.8999) -- (299.3927,387.8511) --
+      cycle(305.5614,383.5183) .. controls (304.6066,382.7839) and
+      (303.8234,382.4902) .. (302.9911,382.4902) .. controls (301.1552,382.4902) and
+      (299.2215,383.7632) .. (299.2706,386.8472) .. controls (301.9384,386.9454) and
+      (305.0961,387.1900) .. (305.4389,387.2391) .. controls (305.9039,387.3367) and
+      (305.9530,387.3858) .. (305.9530,388.2915) .. controls (305.9530,390.0540) and
+      (304.3617,391.7920) .. (302.3058,391.7920) .. controls (299.0745,391.7920) and
+      (296.7982,388.7813) .. (296.8470,385.7212) .. controls (296.8961,382.8575) and
+      (298.7808,380.5809) .. (301.9876,380.5809) .. controls (302.6729,380.5809) and
+      (304.5087,381.0704) .. (305.9039,383.1021) -- (305.5614,383.5183) --
+      cycle(292.7087,391.8408) .. controls (291.4360,391.4492) and
+      (289.8205,391.1067) .. (288.6211,390.9109) -- (288.6211,390.3477) .. controls
+      (290.1387,390.2007) and (290.1875,390.1519) .. (290.1875,388.6585) --
+      (290.1875,383.2000) .. controls (290.1875,381.8537) and (290.0408,381.7070) ..
+      (288.5965,381.5600) -- (288.5965,380.8747) -- (294.6428,380.8747) --
+      (294.6428,381.5600) .. controls (292.8557,381.7070) and (292.7087,381.8537) ..
+      (292.7087,383.2000) -- (292.7087,388.1448) .. controls (293.2476,389.2217) and
+      (293.8105,389.5154) .. (294.2266,389.5154) .. controls (294.6182,389.5154) and
+      (295.0098,389.3196) .. (295.3526,388.9771) .. controls (295.4993,388.8301) and
+      (295.7930,388.7813) .. (296.0625,388.8789) .. controls (296.6253,389.0993) and
+      (297.0660,389.8091) .. (297.0660,390.4211) .. controls (297.0660,391.1067) and
+      (296.4298,391.8408) .. (295.5484,391.8408) .. controls (294.3487,391.8408) and
+      (293.3697,390.2986) .. (292.7823,389.3684) -- (292.7086,389.3684) --
+      (292.7086,391.8408) -- cycle(276.3892,394.4356) .. controls
+      (276.3892,395.0721) and (276.3892,395.5125) .. (276.5362,395.6350) .. controls
+      (276.6829,395.7574) and (277.3194,395.8553) .. (278.1272,395.8553) .. controls
+      (282.0438,395.8553) and (284.6874,394.0440) .. (284.6874,388.8055) .. controls
+      (284.6874,384.7422) and (282.5821,381.8782) .. (278.5188,381.8782) .. controls
+      (276.6341,381.8782) and (276.3892,382.3435) .. (276.3892,384.5952) --
+      (276.3892,394.4356) -- cycle(271.6405,396.7855) -- (271.6405,396.0999) ..
+      controls (273.4518,395.9532) and (273.6476,395.7574) .. (273.6476,393.1138) --
+      (273.6476,384.5464) .. controls (273.6476,381.9028) and (273.4518,381.7070) ..
+      (271.4447,381.5599) -- (271.4447,380.8746) -- (277.4419,380.8746) .. controls
+      (283.1695,380.8746) and (287.8206,383.5183) .. (287.8206,389.5399) .. controls
+      (287.8206,391.6941) and (286.8903,393.5054) .. (285.7643,394.6314) .. controls
+      (284.1488,396.1981) and (281.6522,396.7855) .. (278.9104,396.7855) --
+      (271.6405,396.7855);
+    \path[fill=white,nonzero rule] (277.1649,373.9784) -- (277.1649,371.3099) ..
+      controls (277.1649,370.4792) and (277.1239,369.7235) .. (276.0893,369.7235) ..
+      controls (275.0546,369.7235) and (275.0137,370.4792) .. (275.0137,371.3099) --
+      (275.0137,373.9784) -- (273.9584,373.9784) -- (273.9584,370.9013) .. controls
+      (273.9584,369.5942) and (274.8978,368.9613) .. (276.0893,368.9613) .. controls
+      (277.2808,368.9613) and (278.2201,369.5942) .. (278.2201,370.9013) --
+      (278.2201,373.9784) -- (277.1649,373.9784);
+    \path[fill=white,nonzero rule] (285.3943,369.0631) -- (285.3943,373.9784) --
+      (284.4072,373.9784) -- (284.4072,370.1253) -- (284.3933,370.1119) --
+      (282.5215,373.9785) -- (280.9557,373.9785) -- (280.9557,369.0632) --
+      (281.9429,369.0632) -- (281.9429,373.1344) -- (281.9563,373.1482) --
+      (283.8966,369.0632) -- (285.3943,369.0632);
+    \path[fill=white,nonzero rule] (287.9938,369.0631) -- (289.0489,369.0631) --
+      (289.0489,373.9783) -- (287.9938,373.9783) -- (287.9938,369.0631) -- cycle;
+    \path[fill=white,nonzero rule] (293.1186,369.0631) -- (294.2692,369.0631) --
+      (296.0802,373.9784) -- (295.0383,373.9784) -- (293.7518,370.1047) --
+      (293.7380,370.1047) -- (292.4581,373.9784) -- (291.3076,373.9784) --
+      (293.1186,369.0631);
+    \path[fill=white,nonzero rule] (298.3125,369.0631) -- (301.6824,369.0631) --
+      (301.6824,369.8804) -- (299.3678,369.8804) -- (299.3678,371.1940) --
+      (301.4647,371.1940) -- (301.4647,372.0109) -- (299.3678,372.0109) --
+      (299.3678,373.1615) -- (301.6078,373.1615) -- (301.6078,373.9784) --
+      (298.3125,373.9784) -- (298.3125,369.0631);
+    \path[fill=white,nonzero rule] (305.3086,373.1615) -- (306.1936,373.1615) ..
+      controls (306.6566,373.1545) and (306.9291,372.9710) .. (306.9291,372.5352) ..
+      controls (306.9291,372.0997) and (306.6566,371.8682) .. (306.1936,371.8613) --
+      (305.3086,371.8613) -- (305.3086,373.1615) -- cycle(305.3086,371.0444) --
+      (306.4251,371.0444) .. controls (306.7722,371.0306) and (306.8403,370.6564) ..
+      (306.8675,370.3840) .. controls (306.9153,369.9413) and (306.9631,369.4989) ..
+      (307.0515,369.0631) -- (308.2158,369.0631) .. controls (308.0181,369.3356) and
+      (307.9771,369.9141) .. (307.9297,370.2275) .. controls (307.8413,370.9082) and
+      (307.8413,371.4052) .. (307.0309,371.4936) -- (307.0309,371.5074) .. controls
+      (307.6369,371.6368) and (308.0521,372.0588) .. (308.0521,372.6986) .. controls
+      (308.0521,373.6995) and (307.1877,373.9719) .. (306.3436,373.9785) --
+      (304.2533,373.9785) -- (304.2533,369.0632) -- (305.3086,369.0632) --
+      (305.3086,371.0444);
+    \path[fill=white,nonzero rule] (314.2601,372.5761) .. controls
+      (314.2601,373.5633) and (313.5181,374.0806) .. (312.5650,374.0806) .. controls
+      (311.5572,374.0806) and (310.5225,373.5836) .. (310.5225,372.4605) .. controls
+      (310.5225,371.5889) and (311.4619,371.2759) .. (312.1495,371.1056) .. controls
+      (312.5719,370.9969) and (313.2729,370.9560) .. (313.2729,370.3771) .. controls
+      (313.2729,369.8529) and (312.7146,369.7235) .. (312.2926,369.7235) .. controls
+      (311.7412,369.7235) and (311.4282,370.0912) .. (311.4691,370.6358) --
+      (310.3932,370.6358) .. controls (310.3592,369.3968) and (311.1558,368.9613) ..
+      (312.2792,368.9613) .. controls (313.3341,368.9613) and (314.3963,369.3834) ..
+      (314.3963,370.6017) .. controls (314.3963,371.5889) and (313.2935,371.8001) ..
+      (312.5447,371.9906) .. controls (312.1227,372.0928) and (311.6459,372.1540) ..
+      (311.6459,372.6851) .. controls (311.6459,373.1140) and (312.0408,373.3184) ..
+      (312.4288,373.3184) .. controls (312.9393,373.3184) and (313.2048,373.0731) ..
+      (313.2457,372.5761) -- (314.2601,372.5761);
+    \path[fill=white,nonzero rule] (316.8870,369.0631) -- (317.9422,369.0631) --
+      (317.9422,373.9783) -- (316.8870,373.9783) -- (316.8870,369.0631) -- cycle;
+    \path[fill=white,nonzero rule] (320.2146,373.1615) -- (321.6782,373.1615) --
+      (321.6782,369.0631) -- (322.7335,369.0631) -- (322.7335,373.1615) --
+      (324.1971,373.1615) -- (324.1971,373.9784) -- (320.2146,373.9784) --
+      (320.2146,373.1615);
+    \path[fill=white,nonzero rule] (327.7961,369.0631) -- (328.8511,369.0631) --
+      (328.8511,370.6701) -- (330.5056,373.9784) -- (329.4231,373.9784) --
+      (328.3881,371.7251) -- (327.3741,373.9784) -- (326.1417,373.9784) --
+      (327.7961,370.6701) -- (327.7961,369.0631);
+    \path[fill=black,nonzero rule] (317.2675,431.5469) .. controls
+      (316.1860,431.3992) and (315.2214,430.7506) .. (314.6366,429.7477) .. controls
+      (314.1108,428.7739) and (313.9058,427.3581) .. (314.6661,426.4142) .. controls
+      (315.0459,425.9718) and (315.5138,425.6179) .. (316.0986,425.5884) .. controls
+      (317.6768,425.7655) and (318.7000,427.4174) .. (320.2199,427.8005) .. controls
+      (321.2140,428.1250) and (322.0325,427.5647) .. (322.7342,427.0042) .. controls
+      (323.2604,426.6797) and (323.9912,426.7681) .. (324.4882,427.0926) .. controls
+      (322.8511,425.7652) and (321.7401,423.7889) .. (321.5650,421.6357) .. controls
+      (321.3308,422.6386) and (320.7169,423.7299) .. (319.7232,424.0839) .. controls
+      (318.6126,424.4971) and (317.6480,423.8183) .. (316.8877,423.0810) .. controls
+      (316.1864,422.3436) and (315.8940,421.3997) .. (315.5138,420.5146) .. controls
+      (316.0400,420.9868) and (316.6834,421.6063) .. (317.4725,421.7536) .. controls
+      (318.4665,422.0486) and (319.4020,421.7241) .. (320.1911,421.1344) .. controls
+      (320.4540,420.8689) and (320.7759,420.6328) .. (320.8927,420.2199) .. controls
+      (319.8990,419.5415) and (319.5772,418.3909) .. (319.6358,417.1814) .. controls
+      (319.3142,418.1254) and (318.9636,419.2760) .. (317.8818,419.6889) .. controls
+      (317.1801,419.9839) and (316.3032,419.8955) .. (315.7479,419.3054) .. controls
+      (315.2800,418.8038) and (315.2509,418.0075) .. (315.3678,417.3291) .. controls
+      (315.8062,415.4120) and (317.5602,414.2909) .. (319.2265,413.7304) .. controls
+      (320.9514,413.1109) and (322.5299,411.5180) .. (322.7345,409.6304) .. controls
+      (322.9978,409.6893) and (323.4362,409.8956) .. (323.6700,409.6006) .. controls
+      (323.9329,410.4856) and (324.3422,411.6362) .. (325.3945,411.9309) .. controls
+      (326.1545,412.2262) and (326.9439,411.9309) .. (327.5287,411.4001) .. controls
+      (328.1426,410.7217) and (328.4350,409.8366) .. (328.2595,408.8927) .. controls
+      (328.1717,408.5093) and (327.9962,408.1553) .. (327.7625,407.8308) .. controls
+      (327.8502,408.2732) and (327.9088,408.9814) .. (327.6164,409.3943) .. controls
+      (327.3823,409.7188) and (327.0316,409.9548) .. (326.6515,409.9548) .. controls
+      (326.3594,409.9843) and (326.1548,409.8075) .. (326.0084,409.5714) .. controls
+      (325.6869,408.1258) and (327.4995,407.7424) .. (327.5578,406.3856) .. controls
+      (327.5873,405.6482) and (327.2949,404.9695) .. (326.6518,404.6453) .. controls
+      (325.9505,404.3503) and (325.1902,404.6155) .. (324.6932,405.1466) .. controls
+      (324.4303,405.3824) and (324.2256,405.6777) .. (324.1087,405.9724) .. controls
+      (324.6346,405.7072) and (325.5995,405.4416) .. (326.1548,405.9433) .. controls
+      (326.4180,406.1790) and (326.5346,406.4740) .. (326.5346,406.8280) .. controls
+      (326.5932,407.3591) and (326.1839,407.8014) .. (325.8333,408.0964) .. controls
+      (325.5114,408.3325) and (325.1607,408.4798) .. (324.7515,408.5388) .. controls
+      (324.9856,408.0669) and (324.9564,407.4180) .. (324.6346,407.0051) .. controls
+      (324.1087,406.2677) and (323.1733,406.3264) .. (322.3547,406.4151) .. controls
+      (321.4779,404.2030) and (319.0516,403.0230) .. (316.8884,402.4330) --
+      (315.3098,402.3151) .. controls (316.3039,401.6956) and (317.3562,401.2234) ..
+      (318.4086,400.7222) .. controls (318.9639,401.7251) and (319.7530,402.8458) ..
+      (320.9517,403.0819) .. controls (321.8285,403.1998) and (322.6471,402.9048) ..
+      (323.1441,402.1969) .. controls (323.5534,401.4595) and (323.8163,400.4566) ..
+      (323.4657,399.6011) -- (323.0855,398.8932) .. controls (323.2610,399.5421) and
+      (323.0563,400.3682) .. (322.5011,400.8695) .. controls (322.2087,401.1056) and
+      (321.8285,401.2234) .. (321.4484,401.1645) .. controls (321.0977,401.1056) and
+      (320.7471,400.8695) .. (320.6302,400.5156) .. controls (320.2500,398.7753) and
+      (322.8226,398.7458) .. (322.5302,396.9761) .. controls (322.4719,396.5039) and
+      (322.2673,396.1205) .. (321.8580,395.7961) .. controls (321.2444,395.2948) and
+      (320.1331,395.2358) .. (319.4026,395.6192) .. controls (318.9348,395.7961) and
+      (318.5255,396.1795) .. (318.1457,396.5039) .. controls (317.5609,396.1795) and
+      (316.6546,396.1503) .. (316.1284,396.6221) .. controls (315.3393,397.2711) and
+      (315.1930,398.2147) .. (314.9592,399.1292) .. controls (311.7435,400.3977) and
+      (308.7325,402.2561) .. (306.2186,404.9698) .. controls (304.4354,406.8872) and
+      (303.6460,409.5125) .. (304.0553,412.1968) .. controls (304.4646,414.6744) and
+      (304.2305,417.5357) .. (302.0966,419.0108) .. controls (301.1026,419.5415) and
+      (299.8161,419.8071) .. (298.7055,419.3647) .. controls (297.5945,418.8929) and
+      (296.8346,417.6539) .. (296.8054,416.4150) .. controls (296.8640,414.2026) and
+      (298.0919,412.3444) .. (299.0860,410.4565) .. controls (300.0214,408.2146) and
+      (299.6121,405.4122) .. (297.8581,403.7607) .. controls (296.4842,402.0793) and
+      (294.5259,401.5780) .. (293.0057,400.1914) .. controls (292.8010,399.9848) and
+      (292.7136,399.6606) .. (292.8305,399.3951) .. controls (293.3275,398.7462) and
+      (294.2921,398.7462) .. (295.1107,398.8051) .. controls (296.8644,399.1296) and
+      (298.1796,400.4570) .. (299.8459,400.9288) .. controls (300.8986,401.0764) and
+      (301.9215,400.7225) .. (302.4771,399.8080) .. controls (302.6817,399.4246) and
+      (302.8569,398.9230) .. (302.7109,398.4511) .. controls (302.5648,397.9790) and
+      (302.2138,397.5367) .. (301.8046,397.3300) .. controls (301.5416,397.2122) and
+      (301.1615,397.2416) .. (300.8691,397.2711) .. controls (301.2201,397.3893) and
+      (301.6585,397.6546) .. (301.7754,398.1264) .. controls (301.8631,398.5101) and
+      (301.7463,398.9230) .. (301.4830,399.2180) .. controls (301.1615,399.5130) and
+      (300.8108,399.6607) .. (300.3724,399.6607) .. controls (300.6353,399.3359) and
+      (300.8691,398.8935) .. (300.8108,398.3919) .. controls (300.6939,397.6251) and
+      (300.1678,396.8877) .. (299.4075,396.6811) .. controls (299.0277,396.5633) and
+      (298.6475,396.7106) .. (298.3260,396.9172) .. controls (298.0339,397.1533) and
+      (297.9167,397.4188) .. (297.7707,397.7138) .. controls (297.9753,397.5072) and
+      (298.2383,397.3599) .. (298.5306,397.3893) .. controls (298.9399,397.4482) and
+      (299.2323,397.6840) .. (299.3783,398.0678) .. controls (299.4661,398.3330) and
+      (299.4661,398.6873) .. (299.3197,398.9230) .. controls (299.1446,399.1885) and
+      (298.8522,399.3657) .. (298.5015,399.2769) .. controls (297.3906,398.9230) and
+      (297.1568,397.3599) .. (296.0167,397.0056) .. controls (294.5551,396.8877) and
+      (293.0057,397.0649) .. (291.4858,396.9761) -- (286.8671,396.8582) .. controls
+      (286.6042,396.9466) and (286.2824,397.0056) .. (286.1655,397.3009) .. controls
+      (285.6393,398.1856) and (286.9549,399.1885) .. (285.8439,399.8673) .. controls
+      (283.0376,401.7843) and (279.9097,403.7017) .. (278.0679,406.8283) .. controls
+      (276.4017,409.6307) and (274.9692,413.8490) .. (277.0735,416.9166) .. controls
+      (278.1845,418.5095) and (280.0263,419.4535) .. (282.0432,419.0995) .. controls
+      (283.6508,418.8929) and (284.9956,417.5656) .. (285.4049,416.0316) --
+      (285.4927,415.5005) .. controls (284.8787,416.5921) and (283.8850,417.6834) ..
+      (282.6277,418.0963) .. controls (282.7449,417.7718) and (282.6863,417.3000) ..
+      (282.6280,416.9461) .. controls (282.3942,417.4771) and (281.7509,417.9490) ..
+      (281.1664,418.1556) .. controls (281.4293,417.6834) and (281.7220,417.1229) ..
+      (281.6340,416.5037) .. controls (281.2247,416.9755) and (280.6111,417.4474) ..
+      (279.9386,417.2705) .. controls (280.4647,416.8282) and (280.9326,416.3560) ..
+      (281.1373,415.6776) .. controls (280.6697,415.9726) and (279.9680,416.2676) ..
+      (279.3246,416.0021) .. controls (279.8803,415.6482) and (280.8743,415.3531) ..
+      (280.8743,414.4386) .. controls (280.5819,414.6453) and (280.1727,414.7337) ..
+      (279.8217,414.6453) -- (279.3832,414.4386) .. controls (279.8217,414.2618) and
+      (280.4356,414.1145) .. (280.7571,413.6424) -- (281.0204,413.1705) .. controls
+      (280.4064,413.2294) and (279.7634,413.1407) .. (279.3246,412.6689) .. controls
+      (279.9972,412.5510) and (280.6988,412.4626) .. (281.1373,411.8432) .. controls
+      (280.5525,411.6955) and (279.9386,411.3710) .. (279.7339,410.7221) .. controls
+      (280.2896,411.0171) and (281.1373,411.0171) .. (281.6634,410.5747) .. controls
+      (281.0204,410.2208) and (280.3478,409.5423) .. (280.5233,408.6868) .. controls
+      (281.0790,409.1291) and (281.8681,409.5129) .. (282.6283,409.1586) .. controls
+      (281.8098,408.8047) and (281.2836,407.9789) .. (281.2541,407.1528) --
+      (281.2836,406.9171) .. controls (281.8681,407.5955) and (282.6284,408.0378) ..
+      (283.5344,407.8610) .. controls (282.7453,407.4773) and (282.3943,406.6810) ..
+      (282.4820,405.7959) .. controls (282.6284,405.8846) and (282.7453,406.0910) ..
+      (282.9208,406.2092) .. controls (283.4761,406.5631) and (284.0314,406.9171) ..
+      (284.6745,406.9465) .. controls (284.2360,406.3565) and (283.6221,405.5893) ..
+      (283.8854,404.7341) .. controls (284.2946,405.5013) and (285.0546,406.3270) ..
+      (285.9314,406.4154) .. controls (285.4930,405.8254) and (285.3470,405.0881) ..
+      (285.3470,404.3212) .. controls (285.9609,405.1765) and (286.8669,406.1794) ..
+      (287.8901,406.5631) .. controls (287.5391,405.9141) and (287.2176,404.8225) ..
+      (287.5977,404.0262) .. controls (287.8901,404.9997) and (288.5040,406.0026) ..
+      (289.2348,406.6512) .. controls (289.0885,405.8254) and (289.3517,405.0586) ..
+      (289.9948,404.4980) -- (290.0534,404.5569) .. controls (290.0239,405.6191) and
+      (290.4332,406.5333) .. (290.9594,407.3299) .. controls (290.8425,406.6220) and
+      (291.2517,405.9730) .. (291.8657,405.6188) -- (292.1289,405.5009) .. controls
+      (291.8365,406.2386) and (291.6319,407.0938) .. (291.7779,408.0083) .. controls
+      (292.3041,407.4478) and (293.0644,406.7693) .. (293.9117,406.8872) .. controls
+      (292.6551,408.0083) and (291.3978,409.2473) .. (290.8716,410.8104) .. controls
+      (291.3686,410.2797) and (292.1577,409.9254) .. (293.0054,409.9847) .. controls
+      (291.4272,411.1054) and (289.9948,413.0523) .. (289.8484,415.0876) .. controls
+      (290.1994,414.2618) and (290.9885,413.6125) .. (291.8071,413.3178) .. controls
+      (290.6961,414.9697) and (289.5269,416.8868) .. (290.1405,419.1286) .. controls
+      (290.2868,418.0668) and (290.9008,416.8868) .. (292.0117,416.5626) .. controls
+      (291.3978,417.7129) and (290.5792,418.8929) .. (290.7544,420.3676) .. controls
+      (290.8127,421.2821) and (291.1051,422.1671) .. (291.6312,422.9045) .. controls
+      (291.2514,422.0784) and (291.1928,420.7808) .. (291.9528,420.0137) --
+      (292.0114,419.9548) .. controls (291.7776,422.2556) and (292.6544,424.5269) ..
+      (294.6422,425.5888) -- (295.4022,426.0016) .. controls (294.7883,425.2050) and
+      (294.3793,424.3498) .. (294.3793,423.3171) .. controls (295.2558,425.2050) and
+      (297.0976,427.0635) .. (299.4364,426.9456) .. controls (299.7870,426.9751) and
+      (300.1086,426.9158) .. (300.4301,426.8569) .. controls (299.4655,426.4146) and
+      (298.2668,425.6769) .. (298.1499,424.4677) .. controls (299.7284,425.9129) and
+      (301.9503,426.7096) .. (304.1133,425.9129) .. controls (304.6103,425.7063) and
+      (305.1656,425.4411) .. (305.4872,425.0279) .. controls (304.7272,425.4411) and
+      (303.8504,425.1166) .. (303.2070,424.7034) .. controls (302.9149,424.4972) and
+      (302.5056,424.2021) .. (302.3888,423.8482) .. controls (303.8795,424.4088) and
+      (306.1597,424.7922) .. (307.3289,423.2877) -- (308.0598,422.1374) .. controls
+      (307.2707,422.6685) and (306.3352,423.1108) .. (305.3120,422.9046) .. controls
+      (305.1365,422.8453) and (304.9610,422.7569) .. (304.7858,422.6092) .. controls
+      (306.4226,422.5503) and (308.0306,421.7537) .. (308.7028,420.2200) --
+      (308.9075,419.3055) .. controls (308.4982,420.1021) and (307.6505,420.8984) ..
+      (306.6859,420.9279) .. controls (307.2412,420.3382) and (308.0892,419.7482) ..
+      (308.3521,418.9221) .. controls (308.9078,417.6831) and (309.0538,416.1789) ..
+      (310.3985,415.4121) .. controls (310.9247,415.1466) and (311.4800,414.9694) ..
+      (312.0648,414.8810) .. controls (310.0479,415.7068) and (309.3171,418.1258) ..
+      (309.1707,420.2495) .. controls (309.6677,419.6303) and (310.3108,419.0694) ..
+      (311.0125,418.7748) .. controls (310.6615,419.2171) and (310.3108,419.5121) ..
+      (309.9307,419.9839) .. controls (308.7614,421.4001) and (308.0598,423.2582) ..
+      (308.4982,425.1461) .. controls (308.8197,426.3553) and (309.6383,427.3582) ..
+      (310.4274,428.3611) .. controls (309.7846,427.1224) and (309.6674,425.3233) ..
+      (310.4569,424.1137) .. controls (310.8367,423.5237) and (311.3632,423.0221) ..
+      (311.8893,422.6387) .. controls (310.8661,423.9955) and (310.3982,426.0013) ..
+      (311.0122,427.7419) .. controls (311.8890,430.1312) and (314.3444,431.3993) ..
+      (316.7123,431.5764) -- (317.2676,431.5469);
+    \path[fill=white,nonzero rule] (314.4906,424.9100) .. controls
+      (314.8707,424.6150) and (315.4260,424.4378) .. (315.9231,424.6444) .. controls
+      (316.0109,424.6739) and (316.0986,424.7328) .. (316.2155,424.7623) .. controls
+      (315.7770,424.2905) and (315.3091,423.3171) .. (314.4906,423.5237) .. controls
+      (313.7892,424.0544) and (314.0522,425.1461) .. (313.9936,425.9424) .. controls
+      (314.0231,425.5295) and (314.1982,425.2050) .. (314.4906,424.9100);
+    \path[fill=white,nonzero rule] (312.1524,410.9578) .. controls
+      (312.7372,411.0167) and (313.2634,411.4001) .. (313.5849,411.8723) .. controls
+      (313.9356,410.8101) and (314.4621,409.1880) .. (313.5849,408.1851) .. controls
+      (313.3220,407.9196) and (313.0005,407.8014) .. (312.6203,407.8014) .. controls
+      (311.1587,407.8901) and (310.5157,409.4238) .. (310.1060,410.6627) .. controls
+      (309.8140,411.5183) and (309.8140,412.4623) .. (309.6968,413.4062) .. controls
+      (310.1355,412.3735) and (310.8663,410.9283) .. (312.1524,410.9578);
+    \path[fill=white,nonzero rule] (320.8934,398.4803) .. controls
+      (321.1563,398.2147) and (321.3023,397.9200) .. (321.2440,397.5363) .. controls
+      (321.2440,397.2122) and (320.9517,396.8874) .. (320.6887,396.7695) .. controls
+      (320.0748,396.5039) and (319.3440,396.7106) .. (318.8178,397.0056) .. controls
+      (319.3145,397.5068) and (319.6072,398.0969) .. (319.6947,398.7458) .. controls
+      (320.1331,398.8047) and (320.5424,398.7163) .. (320.8934,398.4803);
+    \path[fill=white,nonzero rule] (322.0034,426.5913) .. controls
+      (322.0616,426.2668) and (321.8865,426.0013) .. (321.6232,425.8834) .. controls
+      (321.1848,425.7652) and (320.6000,425.7652) .. (320.2785,426.1195) .. controls
+      (320.1324,426.3258) and (320.0447,426.6208) .. (320.2199,426.8274) .. controls
+      (320.6586,427.3581) and (321.6818,427.2403) .. (322.0034,426.5913);
+    \path[fill=white,nonzero rule] (317.0930,398.3624) .. controls
+      (317.0639,398.0968) and (316.8592,397.8611) .. (316.5963,397.8018) .. controls
+      (316.2453,397.7723) and (316.1575,398.0968) .. (316.0701,398.3624) --
+      (316.0406,398.7753) -- (317.0929,398.3624);
+    \path[fill=white,nonzero rule] (323.3484,407.8309) .. controls
+      (323.3193,407.3590) and (322.9977,407.1524) .. (322.5885,407.0051) .. controls
+      (322.7345,407.4474) and (322.7640,407.9785) .. (322.7057,408.4504) .. controls
+      (322.9686,408.3325) and (323.2315,408.1259) .. (323.3484,407.8309);
+  \end{scope}
+  \end{tikzpicture}
+}
+\DeclareOptionX{subfig}{\@DUT@subfigopttrue}
+\DeclareOptionX{finalspace}{
+  \setlength\overfullrule{0pt}
+  \def\@DUT@toc@sep{1} % content page separation (# blanklines between entries)
+  \def\@ssp{1} % single space
+  \def\@dsp{2} % double space
+  \def\@tsp{3} % triple space
+}
+\DeclareOptionX{draftspace}{
+  \setlength\overfullrule{5pt}
+  \def\DUT@toc@sep{0} % content page separation (# blanklines between entries)
+  \def\@ssp{1} % single space
+  \def\@dsp{1} % double space
+  \def\@tsp{2} % triple space
+}
+\DeclareOptionX{pagebreak}{
+  \@DUT@pagebreaktrue
+  \PassOptionsToClass{openright}{book}
+}
+\DeclareOptionX{nopagebreak}{
+  \@DUT@pagebreakfalse
+  \PassOptionsToClass{openany}{book}
+}
+\DeclareOptionX{dottedpart}{\@dottedparttrue}
+\DeclareOptionX{dottedchapter}{\@dottedchaptertrue}
+\DeclareOptionX{boldpart}{\@boldparttrue}
+\DeclareOptionX{boldchapter}{\@boldchaptertrue}
+\DeclareOptionX{dottedtoc}{
+  \setkeys{drexel-thesis.cls}{dottedpart}
+  \setkeys{drexel-thesis.cls}{dottedchapter}
+}
+\DeclareOptionX{boldtoc}{
+  \setkeys{drexel-thesis.cls}{boldpart}
+  \setkeys{drexel-thesis.cls}{boldchapter}
+}
+\DeclareOptionX{indenttoc}{\@indenttoctrue}
+\DeclareOptionX{blackref}{\@blackreftrue}
+\DeclareOptionX{draftwatermark}{%
+  \@draftwatermarktrue
+  \@xdraftwatermarkfalse}
+\DeclareOptionX{xdraftwatermark}{%
+  \@draftwatermarkfalse
+  \@xdraftwatermarktrue}
+ \DeclareOptionX{nodraftwatermark}{%
+  \@draftwatermarkfalse
+  \@xdraftwatermarkfalse}
+\DeclareOptionX{indentfirst}{\@indentfirsttrue}
+\DeclareOptionX{oneside}{\PassOptionsToClass{oneside}{book}}
+\DeclareOptionX{twoside}{\PassOptionsToClass{twoside}{book}}
+\DeclareOptionX{final}{
+  \@finaltrue
+  \setkeys{drexel-thesis.cls}{oneside}
+  \setkeys{drexel-thesis.cls}{finalspace}
+  \setkeys{drexel-thesis.cls}{pagebreak}
+  \setkeys{drexel-thesis.cls}{dottedtoc}
+}
+\DeclareOptionX{draft}{
+  \@finalfalse
+  \setkeys{drexel-thesis.cls}{twoside}
+  \setkeys{drexel-thesis.cls}{draftspace}
+  \setkeys{drexel-thesis.cls}{nopagebreak}
+  \setkeys{drexel-thesis.cls}{dottedtoc}
+  \setkeys{drexel-thesis.cls}{xdraftwatermark}
+}
+\DeclareOptionX{daring}{
+  \@daringtrue
+}
+\DeclareOptionX{approvalform}{
+  \@approvalformtrue
+}
+\DeclareOptionX*{\PassOptionsToClass{\CurrentOption}{book}}
+\ExecuteOptionsX{final}
+\ProcessOptionsX\relax
+\LoadClass{book}
+\RequirePackage{setspace}
+\RequirePackage{calc}
+\RequirePackage[final]{graphicx}
+\if@draftwatermark
+  \RequirePackage[draft,allpages,mark={DRAFT \today},
+                  fontsize=2cm,grayness=0.9]{draftmark}
+\fi
+\if@xdraftwatermark
+  \RequirePackage{eso-pic}
+  \RequirePackage{xcolor}
+  \definecolor{watermark}{rgb}{0.9,0.9,0.9}
+  \newcommand{\watermarkfont}{%
+    \color{watermark}}%\fontfamily{phv}\selectfont\sffamily}
+  \newcommand{\watermark}{%
+    \rule{4.25in}{0pt}\raisebox{5.5in}{%
+      \makebox[0pt]{%
+\rotatebox[origin=c]{45}{%
+          \resizebox{!}{1.5in}{%
+            {\watermarkfont DRAFT}%
+    }}}}
+    \raisebox{4.2in}{%
+      \makebox[0pt]{%
+\rotatebox[origin=c]{45}{%
+          \resizebox{!}{.6in}{%
+            {\watermarkfont \qquad\today}%
+    }}}}}
+  \AddToShipoutPicture{\watermark{}}
+\fi
+\if@indentfirst
+  \RequirePackage{indentfirst}
+\fi
+\RequirePackage[letterpaper,margin=1in,bindingoffset=0.5in]{geometry}
+\if@DUT@subfigopt
+  \RequirePackage[subfigure]{tocloft}
+\else
+  \RequirePackage{tocloft}
+\fi
+\RequirePackage[margin=10pt,labelfont=bf,labelsep=colon]{caption}
+\RequirePackage{floatrow}
+\floatsetup[table]{style=plaintop}
+\floatsetup{captionskip=10pt}
+\floatsetup[table]{captionskip=10pt}
+\if@DUT@subfigopt
+  \RequirePackage{fr-subfig}
+\fi
+\if@DUT@subfigopt
+  \RequirePackage{subfig}
+\fi
+\RequirePackage{fancyhdr}
+\pagestyle{fancy}
+\fancyhf{}
+\renewcommand{\headrulewidth}{0pt}
+\renewcommand{\footrulewidth}{0.4pt}
+\fancyfoot[RE,LO]{\scshape\leftmark}
+\fancyfoot[LE,RO]{\scshape\rightmark}
+\fancyhead[LE,RO]{\thepage}
+\fancypagestyle{plain}{
+  \fancyhf{}
+  \renewcommand{\footrulewidth}{0pt}
+  \fancyhead[LE,RO]{\thepage}
+}
+\fancypagestyle{empty}{
+  \fancyhf{}
+  \renewcommand{\footrulewidth}{0pt}
+}
+\RequirePackage{ifpdf}
+\if@approvalform\RequirePackage{tikz}\fi
+\renewcommand{\title}[1]{
+  \gdef\@DUT@title{#1}
+  \ifpdf \hypersetup{pdftitle={\@DUT@title}} \fi
+}
+\let\DUTtitle\title
+\def\@DUT@title{\@latex@error{No \noexpand\title given}\@ehc}
+\renewcommand{\author}[1]{
+  \gdef\@DUT@author{#1}
+  \ifpdf \hypersetup{pdfauthor={\protect\@DUT@author}} \fi
+}
+\let\DUTauthor\author
+\def\@DUT@author{\@latex@error{No \noexpand\author given}\@ehc}
+\def\DUTmonth#1{\gdef\@DUT@month{#1}}
+\def\@DUT@month{\@latex@error{No \noexpand\DUTmonth given}\@ehc}
+\def\DUTyear#1{\gdef\@DUT@year{#1}}
+\def\@DUT@year{\@latex@error{No \noexpand\DUTyear given}\@ehc}
+\def\degree#1{\gdef\@DUT@degree{#1}
+  \ifpdf \hypersetup{pdfsubject={\@DUT@degree}} \fi}
+\let\DUTdegree\degree
+\def\@DUT@degree{\@latex@error{No \noexpand\degree given}\@ehc}
+\def\copyrighttext#1{\gdef\@DUT@copyrighttext{#1}}
+\let\DUTcopyrighttext\copyrighttext
+\def\@DUT@copyrighttext{All Rights Reserved.}
+\newcounter{@DUT@advisors}
+\setcounter{@DUT@advisors}{0}
+\newcommand\advisor[1]{%
+  \ifx
+    \empty{#1}
+  \else
+    \stepcounter{@DUT@advisors}
+    \expandafter\gdef\csname @DUT@advisor@\alph{@DUT@advisors}\endcsname{#1}
+  \fi}
+\newcommand\@DUT@advisor{%
+  \ifnum\c@@DUT@advisors=0%
+    \@latex@error{No \noexpand\advisor given}\@ehc%
+  \else%
+    \begingroup%
+      \count@\@ne
+      \csname @DUT@advisor@\@alph\count@\endcsname\relax%
+      \loop\ifnum\count@<\c@@DUT@advisors%
+        \advance\count@\@ne
+        \ifnum\count@=\c@@DUT@advisors%
+          \ifnum\c@@DUT@advisors=2%
+            {\ and\ }%
+          \else%
+            {, and\ }%
+          \fi%
+        \else%
+          {,\ }%
+        \fi%
+        \csname @DUT@advisor@\@alph\count@\endcsname\relax%
+      \repeat%
+    \endgroup%
+  \fi}
+\newlength\@DUT@baselineskip
+\setlength\@DUT@baselineskip\baselineskip
+\newcommand{\set@lines@length}[2]{%
+  \setlength{#1}{\@DUT@baselineskip * {#2}}}
+\def\@sect#1#2#3#4#5#6[#7]#8{%
+  \ifnum #2>\c@secnumdepth
+    \let\@svsec\@empty
+  \else
+    \refstepcounter{#1}%
+    \protected@edef\@svsec{\@seccntformat{#1}\relax}%
+  \fi
+  \@tempskipa #5\relax
+  \ifdim \@tempskipa>\z@
+    \begingroup
+      \setstretch{\@ssp}%
+      #6{%
+        \@hangfrom{\hskip #3\relax\@svsec}%
+          \interlinepenalty \@M #8\@@par}%
+    \endgroup
+    \csname #1mark\endcsname{#7}%
+    \addcontentsline{toc}{#1}{%
+      \ifnum #2>\c@secnumdepth \else
+        \protect\numberline{\csname the#1\endcsname}%
+      \fi
+      #7}%
+  \else
+    \def\@svsechd{%
+      #6{\hskip #3\relax
+      \@svsec #8}%
+      \csname #1mark\endcsname{#7}%
+      \addcontentsline{toc}{#1}{%
+        \ifnum #2>\c@secnumdepth \else
+          \protect\numberline{\csname the#1\endcsname}%
+        \fi
+        #7}}%
+  \fi
+  \@xsect{#5}}
+\def\@ssect#1#2#3#4#5{%
+  \@tempskipa #3\relax
+  \ifdim \@tempskipa>\z@
+    \begingroup
+      \setstretch{\@ssp}%
+      #4{%
+        \@hangfrom{\hskip #1}%
+          \interlinepenalty \@M #5\@@par}%
+    \endgroup
+  \else
+    \def\@svsechd{#4{\hskip #1\relax #5}}%
+  \fi
+  \@xsect{#3}}
+\newcommand\@DUT@clearpage{%
+  \if@DUT@pagebreak \clearpage \else \blanklinesp{4} \fi}
+\newcommand\@DUT@cleardoublepage{%
+  \if@DUT@pagebreak \cleardoublepage \else \blanklinesp{4} \fi}
+\newcommand\@DUT@newpage{%
+  \if@DUT@pagebreak \newpage \else \blanklinesp{4} \fi}
+\newcommand\@DUT@blankpage{%
+  \if@DUT@pagebreak
+    \@DUT@clearpage
+    \thispagestyle{empty}
+    \hphantom{0}
+    \@DUT@clearpage
+  \fi
+}
+\newlength\@DUT@blanklines@length
+\newcommand{\@blanklines@setup}[1]{%
+  \set@lines@length{\@DUT@blanklines@length}{#1}%
+  %\typeout{BLANKLINES -- #1}%
+  %\showthe\@DUT@blanklines@length
+}
+\newcommand{\blanklines}{\@ifstar\@sblanklines\@blanklines}
+\newcommand{\@blanklines}[1]{%
+  \@blanklines@setup{#1}%
+  \vspace{\@DUT@blanklines@length}}
+\newcommand{\@sblanklines}[1]{%
+  \@blanklines@setup{#1}%
+  \vspace*{\@DUT@blanklines@length}}
+\newcommand{\blanklinesp}{\@ifstar\@sblanklines\@blanklines}
+\newcommand{\@blanklinesp}[1]{%
+  \@blanklines@setup{#1}%
+  \vspace{\@DUT@blanklines@length}\par}
+\newcommand{\@sblanklinesp}[1]{%
+  \@blanklines@setup{#1}%
+  \vspace*{\@DUT@blanklines@length}\par}
+\RequirePackage[final]{hyperref}
+\hypersetup{colorlinks}
+\if@blackref
+  \hypersetup{linkcolor=black}
+  \hypersetup{anchorcolor=black}
+  \hypersetup{citecolor=black}
+  \hypersetup{filecolor=black}
+  \hypersetup{menucolor=black}
+  \hypersetup{runcolor=black}
+  \hypersetup{urlcolor=black}
+\fi
+\RequirePackage[all]{hypcap}
+\set@lines@length{\floatsep}{\@ssp}
+\set@lines@length{\textfloatsep}{\@tsp}
+\newcommand\@DUT@maketitle{
+  \begin{@DUT@titlepage}%
+    \ifpdf
+      \pdfbookmark[-1]{Front Matter}{Front Matter}
+      \pdfbookmark[0]{Title Page}{Title Page}
+    \fi
+    \if@DUT@pagebreak \vspace*{\fill} \fi
+    \begin{center}%
+      {\setstretch{\@tsp} \bfseries \@DUT@title \par}%
+      \blanklines{\@tsp}%
+      \setstretch{\@dsp}%
+      A Thesis\\
+      Submitted to the Faculty\\
+      of\\
+      Drexel University\\
+      by\\
+      \@DUT@author\\
+      in partial fulfillment of the\\
+      requirements for the degree\\
+      of\\
+      \@DUT@degree\\
+      \@DUT@month\ \@DUT@year
+    \end{center}\par
+    \if@DUT@pagebreak \vspace*{\fill} \fi
+  \end{@DUT@titlepage}%
+  \setcounter{footnote}{0}%
+  \global\let\maketitle\relax
+  \global\let\and\relax
+}
+\newcommand\@DUT@makecopyright{%
+  \@DUT@clearpage
+  \ifpdf \pdfbookmark[0]{Copyright Page}{Copyright Page} \fi
+  \if@DUT@pagebreak \vspace*{\fill} \fi
+  \begin{center}
+    \copyright~Copyright \@DUT@year\\
+    \@DUT@author.  \@DUT@copyrighttext
+  \end{center}
+  \if@DUT@pagebreak \vspace*{\fill} \fi
+  \thispagestyle{empty}
+}
+\newcommand\copyrighttextCCBYSA{
+  \begin{quote}
+    This work is licensed under the terms of the Creative Commons
+    Attribution-ShareAlike license Version 3.0.  The license is
+    available at \\
+    \url{http://creativecommons.org/licenses/by-sa/3.0/}.
+  \end{quote}
+}
+\let\DUTcopyrighttextCCBYSA\copyrighttextCCBYSA
+\renewcommand\chaptermark[1]{%
+  \markboth {%
+    \ifnum \c@secnumdepth >\m@ne
+      \if@mainmatter
+        \@chapapp\ \thechapter: \ %
+      \fi
+    \fi
+    #1}{}}
+\newcommand\schaptermark[1]{\markboth{#1}{}}
+\renewcommand{\sectionmark}[1]{%
+  \markright {%
+    \ifnum \c@secnumdepth >\z@
+      \thesection \ %
+    \fi
+    #1}}
+\renewcommand\mainmatter{%
+  \@DUT@cleardoublepage
+  \@mainmattertrue
+  \pagenumbering{arabic}}
+\renewcommand\part{%
+  \if@openright
+    \@DUT@cleardoublepage
+  \else
+    \@DUT@clearpage
+  \fi
+  \thispagestyle{plain}%
+  \@tempswafalse
+  \if@DUT@pagebreak \null\vfil \fi
+  \secdef\@part\@spart}
+\def\@part[#1]#2{%
+    \ifnum \c@secnumdepth >-2\relax
+      \refstepcounter{part}%
+      \addcontentsline{toc}{part}%
+        {\protect\numberline{\thepart}#1}%
+    \else
+      \addcontentsline{toc}{part}{#1}%
+    \fi
+    \markboth{}{}%
+    {\centering
+     \interlinepenalty \@M
+     \normalfont
+     \ifnum \c@secnumdepth >-2\relax
+       \large\bfseries \partname\nobreakspace\thepart
+       \par
+       \vskip 20\p@
+     \fi
+     \large \bfseries #2\par}%
+    \@endpart}
+\def\@spart#1{%
+    {\centering
+     \interlinepenalty \@M
+     \normalfont
+     \large \bfseries #1\par}%
+    \@endpart}
+\def\@endpart{
+  \if@DUT@pagebreak \vfil\newpage \fi
+  \if@twoside
+    \if@openright
+      \null
+      \thispagestyle{empty}%
+      \newpage
+    \fi
+  \fi}
+\renewcommand\chapter{%
+  \if@openright\@DUT@cleardoublepage\else\@DUT@clearpage\fi
+  \thispagestyle{plain}%
+  \global\@topnum\z@
+  \@afterindentfalse
+  \secdef\@chapter\@schapter}
+\newcommand\listed@schapter[1]{%
+  \if@openright\@DUT@cleardoublepage\else\@DUT@clearpage\fi
+  \thispagestyle{plain}%
+  \global\@topnum\z@
+  \phantomsection
+  \addcontentsline{toc}{chapter}{#1}
+  \@afterindentfalse
+  \@schapter{#1}}
+\def\@chapter[#1]#2{
+  \let\@DUT@label=\label%
+  \renewcommand{\label}[1]{}%
+  \typeout{\@chapapp\space\thechapter. #1}%
+  \let\label=\@DUT@label%
+  \ifnum \c@secnumdepth >\m@ne
+    \if@mainmatter
+      \refstepcounter{chapter}%
+      \addcontentsline{toc}{chapter}{\protect\numberline{\thechapter}#1}%
+    \else
+      \addcontentsline{toc}{chapter}{#1}%
+    \fi
+  \else
+    \addcontentsline{toc}{chapter}{#1}%
+  \fi
+  \chaptermark{#1}%
+  \@makechapterhead{#2}%
+  \@afterheading}
+\def\@makechapterhead#1{%
+  \blanklines*{-1}% HACK!
+  {\parindent \z@ \raggedright \normalfont
+    \setstretch{\@ssp}%
+    \interlinepenalty\@M
+    \ifnum \c@secnumdepth >\m@ne
+      \if@mainmatter
+        \center \large \bfseries \@chapapp{} \thechapter: #1\par\nobreak
+      \else
+        \center \large \bfseries #1\par\nobreak
+      \fi
+    \else
+      \center \large \bfseries #1\par\nobreak
+    \fi
+    \blanklines{4}
+  }
+}
+\def\@schapter#1{
+  \typeout{\@chapapp\space #1}%
+  \schaptermark{#1}%
+  \@makeschapterhead{#1}%
+  \@afterheading}
+\def\@makeschapterhead#1{%
+  \blanklines*{-1}% HACK!
+  {\parindent \z@ \raggedright \normalfont
+    \setstretch{\@ssp}%
+    \interlinepenalty\@M
+    \center \large \bfseries  #1\par\nobreak
+    \blanklines{4}%
+  }
+}
+\renewcommand\section{%
+  \@startsection {section}{1}{\z@}%
+    {-3.5ex \@plus -1ex \@minus -.2ex}%
+    {2.3ex \@plus.2ex}%
+    {\normalfont\large\bfseries}}
+\newenvironment{preamble}{%
+  \cleardoublepage
+  \@mainmatterfalse
+  \pagenumbering{roman}
+  \if@approvalform
+    \ifpdf
+      \pdfbookmark[-1]{Approval Form}{Approval Form}
+    \fi
+    \DUT@makeapprovalform
+  \fi
+  \@DUT@maketitle
+  \@DUT@makecopyright
+}{%
+  \@DUT@blankpage
+}
+\let\DUTpreamble\preamble
+\let\endDUTpreamble\endpreamble
+\newenvironment{dedications}{%
+  \@DUT@clearpage
+  \ifpdf
+    \phantomsection
+    \pdfbookmark[0]{\DUTdedicationsname}{\DUTdedicationsname}
+  \fi
+  \chapter*{\DUTdedicationsname}
+  \setstretch{\@dsp}%
+}{%
+  \par\setstretch{\@ssp}%
+}
+\let\DUTdedications\dedications
+\let\endDUTdedications\enddedications
+\newenvironment{acknowledgments}{%
+  \@DUT@clearpage
+  \ifpdf
+    \phantomsection
+    \pdfbookmark[0]{\DUTacknowledgmentsname}{\DUTacknowledgmentsname}
+  \fi
+  \chapter*{\acknowledgmentsname}
+  \setstretch{\@dsp}%
+}{%
+  \par\setstretch{\@ssp}%
+}
+\let\DUTacknowledgments\acknowledgments
+\let\endDUTacknowledgments\endacknowledgments
+\newenvironment{abstract}{%
+  \listed@schapter{\abstractname}%
+  \blanklines{-4}%
+    \begin{center}
+      \setstretch{\@ssp}%
+      \@DUT@title\\
+      \@DUT@author\\
+      \ifdaring{%
+        \ifnum\c@@DUT@advisors=\@ne%
+        Advisor:
+        \else%
+        Advisors:
+        \fi}{}
+      \@DUT@advisor\\
+    \end{center}
+  \blanklines{4}%
+  \setstretch{\@dsp}%
+  \@nobreaktrue
+  \@afterindentfalse
+  \@afterheading
+}{%
+  \par\setstretch{\@ssp}%
+}
+\let\DUTabstract\abstract
+\let\endDUTabstract\endabstract
+\newenvironment{thesis}{%
+  \mainmatter
+  \setstretch{\@dsp}%
+}{%
+  \setstretch{\@ssp}%
+  \@DUT@clearpage
+  \ifpdf
+    \phantomsection
+    \pdfbookmark[-1]{Back Matter}{Back Matter}
+  \fi
+}
+\let\DUTthesis\thesis
+\let\endDUTthesis\endthesis
+\newenvironment{vita}{%
+  \listed@schapter{\vitaname}
+  \setstretch{\@dsp}%
+}{%
+  \par\setstretch{\@ssp}%
+}
+\let\DUTvita\vita
+\let\endDUTvita\endvita
+\renewenvironment{titlepage}%
+  {\thispagestyle{empty}\setcounter{page}\z@}%
+  {\@DUT@newpage}
+\let\@DUT@titlepage\titlepage
+\let\end@DUT@titlepage\endtitlepage
+\let\@DUT@appendix\appendix
+\renewcommand\appendix{%
+  \@DUT@appendix%
+  \addtocontents{toc}{%
+    \protect\cftsetindents{chapter}{0pt}{6.5em}
+    \protect\renewcommand{\protect\cftchappresnum}{\protect\appendixname~}
+    \protect\renewcommand{\protect\cftchapaftersnum}{:}}
+  \setstretch{\@dsp}%
+}
+\let\DUTappendix\appendix
+\renewcommand\cfttoctitlefont{%
+  \@DUT@clearpage
+  \ifpdf
+    \phantomsection
+    \pdfbookmark[0]{\contentsname}{\contentsname}
+  \fi
+  \chapter*}
+\setlength\cftaftertoctitleskip{0pt}
+\newlength\l@DUT@toc@sep
+\set@lines@length{\l@DUT@toc@sep}{\@DUT@toc@sep}
+\newcommand{\DUT@toc@high@font}{\normalsize\scshape}
+\newcommand{\DUT@toc@low@font}{\normalfont}
+\newcommand{\DUT@toc@page@font}{\normalfont}
+\setlength\cftbeforepartskip{\l@DUT@toc@sep}
+\cftsetindents{part}{0pt}{3em}
+\if@boldpart   \renewcommand{\cftpartfont}{\bfseries\DUT@toc@high@font}
+\else          \renewcommand{\cftpartfont}{\DUT@toc@high@font}
+\renewcommand{\cftpartleader}{\cftdotfill{\cftpartdotsep}}
+\if@dottedpart \renewcommand{\cftpartdotsep}{\cftdotsep}
+\else          \renewcommand{\cftpartdotsep}{\cftnodots} \fi
+\renewcommand{\cftpartpagefont}{\DUT@toc@page@font}
+\setlength\cftbeforechapskip{\l@DUT@toc@sep}
+\cftsetindents{chapter}{0pt}{1.5em}
+\renewcommand{\cftchapaftersnum}{.}
+\if@boldchapter   \renewcommand{\cftchapfont}{\bfseries\DUT@toc@high@font}
+\else             \renewcommand{\cftchapfont}{\DUT@toc@high@font} \fi
+\renewcommand{\cftchapleader}{\cftdotfill{\cftchapdotsep}}
+\if@dottedchapter \renewcommand{\cftchapdotsep}{\cftdotsep}
+\else             \renewcommand{\cftchapdotsep}{\cftnodots} \fi
+\renewcommand{\cftchappagefont}{\DUT@toc@page@font}
+\setlength\cftbeforesecskip{\l@DUT@toc@sep}
+\cftsetindents{section}{0pt}{3em}
+\renewcommand{\cftsecfont}{\DUT@toc@low@font}
+\renewcommand{\cftsecpagefont}{\DUT@toc@page@font}
+\setlength\cftbeforesubsecskip{\l@DUT@toc@sep}
+\cftsetindents{subsection}{0pt}{4.5em}
+\renewcommand{\cftsubsecfont}{\DUT@toc@low@font}
+\renewcommand{\cftsubsecpagefont}{\DUT@toc@page@font}
+\setlength\cftbeforesubsubsecskip{\l@DUT@toc@sep}
+\cftsetindents{subsubsection}{0pt}{6em}
+\renewcommand{\cftsubsubsecfont}{\DUT@toc@low@font}
+\renewcommand{\cftsubsubsecpagefont}{\DUT@toc@page@font}
+\if@indenttoc
+  \cftsetindents{chapter}{0pt}{1.5em}
+  \cftsetindents{section}{1.5em}{2.3em}
+  \cftsetindents{subsection}{3.8em}{3.2em}
+  \cftsetindents{subsubsection}{7.0em}{4.1em}
+\fi
+\renewcommand\cftloftitlefont{\listed@schapter}
+\setlength\cftafterloftitleskip{-12pt}
+\setlength{\cftbeforefigskip}{\l@DUT@toc@sep}
+\setlength{\cftfigindent}{0pt}
+\renewcommand{\cftfigfont}{\DUT@toc@low@font}
+\renewcommand{\cftfigpagefont}{\DUT@toc@page@font}
+\renewcommand\cftlottitlefont{\listed@schapter}
+\setlength\cftafterlottitleskip{-12pt}
+\setlength{\cfttabindent}{0pt}
+\setlength{\cftbeforetabskip}{\l@DUT@toc@sep}
+\renewcommand{\cfttabfont}{\DUT@toc@low@font}
+\renewcommand{\cfttabpagefont}{\DUT@toc@page@font}
+\renewenvironment{thebibliography}[1]
+     {\bib@heading%
+      \list{\@biblabel{\@arabic\c@enumiv}}%
+           {\settowidth\labelwidth{\@biblabel{#1}}%
+            \leftmargin\labelwidth
+            \advance\leftmargin\labelsep
+            \@openbib@code
+            \usecounter{enumiv}%
+            \let\p@enumiv\@empty
+            \renewcommand\theenumiv{\@arabic\c@enumiv}}%
+      \sloppy
+      \clubpenalty4000
+      \@clubpenalty \clubpenalty
+      \widowpenalty4000%
+      \sfcode`\.\@m}
+     {\def\@noitemerr
+       {\@latex@warning{Empty `thebibliography' environment}}%
+      \endlist}
+\newcommand{\bib@heading}{%
+  \listed@schapter{\bibname}%
+}
+\renewenvironment{theindex}
+               {\if@twocolumn
+                  \@restonecolfalse
+                \else
+                  \@restonecoltrue
+                \fi
+  \listed@schapter{\indexname}
+  \global\columnwidth\textwidth
+  \global\advance\columnwidth-\columnsep
+  \global\divide\columnwidth\tw@
+  \global\hsize\columnwidth
+  \global\linewidth\columnwidth
+  \global\@twocolumntrue
+  \global\@firstcolumntrue
+  \col@number \tw@
+                \parindent\z@
+                \parskip\z@ \@plus .3\p@\relax
+                \columnseprule \z@
+                \columnsep 35\p@
+                \let\item\@idxitem}
+               {\if@restonecol\onecolumn\else\@DUT@clearpage\fi}
+\newcommand\dedicationsname{Dedications}
+\let\DUTdedicationsname\dedicationsname
+\newcommand\acknowledgmentsname{Acknowledgments}
+\let\DUTacknowledgmentsname\acknowledgmentsname
+\renewcommand\contentsname{Table of Contents}
+\let\DUTcontentsname\contentsname
+\renewcommand\listtablename{List of Tables}
+\let\DUTlisttablename\listtablename
+\renewcommand\listfigurename{List of Figures}
+\let\DUTlistfigurename\listfigurename
+\newcommand\abstractname{Abstract}
+\let\DUTabstractname\abstractname
+\renewcommand\bibname{Bibliography}
+\let\DUTbibname\bibname
+\renewcommand\appendixname{Appendix}
+\let\DUTappendixname\appendixname
+\newcommand\vitaname{Vita}
+\let\DUTvitaname\vitaname
+\newcommand{\DUTnames}{%
+  \gdef\dedicationsname{\DUTdedicationsname}%
+  \gdef\contentsname{\DUTcontentsname}%
+  \gdef\listtablename{\DUTlisttablename}%
+  \gdef\listfigurename{\DUTlistfigurename}%
+  \gdef\bibname{\DUTbibname}%
+  \gdef\appendixname{\DUTappendixname}%
+  \gdef\vitaname{\DUTvitaname}%
+}
+\AtEndDocument{\@DUT@blankpage}
+\endinput
+%%
+%% End of file `drexel-thesis.cls'.
diff --git a/drexel-thesis.pdf b/drexel-thesis.pdf
new file mode 100644 (file)
index 0000000..65608f6
Binary files /dev/null and b/drexel-thesis.pdf differ
diff --git a/drexel-thesis.tar.gz b/drexel-thesis.tar.gz
new file mode 100644 (file)
index 0000000..61ed65a
Binary files /dev/null and b/drexel-thesis.tar.gz differ
diff --git a/etextools.sty b/etextools.sty
new file mode 100644 (file)
index 0000000..cbccdcf
--- /dev/null
@@ -0,0 +1,1129 @@
+%%
+%% This is file `etextools.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% etextools.dtx  (with options: `package')
+%% 
+%% This is a generated file.
+%% 
+%% This work may be distributed and/or modified under the
+%% conditions of the LaTeX Project Public License, either
+%% version 1.3 of this license or (at your option) any later
+%% version. The latest version of this license is in
+%%    http://www.latex-project.org/lppl.txt
+%% 
+%% This work consists of the main source file etextools.dtx
+%% and the derived files
+%%       etextools.sty, etextools.pdf, etextools.ins,
+%% and   etextools-examples.tex
+%% 
+\NeedsTeXFormat{LaTeX2e}[1996/12/01]
+\ProvidesPackage{etextools}
+   [2010/12/07 v3.1415926 e-TeX more useful tools for LaTeX package writers]
+\csname ettl@onlyonce\endcsname\let\ettl@onlyonce\endinput
+\RequirePackage{etex,etoolbox,letltxmacro}
+\let\ettl@AtEnd\@empty
+\def\TMP@EnsureCode#1#2{%
+  \edef\ettl@AtEnd{%
+    \ettl@AtEnd
+    \catcode#1 \the\catcode#1\relax
+  }%
+  \catcode#1 #2\relax
+}
+\TMP@EnsureCode{32}{10}% space... just in case
+\TMP@EnsureCode{47}{8}%  /
+\TMP@EnsureCode{167}{7}% ^^a7
+\TMP@EnsureCode{164}{7}% ^^a4
+\TMP@EnsureCode{95}{11}% _
+\TMP@EnsureCode{42}{12}% *
+\TMP@EnsureCode{43}{12}% +
+\TMP@EnsureCode{45}{12}% -
+\TMP@EnsureCode{46}{12}% .
+\TMP@EnsureCode{60}{12}% <
+\TMP@EnsureCode{61}{12}% =
+\TMP@EnsureCode{62}{12}% >
+\TMP@EnsureCode{33}{12}% !
+\TMP@EnsureCode{152}{13}% ~ for the character test
+\ifundef\pdfstrcmp{%
+  \TMP@EnsureCode{163}{9}% ^^a3 ignore
+  \TMP@EnsureCode{128}{14}% \texteuro comment ^^80
+}{\TMP@EnsureCode{163}{14}% ^^a3 comment
+  \TMP@EnsureCode{128}{9}% \texteuro ignore
+}
+\AtEndOfPackage{\ettl@AtEnd\undef\ettl@AtEnd}
+
+% A few helper macros
+\let\ettl@ifdefined\ifdefined%\ifdefined% turn to \iffalse to test other implementation on pdfTeX
+\long\def\ettl@fi#1\fi{\fi#1}
+\long\def\ettl@else#1\else#2\fi{\fi#1}
+\long\def\ettl@or#1\or#2\fi{\fi#1}
+\def\ettl@expandaftwo{\expandafter\expandafter\expandafter}
+\def\ettl@expandafthree{\expandafter\expandafter\expandafter%
+                        \expandafter\expandafter\expandafter\expandafter}
+\cslet{ettl@1of1}\@firstofone    %% for internal use only
+\cslet{ettl@1of2}\@firstoftwo    %% for internal use only
+\cslet{ettl@2of2}\@secondoftwo   %% for internal use only
+\long\def\rmn@firstoftwo#1#2{\z@#1} %% for romannumeral
+\long\def\rmn@secondoftwo#1#2{\z@#2}%% for romannumeral
+\long\def\ettl@cdr#1#2\@nil{#2}  %% \@cdr should be a LONG macro
+\long\def\ettl@car#1#2\@nil{#1}  %% \@car should be a LONG macro
+\long\csdef{ettl@1of3}#1#2#3{#1}
+\long\csdef{ettl@2of3}#1#2#3{#2}
+\long\csdef{ettl@3of3}#1#2#3{#3}
+\long\csdef{ettl@12of3}#1#2#3{{#1}{#2}}
+\long\def\ettl@carcar#1#2#3#4{#4}
+\long\def\ettl@firstspace#1#2#3{\expandafter\ettl@firstsp@ce\detokenize{#1} \\{#3}{#2}//}
+\long\def\ettl@firstsp@ce#1 #2\\{\ettl@nbk#1//}
+\long\def\ettl@csname#1\endcsname{\fi\endcsname}%% useful to get out of \if
+\long\def\ettl@char#1{\csname ettl@\ifcat $\expandafter\ettl@cdr\detokenize{#1}\@nil$%
+   1\else2\fi of2\endcsname}
+\providecommand*\@intmax{2147483647}
+\def\ettl@intmax{2147483647}
+
+%% \ettl@onlypdfTeX for internal use
+\def\ettl@onlypdfTeX#1#2{\@testopt{\ettl@only@pdfTeX{#1}{#2}}{}}
+\def\ettl@only@pdfTeX#1#2[#3]{\ifundef{#1}
+   {\ifblank{#3}
+      {\def#2{\PackageError{etextools}{\string#1\space primitive not found\MessageBreak
+      pdfTeX seems not to be running}
+      {\string#2\space works only if used with pdfTeX (requires \string#1)}}}
+      {\AtEndOfPackage{\let#2=#3}%
+      \PackageWarning{etextools}{\string#1\space primitive not found\MessageBreak
+      Macro \string#2\space has been replaced by \string#3\space\MessageBreak
+      It is not purely expandable}}
+   }\relax}
+
+%% \ettl@nbk argument to be tested//{ true }{ false }//
+% `/` has a catcode of 3 all along this package
+\long\def\ettl@nbk #1#2/#3#4#5//{#4}
+\long\def\ettl@nbk@else#1#2/#3#4#5//#6\else#7\fi{\fi#4}
+\long\def\ettl@ney#1//#2#3//{\romannumeral 0\csname @%
+   \ifcat $\detokenize{#1}$first\else second\fi oftwo\endcsname
+      { #2}{ #3}}
+
+% The following macros are not used (here just for memory, in case of...)
+\long\def\ettl@nbk@cat#1#2#3/#4#5#6//{\ettl@nbk#6//%
+         {\ifcat#1#2\ettl@else#5\else\ettl@fi#6\fi}{#5}//}
+\long\def\ettl@nbk@ifx#1#2#3/#4#5#6//{\ettl@nbk#6//%
+         {\ifx#1#2\ettl@else#5\else\ettl@fi#6\fi}{#5}//}
+\long\def\ettl@nbk@if#1#2#3/#4#5#6//%
+      {\ettl@nbk#6//{\if#1#2\ettl@else#5\else\ettl@fi#6\fi}{#5}//}
+\long\def\ettl@nbk@IF[#1]#2#3#4/#5#6#7//{\ettl@nbk#7//%
+      {\csname if#1\endcsname\ettl@else#6\else\ettl@fi#7\fi}{#6}//}
+
+%% \@gobblespace and The Space Token
+\long\def\@gobblespace#1 {#1}
+
+%% \@gobblescape \cs-token
+\newcommand*\@gobblescape{\romannumeral-`\q\expandafter\@gobble\string}
+
+% The swap macros
+\newcommand\@swap[2]{#2#1}
+\@swap{ }{\let\ettl@sptoken= }% This makes \ettl@sptoken a space token
+\newcommand\@swaparg[2]{#2{#1}}
+\newcommand\@swaplast[3]{#1#3#2}
+\newcommand\@swaptwo[2]{{#2}{#1}}
+
+%% \expandaftercmds : expansion control
+% level 1 : \expandaftercmds { code }{ cs-token }
+% level 2 : \expandaftercmds\expandaftercmds { code }{ cs-token }
+\newcommand\expandaftercmds[2]{%
+   \ifsingletoken\expandaftercmds{#1}
+      {\expandafter@cmds{#2}{\expandafter\expandafter\expandafter}}
+      {\expandafter\@swap\expandafter{#2}{#1}}}
+\long\def\expandafter@cmds#1#2#3{%
+   \ifsingletoken\expandaftercmds{#1}
+      {\expandafter@cmds{#3}{\expandafter#2#2}}
+      {#2\@swap#2{#3}{#1}}}
+
+%% \expandnext : expansion control
+% level 1 : \expandnext { code }{ control sequences : the first is expanded before code }
+% level 2 : \expandnext\expandnext{ code }{ control sequences }
+\newcommand\expandnext[2]{%
+   \ifsingletoken\expandnext{#1}
+      {\@expandnext{#2}{\expandafter\expandafter\expandafter}}
+      {\expandafter\@swaparg\expandafter{#2}{#1}}}
+\long\def\@expandnext#1#2#3{%
+   \ifsingletoken\expandnext{#1}
+      {\@expandnext{#3}{\expandafter#2#2}}
+      {#2\@swaparg#2{#3}{#1}}}
+
+%% \expandnexttwo{ code }{ control sequences }{ control sequences }
+\newcommand\expandnexttwo[3]{\expandnext{\expandnext{#1}{#2}}{#3}}
+
+%% \ExpandAfter { code } { cs-token }
+\newcommand\ExpandAftercmds[2]{\expandafter\@swap\expandafter{\romannumeral-`\q#2}{#1}}
+
+%% \ExpandNext { code } { argument }
+   % I'm not sure it is interesting to use \expandnext here...
+   %\newcommand\ExpandNext[2]{\expandnext{#1}{\romannumeral-`\q#2}}
+\newcommand\ExpandNext[2]{\expandafter\@swaparg\expandafter{\romannumeral-`\q#2}{#1}}
+
+%% \ExpandNextTwo { code } { arg1 }{ arg2 }
+\newcommand\ExpandNextTwo[3]{\ExpandNext{\ExpandNext{#1}{#2}}{#3}}
+
+% noexpandcs { csname }
+\providecommand*\noexpandcs[1]{\expandafter\noexpand\csname #1\endcsname}
+
+% noexpandafter
+\newcommand*\noexpandafter{\noexpand\expandafter}
+
+%% \thefontname
+\newcommand\thefontname{\nfss@text{\expandafter\expandafter\expandafter\ettl@thefontname
+   \expandafter\expandafter\expandafter\meaning
+      \expandafter\the\expandafter\font
+      \expandafter\string\expandafter(%
+      \expandafter\string\the\font\string)}}
+\ifcsname T1/cmr/m/n/10\endcsname
+   \letcs\ettl@thefontname{T1/cmr/m/n/10}%
+\else
+   \font\ettl@thefontname=ecrm1000
+\fi
+
+%% \showcs { csname }
+\providecommand*\showcs[1]{\expandafter\show\csname#1\endcsname}
+
+%% \showthecs { csname }
+\providecommand*\showthecs[1]{\expandafter\showthe\csname#1\endcsname}
+
+%% \meaningcs { csname }
+\providecommand\meaningcs[1]{\romannumeral-`\q
+   \csname\ifcsdef{#1}{ettl@meaningcs\endcsname{#1}}
+                      {meaning\endcsname\@undefined}}
+\def\ettl@meaningcs#1{\expandafter\meaning\csname#1\endcsname}% here we don't need \z@ to stop \romannumeral
+                                                              % because \meaning is never blank nor begins with a space...
+
+%% \strip@meaning { cs-token }
+%% \strip@meaningcs { csname }
+\newcommand*\strip@meaning[1]{\romannumeral\csname\ifdef{#1}%
+      {\ifdefmacro{#1}{ettl@strip@meaning}{ettl@meaning}\endcsname#1}{z@\endcsname}}
+\providecommand*\strip@meaningcs[1]{\romannumeral\csname\ifcsdef{#1}%
+      {\ifcsmacro{#1}{ettl@strip@meaning}{ettl@meaning}%
+               \expandafter\endcsname\csname#1\endcsname}
+      {z@\endcsname}}
+\def\ettl@strip@meaning{\expandafter\expandafter\expandafter\z@% for \romannumeral in case the \meaning is blank...
+   \expandafter\strip@prefix\meaning}
+\def\ettl@meaning{\expandafter\z@\meaning}
+
+%% \parameters@meaning { cs-token }
+%% \parameters@meaningcs { csname }
+\providecommand*\parameters@meaning[1]{}
+\edef\parameters@meaning#1{\unexpanded{\romannumeral\expandafter
+   \expandafter\expandafter\z@\expandafter\ettl@params@meaning%
+         \meaning}#1\detokenize{macro:->}/}
+\providecommand*\parameters@meaningcs[1]{}
+\edef\parameters@meaningcs#1{\unexpanded{\romannumeral\ettl@expandafthree\z@
+   \expandafter\expandafter\expandafter\ettl@params@meaning%
+         \expandafter\meaning\csname}#1\endcsname\detokenize{macro:->}/}
+\edef\ettl@params@meaning{%
+   \def\noexpand\ettl@params@meaning\detokenize{macro:}##1\detokenize{->}##2/{##1}%
+}\ettl@params@meaning
+
+%% \ifdefcount    { cs-token }{ true }{ false } \FEII
+%% \ifdefdimen    { cs-token }{ true }{ false } \FEII
+%% \ifdeftoks     { cs-token }{ true }{ false } \FEII
+%% \ifdefskip     { cs-token }{ true }{ false } \FEII
+%% \ifdefmuskip   { cs-token }{ true }{ false } \FEII
+%% \ifdefchar     { cs-token }{ true }{ false } \FEII
+%% \ifdefmathchar { cs-token }{ true }{ false } \FEII
+\def\ettl@ifdef[#1]{\expandafter\ettl@ifd@f\expandafter{#1}}
+\def\ettl@ifd@f#1#2{%
+   \csdef{ettl@ifdef#2}##1#1##2/End^^a7Meaning/{\ettl@nbk##2//\rmn@firstoftwo\rmn@secondoftwo//}
+   \csedef{ifdef#2}##1{\noexpand\romannumeral\noexpandafter%
+      \noexpandcs{ettl@ifdef#2}\noexpand\meaning##1#1/End^^a7Meaning/}%//{##2}{##3}//}
+}
+\ettl@ifdef[\string\count]{count}               % defines   \def\ifdefcount
+\ettl@ifdef[\string\toks]{toks}                 %           \def\ifdeftoks
+\ettl@ifdef[\string\dimen]{dimen}               %           \def\ifdefdimen
+\ettl@ifdef[\string\skip]{skip}                 %           \def\ifdefskip
+\ettl@ifdef[\string\muskip]{muskip}             %           \def\ifdefmuskip
+\ettl@ifdef[\string\char]{char}                 %           \def\ifdefchar
+\ettl@ifdef[\string\mathchar]{mathchar}         %           \def\ifdefmathchar
+\ettl@ifdef[\detokenize{blank space}]{blankspace}%          \def\ifdefblankspace
+\ettl@ifdef[\detokenize{the character}]{thechar}%           \def\ifdefthechar
+\ettl@ifdef[\detokenize{the letter}]{theletter} %           \def\ifdeftheletter
+\undef\ettl@ifdef\undef\ettl@ifd@f
+
+%% \avoidvoid [ replacement code ]{ cs-token / string }
+%% \avoidvoid*[ replacement code ]{ cs-token / string }
+\newcommand\avoidvoid[1]{\romannumeral\FE@ifstar{#1}
+      {\ettl@voidvoid{\ettl@ifdefempty\ifempty}}
+      {\ettl@voidvoid{\ettl@ifdefvoid\ifblank}}}
+\long\def\ettl@voidvoid#1#2{\FE@testopt{#2}{\ettl@voidv@id#1}{}}
+\long\def\ettl@voidv@id#1#2[#3]#4{\ifiscs{#4}{#1{#4}}{#2{#4}}{\z@#3}{\z@#4}}
+\long\def\ettl@ifdefvoid#1{\csname @\ifx#1\relax first%
+   \else\expandafter\expandafter\expandafter\ettl@nbk\strip@meaning#1//{second}{first}//%
+   \fi oftwo\endcsname}
+\long\def\ettl@ifdefempty#1{\expandafter\expandafter\expandafter\ifempty%
+   \expandafter\expandafter\expandafter{\strip@meaning#1}}
+
+%% \avoidvoidcs [ replacement code ]{ cs-name }
+%% \avoidvoidcs*[ replacement code ]{ cs-name }
+\newcommand\avoidvoidcs[1]{\romannumeral\FE@ifstar{#1}
+   {\ettl@avoidvoidcs{\ettl@ifdefempty}}
+   {\ettl@avoidvoidcs{\ettl@ifdefvoid}}}
+\long\def\ettl@avoidvoidcs#1#2{\FE@testopt{#2}{\ettl@@voidvoidcs#1}{}}
+\long\def\ettl@@voidvoidcs#1[#2]#3{\csname @\ifcsname#3\endcsname
+   \expandafter#1\csname#3\endcsname{first}{second}\else first\fi
+   oftwo\endcsname{\z@#2}{\z@\csname#3\endcsname}}
+
+%% The ifx-test and the character-test
+\long\def\ettl@ifx#1#2{\csname ettl@\ifx#1#21\else2\fi of2\endcsname}
+\long\def\ettl@ifchar#1#2{\csname ettl@\if\noexpand#2\string#11of2\ettl@csname\fi
+   \unless\ifcat\noexpand#1\noexpand#22of2\ettl@csname\fi
+   \ifx#1#21\else2\fi of2\endcsname}
+
+%% \ifsingletoken{ tokenA }{ tokenB }{ true }{ false }
+\newcommand\ifsingletoken[2]{\romannumeral\csname rmn@\ettl@firstspace{#2}
+   {\ettl@nbk#1#2//{second}{\ifcat $\detokenize{#1#2}$first\else\ifx#1#2first\else second\fi\fi}//}
+   {\ifcat $\detokenize\expandafter{\ettl@cdr#2\@nil}$%
+         \expandafter\ettl@ifxsingle
+   \else\expandafter\ettl@carcar
+   \fi{#1}{#2}{first}{second}}%
+   oftwo\endcsname}
+\def\ettl@ifxsingle#1#2#3#4{\ettl@nbk#1//{\ifx#1#2#3\else#4\fi}{#4}//}
+
+%% \iffirsttoken token { string }{ true }{ false }
+\providecommand\iffirsttoken[2]{\romannumeral\csname rmn@%
+   \ettl@nbk#2//%
+      {\ettl@nbk#1//%
+         {\expandnexttwo\ettl@ifx{\ettl@car#2\@nil}{\ettl@car#1\@nil}{first}{second}}
+         {\ifcat $\detokenize{#1}$secondoftwo\ettl@csname\fi
+         \ettl@firstspace{#2}{first}{second}}//}%
+      {\ettl@nbk#1//%
+         {\ifcat $\detokenize{#2}$secondoftwo\ettl@csname\fi
+         \ettl@firstspace{#1}{first}{second}}
+         {\ifcat $\detokenize{#1#2}$first\else second\fi}}//%
+   oftwo\endcsname}
+
+%% \ifOneToken{ token }{ true }{ false }
+\newcommand\ifOneToken[1]{\romannumeral\csname rmn@\ettl@firstspace{#1}
+   {\ettl@nbk#1//{second}{\ifcat $\detokenize{#1}$second\else first\fi}//}
+   {\ifcat $\detokenize\expandafter{\ettl@cdr#1\@nil}$%
+   first\else second\fi}oftwo\endcsname}
+
+%% \ifsinglechar character{ string }{ true }{ false }
+\long\def\ifsinglechar#1#2{\romannumeral\csname rmn@\ettl@firstspace{#2}
+   {\ettl@nbk#2//{second}{\ifcat $\detokenize{#1#2}$first\else\ifx#1#2first\else second\fi\fi}//}
+   {\ifcat $\detokenize\expandafter{\ettl@cdr#2\@nil}$%
+         \expandafter\ettl@ifchar
+      \else\expandafter\ettl@carcar
+      \fi{#1}{#2}{first}{second}}%
+   oftwo\endcsname}
+
+%% \ifOneChar{ string }{ true }{ false }
+\ettl@ifdefined\pdfmatch
+\newcommand\ifOneChar[1]{\romannumeral\csname rmn@%
+      \ifnum\pdfmatch{\detokenize{^.$}}{\detokenize{#1}}=1 first\else second\fi
+      oftwo\endcsname}
+\else
+\newcommand\ifOneChar[1]{\romannumeral\csname rmn@\ettl@firstspace{#1}
+   {\ettl@nbk#1//{second}{\ifcat $\detokenize{#1}$second\else first\fi}//}
+   {\ifcat $\expandafter\ettl@cdr\detokenize{#1}\@nil$%
+    first\else second\fi}oftwo\endcsname}
+\fi%\pdfmatch
+
+%% \ifOneCharWithBlanks{ string }{ true }{ false }
+\ettl@ifdefined\pdfmatch
+\newcommand\ifOneCharWithBlanks[1]{\romannumeral\csname rmn@%
+      \ifnum\pdfmatch{\detokenize{^[[:space:]]*[^[:space:]][[:space:]]*$}}{\detokenize{#1}}=1 %
+      first\else second\fi oftwo\endcsname}
+\else
+\newcommand\ifOneCharWithBlanks[1]{\romannumeral\csname rmn@\ettl@nbk#1//%
+      {\expandafter\expandafter\expandafter\ettl@nbk
+            \expandafter\ettl@cdr\detokenize{#1}\@nil//{second}{first}//}%
+      {second}//oftwo\endcsname}
+\fi
+
+%% \iffirstchar{ string1 }{ string2 }{ true }{ false }
+\newcommand\iffirstchar[2]{\romannumeral\csname rmn@%
+   \ettl@nbk#2//%
+      {\ettl@nbk#1//%
+         {\expandnexttwo\ettl@ifchar{\ettl@car#2\@nil}{\ettl@car#1\@nil}{first}{second}}
+         {\ifcat $\detokenize{#1}$secondoftwo\ettl@csname\fi
+         \ettl@firstspace{#2}{first}{second}}//}%
+      {\ettl@nbk#1//%
+         {\ifcat $\detokenize{#2}$secondoftwo\ettl@csname\fi
+         \ettl@firstspace{#1}{first}{second}}
+         {\ifcat $\detokenize{#1#2}$first\else second\fi}}//%
+   oftwo\endcsname}
+
+%% \ifiscs { string }{ true }{ false }
+\newcommand\ifiscs[1]{\romannumeral\csname rmn@\ettl@nbk#1//%
+   {\ifcat $\expandafter\ettl@cdr\detokenize{#1}\@nil$secondoftwo\ettl@csname\fi
+    \ifcat $\detokenize\expandafter{\ettl@cdr#1\@nil}$%
+      \expandafter\ettl@firstspace
+    \else secondoftwo\ettl@csname\fi{#1}{second}{first}}
+   {second}//oftwo\endcsname}
+
+%% \detokenizeChars { list of single tokens }
+\newcommand\detokenizeChars[1]{\expandafter\ettl@dosinglelist
+   \expandafter\ettl@do@detokenChars\expandafter{\romannumeral\protectspace{\z@#1}}}
+\long\def\ettl@do@detokenChars#1{\ifOneChar{#1}\detokenize\unexpanded{#1}}
+
+%% \protectspace { string }
+\newcommand\protectspace[1]{\romannumeral\ettl@protectspace#1 /End^^a7String/}
+\long\def\ettl@protectspace#1 #2/End^^a7String/{\ifempty{#2}{\z@#1}
+   {\expandafter\@swap\expandafter{\romannumeral\ettl@protectspace#2/End^^a7String/}{\z@#1{ }}}}
+
+%% \ifempty{ text }{ true }{ false }
+\newcommand\ifempty[1]{\romannumeral\csname rmn@\ifcat $\detokenize{#1}$%
+   first\else second\fi oftwo\endcsname}
+
+%% \ifnotempty{ text }{ true }{ false }
+\newcommand\ifnotempty[1]{\romannumeral\csname rmn@\ifcat $\detokenize{#1}$%
+   second\else first\fi oftwo\endcsname}
+
+%% \xifempty{ text }{ true }{ false }
+\newcommand\xifempty[1]{\xifstrcmp{#1}{}}
+\ettl@onlypdfTeX\pdfstrcmp\xifempty[\xifstrempty]
+
+%% \ifnotblank{ text }{ true }{ false }
+\long\def\ifnotblank#1#2#3{\ettl@nbk#1//{#2}{#3}//}
+
+%% \xifblank{ string }{ true }{ false }
+\newrobustcmd\xifblank[1]{\begingroup
+   \protected@edef\@xifblank{\endgroup
+         \noexpand\ifblank{#1}%
+   }\@xifblank}
+
+%% \deblank{ string }
+\newcommand\deblank[1]{\romannumeral\ettl@deblank#1/ /}
+\long\def\ettl@deblank#1 /{\ettl@deblank@i#1/}
+\long\def\ettl@deblank@i#1/#2{\z@#1}
+\newcommand\ettl@stringify[1]{\romannumeral-`\q\ettl@expandafthree\@gobblescape%
+         \expandafter\ettl@deblank\detokenize{#1}/ /}
+
+%% \ifstrcmp{ string1 }{ string2 }{ true }{ false }
+\newcommand\ifstrcmp[2]{\romannumeral\csname rmn@%
+  \ifnum\pdfstrcmp{\detokenize{#1}}{\detokenize{#2}}=0 first\else second\fi
+  oftwo\endcsname}
+\ettl@onlypdfTeX\pdfstrcmp\ifstrcmp[\ifstrequal]
+
+%% \xifstrcmp{ string1 }{ string2 }{ true }{ false }
+\newcommand\xifstrcmp[2]{\csname @%
+  \ifnum\pdfstrcmp{#1}{#2}=0 first\else second\fi
+  oftwo\endcsname}
+\ettl@onlypdfTeX\pdfstrcmp\xifstrcmp[\xifstrequal]
+\newrobustcmd\xifstrequal[2]{\begingroup
+   \protected@edef\@xifstrequal{\endgroup\noexpand\ifstrequal{#1}{#2}%
+   }\@xifstrequal}
+
+%% \ifcharupper{ string }{ true }{ false }
+%% \ifcharlower{ string }{ true }{ false }
+\newcommand\ifcharupper[1]{\romannumeral\csname rmn@%
+   \ifnum`\#1=\uccode`\#1 first\else second\fi oftwo\endcsname}
+\newcommand\ifcharlower[1]{\romannumeral\csname rmn@%
+   \ifnum`\#1=\lccode`\#1 first\else second\fi oftwo\endcsname}
+
+%% \ifuppercase{ string }{ true }{ false }
+%% \iflowercase{ string }{ true }{ false }
+\newrobustcmd\ifuppercase[1]{\uppercase{\ifstrcmp{#1}}{#1}}
+\newrobustcmd\iflowercase[1]{\lowercase{\ifstrcmp{#1}}{#1}}
+
+%% \ifstrmatch{ pattern }{ string }{ true }{ false }
+\newcommand\ifstrmatch[2]{\romannumeral\csname rmn@%
+   \ifnum\pdfmatch{#1}{#2}=1 first\else second\fi oftwo\endcsname}
+\ettl@onlypdfTeX\pdfmatch\ifstrmatch
+
+%% \ifstrdigit{ string }{ true }{ false }
+\ettl@ifdefined\pdfmatch
+\newcommand\ifstrdigit[1]{\romannumeral\csname rmn@\ifnum\pdfmatch{\detokenize{^[[:digit:]]$}}%
+        {\detokenize{#1}}=1 first\else second\fi oftwo\endcsname}
+\else
+\def\do#1{\cslet{ettl@number#1}=#1%
+}\docsvlist{0,1,2,3,4,5,6,7,8,9}
+\newcommand\ifstrdigit[1]{\romannumeral\csname rmn@%
+   \ifcsname ettl@number\detokenize{#1}\endcsname first\else second\fi oftwo\endcsname}
+\fi%\pdfmatch
+
+%% \ifstrnum{ string }{ true }{ false }
+\ettl@ifdefined\pdfmatch
+\newcommand\ifstrnum[1]{\romannumeral\csname rmn@\ifnum\pdfmatch
+   {\detokenize{^([[:space:]]*-?)*+[[:digit:]]+[[:space:]]*$}}{\detokenize{#1}}=1 %
+   first\else second\fi oftwo\endcsname}
+\else
+\newcommand\ifstrnum[1]{\romannumeral\csname rmn@\ettl@nbk#1//%
+         {\expandafter\ettl@numberminus\detokenize{#1}-/End^^a7String/}{second}//oftwo\endcsname}
+\long\def\ettl@numberminus#1-#2/End^^a7String/{\ettl@nbk#2//%
+         {\ettl@nbk#1//{second}{\ettl@numberminus#2/End^^a7String/}//}%
+         {\expandafter\expandafter\expandafter\ettl@numberspace\deblank{#1} /End^^a7String/}//}%
+\long\def\ettl@numberspace#1 #2/End^^a7String/{\ettl@nbk#2//{second}{\ettl@ifstrnum#1/End^^a7String/}//}
+\long\def\ettl@ifstrnum#1#2/End^^a7String/{%
+   \ifcsname ettl@number#1\endcsname% #1 detokenized before, ok
+      \ettl@nbk#2//{\ettl@ifstrnum#2/End^^a7String/}{first}//%
+   \else second%
+   \fi}
+\fi%\pdfmatch
+
+%% \DeclareStringFilter[\global]{ \StringFilterMacro }{ string }
+\newrobustcmd\DeclareStringFilter[3][\global]{\@ifdefinable#2%
+   {\expandnext\ettl@declarestrfilter%
+            {\csname\@gobblescape#2\detokenize{->"#3"}\endcsname}{#1}{#2}{#3}}}
+\newcommand\ettl@declarestrfilter[4]{%
+   #2\csdef{\@gobblescape#1}##1#4##2/End^^a7String/{##1/##2}% This the FILTER
+   #2\long\def#3##1{\FE@modifiers{=<>?-+!}{##1}
+      {\ettl@strfilt@mod 0{{#4}{}{#1}[1]}}%=
+      {\ettl@strfilt@mod 1{{#4}{}{#1}[1]}}%<
+      {\ettl@strfilt@mod 2{{#4}{}{#1}[\ettl@intmax]}}%>
+      {\ettl@strfilt@mod 3{{#4}{}{#1}}}%?
+      {\ettl@strfilt@mod 4{{#4}{}{#1}}}%-
+      {\ettl@strfilt@mod 5{{#4}{}{#1}}}%+
+      {\ettl@strfilt\ettl@strfilt@count{#4}{}{#1}[\ettl@intmax]}%!
+      {\ettl@strfilt\ettl@strfilt@equal{#4}{}{#1}[1]}}}% default
+\def\ettl@strfilt@mod #1#2#3{%
+   \ifcase#1 \ettl@or\ettl@ifchardot{#3}%
+               {\ettl@strfilt\ettl@strfilt@equal#2}
+               {\FE@ifcharequal{#3}%
+                  {\ettl@strfilt\ettl@strfilt@equaleq#2}%
+                  {\ettl@strfilt\ettl@strfilt@equal#2}}%
+   \or\ettl@or\ettl@ifchardot{#3}%
+               {\ettl@strfilt\ettl@strfilt@start#2}%
+               {\FE@ifcharequal{#3}
+                  {\ettl@strfilt\ettl@strfilt@starteq#2}%
+                  {\ettl@strfilt\ettl@strfilt@start#2}}%
+   \or\ettl@or\ettl@ifchardot{#3}%
+               {\ettl@strfilt\ettl@strfilt@endby#2}%
+               {\FE@ifcharequal{#3}
+                  {\ettl@strfilt\ettl@strfilt@endbyeq#2}%
+                  {\ettl@strfilt\ettl@strfilt@endby#2}}%
+   \or\ettl@or\ettl@ifchardot{#3}%
+               {\ettl@strfilt\ettl@strfilt@instr#2[1]}
+               {\FE@testopt{#3}{\ettl@strfilt\ettl@strfilt@instr#2}{1}}%
+   \or\ettl@or\ettl@ifchardot{#3}%
+               {\ettl@strfilt@REMOVE{#2}[\ettl@intmax]}%
+               {\FE@testopt{#3}{\ettl@strfilt@REMOVE{#2}}{\ettl@intmax}}%
+   \or\ettl@fi\ettl@ifchardot{#3}%
+               {\ettl@strfilt@REPLACE#2[\ettl@intmax]}%
+               {\FE@testopt{#3}{\ettl@strfilt@REPLACE#2}{\ettl@intmax}}%
+   \fi}
+\long\def\ettl@strfilt#1#2#3#4[#5]#6{% % #1 = test macro
+     \ExpandAftercmds#1{\ettl@Remove #6/End^^a7String/{#2}{#3}[{#5}]{#4}}}
+\long\def\ettl@strfilt@REMOVE #1[#2]{%
+   \ifnum\numexpr#2>0 \ettl@else\ettl@strfilt\ettl@strfilt@remove#1[#2]%
+   \else\expandafter\@firstofone%
+   \fi}
+\long\def\ettl@strfilt@REPLACE #1#2#3#4[#5]#6#7{%
+   \ifnum\numexpr#5>0 \ettl@else\ettl@strfilt\ettl@strfilt@replace{#1}{#7}{#3}[{#5}]{#6}%
+   \else\expandafter\@firstoftwo%
+   \fi}
+\long\def\ettl@Remove#1/End^^a7String/#2#3[#4]#5{%
+   \expandafter\ettl@Remove@loop #5#1//#2/End^^a7String//End^^a7String/{#3}[{#4-1}]{#5}}
+\long\def\ettl@Remove@loop#1/#2//#3/End^^a7String/#4[#5]#6{%
+   \ifnum\numexpr#5>0 \ettl@nbk@else#2//%
+            {\ettl@Remove #1#4#2/End^^a7String/{#3}{#4}[{#5}]{#6}}
+            {{#1}{#4#2}{#3}{#5}}//%
+   \else\ettl@fi{#1}{#4#2}{#3}{#5}%
+   \fi}
+\long\def\ettl@strfilt@equal   #1#2#3#4{\csname @%
+      \ettl@nbk#3//{\ettl@nbk#1#2//{second}{first}//}{second}//oftwo\endcsname}
+\long\def\ettl@strfilt@equaleq #1#2#3#4{\csname @%
+      \ettl@nbk#3//{\ifnotempty{#1#2}{second}{first}}{second}//oftwo\endcsname}
+\long\def\ettl@strfilt@start   #1#2#3#4{\csname @%
+      \ettl@nbk#1//{second}{first}//oftwo\endcsname}
+\long\def\ettl@strfilt@starteq #1#2#3#4{\csname @%
+      \ifnotempty{#1}{second}{first}oftwo\endcsname}
+\long\def\ettl@strfilt@endby   #1#2#3#4{\csname @%
+      \ettl@nbk#3//{first}{second}//oftwo\endcsname}
+\long\def\ettl@strfilt@endbyeq #1#2#3#4{\csname @%
+      \ettl@nbk#3//{\ifempty{#2}{first}{second}}{second}//oftwo\endcsname}
+\long\def\ettl@strfilt@count   #1#2#3#4{\number\numexpr\ettl@intmax-(#4)-\ettl@nbk#3//01//}
+\long\def\ettl@strfilt@instr   #1#2#3#4{\csname @%
+      \ifnum\numexpr#4>0 second%
+      \else\ifnum\numexpr#4<0 first%
+      \else\ettl@nbk#3//{first}{second}//%
+      \fi\fi oftwo\endcsname}
+\long\def\ettl@strfilt@remove  #1#2#3#4{#1#2}
+\long\def\ettl@strfilt@replace #1#2#3#4{#1\ettl@nbk#3//{#2}{}//}
+%----------------------------------------------------------------------------
+% Purely Expandable Macros With Options / Star Forms / Variants
+%% \FE@testopt{ #1 }{ commands }{ default option }
+\long\def\ettl@BasicFilter#1#2#3/End^^a7String/{\expandafter\ettl@B@sicFilter #1#3//#2/End^^a7String//End^^a7String/}
+\long\def\ettl@B@sicFilter#1/#2//#3/End^^a7String/{@\ettl@nbk#3//%
+      {\ifcat $\detokenize{#1#2}$first\else second\fi}
+      {second}//oftwo}
+\newcommand\FE@testopt[3]{\ettl@FE@testopt#1/[/%
+               {#2#1}%
+               {#2[{#3}]{#1}}}%]
+\long\def\ettl@FE@testopt#1[#2/#3#{\csname @\ifcat $\detokenize{#1#2}$%
+   first\else second\fi oftwo\endcsname}
+
+%% \FE@ifstar{ #1 } { \StarredMacro }{ \NotStarredMacro }
+\newcommand\FE@ifstar[3]{\ettl@FE@ifstar#1/*/%
+               {#2}%
+               {#3{#1}}}
+\long\def\ettl@FE@ifstar#1*#2/#3#{\csname @\ifcat $\detokenize{#1#2}$%
+   first\else second\fi oftwo\endcsname}
+
+%% \FE@charequal{ #1 } { \MacroWith= }{ \NormalMacro } % used by the string filters
+\newcommand\FE@ifcharequal[3]{\ettl@FE@charequal#1/=/%
+               {#2}%
+               {#3{#1}}}
+\long\def\ettl@FE@charequal#1=#2/#3#{\csname @\ifcat $\detokenize{#1#2}$%
+   first\else second\fi oftwo\endcsname}
+
+%% \ettl@strfilt@dot{ #1 } { \MacroWith= }{ \NormalMacro } % used by the string filters
+\newcommand\ettl@ifchardot[1]{\ettl@FE@chardot#1/./}
+\long\def\ettl@FE@chardot#1.#2/#3#{\csname @\ifcat $\detokenize{#1#2}$%
+   first\else second\fi oftwo\endcsname}
+
+%% \FE@ifchar{ <Character> }{ #1 }{ \SpecialFormMacro }{ \NormalMacro }
+\newcommand\FE@ifchar[4]{\ifsinglechar{#1}{#2}{#3}{#4{#2}}}
+
+%% \FE@modifiers{ Allowed Characters }{ #1 }{ \MacroA }{ \MacroB }{ \MacroC }...{ \MacroZ }{ \MacroDefault }
+\newcommand\FE@modifiers[2]{%
+   \ifOneToken{#2}%
+      {\ExpandAftercmds\ettl@FE@modifiers%
+               {\ExpandAftercmds{\ettl@setresult 12of3><}
+                  {\ettl@getsinglelist{\ettl@ifchar{#2}}{#1}}}{#2}}
+      {\ExpandNextTwo{\ettl@supergobble[{{#2}}]}{-1}{\getcharlistcount{#1}+1}}}
+\long\def\ettl@FE@modifiers#1#2#3{\expandafter\ettl@supergobble%
+   \expandafter[\romannumeral-`\q\ifnum#2<0 \@swap{{#3}}\fi]{#2}{#1+1}}
+
+%% \ettl@supergobble{ p }{ q }{token_1}{token_2}...{token_p}{TOKEN_p+1}{token_p+2}...{token_p+q+1}
+\newcommand\ettl@supergobble[1]{\FE@testopt{#1}\ettl@superg@bble{}}
+\long\def\ettl@superg@bble[#1]#2#3{%
+   \ifnum\numexpr#3>0
+      \ifnum\numexpr#3-(#2)=0
+         \ettl@supergobble@loop{#3+2}0{\ettl@supergobble@end{}{}}%
+      \else
+         \expandafter\ettl@supergobble@loop\expandafter{%
+            \number\numexpr\ifnum\numexpr#2*(#2-(#3))>0 #3+1\else#2+2\fi}{#3+2}%
+                           {\ettl@supergobble@next{}{#1}}%
+   \fi\fi}
+\long\def\ettl@supergobble@loop#1#2#3{%
+   \ifcsname ettl@supergobble\number\numexpr#1\endcsname
+      \csname ettl@supergobble\number\numexpr#1\endcsname
+         {#3{#2-(#1)-1}}%
+   \else\ettl@supergobbleeight{\ettl@supergobble@loop{#1-8}{#2-8}{#3}}%
+   \fi}
+\long\def\ettl@supergobble@end#1#2#3{\fi\fi\fi#1#2}
+\long\csdef{ettl@supergobbleeight}#1\fi#2#3#4#5#6#7#8#9{\fi#1}
+\long\csdef{ettl@supergobble7}#1#2\fi#3#4#5#6#7#8#9{#1}
+\long\csdef{ettl@supergobble6}#1#2\fi#3#4#5#6#7#8{#1}
+\long\csdef{ettl@supergobble5}#1#2\fi#3#4#5#6#7{#1}
+\long\csdef{ettl@supergobble4}#1#2\fi#3#4#5#6{#1}
+\long\csdef{ettl@supergobble3}#1#2\fi#3#4#5{#1}
+\long\csdef{ettl@supergobble2}#1#2\fi#3#4{#1}
+\long\csdef{ettl@supergobble1}#1#2\fi#3{#1}
+\long\csdef{ettl@supergobble0}#1#2\fi{#1}
+\long\def\ettl@supergobble@next#1#2#3#4{\fi
+   \ettl@supergobble@loop{#3}0{\ettl@supergobble@end{#4}{#2}}}
+
+%% \AfterGroup{ code }  /  \AfterGroup*{ code }    the star form expands its argument once
+\newcount\ettl@fter
+\newrobustcmd\AfterGroup{\@ifstar{\ettl@AfterGroup\@firstofone}{\ettl@AfterGroup\unexpanded}}
+\newrobustcmd\ettl@AfterGroup[2]{%
+   \csxdef{ettl@fterGroup\number\numexpr\the\ettl@fter+1}%
+      {\global\csundef{ettl@fterGroup\number\numexpr\the\ettl@fter+1}#1{#2}}%
+   \global\advance\ettl@fter\@ne
+   \expandafter\aftergroup\csname ettl@fterGroup\the\ettl@fter\endcsname}
+
+%% \AfterAssignment{ code }
+\newrobustcmd\AfterAssignment{\@ifstar{\ettl@AfterAssignment\@firstofone}{\ettl@AfterAssignment\unexpanded}}
+\newrobustcmd\ettl@AfterAssignment[2]{%
+   \csedef{ettl@afterassignment@hook\number\numexpr\the\ettl@fter}{#1{#2}}%
+   \global\advance\ettl@fter\@ne
+   \expandafter\afterassignment\csname ettl@afterassignment@hook\the\ettl@fter\endcsname}
+
+%% \aftergroup@def{ cs-token }
+\newrobustcmd*\aftergroup@def{\@ifstar\aftergroup@defstar\aftergroup@d@f}
+\newrobustcmd*\@ftergroup@def[3]{%
+   \aftergroup#2\aftergroup#3\aftergroup#1%
+   \aftergroup\global \aftergroup\undef \aftergroup#1}
+\newrobustcmd*\aftergroup@defstar[1]{%
+   \global\expandafter\let\csname ettl@ftergroup@def\the\numexpr\ettl@fter+1\endcsname#1%
+   \global\advance\ettl@fter\@ne
+   \expandafter\@ftergroup@def\csname ettl@ftergroup@def\the\ettl@fter\endcsname\let#1}
+\newrobustcmd*\aftergroup@d@f[1]{%
+   \let\etex@let@primitive\let   \def\let{\global\etex@let@primitive}%
+   \expandafter\LetLtxMacro\csname ettl@ftergroup@def\the\numexpr\ettl@fter+1\endcsname#1%
+   \global\advance\ettl@fter\@ne
+   \etex@let@primitive\let=\etex@let@primitive
+   \expandafter\@ftergroup@def\csname ettl@ftergroup@def\the\ettl@fter\endcsname\LetLtxMacro#1}%
+\let\ettl@aftergroup@def\aftergroup@def
+%----------------------------------------------------------------------------
+
+%% \@ifchar{ single token }{ true }{ false }
+
+\long\def\@ifchar#1#2{\ettl@ifnextchar #1{\@firstoftwo{#2}}}
+
+%% \@char@testopt{ code }{ single token }{ default value }{ single token }
+
+\newcommand\@char@testopt[4]{\ettl@ifnextchar#2{#1}{#1#2#3#4}}
+
+%% \@ifnextchardigit{ true }{ false }
+
+\newrobustcmd\@ifnextchardigit[2]{\begingroup
+
+   \endgroup
+}% \@ifnextchardigit
+
+%% \ettl@ifnextchar{ character token }{ true }{ false }
+
+\newrobustcmd\ettl@ifnextchar[3]{\begingroup
+   \long\edef\1##1/##2/##3{##1\endgroup\unexpanded{#2}##3}%
+   \long\edef\2##1/##2/##3{##1\endgroup\unexpanded{#3}##3}%
+   \ifOneToken{#1}
+      {\csname ettl@\ifcat $\expandafter\ettl@cdr\detokenize{#1}\@nil$% OneChar
+         xifnch\else xifntk\fi\endcsname{#1}}
+      {\2//{}}}
+\long\def\ettl@xifnch#1{%
+   \ifx#1\@sptoken \def\ettl@xifnch{\ifx\@let@token\@sptoken\1\else\2\fi//{}}%
+   \else \def\ettl@xifnch{%
+      \ifx\@let@token\bgroup      \2
+      \else\ifx\@let@token\egroup \2
+      \else\ifx\@let@token\@sptoken \ettl@ifnspace\ettl@xifnch
+     \else\ettl@ifnch
+      \fi\fi\fi/{#1}/{}}%
+   \fi\futurelet\@let@token\ettl@xifnch}
+\long\def\ettl@ifnch#1/#2/#3{#1\long\def\ettl@ifnch##1{\ettl@char{##1}
+      {\if\string##1\string#2\1\else\2\fi}\2//{##1}}\ettl@ifnch}
+\long\def\ettl@xifntk#1{%
+   \ifx#1\bgroup\def\ettl@xifntk{\ifx\@let@token\bgroup\1\else\2\fi//{}}%
+   \else\ifx#1\egroup\def\ettl@xifntk{\ifx\@let@token\egroup\1\else\2\fi//{}}%
+   \else\def\ettl@xifntk{%
+      \ifx\@let@token\bgroup        \2
+      \else\ifx\@let@token\egroup   \2
+      \else\ifx\@let@token\@sptoken \ettl@ifnspace\ettl@xifntk%
+      \else\ettl@ifntk%
+      \fi\fi\fi/{#1}/{}}%
+   \fi\futurelet\@let@token\ettl@xifntk}
+\long\def\ettl@ifntk#1/#2/#3{#1\long\def\ettl@ifntk##1{\ettl@char{##1}
+   \2{\ifx##1#2\1\else\2\fi}//{##1}}\ettl@ifntk}
+\long\def\ettl@ifnspace#1#2/#3/#4 {#2\futurelet\@let@token#1}
+
+%% \futuredef[list of allowed tokens]{ command }{ commands to expand after }
+%% \futuredef*[list of allowed tokens]{ command }{ commands to expand after }
+%% \futuredef=[list of allowed tokens]{ command }{ commands to expand after }
+%% \futuredef*=[list of allowed tokens]{ command }{ commands to expand after } (or \futuredef=*[...] )
+\newrobustcmd*\futuredef{\begingroup\ettl@futdef\ettl@futuredef\detokenize}
+\protected\def\ettl@futdef#1#2{\@ifstar%
+      {\ettl@futdef\ettl@futured@f#2}
+      {\@ifchar={\ettl@futdef#1\unexpanded}
+                {\@testopt{\ettl@futur@def#1#2}{}}}}
+\long\def\ettl@futur@def#1#2[#3]{%
+   \csname ettl@\ifcat $\detokenize{#3}$1\else2\fi of2\endcsname
+   {\let \ettl@x \@empty \letcs \ettl@futur@def@collect{\@gobblescape#1@collectall}}%
+   {\def \ettl@x {#3}\edef \ettl@y {#2{#3}}%
+   \ifx\ettl@x\ettl@y      \let\ettl@y\@gobble
+   \else \ifx#2\unexpanded \let\ettl@y\@gobble
+   \else             \def\ettl@y{\edef\ettl@x}%
+   \fi\fi\ettl@y{\detokenizeChars{#3}}%
+   \letcs\ettl@futur@def@collect{\@gobblescape#1@collect}}%
+   \expandafter#1\expandafter#2\expandafter{\ettl@x}}
+\long\def\ettl@futuredef#1#2#3#4{% #1=detokenize #2=list, #3=macro result, #4=code-next
+   \def \ettl@futuredef@loop{\ettl@futuredef@test{}}%
+   \long \def \ettl@futuredef@test##1{%
+      \ifcat\noexpand\ettl@x\bgroup\ettl@futuredef@end{}\else
+      \ifcat\noexpand\ettl@x\egroup\ettl@futuredef@end{}\else
+      \ifcat\noexpand\ettl@x\ettl@sptoken\ettl@futuredef@space#1\else
+      \ettl@futur@def@collect#1\fi\fi\fi/Ne^^a4t/{#2}{##1}}%
+   \long \def \ettl@futuredef@end##1##2/Ne^^a4t/##3##4{##2\endgroup\def#3{##4}#4##1}%
+   \futurelet \ettl@x \ettl@futuredef@loop}
+\long\def\ettl@futuredef@collect#1#2/Ne^^a4t/#3#4#5{#2%
+   \ifcat\noexpand#5\relax \ettl@futuredef@filt\unexpanded
+   \else \ettl@futuredef@filt#1
+   \fi{#5}{#3}
+   {\def\ettl@futuredef@loop{\ettl@futuredef@test{#4#5}}\futurelet\ettl@x\ettl@futuredef@loop}
+   {\ettl@futuredef@end{#5}/Ne^^a4t/{}{#4}}/Ne^^a4t/}
+\long\def\ettl@futuredef@space#1#2/Ne^^a4t/#3#4 {%
+   \ettl@futur@def@collect#1#2/Ne^^a4t/{#3}{#4}{ }}
+\long\def\ettl@futuredef@collectall#1#2/Ne^^a4t/#3#4#5{#2%
+   \def\ettl@futuredef@loop{\ettl@futuredef@test{#4#5}}\futurelet\ettl@x\ettl@futuredef@loop}
+\long\def\ettl@futur@def@filt#1#2{% #1=token to check, #2=allowed list
+   \long\def\ettl@futdef@filt##1#1##2##3/##4##5##6/Ne^^a4t/{##5}%
+   \ettl@futdef@filt#2#1//}
+\long\def\ettl@futuredef@filt#1#2\fi#3#4{\fi % #1=detokenize/unexpanded, #2=discard, #3=token,#4=allowed list
+   \expandafter\ettl@futur@def@filt\expandafter{#1{#3}}{#4}}
+\long\def\ettl@futured@f#1#2#3#4{% #1=detokenize #2=list, #3=macro result, #4=code-next
+   \let \ettl@y \@undefined
+   \def \ettl@futured@f@loop{\ettl@futured@f@test{}}%
+   \long \def \ettl@futured@f@test##1{%
+      \ifcat\noexpand\ettl@x\bgroup\ettl@futured@f@end\else
+      \ifcat\noexpand\ettl@x\egroup\ettl@futured@f@end\else
+      \ifcat\noexpand\ettl@x\ettl@sptoken\ettl@futured@f@space#1\else
+      \ettl@futur@def@collect#1\fi\fi\fi/Ne^^a4t/{##1}{#2}{}}%
+   \long \def \ettl@futured@f@end##1/Ne^^a4t/##2##3##4{##1\endgroup\def#3{##2}#4##4}%
+   \futurelet \ettl@x \ettl@futured@f@loop}
+\long\def\ettl@futured@f@space#1#2/Ne^^a4t/#3#4#5 {%
+      \ettl@futur@def@collect#1#2/Ne^^a4t/{#3}{#4}{#5}{ }}
+\long\def\ettl@futured@f@collect#1#2/Ne^^a4t/#3#4#5#6{#2%
+   \ifcat\noexpand\ettl@x\relax \ettl@futuredef@filt\unexpanded
+   \else \ettl@futuredef@filt#1
+   \fi{#6}{#4}
+   {\let \ettl@y \@undefined \ettl@futured@f@append/Ne^^a4t/{#3}{}{#6}}%
+   {\ettl@futured@f@try@expand{#3}\ettl@futured@f@end{#6}}/Ne^^a4t/}
+\long\def\ettl@futured@f@collectall#1#2/Ne^^a4t/#3#4#5#6{#2%
+   \ettl@futured@f@try@expand{#3}\ettl@futured@f@append{#6}}
+\long\def\ettl@futured@f@space#1#2/Ne^^a4t/#3#4#5 {%
+      \ettl@futur@def@collect#1#2/Ne^^a4t/{#3}{#4}{#5}{ }}
+\long\def\ettl@futured@f@try@expand#1#2#3{%
+   \expandafter\ifx\noexpand\ettl@x\ettl@x
+      \let\ettl@y=#2%
+   \else\ettl@futured@f@CheckSpecials{#3}%
+      {\let \ettl@y=#2}%
+      {\ifx\ettl@x\ettl@y \let \ettl@y \ettl@futured@f@end\else
+       \let \ettl@y \ettl@futured@f@expand\fi}%
+   \fi\ettl@y/Ne^^a4t/{#1}{}{#3}}
+\long\def\ettl@futured@f@expand/Ne^^a4t/#1#2#3{\let\ettl@y\ettl@x
+   \expandafter\futurelet\expandafter\ettl@x\expandafter\ettl@futured@f@loop#3}
+\long\def\ettl@futured@f@CheckSpecials#1{\ifintokslist{#1}{%
+   \@undefined\if\ifcat\ifnum\ifdim\ifodd%
+   \ifvmode\ifhmode\ifmmode\ifinner\ifvoid\ifhbox\ifvbox%
+   \ifx\ifeof\iftrue\iffalse\ifcase\ifdefined\ifcsname\iffontchar%
+   \else\fi\or}}
+\def\ettl@futured@f@append/Ne^^a4t/#1#2#3{%
+   \def\ettl@futured@f@loop{\ettl@futured@f@test{#1#3}}%
+   \futurelet\ettl@x\ettl@futured@f@loop}%
+
+%----------------------------------------------------------------------------
+
+%% \naturalloop [ auxiliary commands (default \do) ]{ n times }{ argument }
+\newcommand\naturalloop[1]{\FE@testopt{#1}\ettl@naturalloop{\do}}
+\def\ettl@naturalloop[#1]#2#3{%
+   \ifnum\numexpr#2>0 \expandafter\@swaparg\expandafter{\romannumeral-`\q#1[0]{#3}{#3}}%
+         {\ettl@naturall@@p[{#1}]{#2-1}{0}{#3}}
+   \else\@swap{\unexpanded{#3}}%
+   \fi}
+\def\ettl@naturall@@p[#1]#2#3#4#5#6\fi{\fi%
+   \ifnum\numexpr#2>0 \expandafter\@swaparg\expandafter{\romannumeral-`\q%
+      \expandafter\@swap\expandafter{\expandafter[\number\numexpr#3+1]}{#1}{#4}{#5}}%
+      {\ettl@naturall@@p[{#1}]{#2-1}{#3+1}{#4}}%
+   \else\@swap{\unexpanded{#5}}%
+   \fi}
+
+%% \ifinttokslist{ item }{ list of tokens }{ true }{ false }
+\newcommand\ifintokslist[2]{\romannumeral\csname rmn@%
+   \expandafter\ettl@nbk\romannumeral\ettl@dosinglelist{\ettl@ifintokslist{#1}}{#2}\z@//%
+   {first}{second}//oftwo\endcsname}
+\long\def\ettl@ifintokslist#1#2{\ifx#1#2\ettl@breakloop\z@\fi}
+\newcommand\ifincharlist[2]{\romannumeral\csname rmn@%
+   \expandafter\ettl@nbk\romannumeral\ettl@dosinglelist{\ettl@ifincharlist{#1}}{#2}\z@//%
+   {first}{second}//oftwo\endcsname}
+\long\def\ettl@ifincharlist#1#2{\ettl@ifchar{#1}{#2}{\ettl@breakloop\z@}{}}
+\long\def\ettl@dosinglelist#1#2{\ettl@nbk#2//%
+      {\ettl@dosinglelist@loop{#1}#2//{\ettl@dosinglelist@loop{#1}}{\ettl@breakloop{}}}
+      {\ettl@breakloop{}}///End^^a7List/}
+\long\def\ettl@dosinglelist@loop#1#2#3#4/#5#6#7/End^^a7List/{%
+      #1{#2}#6{#3}#4//{#6}{#7}/End^^a7List/}
+
+%% \gettokslistindex { item }{ list of tokens }
+%% \gettokslistcount { item }{ list of tokens }
+%% \gettokslisttoken { item }{ list of tokens }
+\newcommand\gettokslistindex[2]{\number\ifnotempty{#2}{\ettl@nbk#1//%
+   {\ExpandAftercmds{\ettl@setresult 2of3><}{\ettl@getsinglelist{\ettl@ifx{#1}}{#2}}}
+   {-1}//}{-1}}
+\newcommand\getcharlistindex[2]{\number\ifnotempty{#2}{\ettl@nbk#1//%
+   {\ExpandAftercmds{\ettl@setresult 2of3><}{\ettl@getsinglelist{\ettl@ifchar{#1}}{#2}}}
+   {-1}//}{-1}}
+\newcommand\gettokslistcount[1]{\number\ifnotempty{#1}%
+   {\ExpandAftercmds{\ettl@setresult 1of3><}{\ettl@getsinglelist{\ettl@ifx{\\}}{#1}}}
+   0}
+\newcommand\getcharlistcount[1]{}%
+\let\getcharlistcount=\gettokslistcount
+\newcommand\gettokslisttoken[2]{\ifnotempty{#2}{\ettl@nbk#1//%
+   {\ExpandAftercmds{\ettl@setresult 3of3><}{\ettl@getsinglelist{\ettl@ifx{#1}}{#2}}}
+   {}//}{}}
+\newcommand\getcharlisttoken[2]{\ifnotempty{#2}{\ettl@nbk#1//%
+   {\ExpandAftercmds{\ettl@setresult 3of3><}{\ettl@getsinglelist{\ettl@ifchar{#1}}{#2}}}
+   {}//}{}}
+\long\def\ettl@getsinglelist#1#2{\ettl@singlelist@loop{-1}{-1}{}#2//%
+         {\ettl@expandafthree\ettl@singlelist@loop#1}%
+         {\expandafter\ettl@singlelist@result\@thirdofthree}/End^^a7List/}
+\long\def\ettl@singlelist@loop#1#2#3#4#5/#6#7#8/End^^a7List/{%
+      #7{#4}
+         {{#1+1}{#2+1+0*(0}{#4}}
+         {{#1+1}{#2+1}{#3}}#5//{#7}{#8}/End^^a7List/}
+   %   \csname @#1#5{first}{second}oftwo\endcsname
+   %      {#8{#1}{#2+1}{#3+1+0*(0}{#5}#6//#8#9}
+   %      {#8{#1}{#2+1}{#3+1}{#4}#6//#8#9}/End^^a7List/}
+
+\def\ettl@singlelist@result#1#2#3#4/End^^a7List/{\ExpandNextTwo\@swaptwo%
+      {\number\numexpr\ifempty{#3}{-1}{#2)}}{\number\numexpr#1}{#3}}
+\def\ettl@setresult#1of#2>#3<{\ettl@nbk #3//%
+      {\ettl@set@result#1of#2>#3<}
+      {\csname ettl@#1of#2\endcsname}//}
+\def\ettl@set@result#1of#2>#3<#4{\ifdefcount{#3}
+   {#3=\csname ettl@#1of#2\endcsname#4}
+   {\expandafter\edef\noexpand#3{\csname ettl@#1of#2\endcsname{#4}}}%
+}
+
+%% \DeclareCmdListParser : general constructor for command-list parsers
+%% \DeclareCmdListParser\ParserName{separator}
+\newrobustcmd\DeclareCmdListParser[3][\global]{\@ifdefinable{#2}{\begingroup
+      \protected\def\ettl@defcmdparser##1{%
+         \edef\ettl@defcmdparser{\endgroup\ettl@defcmdparser
+            {#1}{\noexpand#2}{\unexpanded{#3}}
+            {\noexpandcs{##1->start}}
+            {\noexpandcs{##1->loop}}
+            {\noexpandcs{##1->loop+}}
+            {\noexpandcs{for##1}}%
+         }\ettl@defcmdparser
+      }\expandafter\ettl@defcmdparser\expandafter{\romannumeral-`\q\@gobblescape#2}}}
+\protected\long\def\ettl@defcmdparser#1#2#3#4#5#6#7{%#1=global,#2=command,#3=sep,#4=start,#5=loop,#6=loop+
+   #1\long\def#4##1##2[##3]##4{% ##1=case, ##2=expandafter??? , ##3=do, ##4=list
+      ##2{##4}% ifiscs or @thirdofthree
+         {\expandafter\@swaparg\expandafter{##4}{#4{##1}\@thirdofthree[{##3}]}}
+         {\ettl@nbk##4//%
+            {\ifcase##1 \ettl@or\@swaplast{\number\numexpr#60{\ettl@lst@count}}#6%
+               \or      \ettl@or\@swaplast{#60{\ettl@lst@getitem{##3}}}#6%
+               \or      \ettl@or\@swaplast{#5{##3}}#5%
+               \or      \ettl@fi\@swaplast{#60{##3}}#6%
+               \fi{##4#3//}{\ettl@breakloop{\ifx##10\expandafter\relax\fi}}%
+            }{\ettl@breakloop{}}///End^^a7List/}}%
+   #1\long\def#5##1##2#3##3##4/##5##6##7/End^^a7List/{%
+      \ifcat $\detokenize{##2}$\expandafter\@gobbletwo\fi\@firstofone{##1{##2}}%
+      ##6{##1}##3##4//{##6}{##7}/End^^a7List/}
+   #1\long\def#6##1##2##3#3##4##5/##6##7##8/End^^a7List/{%
+      \ifcat $\detokenize{##3}$\expandafter\@gobbletwo\fi\@firstofone{##2[##1]{##3}}%
+      \expandafter##7\expandafter{\number\numexpr##1+1}{##2}##4##5//{##7}{##8}/End^^a7List/}
+   #1\protected\def#7{\@ifchar*%
+      {\@ifchar+{\ettl@forloop{\expandafter#2\expandafter*\expandafter+}{[####1]####2}}
+                {\ettl@forloop{\expandafter#2\expandafter*}{####1}}}
+      {\@ifchar+{\@ifchar*%
+                     {\ettl@forloop{\expandafter#2\expandafter*\expandafter+}{[####1]####2}}
+                     {\ettl@forloop{\expandafter#2\expandafter+}{[####1]####2}}}
+                {\ettl@forloop{\expandafter#2}{####1}}}}
+   #1\def#2{\ettl@lst@modif#423\ifiscs}}
+\long\def\ettl@lst@getitem#1[#2]#3{%
+   \ifnum\numexpr#1<0 \@swap{\breakloop{}}\fi
+   \ifnum\numexpr#1=#2 \@swap{\breakloop{#3}}\fi}
+\long\def\ettl@lst@count[#1]#2{+\ettl@nbk#2//10//}
+\long\def\ettl@lst@modif#1#2#3#4#5{\FE@modifiers{*+![}{#5}%
+   {\ettl@lst@modif{#1}#2#3\@thirdofthree}%    * case
+   {\ettl@lst@modif{#1}#3#2{#4}}%  + (case 3/default 2)
+   {\ettl@lst@modif{#1}00{#4}}% ! (case 0)
+   {\ettl@lst@opt{#1}{#2}{#4}#5}% [   (option)
+   {\ettl@lst@opt{#1}{#2}{#4}[\do]}}% (default option)
+\long\def\ettl@lst@opt#1#2#3[#4]{%
+   \expandafter#1\expandafter{\number\ifnum#2=0 0\else\ifstrnum{#4}{1}{#2}\fi}{#3}[{#4}]}
+\long\def\ettl@breakloop#1#2/End^^a7List/{#1}
+\let\breakloop\ettl@breakloop
+\globcount\ettl@for@nested
+\long\def\ettl@forloop#1#2#3\do{%
+   \global\advance\ettl@for@nested\@ne\relax
+   \csdef{ettl@for@loop\the\ettl@for@nested}{%
+      #1\expandafter[\csname ettl@for@do\the\ettl@for@nested\endcsname]{#3}%
+      \csundef{ettl@for@do\the\ettl@for@nested}%
+      \csundef{ettl@for@loop\the\ettl@for@nested}%
+      \global\advance\ettl@for@nested\m@ne\relax}%
+   \expandafter\afterassignment\csname ettl@for@loop\the\ettl@for@nested\endcsname
+   \long\csdef{ettl@for@do\the\ettl@for@nested}#2%
+}% \ettl@for@nested
+
+
+%% \csvloop[\command]\csvListMacro
+%% \csvloop*[\command]{item,item,item}
+\DeclareCmdListParser\csvloop{,}
+\begingroup\catcode`\|=3
+\DeclareCmdListParser\listloop{|}% global declaration
+\endgroup
+\DeclareCmdListParser\toksloop{}
+
+%% \forcsvloop\csvListMacro\do{...#1...}
+%% \forcsvloop*{item,item,item,...}\do{...#1...}
+
+%% \csvlistadd \csvListMacro { item }
+%% \csvlist(g|e|x)add \csvListMacro { item }
+\providerobustcmd\csvlistadd[2]{\ettl@nbk#2//{\appto#1{#2,}}{}//}
+\providerobustcmd\csvlistgadd[2]{\ettl@nbk#2//{\gappto#2{#2,}}{}//}
+\providerobustcmd\csvlisteadd[2]{\begingroup \protected@edef#1{#2}%
+   \expandafter\ettl@nbk#1//{\expandafter\endgroup
+      \expandafter\appto\expandafter#1\expandafter{#1,}}\endgroup//}
+\providerobustcmd\csvlistxadd[2]{\begingroup \protected@edef#1{#2}%
+   \expandafter\ettl@nbk#1//{\expandafter\endgroup
+      \expandafter\gappto\expandafter#1\expandafter{#1,}}\endgroup//}
+
+%% \csvtolist  [\ListMacro] \csvListMacro
+%% \csvtolist* [\ListMacro] {item,item,item}
+% Recommended use: \edef\ListMacro{\csvtolist{item,item,item}}
+\newcommand\csvtolist[1]{\FE@ifstar{#1}{\ettl@convertlist{{\csvloop*}\ettl@do@csvtolist}}
+                                       {\ettl@convertlist{\csvloop\ettl@do@csvtolist}}}
+\long\def\ettl@convertlist#1#2{\FE@testopt{#2}{\ettl@convert@list#1}{}}
+\long\def\ettl@convert@list#1#2[#3]#4{\ettl@nbk#3//%
+      {\edef#3{#1[#2]{#4}}}
+      {#1[#2]{#4}}//}
+\begingroup\catcode`\|=3% etb catcode
+\long\gdef\ettl@do@csvtolist#1{\unexpanded{#1}|}
+\endgroup
+
+%% \listtocsv  [\csvListMacro] \ListMacro
+%% \listtocsv* [\csvListMacro] { expanded List }
+% Recommended use: \edef\csvListMacro{\listtocsv\ListMacro}
+\newcommand\listtocsv[1]{\FE@ifstar{#1}{\ettl@convertlist{{\listloop*}\ettl@do@listtocsv}}
+                                       {\ettl@convertlist{\listloop\ettl@do@listtocsv}}}
+\long\def\ettl@do@listtocsv#1{\unexpanded{#1,}}
+%% \tokstolist [\ListMacro] { \toksListMacro   /  token token token }
+\newcommand\tokstolist[1]{\FE@ifstar{#1}{\ettl@convertlist{{\toksloop*}\ettl@do@tokstolist}}
+                                        {\ettl@convertlist{\toksloop\ettl@do@tokstolist}}}
+\begingroup\catcode`\|=3% etb catcode
+\long\gdef\ettl@do@tokstolist#1{\unexpanded{#1}|}
+\endgroup
+
+%% \csvtolistadd \ListMacro \csvListMacro
+%% \csvtolistadd* \ListMacro {item,item,item}
+\newrobustcmd*\csvtolistadd{\@ifstar{\ettl@csvtolistadd*}{\ettl@csvtolistadd{}}}
+\long\def\ettl@csvtolistadd#1#2#3{\eappto#2{\csvtolist#1[]{#3}}}
+
+%% \tokstolistadd \ListMacro { \toksListMacro  /  token token token }
+\newrobustcmd*\tokstolistadd{\@ifstar{\ettl@tokstolistadd*}{\ettl@tokstolistadd{}}}
+\long\def\ettl@tokstolistadd#1#2#3{\eappto#2{\tokstolist#1[]{#3}}}
+\newrobustcmd\ettl@RemoveInList[2]{\begingroup
+   \def\ettl@RemoveInList##1{%
+      \edef\ettl@RemoveInList####1####2{%
+         \ettl@Rem@veInList{####1}####2\noexpandcs{##1->remove}\noexpandcs{##1->result}%
+      }\ettl@RemoveInList{#1}#2%
+   }\expandafter\ettl@RemoveInList\expandafter{\romannumeral-`\q\@gobblescape#2}}
+\protected\long\def\ettl@Rem@veInList#1#2#3#4#5#6#7#8{%
+   \long\def#3[##1]##2#5#8#5##3##4/##5##6##7/End^^a7List/{##6[##1+1]##2#5##3##4//##6##7/End^^a7List/}%
+   \ifnotempty{#5}%% special case if no separator
+      {\long\def#4[##1]#5##2#5#5##3//##4/End^^a7List/{\unexpanded{#1\def#7{##2#5}}%
+               \ettl@nbk#6//{\ettl@setresult 1of1>#6<{\number\numexpr##1-1\relax}}{}//}}%
+      {\long\def#4[##1]##2//##3/End^^a7List/{\unexpanded{#1\def#7{##2}}%
+               \ettl@nbk#6//{\ettl@setresult 1of1>#6<{\number\numexpr##1-1\relax}}{}//}}%
+   \long\def#2##1{#3[0]#5##1#5#5#8#5//#3#4/End^^a7List/}%
+   \edef#7{\endgroup\expandafter#2\expandafter{#7}}#7}
+\def\ettl@gobble@relax#1\relax{}
+
+%% \listdel  \listMacro { item }
+%% \listgdel \listMacro { item }
+%% \listedel \listMacro { item }
+%% \listxdel \listMacro { item }
+\edef\ettl@restore@catcode{\catcode124 \the\catcode124}% |=124
+\catcode`\|=3
+\newrobustcmd\listdel[1][]{\ettl@RemoveInList{}\listdel|{#1}}
+\newrobustcmd\listgdel[1][]{\ettl@RemoveInList\global\listdel|{#1}}
+\newrobustcmd\listedel[1][]{\ettl@listedel{}\listdel|{#1}}
+\newrobustcmd\listxdel[1][]{\ettl@listedel\global\listdel|{#1}}
+\ettl@restore@catcode\undef\ettl@restore@catcode
+\newrobustcmd\ettl@listedel[6]{\begingroup\protected@edef#5{#6}\expandafter\endgroup
+   \expandafter\@swaparg\expandafter{#5}{\ettl@RemoveInList#1#2{#3}{#4}#5}}
+
+%% \csvdel  \listMacro { item }
+%% \csvgdel \listMacro { item }
+%% \csvedel \listMacro { item }
+%% \csvxdel \listMacro { item }
+\newrobustcmd\csvdel[1][]{\ettl@RemoveInList{}\csvdel,{#1}}
+\newrobustcmd\csvgdel[1][]{\ettl@RemoveInList\global\csvdel,{#1}}
+\newrobustcmd\csvedel[1][]{\ettl@listedel{}\csvdel,{#1}}
+\newrobustcmd\csvxdel[1][]{\ettl@listedel\global\csvdel,{#1}}
+
+%% \toksdel  \listMacro { item }
+%% \toksgdel \listMacro { item }
+%% \toksedel \listMacro { item }
+%% \toksxdel \listMacro { item }
+\newrobustcmd\toksdel[1][]{\ettl@RemoveInList{}\toksdel{}{#1}}
+\newrobustcmd\toksgdel[1][]{\ettl@RemoveInList\global\toksdel{}{#1}}
+\newrobustcmd\toksedel[1][]{\ettl@listedel{}\toksdel{}{#1}}
+\newrobustcmd\toksxdel[1][]{\ettl@listedel\global\toksdel{}{#1}}
+
+
+%% \getlistindex[\indexmacro]{ \Listmacro }
+%% \getlistindex*[\indexmacro]{ expanded List }
+\newrobustcmd\ettl@getlistindex[6]{% #1=result, #2=\expandafter, #3=loop macro, #4=separator, #5=list of list macro, #6=item
+   \begingroup\long\def\ettl@getlistindex##1#4#6#4##2/End^^a7List/{\endgroup
+   \ExpandAftercmds{\ettl@setresult 1of1>#1<}{\ettl@nbk##2//{#3*!{##1}}{-1}//}%
+   }#2\ettl@getlistindex#5#4#6#4/End^^a7List/}
+\newrobustcmd\getlistindex{\@ifstar
+   {\@testopt{\ettl@get@listindex\relax}{}}
+   {\@testopt{\ettl@get@listindex\expandafter}{}}}
+\begingroup\catcode`\|=3% etb catcode
+\protected\long\gdef\ettl@get@listindex#1[#2]#3#4{%
+   \ifx#1\relax
+      \ettl@getlistindex{#2}{}\listloop|{#4}{#3}%
+   \else \ifiscs{#4}
+      {\ettl@getlistindex{#2}#1\listloop|{#4}{#3}}
+      {\ettl@getlistindex{#2}\listloop|{#4}{#3}}%
+   \fi}
+\endgroup%\catcode group
+
+%\getcsvlistindex [\result]{ item }{ csvlistmacro }
+%\getcsvlistindex*[\result]{ item }{ item,item,item }
+\newrobustcmd\getcsvlistindex{\@ifstar
+   {\@testopt{\ettl@get@csvlistindex\relax}{}}
+   {\@testopt{\ettl@get@csvlistindex\expandafter}{}}}
+\protected\long\gdef\ettl@get@csvlistindex#1[#2]#3#4{%
+   \ifx#1\relax
+      \ettl@getlistindex{#2}{}\csvloop,{#4}{#3}%
+   \else \ifiscs{#4}
+      {\ettl@getlistindex{#2}#1\csvloop,{#4}{#3}}
+      {\ettl@getlistindex{#2}\csvloop,{#4}{#3}}%
+   \fi}
+\def\ettl@if@inlist#1#2{%#1=macro,#2=separator
+\newrobustcmd*#1{\@ifstar{\ettl@ifinlist{#2}{}}{\ettl@ifinlist{#2}\expandafter}}}
+\def\ettl@xif@inlist#1#2{%
+\newrobustcmd*#1{\@ifstar{\ettl@xifinlist{#2}{}}{\ettl@xifinlist{#2}\expandafter}}}
+\protected\long\def\ettl@ifinlist#1#2#3#4{\begingroup
+   \def\ettl@tempa##1#1##2#1/End^^a7List/{\endgroup\ifnotblank{##2}%
+   }#2\ettl@tempa#2#1#3#1#4#1/End^^a7List/}
+\protected\long\def\ettl@xifinlist#1#2#3#4{\begingroup
+   \protected@edef\ettl@tempa{\endgroup\ettl@ifinlist{#1}{#2}{#3}{#4}%
+   }\ettl@tempa}
+
+
+%% \ifincsvlist{ item }{ csvlistmacro }{ true }{ false }
+%% \ifincsvlist*{ item }{ item,item,item,... }{ true }{ false }
+%% \xifincsvlist{ item }{ csvlistmacro }{ true }{ false }
+%% \xifincsvlist*{ item }{ item,item,item,... }{ true }{ false }
+\ettl@if@inlist\ifincsvlist{,}
+\ettl@xif@inlist\xifincsvlist{,}
+\undef\ettl@if@inlist
+\undef\ettl@xif@inlist
+
+%% \interval{ number }{ sorted comma separated list of numbers }
+\newcommand\interval[2]{\romannumeral-`\q%
+   \ExpandNext{\avoidvoid[\csvloop!{#2}]}{\csvloop+[\ettl@do@interval{#1}]{#2}}}
+\def\ettl@do@interval#1[#2]#3{\ifdim#1\p@<#3\p@ \@swap{\breakloop{#2}}\fi}
+
+%% \interplin{ number }{ sorted comma separated list of numbers }{ comma separated liist of numbers }
+\newcommand\locinterplin[3]{\romannumeral-`\q
+   \unless\ifnum\numexpr(\csvloop!{#2})-(\csvloop!{#3})=0
+      \PackageError{etextools}{Using \string\locinterplin\space the lists in argument 1 and 2\MessageBreak
+      must have the same number of elements}
+      {You're in trouble here and I cannot proceed...}
+   \fi
+   \ExpandNextTwo{\ettl@locinterplin{#1}{#3}{#2}}{\interval{#1}{#2}}{\csvloop!{#2}}}
+\begingroup\catcode`\/ 12%
+\gdef\ettl@locinterplin#1#2#3#4#5{%
+   \ifnum#4=0 \csvloop[#4]{#2}%
+   \else\ifnum#4=#5 \expandafter\csvloop\expandafter[\number\numexpr#5-1]{#2}%
+   \else\ifdim#1\p@=\expandafter\csvloop\expandafter[\number\numexpr#4-1]{#3}\p@
+      \expandafter\csvloop\expandafter[\number\numexpr#4-1]{#2}%
+   \else\strip@pt\dimexpr%
+      \expandafter\csvloop\expandafter[\number\numexpr#4-1]{#2}\p@+%
+         (#1\p@-\expandafter\csvloop\expandafter[\number\numexpr#4-1]{#3}\p@)*%
+         (\expandafter\csvloop\expandafter[\number\numexpr#4-1]{#2}-\csvloop[#4]{#2})/%
+         (\expandafter\csvloop\expandafter[\number\numexpr#4-1]{#3}-\csvloop[#4]{#3})\relax
+   \fi\fi\fi}
+\endgroup% catcode group
+\DeclareOption{etoolbox}{%
+\renewcommand\ifblank[3]{\ettl@nbk #1//{#2}{#3}//}
+\renewcommand\ifdef[1]{\csname @\ifdefined#1first\else second\fi oftwo\endcsname}
+\renewcommand\ifcsdef[1]{\csname @\ifcsname#1\endcsname first\else second\fi oftwo\endcsname}
+\renewcommand\ifundef[1]{\csname @%
+   \ifdefined#1\ifx#1\relax first\else second\fi\else first\fi oftwo\endcsname}
+\renewcommand\ifcsundef[1]{\csname @%
+   \ifcsname#1\endcsname\expandafter\ifx\csname#1\endcsname\relax
+      first\else second\fi\else first\fi oftwo\endcsname}
+\edef\ifdefmacro#1{\unexpanded{\csname @%
+     \expandafter\ettl@ifdefmacro\meaning}#1\detokenize{macro:}/oftwo\endcsname}
+\edef\ettl@ifdefmacro{%
+   \def\noexpand\ettl@ifdefmacro##1\detokenize{macro:}##2/{\noexpand\ettl@nbk##2//{first}{second}//}%
+}\ettl@ifdefmacro
+\long\edef\ifcsmacro#1{\unexpanded{\csname @%
+   \expandafter\expandafter\expandafter\ettl@ifdefmacro\meaningcs}{#1}\detokenize{macro:}/oftwo\endcsname}
+\renewcommand\ifdefparam[1]{\csname @%
+   \ettl@expandaftwo\ettl@nbk\expandafter\ettl@params@meaning\meaning#1///{first}{second}//oftwo\endcsname}
+\renewcommand\ifcsparam[1]{\csname @%
+   \expandafter\expandafter\expandafter\ettl@nbk\parameters@meaningcs{#1}//{first}{second}//oftwo\endcsname}
+\renewcommand\ifnumcomp[3]{\csname @%
+   \ifnum\numexpr#1#2\numexpr#3 first\else second\fi oftwo\endcsname}
+}% etoolbox option - not to be used - experimental
+\ProcessOptions*\relax
+
+\endinput
+%%
+%% End of file `etextools.sty'.
diff --git a/etoolbox.sty b/etoolbox.sty
new file mode 100644 (file)
index 0000000..ae37d94
--- /dev/null
@@ -0,0 +1,1708 @@
+% $Id: etoolbox.sty,v 2.1 2011/01/03 19:14:10 lehman stable $
+
+% Copyright (c) 2007-2011 Philipp Lehman.
+%
+% Permission is granted to copy, distribute and/or modify this
+% software under the terms of the LaTeX Project Public License
+% (LPPL), version 1.3.
+%
+% The LPPL maintenance status of this software is
+% 'author-maintained'.
+%
+% This software is provided 'as is', without warranty of any kind,
+% either expressed or implied, including, but not limited to, the
+% implied warranties of merchantability and fitness for a
+% particular purpose.
+
+\def\etb@rcsid$#1: #2 #3 #4 #5${#4 v#3}
+
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesPackage{etoolbox}
+[\etb@rcsid $Id: etoolbox.sty,v 2.1 2011/01/03 19:14:10 lehman stable $
+ e-TeX tools for LaTeX]
+
+\begingroup
+\@ifundefined{eTeXversion}
+  {\PackageError{etoolbox}
+     {Not running under e-TeX}
+     {This package requires e-TeX. Try compiling the document
+      with\MessageBreak 'elatex' instead of 'latex'. When using
+      pdfTeX, try 'pdfelatex'\MessageBreak instead of 'pdflatex'.
+      This is a fatal error. I'm aborting now.}%
+   \aftergroup\endinput}
+  {}
+\endgroup
+
+\RequirePackage{etex}
+
+\def\etb@catcodes{\do\&\do\|\do\:\do\-\do\=\do\<\do\>}
+\def\do#1{\catcode\number`#1=\the\catcode`#1\relax}
+\edef\etb@catcodes{\etb@catcodes}
+\let\do\noexpand
+\AtEndOfPackage{\etb@catcodes\undef\etb@catcodes}
+
+\catcode`\&=3
+\catcode`\|=3
+\@makeother\:
+\@makeother\-
+\@makeother\=
+\@makeother\<
+\@makeother\>
+
+\protected\def\etb@error{\PackageError{etoolbox}}
+\protected\def\etb@warning{\PackageWarning{etoolbox}}
+\protected\def\etb@info{\PackageInfo{etoolbox}}
+\newcount\etb@tempcnta
+
+% {<cstoken>}[<arguments>][<optarg default>]{<definition>}
+
+\newcommand*{\newrobustcmd}{}
+\protected\def\newrobustcmd{\@star@or@long\etb@new@command}
+
+\def\etb@new@command#1{\@testopt{\etb@newcommand#1}0}
+
+\def\etb@newcommand#1[#2]{%
+  \@ifnextchar[%]
+    {\etb@xargdef#1[#2]}
+    {\ifx\l@ngrel@x\relax
+       \let\l@ngrel@x\protected
+     \else
+       \protected\def\l@ngrel@x{\protected\long}%
+     \fi
+     \@argdef#1[#2]}}
+
+\long\def\etb@xargdef#1[#2][#3]#4{%
+  \@ifdefinable#1{%
+    \expandafter\protected
+    \expandafter\def
+    \expandafter#1%
+    \expandafter{%
+      \expandafter\@testopt
+      \csname\string#1\endcsname{#3}}%
+    \expandafter\@yargdef\csname\string#1\endcsname\tw@{#2}{#4}}}
+
+% {<cstoken>}[<arguments>][<optarg default>]{<definition>}
+
+\newrobustcmd*{\renewrobustcmd}{\@star@or@long\etb@renew@command}
+
+\def\etb@renew@command#1{%
+  \ifundef{#1}
+     {\etb@error{\string#1 undefined}\@ehc}
+     {}%
+  \let\@ifdefinable\@rc@ifdefinable
+  \etb@new@command#1}
+
+% {<cstoken>}[<arguments>][<optarg default>]{<definition>}
+
+\newrobustcmd*{\providerobustcmd}{\@star@or@long\etb@provide@command}
+
+\def\etb@provide@command#1{%
+  \ifundef{#1}
+    {\def\reserved@a{\etb@new@command#1}}
+    {\def\reserved@a{\etb@renew@command\reserved@a}}%
+  \reserved@a}
+
+% {<csname>}
+
+\newrobustcmd*{\csshow}[1]{%
+  \begingroup\expandafter\endgroup
+  \expandafter\show\csname#1\endcsname}
+
+% {<cstoken>}{<true>}{<false>}
+
+\newcommand{\ifdef}[1]{%
+  \ifdefined#1%
+    \expandafter\@firstoftwo
+  \else
+    \expandafter\@secondoftwo
+  \fi}
+
+% {<cstoken>}{<true>}{<false>}
+
+\newcommand{\ifundef}[1]{%
+  \ifdefined#1%
+    \ifx#1\relax
+      \expandafter\expandafter
+      \expandafter\@firstoftwo
+    \else
+      \expandafter\expandafter
+      \expandafter\@secondoftwo
+    \fi
+  \else
+    \expandafter\@firstoftwo
+  \fi}
+
+% {<csname>}{<true>}{<false>}
+
+\newcommand*{\ifcsdef}[1]{%
+  \ifcsname#1\endcsname
+    \expandafter\@firstoftwo
+  \else
+    \expandafter\@secondoftwo
+  \fi}
+
+% {<csname>}{<true>}{<false>}
+
+\newcommand*{\ifcsundef}[1]{%
+  \ifcsname#1\endcsname
+    \expandafter\ifx\csname#1\endcsname\relax
+      \expandafter\expandafter
+      \expandafter\@firstoftwo
+    \else
+      \expandafter\expandafter
+      \expandafter\@secondoftwo
+    \fi
+  \else
+    \expandafter\@firstoftwo
+  \fi}
+
+% {<cstoken>}{<true}{<false>}
+
+\newcommand{\ifdefmacro}{}
+\long\edef\ifdefmacro#1{%
+  \noexpand\expandafter\noexpand\etb@ifdefmacro
+  \noexpand\meaning#1\detokenize{macro}:&}
+\edef\etb@ifdefmacro{%
+  \def\noexpand\etb@ifdefmacro##1\detokenize{macro}:##2&}
+\etb@ifdefmacro{\notblank{#2}}
+
+% {<csname>}{<true>}{<false>}
+
+\newcommand*{\ifcsmacro}[1]{%
+  \ifcsdef{#1}
+    {\expandafter\ifdefmacro\csname#1\endcsname}
+    {\@secondoftwo}}
+
+% {<cstoken>}{<true}{<false>}
+
+\newcommand{\ifdefprefix}[1]{%
+  \ifdefmacro{#1}
+    {\etb@ifdefprefix{#1}}
+    {\@secondoftwo}}
+\long\edef\etb@ifdefprefix#1{%
+  \noexpand\expandafter\noexpand\etb@ifdefprefix@i
+  \noexpand\meaning#1\detokenize{macro}:&}
+\edef\etb@ifdefprefix@i{%
+  \def\noexpand\etb@ifdefprefix@i##1\detokenize{macro}:##2&}
+\etb@ifdefprefix@i{\notblank{#1}}
+
+% {<csname>}{<true>}{<false>}
+
+\newcommand*{\ifcsprefix}[1]{%
+  \ifcsdef{#1}
+    {\expandafter\ifdefprefix\csname#1\endcsname}
+    {\@secondoftwo}}
+
+% {<cstoken>}{<true}{<false>}
+
+\newcommand{\ifdefparam}{}
+\long\edef\ifdefparam#1{%
+  \noexpand\expandafter\noexpand\etb@ifdefparam
+  \noexpand\meaning#1\detokenize{macro}:->&}
+\edef\etb@ifdefparam{%
+  \def\noexpand\etb@ifdefparam##1\detokenize{macro}:##2->##3&}
+\etb@ifdefparam{\notblank{#2}}
+
+% {<csname>}{<true>}{<false>}
+
+\newcommand*{\ifcsparam}[1]{%
+  \ifcsdef{#1}
+    {\expandafter\ifdefparam\csname#1\endcsname}
+    {\@secondoftwo}}
+
+% {<cstoken>}{<true}{<false>}
+
+\newcommand{\ifdefprotected}{}
+\long\edef\ifdefprotected#1{%
+  \noexpand\expandafter\noexpand\etb@ifdefprotected
+  \noexpand\meaning#1\string\protected&}
+\edef\etb@ifdefprotected{%
+  \def\noexpand\etb@ifdefprotected##1\string\protected##2&}
+\etb@ifdefprotected{\notblank{#2}}
+
+% {<csname>}{<true>}{<false>}
+
+\newcommand*{\ifcsprotected}[1]{%
+  \ifcsdef{#1}
+    {\expandafter\ifdefprotected\csname#1\endcsname}
+    {\@secondoftwo}}
+
+% {<cstoken>}{<true}{<false>}
+
+\newrobustcmd{\ifdefltxprotect}[1]{%
+  \begingroup
+  \edef\etb@resrvda{%
+    \noexpand\protect\expandafter\noexpand
+    \csname\expandafter\@gobble\string#1 \endcsname}%
+  \expandafter\endgroup\ifx#1\etb@resrvda
+    \expandafter\@firstoftwo
+  \else
+    \expandafter\@secondoftwo
+  \fi}
+
+% {<csname>}{<true>}{<false>}
+
+\newrobustcmd*{\ifcsltxprotect}[1]{%
+  \ifcsdef{#1}
+    {\expandafter\ifdefltxprotect\csname#1\endcsname}
+    {\@secondoftwo}}
+
+% {<cstoken>}{<true>}{<false>}
+
+\newcommand{\ifdefempty}[1]{%
+  \ifundef{#1}
+    {\@secondoftwo}
+    {\ifdefmacro{#1}
+       {\ifdefparam{#1}
+         {\@secondoftwo}
+         {\etb@ifdefempty{#1}}}
+       {\@secondoftwo}}}
+
+\def\etb@ifdefempty#1{%
+  \expandafter\expandafter
+  \expandafter\ifblank
+  \expandafter\expandafter
+  \expandafter{%
+  \expandafter\strip@prefix\meaning#1}}
+
+% {<csname>}{<true>}{<false>}
+
+\newcommand*{\ifcsempty}[1]{%
+  \ifcsundef{#1}
+    {\@secondoftwo}
+    {\expandafter\ifdefparam\csname#1\endcsname
+       {\@secondoftwo}
+       {\expandafter\etb@ifdefempty\csname#1\endcsname}}}
+
+% {<cstoken>}{<true>}{<false>}
+
+\newcommand{\ifdefvoid}[1]{%
+  \ifundef{#1}
+    {\@firstoftwo}
+    {\ifdefmacro{#1}
+       {\ifdefparam{#1}
+         {\@secondoftwo}
+         {\etb@ifdefempty{#1}}}
+       {\@secondoftwo}}}
+
+% {<csname>}{<true>}{<false>}
+
+\newcommand*{\ifcsvoid}[1]{%
+  \ifcsundef{#1}
+    {\@firstoftwo}
+    {\expandafter\ifdefparam\csname#1\endcsname
+       {\@secondoftwo}
+       {\expandafter\etb@ifdefempty\csname#1\endcsname}}}
+
+% {<cstoken1>}{<cstoken2>}{<true>}{<false>}
+
+\newcommand{\ifdefequal}[2]{%
+  \ifundef{#1}
+    {\@secondoftwo}
+    {\ifundef{#2}
+       {\@secondoftwo}
+       {\ifx#1#2%
+          \expandafter\@firstoftwo
+        \else
+          \expandafter\@secondoftwo
+        \fi}}}
+
+% {<csname1>}{<csname2>}{<true>}{<false>}
+
+\newcommand*{\ifcsequal}[2]{%
+  \ifcsundef{#1}
+    {\@secondoftwo}
+    {\ifcsundef{#2}
+       {\@secondoftwo}
+       {\expandafter\ifx
+        \csname#1\expandafter\endcsname
+        \csname#2\endcsname
+          \expandafter\@firstoftwo
+        \else
+          \expandafter\@secondoftwo
+        \fi}}}
+
+% {<cstoken1>}{<cstoken2>}{<true>}{<false>}
+
+\newrobustcmd{\ifdefstrequal}[2]{%
+  \ifdefmacro{#1}
+    {\ifdefmacro{#2}
+       {\begingroup
+       \edef\etb@tempa{\expandafter\strip@prefix\meaning#1}%
+       \edef\etb@tempb{\expandafter\strip@prefix\meaning#2}%
+       \ifx\etb@tempa\etb@tempb
+         \aftergroup\@firstoftwo
+       \else
+         \aftergroup\@secondoftwo
+       \fi
+       \endgroup}
+       {\@secondoftwo}}
+    {\@secondoftwo}}
+
+% {<csname1>}{<csname2>}{<true>}{<false>}
+
+\newcommand*{\ifcsstrequal}[2]{%
+  \ifcsundef{#1}
+    {\@secondoftwo}
+    {\ifcsundef{#2}
+       {\@secondoftwo}
+       {\expandafter\ifdefstrequal
+        \csname#1\expandafter\endcsname
+       \csname#2\endcsname}}}
+
+% {<cstoken>}{<string>}{<true>}{<false>}
+
+\newrobustcmd{\ifdefstring}[2]{%
+  \ifdefmacro{#1}
+    {\begingroup
+     \edef\etb@tempa{\expandafter\strip@prefix\meaning#1}%
+     \edef\etb@tempb{\detokenize{#2}}%
+     \ifx\etb@tempa\etb@tempb
+       \aftergroup\@firstoftwo
+     \else
+       \aftergroup\@secondoftwo
+     \fi
+     \endgroup}
+    {\@secondoftwo}}
+
+% {<csname>}{<string>}{<true>}{<false>}
+
+\newrobustcmd{\ifcsstring}[2]{%
+  \ifcsundef{#1}
+    {\@secondoftwo}
+    {\expandafter\ifdefstring\csname#1\endcsname{#2}}}
+
+% {<cstoken>}{<true}{<false>}
+
+\newcommand{\ifdefcounter}[1]{\etb@ifcounter#1&}
+\long\def\etb@ifcounter#1#2&{%
+  \ifx\count#1%
+    \expandafter\@secondoftwo
+  \else
+    \expandafter\etb@ifcounter@i\meaning#1:%
+  \fi}
+\edef\etb@ifcounter@i#1:#2\fi{\noexpand\fi
+  \noexpand\etb@ifcounter@ii#1\string\count&}
+\edef\etb@ifcounter@ii{%
+  \def\noexpand\etb@ifcounter@ii##1\string\count##2&}
+\etb@ifcounter@ii{\ifblank{#1}}
+
+% {<csname>}{<true>}{<false>}
+
+\newcommand*{\ifcscounter}[1]{%
+  \ifcsdef{#1}
+    {\expandafter\ifdefcounter\csname#1\endcsname}
+    {\@secondoftwo}}
+
+% {<name>}{<true>}{<false>}
+
+\newcommand*{\ifltxcounter}[1]{%
+  \ifcsdef{c@#1}
+    {\expandafter\ifdefcounter\csname c@#1\endcsname}
+    {\@secondoftwo}}
+
+% {<cstoken>}{<true}{<false>}
+
+\newcommand{\ifdeflength}[1]{\etb@iflength#1&}
+\long\def\etb@iflength#1#2&{%
+  \ifx\skip#1%
+    \expandafter\@secondoftwo
+  \else
+    \expandafter\etb@iflength@i\meaning#1:%
+  \fi}
+\edef\etb@iflength@i#1:#2\fi{\noexpand\fi
+  \noexpand\etb@iflength@ii#1\string\skip&}
+\edef\etb@iflength@ii{%
+  \def\noexpand\etb@iflength@ii##1\string\skip##2&}
+\etb@iflength@ii{\ifblank{#1}}
+
+% {<csname>}{<true>}{<false>}
+
+\newcommand*{\ifcslength}[1]{%
+  \ifcsdef{#1}
+    {\expandafter\ifdeflength\csname#1\endcsname}
+    {\@secondoftwo}}
+
+% {<cstoken>}{<true}{<false>}
+
+\newcommand{\ifdefdimen}[1]{\etb@ifdimen#1&}
+\long\def\etb@ifdimen#1#2&{%
+  \ifx\dimen#1%
+    \expandafter\@secondoftwo
+  \else
+    \expandafter\etb@ifdimen@i\meaning#1:%
+  \fi}
+\edef\etb@ifdimen@i#1:#2\fi{\noexpand\fi
+  \noexpand\etb@ifdimen@ii#1\string\dimen&}
+\edef\etb@ifdimen@ii{%
+  \def\noexpand\etb@ifdimen@ii##1\string\dimen##2&}
+\etb@ifdimen@ii{\ifblank{#1}}
+
+% {<csname>}{<true>}{<false>}
+
+\newcommand*{\ifcsdimen}[1]{%
+  \ifcsdef{#1}
+    {\expandafter\ifdefdimen\csname#1\endcsname}
+    {\@secondoftwo}}
+
+% {<string1>}{<string2>}{<true>}{<false>}
+
+\newrobustcmd{\ifstrequal}[2]{%
+  \begingroup
+  \edef\etb@tempa{\detokenize{#1}}%
+  \edef\etb@tempb{\detokenize{#2}}%
+  \ifx\etb@tempa\etb@tempb
+    \aftergroup\@firstoftwo
+  \else
+    \aftergroup\@secondoftwo
+  \fi
+  \endgroup}
+
+% {<string>}{<true>}{<false>}
+
+\newcommand{\ifstrempty}[1]{%
+  \expandafter\ifx\expandafter&\detokenize{#1}&%
+    \expandafter\@firstoftwo
+  \else
+    \expandafter\@secondoftwo
+  \fi}
+
+% {<string>}{<true>}{<false>}
+
+\newcommand{\ifblank}[1]{% from url.sty
+  \etb@ifblank@i#1&&\@secondoftwo\@firstoftwo:}
+\long\def\etb@ifblank@i#1#2&#3#4#5:{#4}
+
+\newcommand{\notblank}[1]{%
+  \etb@ifblank@i#1&&\@firstoftwo\@secondoftwo:}
+
+% {<numexpr>}{<comp>}{<numexpr>}{<true>}{<false>}
+
+\newcommand*{\ifnumcomp}[3]{%
+  \ifnum\numexpr#1\relax#2\numexpr#3\relax
+    \expandafter\@firstoftwo
+  \else
+    \expandafter\@secondoftwo
+  \fi}
+
+% {<numexpr>}{<numexpr>}{<true>}{<false>}
+
+\newcommand*{\ifnumequal}[1]{%
+  \ifnumcomp{#1}=}
+
+\newcommand*{\ifnumgreater}[1]{%
+  \ifnumcomp{#1}>}
+
+\newcommand*{\ifnumless}[1]{%
+  \ifnumcomp{#1}<}
+
+% {<numexpr>}{<true>}{<false>}
+
+\newcommand*{\ifnumodd}[1]{%
+  \ifodd\numexpr#1\relax
+    \expandafter\@firstoftwo
+  \else
+    \expandafter\@secondoftwo
+  \fi}
+
+% {<dimexpr>}{<comp>}{<dimexpr>}{<true>}{<false>}
+
+\newcommand*{\ifdimcomp}[3]{%
+  \ifdim\dimexpr#1\relax#2\dimexpr#3\relax
+    \expandafter\@firstoftwo
+  \else
+    \expandafter\@secondoftwo
+  \fi}
+
+% {<dimexpr>}{<dimexpr>}{<true>}{<false>}
+
+\newcommand*{\ifdimequal}[1]{%
+  \ifdimcomp{#1}=}
+
+\newcommand*{\ifdimgreater}[1]{%
+  \ifdimcomp{#1}>}
+
+\newcommand*{\ifdimless}[1]{%
+  \ifdimcomp{#1}<}
+
+% {<expr>}{<true>}{<false>}
+
+\newcommand{\ifboolexpe}[1]{%
+  \etb@be@beg\etb@be@bgroup#1(&\etb@be@end}
+
+\let\etb@be@true\@empty
+\def\etb@be@false{-\@ne}
+
+\def\etb@be@beg{%
+  \ifnum\numexpr\z@\ifnum\numexpr\z@}
+
+\def\etb@be@end{%
+  <\z@
+    \expandafter\etb@be@false
+  \fi
+  <\z@
+    \expandafter\@secondoftwo
+  \else
+    \expandafter\@firstoftwo
+  \fi}
+
+\long\def\etb@be@bgroup#1(#2&{%
+  \etb@be@egroup#1)&%
+  \ifblank{#2}
+    {}
+    {\etb@be@beg
+     \etb@be@bgroup#2&}}
+
+\long\def\etb@be@egroup#1)#2&{%
+  \etb@be@and#1and&%
+  \ifblank{#2}
+    {}
+    {\etb@be@end\etb@be@true\etb@be@false
+     \etb@be@egroup#2&}}
+
+\long\def\etb@be@and#1and#2&{%
+  \etb@be@or#1or&%
+  \ifblank{#2}
+    {}
+    {<\z@
+       \expandafter\@firstofone
+     \else
+       \expandafter\@gobble
+     \fi
+     {=\z@\fi\ifnum\numexpr\m@ne}%
+     \ifnum\numexpr\z@
+     \etb@be@and#2&}}
+
+\long\def\etb@be@or#1or#2&{%
+  \etb@be@not#1not&%
+  \ifblank{#2}
+    {}
+    {<\z@
+       \expandafter\@secondoftwo
+     \else
+       \expandafter\@firstoftwo
+     \fi
+     {=\z@\fi\ifnum\numexpr\z@
+      \ifnum\numexpr\@ne}
+     {=\z@\fi\ifnum\numexpr\z@
+      \ifnum\numexpr\z@}%
+     \etb@be@or#2&}}
+
+\long\def\etb@be@not#1not#2&{%
+  \etb@be@togl#1togl&%
+  \ifblank{#2}
+    {}
+    {>\z@
+       \expandafter\@firstoftwo
+     \else
+       \expandafter\@secondoftwo
+     \fi
+     {\unless\ifnum\numexpr\m@ne}
+     {\unless\ifnum\numexpr\z@}%
+     \etb@be@not#2&}}
+
+\long\def\etb@be@togl#1togl#2&{%
+  \etb@be@bool#1bool&%
+  \ifblank{#2}
+    {}
+    {\etb@be@togl@i#2&}}
+
+\long\def\etb@be@togl@i#1#2&{%
+  \ifcsdef{etb@tgl@#1}
+    {\csname etb@tgl@#1\endcsname\etb@be@true\etb@be@false}
+    {\etb@be@err{Toggle '#1' undefined}{}}%
+  \etb@be@togl#2&}
+
+\long\def\etb@be@bool#1bool#2&{%
+  \etb@be@test#1test&%
+  \ifblank{#2}
+    {}
+    {\etb@be@bool@i#2&}}
+
+\long\def\etb@be@bool@i#1#2&{%
+  \ifcsundef{if#1}
+    {\etb@be@err{Boolean '#1' undefined}{}}
+    {\csname if#1\endcsname
+     \else
+       \etb@be@false
+     \fi}%
+  \etb@be@bool#2&}
+
+\long\def\etb@be@test#1test#2&{%
+  \ifblank{#1}
+    {}
+    {\etb@be@err{The invalid part is: '\detokenize{#1}'}{}}%
+  \ifblank{#2}
+    {}
+    {\etb@be@test@i#2&}}
+
+\long\def\etb@be@test@i#1#2&{%
+  #1\etb@be@true\etb@be@false
+  \etb@be@test#2&}
+
+\long\def\etb@be@err#1#2{%
+  \expandafter\ifnum\the\numexpr
+    \expandafter\ifnum\the\currentiftype=-3
+      \expandafter\thr@@
+    \else
+      \expandafter\currentiftype
+    \fi
+  =\thr@@
+    \expandafter\@firstoftwo
+  \else
+    \expandafter\@secondoftwo
+  \fi
+  {=\z@\fi
+   \etb@be@err{#1}{#2\ifnum\numexpr\m@ne}}
+  {\etb@err@expr{#1}#2}}
+
+% {<expr>}{<true>}{<false>}
+
+\newrobustcmd{\ifboolexpr}[1]{\etb@boolexpr{#1}}
+
+\long\def\etb@boolexpr#1{%
+  \begingroup
+  \let\etb@br@neg\@firstoftwo
+  \etb@tempcnta\z@
+  \etb@br@beg
+  \etb@br@bgroup#1(&%
+  \etb@br@end
+  \etb@br@eval}
+
+\def\etb@br@beg{%
+  \begingroup
+  \let\etb@br@neg\@firstoftwo
+  \etb@tempcnta\z@}
+
+\def\etb@br@end{%
+  \etb@br@eval\etb@br@true\etb@br@false}
+
+\def\etb@br@eval{%
+  \ifnum\etb@tempcnta<\z@
+    \aftergroup\@secondoftwo
+  \else
+    \aftergroup\@firstoftwo
+  \fi
+  \endgroup}
+
+\def\etb@br@true{%
+  \advance\etb@tempcnta\etb@br@neg\z@\m@ne
+  \let\etb@br@neg\@firstoftwo}
+
+\def\etb@br@false{%
+  \advance\etb@tempcnta\etb@br@neg\m@ne\z@
+  \let\etb@br@neg\@firstoftwo}
+
+\long\def\etb@br@bgroup#1(#2&{%
+  \etb@br@egroup#1)&%
+  \ifblank{#2}
+    {}
+    {\etb@br@beg
+     \etb@br@bgroup#2&}}
+
+\long\def\etb@br@egroup#1)#2&{%
+  \etb@br@and#1and&%
+  \ifblank{#2}
+    {}
+    {\etb@br@end
+     \etb@br@egroup#2&}}
+
+\long\def\etb@br@and#1and#2&{%
+  \etb@br@or#1or&%
+  \ifblank{#2}
+    {}
+    {\ifnum\etb@tempcnta<\z@
+       \etb@tempcnta\m@ne
+     \else
+       \etb@tempcnta\z@
+     \fi
+     \etb@br@and#2&}}
+
+\long\def\etb@br@or#1or#2&{%
+  \etb@br@not#1not&%
+  \ifblank{#2}
+    {}
+    {\ifnum\etb@tempcnta<\z@
+       \etb@tempcnta\z@
+     \else
+       \etb@tempcnta\@ne
+     \fi
+     \etb@br@or#2&}}
+
+\long\def\etb@br@not#1not#2&{%
+  \etb@br@togl#1togl&%
+  \ifblank{#2}
+    {}
+    {\let\etb@br@neg\@secondoftwo
+     \etb@br@not#2&}}
+
+\long\def\etb@br@togl#1togl#2&{%
+  \etb@br@bool#1bool&%
+  \ifblank{#2}
+    {}
+    {\etb@br@togl@i#2&}}
+
+\long\def\etb@br@togl@i#1#2&{%
+  \ifcsdef{etb@tgl@#1}
+    {\csname etb@tgl@#1\endcsname\etb@br@true\etb@br@false}
+    {\etb@err@expr{Toggle '#1' undefined}\etb@br@false}%
+  \etb@br@togl#2&}
+
+\long\def\etb@br@bool#1bool#2&{%
+  \etb@br@test#1test&%
+  \ifblank{#2}
+    {}
+    {\etb@br@bool@i#2&}}
+
+\long\def\etb@br@bool@i#1#2&{%
+  \ifcsundef{if#1}
+    {\etb@err@expr{Boolean '#1' undefined}\etb@br@false}
+    {\csname if#1\endcsname
+       \etb@br@true
+     \else
+       \etb@br@false
+     \fi}%
+  \etb@br@bool#2&}
+
+\long\def\etb@br@test#1test#2&{%
+  \ifblank{#1}
+    {}
+    {\etb@err@expr{The invalid part is: '\detokenize{#1}'}}%
+  \ifblank{#2}
+    {}
+    {\etb@br@test@i#2&}}
+
+\long\def\etb@br@test@i#1#2&{%
+  \ignorespaces#1\etb@br@true\etb@br@false
+  \etb@br@test#2&}
+
+\long\def\etb@err@expr#1{%
+  \etb@error
+    {Invalid boolean expression}
+    {#1.}}
+
+% {<expr>}{<code>}
+
+\newrobustcmd{\whileboolexpr}[2]{%
+  \etb@boolexpr{#1}{#2\whileboolexpr{#1}{#2}}{}}
+
+% {<expr>}{<code>}
+
+\newrobustcmd{\unlessboolexpr}[2]{%
+  \etb@boolexpr{#1}{}{#2\unlessboolexpr{#1}{#2}}}
+
+% {<cstoken>}
+
+\newcommand{\expandonce}[1]{%
+  \unexpanded\expandafter{#1}}
+
+% {<csname>}
+
+\newcommand*{\csexpandonce}[1]{%
+  \expandafter\expandonce\csname#1\endcsname}
+
+% {<code>}
+
+\newcommand*{\protecting}{}
+\def\protecting#{%
+  \ifx\protect\@typeset@protect
+    \etb@protecting\@firstofone
+  \fi
+  \ifx\protect\@unexpandable@protect
+    \etb@protecting\etb@unexpandable
+  \fi
+  \ifx\protect\noexpand
+    \etb@protecting\unexpanded
+  \fi
+  \ifx\protect\string
+    \etb@protecting\detokenize
+  \fi
+  \relax\@firstofone}
+
+\def\etb@protecting#1#2\relax\@firstofone{\fi#1}
+\long\def\etb@unexpandable#1{\unexpanded{\protecting{#1}}}
+
+% {<csname>}
+
+\newrobustcmd*{\csdef}[1]{\expandafter\def\csname#1\endcsname}
+\newrobustcmd*{\csedef}[1]{\expandafter\edef\csname#1\endcsname}
+\newrobustcmd*{\csgdef}[1]{\expandafter\gdef\csname#1\endcsname}
+\newrobustcmd*{\csxdef}[1]{\expandafter\xdef\csname#1\endcsname}
+\newrobustcmd*{\protected@csedef}{\etb@protected\csedef}
+\newrobustcmd*{\protected@csxdef}{\etb@protected\csxdef}
+
+\def\etb@protected{%
+  \let\@@protect\protect
+  \let\protect\@unexpandable@protect
+  \afterassignment\restore@protect}
+
+% {<csname>}{<cstoken>}
+
+\newrobustcmd{\cslet}[2]{%
+  \expandafter\let\csname#1\endcsname#2}
+
+% {<cstoken>}{<csname>}
+
+\newrobustcmd{\letcs}[2]{%
+  \ifcsdef{#2}
+    {\expandafter\let\expandafter#1\csname#2\endcsname}
+    {\undef#1}}
+
+% {<csname>}{<csname>}
+
+\newrobustcmd*{\csletcs}[2]{%
+  \ifcsdef{#2}
+    {\expandafter\let
+     \csname#1\expandafter\endcsname
+     \csname#2\endcsname}
+    {\csundef{#1}}}
+
+% {<csname>}
+
+\newcommand*{\csuse}[1]{%
+  \ifcsname#1\endcsname
+    \csname#1\expandafter\endcsname
+  \fi}
+
+% {<cstoken>}
+
+\newrobustcmd{\undef}[1]{\let#1\etb@undefined}
+
+% {<csname>}
+
+\newrobustcmd*{\csundef}[1]{\cslet{#1}\etb@undefined}
+
+% {<cstoken>}{<code>}
+
+\newrobustcmd{\appto}[2]{%
+  \ifundef{#1}
+    {\edef#1{\unexpanded{#2}}}
+    {\edef#1{\expandonce#1\unexpanded{#2}}}}
+\newrobustcmd{\eappto}[2]{%
+  \ifundef{#1}
+    {\edef#1{#2}}
+    {\edef#1{\expandonce#1#2}}}
+\newrobustcmd{\gappto}[2]{%
+  \ifundef{#1}
+    {\xdef#1{\unexpanded{#2}}}
+    {\xdef#1{\expandonce#1\unexpanded{#2}}}}
+\newrobustcmd{\xappto}[2]{%
+  \ifundef{#1}
+    {\xdef#1{#2}}
+    {\xdef#1{\expandonce#1#2}}}
+
+\newrobustcmd*{\protected@eappto}{\etb@protected\eappto}
+\newrobustcmd*{\protected@xappto}{\etb@protected\xappto}
+
+% {<cstoken>}{<code>}
+
+\newrobustcmd{\preto}[2]{%
+  \ifundef{#1}
+    {\edef#1{\unexpanded{#2}}}
+    {\edef#1{\unexpanded{#2}\expandonce#1}}}
+\newrobustcmd{\epreto}[2]{%
+  \ifundef{#1}
+    {\edef#1{#2}}
+    {\edef#1{#2\expandonce#1}}}
+\newrobustcmd{\gpreto}[2]{%
+  \ifundef{#1}
+    {\xdef#1{\unexpanded{#2}}}
+    {\xdef#1{\unexpanded{#2}\expandonce#1}}}
+\newrobustcmd{\xpreto}[2]{%
+  \ifundef{#1}
+    {\xdef#1{#2}}
+    {\xdef#1{#2\expandonce#1}}}
+
+\newrobustcmd*{\protected@epreto}{\etb@protected\epreto}
+\newrobustcmd*{\protected@xpreto}{\etb@protected\xpreto}
+
+% {<csname>}{<code>}
+
+\newrobustcmd*{\csappto}[1]{\expandafter\appto\csname#1\endcsname}
+\newrobustcmd*{\cseappto}[1]{\expandafter\eappto\csname#1\endcsname}
+\newrobustcmd*{\csgappto}[1]{\expandafter\gappto\csname#1\endcsname}
+\newrobustcmd*{\csxappto}[1]{\expandafter\xappto\csname#1\endcsname}
+\newrobustcmd*{\protected@cseappto}{\etb@protected\cseappto}
+\newrobustcmd*{\protected@csxappto}{\etb@protected\csxappto}
+
+% {<csname>}{<code>}
+
+\newrobustcmd*{\cspreto}[1]{\expandafter\preto\csname#1\endcsname}
+\newrobustcmd*{\csepreto}[1]{\expandafter\epreto\csname#1\endcsname}
+\newrobustcmd*{\csgpreto}[1]{\expandafter\gpreto\csname#1\endcsname}
+\newrobustcmd*{\csxpreto}[1]{\expandafter\xpreto\csname#1\endcsname}
+\newrobustcmd*{\protected@csepreto}{\etb@protected\csepreto}
+\newrobustcmd*{\protected@csxpreto}{\etb@protected\csxpreto}
+
+% {<cstoken>}{<numexpr>}
+
+\newrobustcmd*{\numdef}[2]{%
+  \ifundef#1{\let#1\z@}{}%
+  \edef#1{\the\numexpr#2}}
+\newrobustcmd*{\numgdef}[2]{%
+  \ifundef#1{\let#1\z@}{}%
+  \xdef#1{\the\numexpr#2}}
+
+% {<csname>}{<numexpr>}
+
+\newrobustcmd*{\csnumdef}[1]{%
+  \expandafter\numdef\csname#1\endcsname}
+\newrobustcmd*{\csnumgdef}[1]{%
+  \expandafter\numgdef\csname#1\endcsname}
+
+% {<cstoken>}{<dimexpr>}
+
+\newrobustcmd*{\dimdef}[2]{%
+  \ifundef#1{\let#1\z@}{}%
+  \edef#1{\the\dimexpr#2}}
+\newrobustcmd*{\dimgdef}[2]{%
+  \ifundef#1{\let#1\z@}{}%
+  \xdef#1{\the\dimexpr#2}}
+
+% {<csname>}{<dimexpr>}
+
+\newrobustcmd*{\csdimdef}[1]{%
+  \expandafter\dimdef\csname#1\endcsname}
+\newrobustcmd*{\csdimgdef}[1]{%
+  \expandafter\dimgdef\csname#1\endcsname}
+
+% {<cstoken>}{<glueexpr>}
+
+\newrobustcmd*{\gluedef}[2]{%
+  \ifundef#1{\let#1\z@skip}{}%
+  \edef#1{\the\glueexpr#2}}
+\newrobustcmd*{\gluegdef}[2]{%
+  \ifundef#1{\let#1\z@skip}{}%
+  \xdef#1{\the\glueexpr#2}}
+
+% {<csname>}{<glueexpr>}
+
+\newrobustcmd*{\csgluedef}[1]{%
+  \expandafter\gluedef\csname#1\endcsname}
+\newrobustcmd*{\csgluegdef}[1]{%
+  \expandafter\gluegdef\csname#1\endcsname}
+
+% {<cstoken>}{<muexpr>}
+
+\newrobustcmd*{\mudef}[2]{%
+  \ifundef#1{\def#1{0mu}}{}%
+  \edef#1{\the\muexpr#2}}
+\newrobustcmd*{\mugdef}[2]{%
+  \ifundef#1{\let#1\z@}{}%
+  \xdef#1{\the\muexpr#2}}
+
+% {<csname>}{<muexpr>}
+
+\newrobustcmd*{\csmudef}[1]{%
+  \expandafter\mudef\csname#1\endcsname}
+\newrobustcmd*{\csmugdef}[1]{%
+  \expandafter\mugdef\csname#1\endcsname}
+
+% {<counter>}{<numexpr>}
+
+\newrobustcmd*{\defcounter}[2]{%
+  \ifcsundef{c@#1}
+    {\etb@noglobal\@nocounterr{#1}}%
+    {\csname c@#1\endcsname\numexpr#2\relax}}
+
+% {<length>}{<glueexpr>}
+
+\newrobustcmd*{\deflength}[2]{%
+  \ifundef{#1}
+    {\etb@noglobal\etb@err@nolen{#1}}%
+    {#1\glueexpr#2\relax}}
+
+\protected\def\etb@err@nolen#1{%
+  \etb@error{Length '\string#1' undefined}\@eha}
+
+% {<name>}
+
+\newrobustcmd*{\newbool}[1]{%
+  \expandafter\@ifdefinable\csname if#1\endcsname{%
+    \expandafter\newif\csname if#1\endcsname}}
+
+% {<name>}
+
+\newrobustcmd*{\providebool}[1]{%
+  \ifcsundef{if#1}
+    {\expandafter\newif\csname if#1\endcsname}
+    {\begingroup
+     \edef\@tempa{\expandafter\meaning\csname if#1\endcsname}%
+     \ifx\@tempa\etb@isfalse
+     \else
+       \ifx\@tempa\etb@istrue
+       \else
+         \etb@error{\@backslashchar if#1 not a boolean}\@eha
+       \fi
+     \fi
+     \endgroup}}
+
+% {<name>}{<true>|<false>}
+
+\newrobustcmd*{\setbool}[2]{%
+  \ifcsundef{if#1}
+    {\etb@noglobal\etb@err@nobool{#1}}
+    {\ifcsundef{#1#2}
+       {\etb@noglobal\etb@err@boolval{#2}}
+       {\csname#1#2\endcsname}}}
+
+% {<name>}
+
+\newrobustcmd*{\booltrue}[1]{%
+  \ifcsundef{if#1}
+    {\etb@noglobal\etb@err@nobool{#1}}
+    {\csname#1true\endcsname}}
+
+% {<name>}
+
+\newrobustcmd*{\boolfalse}[1]{%
+  \ifcsundef{if#1}
+    {\etb@noglobal\etb@err@nobool{#1}}
+    {\csname#1false\endcsname}}
+
+\edef\etb@istrue{\meaning\iftrue}
+\edef\etb@isfalse{\meaning\iffalse}
+\protected\def\etb@noglobal{\let\relax\relax}
+
+% {<name>}{<true}{<false>}
+
+\newcommand*{\ifbool}[1]{%
+  \ifcsundef{if#1}
+    {\etb@err@nobool{#1}\@gobbletwo}
+    {\csname if#1\endcsname
+       \expandafter\@firstoftwo
+     \else
+       \expandafter\@secondoftwo
+     \fi}}
+
+% {<name>}{<not true}{<not false>}
+
+\newcommand*{\notbool}[1]{%
+  \ifcsundef{if#1}
+    {\etb@err@nobool{#1}\@gobbletwo}
+    {\csname if#1\endcsname
+       \expandafter\@secondoftwo
+     \else
+       \expandafter\@firstoftwo
+     \fi}}
+
+\protected\def\etb@err@nobool#1{%
+  \etb@error{Boolean '\@backslashchar if#1' undefined}\@eha}
+
+\def\etb@err@boolval#1{%
+  \etb@error
+    {Invalid boolean value '#1'}
+    {Valid boolean values are 'true' and 'false'.}}
+
+% {<name>}
+
+\newrobustcmd*{\newtoggle}[1]{%
+  \ifcsdef{etb@tgl@#1}
+    {\etb@error{Toggle '#1' already defined}\@eha}
+    {\cslet{etb@tgl@#1}\@secondoftwo}}
+
+% {<name>}
+
+\newrobustcmd*{\providetoggle}[1]{%
+  \ifcsdef{etb@tgl@#1}
+    {}
+    {\cslet{etb@tgl@#1}\@secondoftwo}}
+
+% {<name>}{<true>|<false>}
+
+\newrobustcmd*{\settoggle}[2]{%
+  \ifcsdef{etb@tgl@#1}
+    {\ifcsdef{etb@toggle#2}
+       {\csletcs{etb@tgl@#1}{etb@toggle#2}}
+       {\etb@noglobal\etb@err@boolval{#2}}}
+    {\etb@noglobal\etb@err@notoggle{#1}}}
+
+% {<name>}
+
+\newrobustcmd*{\toggletrue}[1]{%
+  \ifcsdef{etb@tgl@#1}
+    {\cslet{etb@tgl@#1}\etb@toggletrue}
+    {\etb@noglobal\etb@err@notoggle{#1}}}
+
+% {<name>}
+
+\newrobustcmd*{\togglefalse}[1]{%
+  \ifcsdef{etb@tgl@#1}
+    {\cslet{etb@tgl@#1}\etb@togglefalse}
+    {\etb@noglobal\etb@err@notoggle{#1}}}
+
+\let\etb@toggletrue\@firstoftwo
+\let\etb@togglefalse\@secondoftwo
+
+% {<name>}{<true}{<false>}
+
+\newcommand*{\iftoggle}[1]{%
+  \ifcsdef{etb@tgl@#1}
+    {\csname etb@tgl@#1\endcsname}
+    {\etb@err@notoggle{#1}\@gobbletwo}}
+
+% {<name>}{<not true}{<not false>}
+
+\newcommand*{\nottoggle}[1]{%
+  \ifcsdef{etb@tgl@#1}
+    {\csname etb@tgl@#1\endcsname\@secondoftwo\@firstoftwo}
+    {\etb@err@notoggle{#1}\@gobbletwo}}
+
+\protected\def\etb@err@notoggle#1{%
+  \etb@error{Toggle '#1' undefined}\@eha}
+
+% {<cstoken>}{<true}{<false>}
+
+\protected\def\etb@ifscanable#1{%
+  \begingroup
+  \edef\etb@resrvda{%
+    \def\noexpand\etb@resrvda####1\detokenize{macro}:####2->####3&{%
+      ####1\def\string\etb@resrvda####2{####3}}%
+    \edef\noexpand\etb@resrvda{\noexpand\etb@resrvda\meaning#1&}}%
+  \etb@resrvda
+  \makeatletter
+  \scantokens\expandafter{\etb@resrvda}%
+  \expandafter\endgroup\ifx#1\etb@resrvda
+    \expandafter\@firstoftwo
+  \else
+    \expandafter\@secondoftwo
+  \fi}
+
+% {<cstoken>}{<search>}{<true}{<false>}
+
+\protected\long\def\etb@ifpattern#1#2{%
+  \begingroup
+  \edef\etb@resrvda{%
+    \def\noexpand\etb@resrvda####1\detokenize{#2}####2&{%
+      \endgroup\noexpand\noexpand\noexpand\ifblank{####2}}%
+    \edef\noexpand\etb@resrvda{\noexpand\etb@resrvda
+      \expandafter\strip@prefix\meaning#1\detokenize{#2}&}%
+    \noexpand\etb@resrvda}
+  \etb@resrvda\@secondoftwo\@firstoftwo}
+
+% {<string>}{<true}{<false>}
+
+\protected\long\def\etb@ifhashcheck#1{%
+  \begingroup
+  \edef\etb@resrvda{\detokenize{#1}}%
+  \expandafter\endgroup
+  \expandafter\etb@ifhashcheck@i\meaning\etb@resrvda&}
+
+\edef\etb@ifhashcheck@i#1&{%
+  \noexpand\expandafter
+  \noexpand\etb@ifhashcheck@ii
+  \noexpand\strip@prefix#1\string#\string#&}
+
+\edef\etb@ifhashcheck@ii{%
+  \def\noexpand\etb@ifhashcheck@ii##1\string#\string###2&}
+\etb@ifhashcheck@ii{\ifblank{#2}}
+
+% {<cstoken>}
+
+\newrobustcmd*{\robustify}[1]{%
+  \ifundef{#1}
+    {\etb@error{\string#1 undefined}\@eha}
+    {\ifdefmacro{#1}
+       {\ifdefltxprotect{#1}
+          {\letcs\etb@resrvda{\expandafter\@gobble\string#1 }%
+           \@tempswatrue}
+          {\let\etb@resrvda#1%
+           \@tempswafalse}%
+        \ifdefparam\etb@resrvda
+          {\etb@ifscanable\etb@resrvda
+             {\etb@robustify\etb@resrvda
+              \let#1\etb@resrvda}
+             {\etb@error{Failed to robustify \string#1}
+                {The command is special and cannot be
+                 handled by \string\robustify.}%
+              \@tempswafalse}}
+          {\protected\edef#1{\expandonce\etb@resrvda}}
+        \if@tempswa
+          \ifcsdef{\string#1 }
+            {}
+            {\csundef{\expandafter\@gobble\string#1 }}%
+        \fi
+        \undef\etb@resrvda}
+       {\etb@error{\string#1 not a macro}\@eha}}}
+
+\def\etb@robustify#1{%
+  \begingroup
+  \edef\etb@resrvdb{%
+    \def\noexpand\etb@resrvdb####1\detokenize{macro}:####2->####3&{%
+      \protected####1\def\string#1\space####2{####3}}%
+    \edef\noexpand\etb@resrvdb{%
+      \noexpand\etb@resrvdb\meaning#1&}}%
+  \etb@resrvdb
+  \etb@patchcmd@scantoks\etb@resrvdb}
+
+%  {<cstoken>}{<search>}{<true}{<false>}
+% *{<cstoken>}{<true}{<false>}
+
+\newrobustcmd{\ifpatchable}{%
+  \etb@dbg@trce\ifpatchable
+  \begingroup
+  \@makeother\#%
+  \@ifstar\etb@ifpatchable@i\etb@ifpatchable}
+
+\long\def\etb@ifpatchable#1#2{%
+  \endgroup
+  \etb@dbg@init#1%
+  \ifundef{#1}
+    {\etb@dbg@fail{def}\@secondoftwo}
+    {\etb@dbg@info{def}%
+     \ifdefmacro{#1}
+       {\etb@dbg@info{mac}%
+        \etb@ifscanable{#1}
+          {\etb@ifhashcheck{#2}
+             {\etb@dbg@info{tok}%
+              \etb@ifpattern#1{#2}
+                 {\etb@dbg@info{pat}%
+                  \etb@dbg@info{pos}\@firstoftwo}
+                 {\etb@dbg@fail{pat}\@secondoftwo}}
+             {\etb@dbg@fail{hsh}\@secondoftwo}}
+          {\etb@dbg@fail{tok}\@secondoftwo}}
+       {\etb@dbg@fail{mac}\@secondoftwo}}}
+
+\long\def\etb@ifpatchable@i#1{%
+  \endgroup
+  \etb@dbg@init#1%
+  \ifundef{#1}
+    {\etb@dbg@fail{def}\@secondoftwo}
+    {\etb@dbg@info{def}%
+     \ifdefmacro{#1}
+       {\etb@dbg@info{mac}%
+        \ifdefparam{#1}
+          {\etb@dbg@info{prm}%
+           \etb@ifscanable{#1}
+             {\etb@dbg@info{tok}%
+              \etb@dbg@info{pos}\@firstoftwo}
+             {\etb@dbg@fail{tok}\@secondoftwo}}
+          {\etb@dbg@info{prl}%
+           \ifdefprotected{#1}
+             {\etb@dbg@info{pro}}
+             {}%
+           \etb@dbg@info{pos}\@firstoftwo}}
+       {\etb@dbg@fail{mac}\@secondoftwo}}}
+
+% [<prefix>]{<cstoken>}{<search>}{<replace>}{<success>}{<failure>}
+
+\newrobustcmd*{\patchcmd}{%
+  \etb@dbg@trce\patchcmd
+  \begingroup
+  \@makeother\#%
+  \etb@patchcmd}
+
+\newcommand{\etb@patchcmd}[4][########1]{%
+  \etb@ifpatchable#2{#3}
+    {\etb@dbg@succ{ret}%
+     \begingroup
+     \edef\etb@resrvda{%
+       \def\noexpand\etb@resrvda####1\detokenize{macro:}####2->####3&{%
+         #1\def\string\etb@resrvda\space####2{\noexpand\etb@resrvdb####3&}}%
+       \def\noexpand\etb@resrvdb####1\detokenize{#3}####2&{%
+         ####1\detokenize{#4}####2}%
+       \edef\noexpand\etb@resrvda{%
+         \noexpand\etb@resrvda\meaning#2&}}%
+     \etb@resrvda
+     \etb@patchcmd@scantoks\etb@resrvda
+     \let#2\etb@resrvda
+     \undef\etb@resrvda
+     \@firstoftwo}
+    {\@secondoftwo}}
+
+\def\etb@patchcmd@scantoks#1{%
+  \edef\etb@resrvda{\endgroup
+    \unexpanded{\makeatletter\scantokens}{#1}%
+    \catcode\number`\@=\the\catcode`\@\relax}%
+  \etb@resrvda}
+
+% {<cstoken>}{<code>}{<success>}{<failure>}
+
+\newrobustcmd*{\apptocmd}{%
+  \etb@dbg@trce\apptocmd
+  \begingroup
+  \@makeother\#%
+  \etb@hooktocmd\etb@append}
+
+\newrobustcmd*{\pretocmd}{%
+  \etb@dbg@trce\pretocmd
+  \begingroup
+  \@makeother\#%
+  \etb@hooktocmd\etb@prepend}
+
+\long\def\etb@hooktocmd#1#2#3{%
+  \endgroup
+  \etb@dbg@init#2%
+  \ifundef{#2}
+    {\etb@dbg@fail{def}\@secondoftwo}
+    {\etb@dbg@info{def}%
+     \ifdefmacro{#2}
+       {\etb@dbg@info{mac}%
+        \ifdefparam{#2}
+          {\etb@dbg@info{prm}%
+           \etb@ifscanable{#2}
+             {\etb@ifhashcheck{#3}
+                {\etb@dbg@info{tok}%
+                 \etb@dbg@succ{ret}%
+                 \etb@hooktocmd@i#1#2{#3}%
+                 \@firstoftwo}
+                {\etb@dbg@fail{hsh}\@secondoftwo}}
+             {\etb@dbg@fail{tok}\@secondoftwo}}
+          {\etb@dbg@info{prl}%
+           \ifdefprotected{#2}
+             {\etb@dbg@info{pro}%
+              \etb@dbg@succ{red}%
+              \protected}
+             {\etb@dbg@succ{red}}%
+           \edef#2{#1{\expandonce#2}{\unexpanded{#3}}}%
+           \@firstoftwo}}
+       {\etb@dbg@fail{mac}\@secondoftwo}}}
+
+\long\def\etb@hooktocmd@i#1#2#3{%
+  \begingroup
+  \edef\etb@resrvda{%
+    \def\noexpand\etb@resrvda####1\detokenize{macro}:####2->####3&{%
+      ####1\def\string\etb@resrvda\space####2{#1{####3}{\detokenize{#3}}}}%
+    \edef\noexpand\etb@resrvda{%
+      \noexpand\etb@resrvda\meaning#2&}}%
+  \etb@resrvda
+  \etb@patchcmd@scantoks\etb@resrvda
+  \let#2\etb@resrvda
+  \undef\etb@resrvda}
+
+\long\def\etb@append#1#2{#1#2}
+\long\def\etb@prepend#1#2{#2#1}
+
+\newrobustcmd*{\tracingpatches}{%
+  \etb@info{Enabling tracing}%
+  \input{etoolbox.def}%
+  \global\let\tracingpatches\relax}
+\@onlypreamble\tracingpatches
+
+\let\etb@dbg@trce\@gobble
+\let\etb@dbg@init\@gobble
+\let\etb@dbg@info\@gobble
+\let\etb@dbg@succ\@gobble
+\let\etb@dbg@fail\@gobble
+
+% {<numeral>}
+
+\newcommand{\rmntonum}[1]{%
+  \ifblank{#1}
+    {}
+    {\expandafter\etb@rti@end\number\numexpr
+     \expandafter\etb@rti@prs\detokenize{#1}&\relax}}
+
+\def\etb@rti@prs#1#2{%
+  \ifx&#1%
+    \expandafter\@firstoftwo
+  \else
+    \expandafter\@secondoftwo
+  \fi
+  {#1#2}
+  {\ifx&#2%
+     \expandafter\@firstoftwo
+   \else
+     \expandafter\@secondoftwo
+   \fi
+   {\etb@rti@chk#1+\etb@rti@num#1#2}
+   {\etb@rti@chk#1\etb@rti@chk#2%
+    \ifnum\etb@rti@num#1<\etb@rti@num#2 %
+      \expandafter\@firstoftwo
+    \else
+      \expandafter\@secondoftwo
+    \fi
+    {+\etb@rti@num#2-\etb@rti@num#1\etb@rti@prs}
+    {+\etb@rti@num#1\etb@rti@prs#2}}}}
+
+\def\etb@rti@chk#1{%
+  \ifcsname etb@rmn@#1\endcsname
+  \else
+    \expandafter\etb@rti@brk
+  \fi}
+
+\def\etb@rti@brk#1&{+\z@&-1}
+\def\etb@rti@end#1&#2\relax{\ifblank{#2}{#1}{#2}}
+\def\etb@rti@num#1{\csname etb@rmn@#1\endcsname}
+
+\chardef\etb@rmn@i=1
+\chardef\etb@rmn@I=1
+\chardef\etb@rmn@v=5
+\chardef\etb@rmn@V=5
+\chardef\etb@rmn@x=10
+\chardef\etb@rmn@X=10
+\chardef\etb@rmn@l=50
+\chardef\etb@rmn@L=50
+\chardef\etb@rmn@c=100
+\chardef\etb@rmn@C=100
+\mathchardef\etb@rmn@d=500
+\mathchardef\etb@rmn@D=500
+\mathchardef\etb@rmn@m=1000
+\mathchardef\etb@rmn@M=1000
+
+% {<numeral>}{<true>}{<false>}
+
+\newcommand{\ifrmnum}[1]{%
+  \ifblank{#1}
+    {\@secondoftwo}
+    {\expandafter\etb@ifr@prs\detokenize{#1}\relax}}
+
+\def\etb@ifr@prs#1{%
+  \ifx\relax#1%
+    \expandafter\@firstoftwo
+  \else
+    \ifcsname etb@rmn@#1\endcsname
+      \expandafter\expandafter
+      \expandafter\etb@ifr@prs
+    \else
+      \expandafter\expandafter
+      \expandafter\etb@ifr@brk
+    \fi
+  \fi}
+
+\def\etb@ifr@brk#1\relax{\@secondoftwo}
+
+% <*>{<command>}{<separator>}
+
+\newrobustcmd*{\DeclareListParser}{%
+  \@ifstar
+    {\etb@defparser\etb@defparser@arg}
+    {\etb@defparser\etb@defparser@do}}
+
+\def\etb@defparser#1#2#3{%
+  \@ifdefinable#2{#1{#2}{#3}}}
+
+\def\etb@defparser@do#1#2{%
+  \begingroup
+  \edef\@tempa{\endgroup
+    \long\def\noexpand#1####1{%
+      \expandafter\noexpand
+      \csname etb@lst@\expandafter\@gobble\string#1\endcsname
+      \space####1\noexpand#2&}%
+    \long\csdef{etb@lst@\expandafter\@gobble\string#1}####1\noexpand#2####2&{%
+      \noexpand\etb@listitem\noexpand\do{####1}%
+      \noexpand\ifblank{####2}
+        {\noexpand\listbreak}
+        {\expandafter\noexpand
+         \csname etb@lst@\expandafter\@gobble\string#1\endcsname
+        \space####2}&}}%
+  \@tempa}
+
+\def\etb@defparser@arg#1#2{%
+  \begingroup
+  \edef\@tempa{\endgroup
+    \long\def\noexpand#1####1####2{%
+      \expandafter\noexpand
+      \csname etb@lst@\expandafter\@gobble\string#1\endcsname
+      {####1}\space####2\noexpand#2&}%
+    \long\csdef{etb@lst@\expandafter\@gobble\string#1}####1####2\noexpand#2####3&{%
+      \noexpand\etb@listitem{####1}{####2}%
+      \noexpand\ifblank{####3}
+        {\noexpand\listbreak}
+        {\expandafter\noexpand
+         \csname etb@lst@\expandafter\@gobble\string#1\endcsname
+        {####1}\space####3}&}}%
+  \@tempa}
+
+\long\def\etb@listitem#1#2{%
+  \ifblank{#2}
+    {}
+    {\expandafter\etb@listitem@i
+     \expandafter{\@firstofone#2}{#1}}}
+\long\def\etb@listitem@i#1#2{#2{#1}}
+
+\newcommand*{\listbreak}{}
+\long\def\listbreak#1&{}
+
+% {<item1>,<item2>,...} => \do{<item1>}\do{<item2>}...
+
+\DeclareListParser{\docsvlist}{,}
+
+% {<handler>}{<item1>,<item2>,...} => <handler>{<item1>}<handler>{<item2>}...
+
+\DeclareListParser*{\forcsvlist}{,}
+
+% {<listmacro>}{<string>}
+
+\newrobustcmd{\listadd}[2]{%
+  \ifblank{#2}{}{\appto#1{#2|}}}
+\newrobustcmd{\listeadd}[2]{%
+  \begingroup
+  \edef\etb@tempa{\endgroup\noexpand\ifblank{#2}}%
+  \etb@tempa{}{\eappto#1{#2|}}}
+\newrobustcmd{\listgadd}[2]{%
+  \ifblank{#2}{}{\gappto#1{#2|}}}
+\newrobustcmd{\listxadd}[2]{%
+  \begingroup
+  \edef\etb@tempa{\endgroup\noexpand\ifblank{#2}}%
+  \etb@tempa{}{\xappto#1{#2|}}}
+
+% {<listcsname>}{<string>}
+
+\newrobustcmd{\listcsadd}[1]{%
+  \expandafter\listadd\csname#1\endcsname}
+\newrobustcmd{\listcseadd}[1]{%
+  \expandafter\listeadd\csname#1\endcsname}
+\newrobustcmd{\listcsgadd}[1]{%
+  \expandafter\listgadd\csname#1\endcsname}
+\newrobustcmd{\listcsxadd}[1]{%
+  \expandafter\listxadd\csname#1\endcsname}
+
+% {<string>}{<listmacro>}{<true>}{<false>}
+
+\newrobustcmd{\ifinlist}[2]{%
+  \begingroup
+  \def\etb@tempa##1|#1|##2&{\endgroup
+    \ifblank{##2}\@secondoftwo\@firstoftwo}%
+  \expandafter\etb@tempa\expandafter|#2|#1|&}
+
+\newrobustcmd{\xifinlist}[1]{%
+  \begingroup
+  \edef\etb@tempa{\endgroup\ifinlist{#1}}%
+  \etb@tempa}
+
+% {<string>}{<listcsname>}{<true>}{<false>}
+
+\newrobustcmd{\ifinlistcs}[2]{%
+  \expandafter\etb@ifinlistcs@i\csname #2\endcsname{#1}}
+\long\def\etb@ifinlistcs@i#1#2{\ifinlist{#2}{#1}}
+
+\newrobustcmd{\xifinlistcs}[1]{%
+  \begingroup
+  \edef\etb@tempa{\endgroup\ifinlistcs{#1}}%
+  \etb@tempa}
+
+% {<handler>}{<listmacro>} => <handler>{<item1>}<handler>{<item2>}...
+
+\newcommand*{\forlistloop}[2]{%
+  \expandafter\etb@forlistloop\expandafter{#2}{#1}}
+
+\long\def\etb@forlistloop#1#2{\etb@forlistloop@i{#2}#1|&}
+
+\long\def\etb@forlistloop@i#1#2|#3&{%
+  \ifblank{#2}
+    {}
+    {#1{#2}}%
+  \ifblank{#3}
+    {\listbreak}
+    {\etb@forlistloop@i{#1}#3}%
+  &}
+
+% {<handler>}{<listcsname>} => <handler>{<item1>}<handler>{<item2>}...
+
+\newcommand*{\forlistcsloop}[2]{%
+  \expandafter\expandafter\expandafter\etb@forlistloop
+  \expandafter\expandafter\expandafter{\csname#2\endcsname}{#1}}
+
+% {<listmacro>} => \do{<item1>}\do{<item2>}...
+
+\newcommand*{\dolistloop}{\forlistloop\do}
+
+% {<listcsname>} => \do{<item1>}\do{<item2>}...
+
+\newcommand*{\dolistcsloop}{\forlistcsloop\do}
+
+% {<code>}
+
+\newrobustcmd*{\AtEndPreamble}{\gappto\@endpreamblehook}
+\newcommand*{\@endpreamblehook}{}
+
+\preto\document{%
+  \endgroup
+  \let\AtEndPreamble\@firstofone
+  \@endpreamblehook
+  \protected\def\AtEndPreamble{\@notprerr\@gobble}%
+  \undef\@endpreamblehook
+  \begingroup}
+
+% {<code>}
+
+\newrobustcmd*{\AfterPreamble}{\AtBeginDocument}
+\AtEndPreamble{\let\AfterPreamble\@firstofone}
+
+% {<code>}
+
+\newrobustcmd*{\AfterEndPreamble}{\gappto\@afterendpreamblehook}
+\newcommand*{\@afterendpreamblehook}{}
+
+\appto\document{%
+  \let\AfterEndPreamble\@firstofone
+  \@afterendpreamblehook
+  \protected\def\AfterEndPreamble{\@notprerr\@gobble}%
+  \undef\@afterendpreamblehook
+  \ignorespaces}
+
+\AtEndDocument{\let\AfterEndPreamble\@gobble}
+
+% {<code>}
+
+\newrobustcmd*{\AfterEndDocument}{\gappto\@afterenddocumenthook}
+\newcommand*{\@afterenddocumenthook}{}
+
+\patchcmd\enddocument
+  {\deadcycles}
+  {\let\AfterEndDocument\@firstofone
+   \@afterenddocumenthook
+   \deadcycles}
+  {}
+  {\let\etb@@end\@@end
+   \def\@@end{%
+     \let\AfterEndDocument\@firstofone
+     \@afterenddocumenthook
+     \etb@@end}}
+
+% {<environment>}{<code>}
+
+\newrobustcmd{\AtBeginEnvironment}[1]{%
+  \csgappto{@begin@#1@hook}}
+
+\patchcmd\begin
+  {\csname #1\endcsname}
+  {\csuse{@begin@#1@hook}%
+   \csname #1\endcsname}
+  {}
+  {\etb@warning{%
+     Patching '\string\begin' failed!\MessageBreak
+     '\string\AtBeginEnvironment' will not work\@gobble}}
+
+% {<environment>}{<code>}
+
+\newrobustcmd{\AtEndEnvironment}[1]{%
+  \csgappto{@end@#1@hook}}
+
+\patchcmd\end
+  {\csname end#1\endcsname}
+  {\csuse{@end@#1@hook}%
+   \csname end#1\endcsname}
+  {}
+  {\etb@warning{%
+     Patching '\string\end' failed!\MessageBreak
+     '\string\AtEndEnvironment' will not work\@gobble}}
+
+% {<environment>}{<code>}
+
+\newrobustcmd{\BeforeBeginEnvironment}[1]{%
+  \csgappto{@beforebegin@#1@hook}}
+
+\pretocmd\begin
+  {\csuse{@beforebegin@#1@hook}}
+  {}
+  {\etb@warning{%
+     Patching '\string\begin' failed!\MessageBreak
+     '\string\BeforeBeginEnvironment' will not work\@gobble}}
+
+% {<environment>}{<code>}
+
+\newrobustcmd{\AfterEndEnvironment}[1]{%
+  \csgappto{@afterend@#1@hook}}
+
+\patchcmd\end
+  {\if@ignore}
+  {\csuse{@afterend@#1@hook}%
+   \if@ignore}
+  {}
+  {\etb@warning{%
+     Patching '\string\end' failed!\MessageBreak
+     '\string\AfterEndEnvironment' will not work\@gobble}}
+
+\endinput
diff --git a/example-1.tex b/example-1.tex
new file mode 100644 (file)
index 0000000..da3de7a
--- /dev/null
@@ -0,0 +1,101 @@
+%%
+%% This is file `example-1.tex',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% drexel-thesis.dtx  (with options: `example-part')
+%% 
+%% This is a generated file.
+%% 
+%% Copyright (C) 2010-2012 W. Trevor King
+%% 
+%% This file may be distributed and/or modified under the conditions of
+%% the LaTeX Project Public License, either version 1.3 of this license
+%% or (at your option) any later version.  The latest version of this
+%% license is in:
+%% 
+%%    http://www.latex-project.org/lppl.txt
+%% 
+%% and version 1.3 or later is part of all distributions of LaTeX version
+%% 2003/06/01 or later.
+%% 
+\part{A Part Heading}
+\chapter{A Chapter Heading}
+\section{A Section Heading}
+The following sectioning commands are available:
+\begin{quote}
+ part \\
+ chapter \\
+ section \\
+ subsection \\
+ subsubsection \\
+ paragraph \\
+ subparagraph
+\end{quote}
+
+\subsection{natbib}
+You can cite your references with |natbib|'s |\citet| and |\citep|
+macros.  See
+\href{http://www.ctan.org/tex-archive/macros/latex/contrib/natbib/}
+{the natbib manual} for details.
+
+Here we have a text citation \citet{rief97} followed by a
+parenthetical citation\citep{rief97}.
+
+\subsubsection{Tables and Figures}
+\Blindtext[2]
+\begin{table}
+  \begin{center}
+  \begin{tabular}{r@{.}l r@{.}l r@{.}l}
+    \multicolumn{2}{c}{Time (s)} &
+      \multicolumn{2}{c}{John Henry (m)} &
+      \multicolumn{2}{c}{Steam drill (m)} \\
+    0&0 & 0&0 & 0&0 \\
+    10&0 & 4&3 & 3&75 \\
+    30&0 & 11&9 & 10&1 \\
+    \ldots
+  \end{tabular}
+  \caption{A table float.} % low caption allowed with floatrow
+%% Note the strange |r@{.}l| notation in the |\tabular| column
+%% definition.  This allows for numbers aligned at the decimal point
+%% (see \href{http://www.stat.unipg.it/tex-man/ltx-68.html}{here}).
+%%
+%% |\multicolumn{num_cols}{alignment}{contents}| allows the headings
+%% to span the pre- and post-decimal columns.
+  \end{center}
+\end{table}
+\Blindtext[2]
+\begin{figure}
+  \caption{A figure float. \blindtext} % high caption allowed with floatrow
+  \begin{center}
+    \includegraphics[width=0.4\textwidth]{drexel-logo}
+  \end{center}
+\end{figure}
+\Blindtext[3]
+\begin{figure}
+  \begin{center}
+    \subfloat[][]{%
+      \includegraphics[width=0.2\textwidth]{drexel-logo}%
+      \label{fig:sub-a}}
+    \subfloat[][]{%
+      \includegraphics[width=0.2\textwidth]{drexel-logo}%
+      \label{fig:sub-b}}
+    \caption{(a) One subfig float. (b) Another subfig float.%
+      \label{fig:both}}
+  \end{center}
+\end{figure}
+You can reference the subfig floats individually (\ref{fig:sub-a}) or
+together (\ref{fig:both}).
+
+\Blindtext[3]
+
+\part{Another Part}
+\chapter{Another Chapter}
+\Blindtext[5]
+\chapter{A Long Title Bla Bla Bla Bla Bla Bla Bla Bla Bla Bla Bla
+Bla Bla Bla Bla Bla Bla Bla Bla Bla Bla Bla Bla Bla Bla Bla}
+\Blindtext[5]
+\endinput
+%%
+%% End of file `example-1.tex'.
diff --git a/example-a.tex b/example-a.tex
new file mode 100644 (file)
index 0000000..33e81d6
--- /dev/null
@@ -0,0 +1,29 @@
+%%
+%% This is file `example-a.tex',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% drexel-thesis.dtx  (with options: `example-appendix')
+%% 
+%% This is a generated file.
+%% 
+%% Copyright (C) 2010-2012 W. Trevor King
+%% 
+%% This file may be distributed and/or modified under the conditions of
+%% the LaTeX Project Public License, either version 1.3 of this license
+%% or (at your option) any later version.  The latest version of this
+%% license is in:
+%% 
+%%    http://www.latex-project.org/lppl.txt
+%% 
+%% and version 1.3 or later is part of all distributions of LaTeX version
+%% 2003/06/01 or later.
+%% 
+\chapter{Some Appendix Heading}
+\Blindtext[5]
+\chapter{Another Appendix Heading}
+\Blindtext[5]
+\endinput
+%%
+%% End of file `example-a.tex'.
diff --git a/example-draft.pdf b/example-draft.pdf
new file mode 100644 (file)
index 0000000..cd340f3
Binary files /dev/null and b/example-draft.pdf differ
diff --git a/example-draft.tex b/example-draft.tex
new file mode 100644 (file)
index 0000000..d9fccb9
--- /dev/null
@@ -0,0 +1,88 @@
+%%
+%% This is file `example-draft.tex',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% drexel-thesis.dtx  (with options: `example-draft')
+%% 
+%% This is a generated file.
+%% 
+%% Copyright (C) 2010-2012 W. Trevor King
+%% 
+%% This file may be distributed and/or modified under the conditions of
+%% the LaTeX Project Public License, either version 1.3 of this license
+%% or (at your option) any later version.  The latest version of this
+%% license is in:
+%% 
+%%    http://www.latex-project.org/lppl.txt
+%% 
+%% and version 1.3 or later is part of all distributions of LaTeX version
+%% 2003/06/01 or later.
+%% 
+%% See drexel-thesis.pdf for details.
+\documentclass[draft,subfig]{drexel-thesis}
+
+%% Enter the appropriate information here
+\author{Johny Henry}
+\title{Inadequacies of Steam-Driven Boring Machines}
+\DUTmonth{July}
+\DUTyear{1872}
+\degree{Doctor of Philosophy}
+\advisor{Collis Potter Huntington, R.R.D.}
+\advisor{Advisor 2, Ph.D.}
+\advisor{Advisor 3, Ph.D.}
+\copyrighttext{\copyrighttextCCBYSA}
+
+\usepackage[super,sort&compress]{natbib} % fancy citation extensions
+\bibliographystyle{unsrtnat}
+
+\usepackage{fancyvrb} % nicer verbatim handling
+\DefineShortVerb{\|}  % \verb+TEXT+  ->  |TEXT|
+
+\renewenvironment{preamble}{% look, we're clobbering an environment!
+  What preamble?\begingroup\color{white}}{\endgroup}
+
+\usepackage[english]{babel} % English blindtext
+\usepackage{blindtext} % macros for producing dummy output
+\addto\captionsenglish{\DUTnames}
+
+\begin{document}
+\begin{DUTpreamble} % "DUT" because original preamble was clobbered.
+
+\begin{dedications}
+We're in \iffinal{final}{draft} mode!
+
+\Blindtext[3]
+\end{dedications}
+
+\begin{acknowledgments}
+\Blindtext[3]
+\end{acknowledgments}
+
+\tableofcontents
+\listoftables
+\listoffigures
+
+\begin{abstract}
+\Blindtext[3]
+\end{abstract}
+\end{DUTpreamble}
+
+\begin{thesis}
+\include{example-1}
+\end{thesis}
+
+\bibliography{example-ref}
+
+\appendix
+\include{example-a}
+
+\begin{vita}
+\Blindtext[3]
+\end{vita}
+
+\end{document}
+\endinput
+%%
+%% End of file `example-draft.tex'.
diff --git a/example-ref.bib b/example-ref.bib
new file mode 100644 (file)
index 0000000..e0381e7
--- /dev/null
@@ -0,0 +1,59 @@
+%%
+%% This is file `example-ref.bib',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% drexel-thesis.dtx  (with options: `example-bibtex-refs')
+%% 
+%% This is a generated file.
+%% 
+%% Copyright (C) 2010-2012 W. Trevor King
+%% 
+%% This file may be distributed and/or modified under the conditions of
+%% the LaTeX Project Public License, either version 1.3 of this license
+%% or (at your option) any later version.  The latest version of this
+%% license is in:
+%% 
+%%    http://www.latex-project.org/lppl.txt
+%% 
+%% and version 1.3 or later is part of all distributions of LaTeX version
+%% 2003/06/01 or later.
+%% 
+%% Publishers
+@String{APS = "American Physical Society"}
+
+%% Journals
+@String{SCI = "Science"}
+
+%% Authors
+@String{MRief = "Rief, Matthias"}
+@String{MGautel = "Gautel, Mathias"}
+@String{FOesterhelt = "Oesterhelt, Filipp"}
+@String{JFernandez = "Fernandez, Julio M."}
+@String{HGaub = "Gaub, Hermann E."}
+
+%% Articles
+@Article{rief97,
+  author = MRief #" and "# MGautel #" and "# FOesterhelt #" and "#
+           JFernandez #" and "# HGaub,
+  title = "Reversible Unfolding of Individual Titin Immunoglobulin
+           Domains by {AFM}",
+  journal = SCI,
+  volume =  276,
+  number =  5315,
+  pages =   "1109--1112",
+  year =    1997,
+  doi =     "10.1126/science.276.5315.1109",
+  URL =     "http://www.sciencemag.org/cgi/content/abstract/276/5315/1109",
+  eprint =  "http://www.sciencemag.org/cgi/reprint/276/5315/1109.pdf",
+  mynote = "Seminal paper for force spectroscopy on Titin. Cited by
+           Dietz '04 (ref 9) as an example of how unfolding large
+           proteins is easily interpreted (vs.\ confusing unfolding in
+           bulk), but Titin is a rather simple example of that, because
+           of its globular-chain structure.",
+}
+%% ...
+\endinput
+%%
+%% End of file `example-ref.bib'.
diff --git a/example.pdf b/example.pdf
new file mode 100644 (file)
index 0000000..b00126e
Binary files /dev/null and b/example.pdf differ
diff --git a/example.tex b/example.tex
new file mode 100644 (file)
index 0000000..a09c914
--- /dev/null
@@ -0,0 +1,88 @@
+%%
+%% This is file `example.tex',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% drexel-thesis.dtx  (with options: `example')
+%% 
+%% This is a generated file.
+%% 
+%% Copyright (C) 2010-2012 W. Trevor King
+%% 
+%% This file may be distributed and/or modified under the conditions of
+%% the LaTeX Project Public License, either version 1.3 of this license
+%% or (at your option) any later version.  The latest version of this
+%% license is in:
+%% 
+%%    http://www.latex-project.org/lppl.txt
+%% 
+%% and version 1.3 or later is part of all distributions of LaTeX version
+%% 2003/06/01 or later.
+%% 
+%% See drexel-thesis.pdf for details.
+\documentclass[subfig,blackref,approvalform]{drexel-thesis}
+
+%% Enter the appropriate information here
+\author{Johny Henry}
+\title{Inadequacies of Steam-Driven Boring Machines}
+\DUTmonth{July}
+\DUTyear{1872}
+\degree{Doctor of Philosophy}
+\advisor{Collis Potter Huntington, R.R.D.}
+\advisor{Advisor 2, Ph.D.}
+\advisor{Advisor 3, Ph.D.}
+\copyrighttext{\copyrighttextCCBYSA}
+
+\usepackage[super,sort&compress]{natbib} % fancy citation extensions
+\bibliographystyle{unsrtnat}
+
+\usepackage{fancyvrb} % nicer verbatim handling
+\DefineShortVerb{\|}  % \verb+TEXT+  ->  |TEXT|
+
+\renewenvironment{preamble}{% look, we're clobbering an environment!
+  What preamble?\begingroup\color{white}}{\endgroup}
+
+\usepackage[english]{babel} % English blindtext
+\usepackage{blindtext} % macros for producing dummy output
+\addto\captionsenglish{\DUTnames}
+
+\begin{document}
+\begin{DUTpreamble} % "DUT" because original preamble was clobbered.
+
+\begin{dedications}
+We're in \iffinal{final}{draft} mode!
+
+\Blindtext[3]
+\end{dedications}
+
+\begin{acknowledgments}
+\Blindtext[3]
+\end{acknowledgments}
+
+\tableofcontents
+\listoftables
+\listoffigures
+
+\begin{abstract}
+\Blindtext[3]
+\end{abstract}
+\end{DUTpreamble}
+
+\begin{thesis}
+\include{example-1}
+\end{thesis}
+
+\bibliography{example-ref}
+
+\appendix
+\include{example-a}
+
+\begin{vita}
+\Blindtext[3]
+\end{vita}
+
+\end{document}
+\endinput
+%%
+%% End of file `example.tex'.
diff --git a/floatrow.sty b/floatrow.sty
new file mode 100644 (file)
index 0000000..01a33fb
--- /dev/null
@@ -0,0 +1,1472 @@
+%%
+%% This is file `floatrow.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% floatrow.dtx  (with options: `floatrow,floatsetup')
+%% 
+%% IMPORTANT NOTICE:
+%% 
+%% For the copyright see the source file.
+%% 
+%% Any modified versions of this file must be renamed
+%% with new filenames distinct from floatrow.sty.
+%% 
+%% For distribution of the original source see the terms
+%% for copying and modification in the file floatrow.dtx.
+%% 
+%% This generated file may be distributed as long as the
+%% original source files, as listed above, are part of the
+%% same distribution. (The sources need not necessarily be
+%% in the same archive or directory.)
+\NeedsTeXFormat{LaTeX2e}[1995/06/01]
+\ProvidesPackage{floatrow}
+       [2008/08/02 v0.3b floatrow: float package extension]
+\@ifundefined{float@caption}{%
+  \@ifundefined{rotfloat@float}{}%
+    {\PackageError{floatrow}{Do not use rotfloat package with floatrow.\MessageBreak
+        The latter will be skipped}{}%
+  \@namedef{opt@floatrow.sty}{}\endinput}}%
+  {\PackageError{floatrow}{Do not use float package with floatrow.\MessageBreak
+        The latter will be skipped}{}%
+  \@namedef{opt@floatrow.sty}{}\endinput}
+\@namedef{ver@float.sty}{2001/11/08 v1.3d (excerpt)
+    Float enhancements (AL)}
+\@namedef{ver@rotfloat.sty}{2004/01/04 v1.2 (excerpt)
+    Combining float+rotating package (AS)}
+\RequirePackage{keyval}
+\RequirePackage{caption3}
+\@ifpackagelater{caption3}{2007/04/11 v3.0q}{}{\PackageError
+    {floatrow}{For a successful cooperation we need at least\MessageBreak
+    version `2007/04/11 v3.0q' of package caption,\MessageBreak
+        but only version\MessageBreak
+          `\csname ver@caption.\@pkgextension\endcsname'\MessageBreak
+        is available}\@eha\endinput}
+\providecommand*\caption@fnum[1]{%
+   \caption@lfmt{\@nameuse{#1name}}{\@nameuse{the#1}}}
+\@ifdefinable\FR@flboxreset{\let\FR@flboxreset\@floatboxreset}
+\@ifdefinable\FR@makecaption{\let\FR@makecaption\@makecaption}
+\newcommand\flrow@caption{%
+   \ifx\@captype\@undefined
+     \@latex@error{\noexpand\caption outside float}\@ehd
+     \expandafter\@gobble
+   \else
+     \refstepcounter\@captype
+     \expandafter\@firstofone
+   \fi
+   {\@dblarg{\@caption\@captype}}%
+}
+\@ifdefinable\float@caption{\let\float@caption\@caption}
+\newcounter{float@type}
+\@ifundefined{c@figure}%
+  {\setcounter{float@type}{1}}%
+  {\setcounter{float@type}{4}}
+\newcommand\flrow@package{floatrow}
+\newcommand*\flrow@error[1]{\PackageError\flrow@package{#1}\flrow@eh}
+\newcommand*\flrow@eh{%
+  If you do not understand this error, please take look\MessageBreak
+  at `floatrow' and `caption' package documentations.\MessageBreak
+  \@ehc}
+\newcommand\floatstyle[1]{\@ifundefined{flrow@sty@#1}%
+  {\flrow@error{Unknown float style `#1'}}{\edef\float@style{#1}}}
+\newcommand\floatname[2]{\@namedef{#1name}{#2}}
+\newcommand\floatplacement[2]{\@namedef{fps@#1}{#2}}
+\newif\if@@FS
+\newcommand\FR@redefs{%
+  \@ifundefined{HyOrg@float@makebox}{}%
+    {\let\float@makebox\HyOrg@float@makebox}%
+  \ifx\flrow@makecaption\@makecaption\relax
+  \else
+    \let\FR@makecaption\@makecaption
+    \let\@makecaption\flrow@makecaption
+  \fi
+  \let\@floatboxreset\flrow@flboxreset}
+\newcommand\flrow@makecaption[2]{\ifnum\floatbox@depth=\z@
+    \ifvoid\@floatcapt
+      \else\flrow@error{Caption(s) lost}\fi\fi
+  \global\setbox\@floatcapt
+  \vbox\bgroup\@parboxrestore
+   \reset@font
+   \if@@FS
+      \ifdim\FBc@wd>\z@
+        \hsize\FBc@wd
+      \else
+        \adj@dim\hsize+\FBo@wadj=\hsize
+      \fi
+   \fi
+   \linewidth\hsize
+   \ifdim\hsize<70mm\sloppy\fi
+   \normalsize
+   \abovecaptionskip\z@\belowcaptionskip\z@
+   \FR@makecaption{#1}{#2}\egroup}
+\newcommand\killfloatstyle{\FBbuildtrue\if@@FS\hsize\FB@wd\fi\@@FSfalse}
+\newcommand\flrow@capsetup{}
+\edef\float@style{plain}
+\@ifdefinable\FBB@wd{\let\FBB@wd\relax}
+\newcommand\restylefloat{%
+   \@ifstar{\flrow@restylefloat{no}\flrow@restyle}%
+     {\flrow@restylefloat{yes}\flrow@restyle}}
+\newcommand\flrow@restylefloat[3]{%
+   \edef\FR@tmp{\noexpand
+     \floatsetup[#3]{style=\float@style,relatedcapstyle=#1}}\FR@tmp
+   #2{#3}}
+\newcommand\flrow@restyle[1]{%
+  \@namedef{#1}{\killfloatstyle\def\@captype{#1}\FR@redefs
+    \flrow@setlist{{#1}}%
+    \textwidth\columnwidth\edef\FBB@wd{\the\columnwidth}%
+    \FRifFBOX\@@setframe\relax\@@FStrue\@float{#1}}%
+  \@namedef{#1*}{\killfloatstyle\def\@captype{#1}\FR@redefs
+    \flrow@setlist{{#1}{widefloat}{wide#1}}%
+    \FRifFBOX\@@setframe\relax\@@FStrue\edef\FBB@wd{\the\textwidth}%
+    \let\@xdblfloat\@xfloat\relax
+    \FR@ifdoubleaswide
+     {\if@twocolumn\else\let\@dblfloat\@float\fi}\relax
+    \@dblfloat{#1}}%
+  \expandafter\let\csname end#1\endcsname\float@end
+  \expandafter\let\csname end#1*\endcsname\float@dblend
+ \@ifundefined{@rotfloat}{}{%
+  \@namedef{sideways#1}{\killfloatstyle\def\@captype{#1}\FR@redefs
+    \flrow@setlist{{#1}{rotfloat}{rot#1}}%
+    \columnwidth\textheight\edef\FBB@wd{\the\textheight}%
+    \FRifFBOX\@@setframe\relax\@@FStrue
+    \let\rotfloat@@makebox\float@makebox
+    \let\float@makebox\rotfloat@makebox
+    \@float{#1}}%
+  \@namedef{endsideways#1}{\FBbuildtrue\float@end}
+  \ifx\@rotdblfloat\undefined
+   \@namedef{sideways#1*}{%
+     \flrow@error{%
+      You need rotating version 2.10 or newer to do this}%
+     \@nameuse{sideways#1}}%
+  \else
+   \@namedef{sideways#1*}{\killfloatstyle\def\@captype{#1}\FR@redefs
+     \flrow@setlist{{#1}{rotfloat}{rot#1}{widerotfloat}{widerot#1}}%
+     \columnwidth\textheight\edef\FBB@wd{\the\textheight}%
+     \FRifFBOX\@@setframe\relax\@@FStrue
+     \let\@xdblfloat\@xfloat
+     \let\rotfloat@@makebox\float@makebox
+     \let\float@makebox\rotdblfloat@makebox
+     \@dblfloat{#1}}%
+  \fi
+  \@namedef{endsideways#1*}{\FBbuildtrue\float@dblend}}
+ \@ifundefined{wrapfloat}{}{%
+   \@ifundefined{flrow@WF@rapt}{\let\flrow@WF@rapt\WF@rapt
+   \def\WF@rapt[##1]##2{\FRifFBOX\@@setframe\relax\@@FStrue
+     \dimen@##2\relax
+     \ifdim\dimen@>\z@
+       \edef\FBB@wd{\the\dimen@}\FB@fs@wd\dimen@\FBo@wd
+     \fi
+     \flrow@WF@rapt[##1]{\dimen@}%
+       \the\FR@everyfloat\ignorespaces}%
+   }{}%
+   \@namedef{wrap#1}{\killfloatstyle\def\@captype{#1}%
+     \FR@redefs\FBc@wd\z@
+     \flrow@setlist{{#1}{wrapfloat}{wrap#1}}%
+     \def\WF@floatstyhook{\let\@currbox\WF@box
+       \ifFBbuild
+         \global\setbox\WF@box\flrow@FB{\wd\WF@box}%
+       \else
+         \global\let\flrow@typ@tmpset\undefined
+         \global\let\WF@box\@currbox
+       \fi}%
+     \@ifnextchar[\WF@wr{\WF@wr[]}}%]
+   \@namedef{endwrap#1}{\endwrapfloat
+     \@ifundefined{FloatHBarrier}{}\FloatHBarrier
+     }}
+ \@ifundefined{sf@@@subfloat}{}{\@ifundefined{c@sub#1}{\newsubfloat{#1}}{}}}
+\newcommand\RawFloats{\@ifnextchar[%]
+    \flrow@rawfloatschk\flrow@rawfloats}
+\newcommand\flrow@rawfloats{\killfloatstyle\@parboxrestore
+    \let\@makecaption\FR@makecaption
+    \expandafter\ifx\csname end\@captype\endcsname\float@endH
+        \global\FBbuildfalse
+    \else
+        \@namedef{end\@captype}{\end@float}%
+    \fi
+    \expandafter\ifx\csname end\@captype*\endcsname\float@endH
+        \global\FBbuildfalse
+    \else
+        \@namedef{end\@captype*}{\end@dblfloat}%
+    \fi
+  \@ifundefined{@rotfloat}{}{%
+    \@namedef{endsideways\@captype}{\end@rotfloat}%
+    \@namedef{endsideways\@captype*}{\end@rotdblfloat}%
+  }%
+  \@ifundefined{wrapfloat}{}{%
+    \@namedef{endwrap\@captype}{\endwrapfloat}%
+  }}
+\@ifdefinable\flrow@rawfloatschk{}
+\def\flrow@rawfloatschk[#1]{\@ifnextchar[%]
+    {\flrow@RawFloats[#1]}{\flrow@@RawFloats#1,;}}
+\@ifdefinable\flrow@RawFloats{}
+\newcommand\flrow@raw@set{\AtBeginDocument}
+\AtBeginDocument{\let\flrow@raw@set\@firstofone}
+\def\flrow@RawFloats[#1][#2]{\flrow@RawFloats@[#1]#2,;}
+\def\flrow@RawFloats@[#1]#2,{%
+  \caption@ifinlist{#2}{float}{\flrow@raw@set
+        {\@namedef{#1}{\@float{#1}}}%
+  }{\caption@ifinlist{#2}{widefloat}{\flrow@raw@set%
+        {\@namedef{#1*}{\let\@xdblfloat\@xfloat\@dblfloat{#1}}}%
+  }{\caption@ifinlist{#2}{rotfloat}{%
+    \@ifundefined{@rotfloat}{}{\flrow@raw@set
+        {\@namedef{sideways#1}{\@rotfloat{#1}}}}%
+  }{\caption@ifinlist{#2}{widerotfloat}{%
+    \@ifundefined{@rotfloat}{}{\flrow@raw@set
+        {\@namedef{sideways#1*}{\@rotdblfloat{#1}}}}%
+  }{\caption@ifinlist{#2}{wrapfloat}{%
+    \@ifundefined{wrapfloat}{}{\flrow@raw@set
+        {\@namedef{wrap#1}{\wrapfloat{#1}}}}}%
+  }{\caption@ifinlist{#2}{all,allfloats}{%
+    \flrow@@RawFloats{#1}%
+  }{\flrow@error{Undefined float subtype `#2'}%
+  }}}}}\@ifnextchar;\@gobble{\flrow@RawFloats@[#1]}}
+\@ifdefinable\flrow@@RawFloats{}
+\def\flrow@@RawFloats#1,{%
+ \flrow@raw@set{\@namedef{#1}{\@float{#1}}%
+    \@namedef{#1*}{\let\@xdblfloat\@xfloat\@dblfloat{#1}}%
+  \@ifundefined{@rotfloat}{}{%
+    \@namedef{sideways#1}{\@rotfloat{#1}}%
+    \@namedef{sideways#1*}{\@rotdblfloat{#1}}%
+  }%
+  \@ifundefined{wrapfloat}{}{%
+    \@namedef{wrap#1}{\wrapfloat{#1}}}%
+  }\@ifnextchar;\@gobble\flrow@@RawFloats
+}
+\newcommand\flrow@Raw@restyle[1]{%
+    \@namedef{#1}{\@float{#1}}%
+    \@namedef{#1*}{\@dblfloat{#1}}%
+    \@namedef{end#1}{\end@float}%
+    \@namedef{end#1*}{\end@dblfloat}%
+  \@ifundefined{@rotfloat}{}{%
+    \@namedef{sideways#1}{\@rotfloat{#1}}%
+    \@namedef{sideways#1*}{\@rotdblfloat{#1}}%
+    \@namedef{endsideways#1}{\end@rotfloat}%
+    \@namedef{endsideways#1*}{\end@rotdblfloat}%
+  }%
+  \@ifundefined{wrapfloat}{}{%
+    \@namedef{wrap#1}{\wrapfloat{#1}}%
+    \@namedef{endwrap#1}{\endwrapfloat}%
+  }%
+ }
+\newcommand\RawCaption[1]{{\let\@makecaption\FR@makecaption #1}}
+\@ifdefinable\float@exts{\newtoks\float@exts}
+\newcommand\newfloat{\@ifstar{\flrow@restylefloat{no}\newfloat@}%
+   {\flrow@restylefloat{yes}\newfloat@}}
+\newcommand\newfloat@[3]{\@ifnextchar[{\@@newfloat{#1}{#2}{#3}}%
+  {\@newfloat{#1}{#2}{#3}}}
+\newcommand\@newfloat[3]{%
+  \DeclareNewFloatType{#1}{placement=#2,fileext=#3}}
+\@ifdefinable\@@newfloat{}
+\def\@@newfloat#1#2#3[#4]{%
+  \DeclareNewFloatType{#1}{placement=#2,fileext=#3,within=#4}}
+\let\@float@Hx\@xfloat
+\def\@xfloat#1[{\@ifnextchar{H}{\@float@HH{#1}[}{\@float@Hx{#1}[}}
+\AtBeginDocument{%
+  \@ifundefined{latex@xfloat}{}{%
+    \let\floatrow@ORI@xfloat\@xfloat
+    \def\@xfloat#1[#2]{%
+      \floatrow@ORI@xfloat{#1}[#2]%
+      \floatfont}}}%
+\newsavebox\float@box
+\def\@float@HH#1[H]{%
+  \@ifundefined{FloatHBarrier}{}\FloatHBarrier
+  \expandafter\let\csname end#1\endcsname\float@endH
+  \FR@ifdoubleaswide
+   {\expandafter\let\csname end#1*\endcsname\float@endH}\relax
+  \let\@currbox\float@box
+  \flrow@setlist*{{floatH}{#1H}}%
+  \def\@captype{#1}%\setbox\@floatcapt=\vbox{}%
+  \setbox\@currbox\color@vbox\normalcolor
+    \vbox\bgroup
+      \hsize\columnwidth
+      \linewidth\columnwidth
+      \@parboxrestore\leftmargin\z@\rightmargin\z@
+      \@floatboxreset \@setnobreak
+  \ignorespaces}
+\newcommand\flrow@flboxreset{\FR@flboxreset
+  \@ifundefined{capstart}{}{\capstart}%
+  \FB@facing\@tempswafalse\FR@iffacing\@tempswatrue\relax
+  \if@tempswa\FB@readaux{\relax}\fi
+  \global\let\FBcheight\relax\global\let\FBoheight\relax
+  \global\let\FBfheight\relax
+  \FBifcapbeside\FC@fs@wd\FB@fs@wd
+  \the\FR@everyfloat}
+\@ifdefinable\FBcheight{\let\FBcheight\relax}
+\@ifdefinable\FBoheight{\let\FBoheight\relax}
+\@ifdefinable\FBfheight{\let\FBfheight\relax}
+\newcommand\FB@fs@wd{\@tempdima\FBB@wd
+  \flrow@setwd\textwidth\@tempdima
+  \adj@dim\@tempdima-\FB@wadj=\@tempdima
+  \settowidth\@tempdimb{{\FBleftmargin}{\FBrightmargin}}%
+  \advance\@tempdima-\@tempdimb
+  \global\FBc@wd\@tempdima\global\FB@wd\@tempdima
+  \adj@dim\@tempdima-\FBo@wadj={\global\FBo@wd}%
+  \hsize\FBo@wd\linewidth\hsize
+  \FBifcaptop
+    {\ifnum\FPOScnt=\z@\columnwidth\hsize\else\columnwidth\FBc@wd\fi}%
+    {\columnwidth\FBc@wd}%
+  }
+\newcommand\FC@fs@wd{\@tempdima\FBB@wd\flrow@FClist
+  \settowidth\@tempdimb{{\FCleftmargin}{\FCrightmargin}}%
+  \advance\@tempdima-\@tempdimb
+  \adj@dim\@tempdima-\FB@wadj=\@tempdima
+  \settowidth\@tempdimb{{\floatcapbesidesep}}%
+  \advance\@tempdima-\@tempdimb
+  \FC@ifc@wd\@tempswatrue\@tempswafalse
+  \if@tempswa
+     \ifx\FCwidth\relax
+        \flrow@error{You didn't define width of caption\MessageBreak
+          for plain floating environment.}%
+     \else
+        \global\FBc@wd=\FCwidth
+        \FC@ifo@fil{\advance\@tempdima-\FBc@wd}\relax
+     \fi
+  \else
+    \global\FBc@wd\@tempdima
+  \fi
+  \FC@ifo@fil\relax{\@tempdima.5\@tempdima
+    \flrow@setwd\FB@wd\@tempdima}%
+  \adj@dim\@tempdima-\FBo@wadj={\global\FBo@wd}%
+  \FC@ifc@wd\relax{\global\advance\FBc@wd-\FB@wd}%
+  \hsize\FBo@wd\linewidth\hsize\columnwidth\FBc@wd\linewidth\hsize
+  \FCset@vpos}
+\newcommand\float@makebox[1]{%
+  \FBifcapbeside{\flrow@FC{#1}}{\flrow@FB{#1}}}
+\newcommand\FBaskip{\z@}\newcommand\FBbskip{\z@}
+\newif\ifFBbuild\FBbuildtrue
+\newcommand\flrow@FB[1]{\vbox{\@tempdima=#1\vskip\FBaskip
+  \@parboxrestore\leftmargin\z@\rightmargin\z@
+  \hbox to\@tempdima{\def\FB@zskip{\vskip\z@}%
+  \FBleftmargin\flrow@FB@\FBrightmargin}%
+  \FR@iffacing{\FB@writeaux{\string\global\string\c@FBcnt\thepage}}\relax
+  \gdef\begin@FBBOX{\vbox\bgroup}\gdef\end@FBBOX{\egroup}%
+  \vskip\FBbskip\gdef\FBaskip{\z@}\gdef\FBbskip{\z@}}}
+\newcommand\flrow@FC[1]{\vbox{\@tempdima=#1\@parboxrestore
+  \leftmargin\z@\rightmargin\z@\flrow@FClist\vskip\FBaskip
+  \hbox to\@tempdima{\FCleftmargin\flrow@FC@\FCrightmargin}%
+  \FR@iffacing{\FB@writeaux{\string\global\string\c@FBcnt\thepage}}\relax
+  \nocapbeside\global\let\FCwidth\relax
+  \vskip\FBbskip\gdef\FBaskip{\z@}\gdef\FBbskip{\z@}}}
+\newcommand\FCc@box[1]{\def\@parboxto{}\FC@bbox#1\FC@ebox}
+\newcommand\FC@bbox{\vbox\@parboxto\bgroup}
+\newcommand\FC@ebox{\vskip\z@\egroup}
+\newcommand\FCo@box[1]{\def\@parboxto{}\ifx\FBoheight\relax\FC@bbox\else
+  \def\@parboxto{to\FBoheight}\FC@bbox\vsize\FBoheight\fi#1\FC@ebox}
+\newcommand\FBafil{\vfill}\newcommand\FBbfil{\vfill}
+\newcommand\FBw@box[1]{\hsize#1\columnwidth#1\linewidth#1%
+  \normalfont\normalcolor}
+\newcommand\FB@vbox[3]{\ifx#2\relax\vbox\bgroup\else
+  \vbox to#2\bgroup\vsize#2\fi\FBw@box#1#3\vskip\z@\egroup}
+\newcommand\FB@vtop[3]{\ifx#2\relax\vtop\bgroup\else
+  \vtop to#2\bgroup\vsize#2\fi\vskip\z@\FBw@box#1#3\egroup}
+\newcommand\flrow@FB@{\global\let\flrow@typ@tmpset\undefined
+ \FB@frame{\begin@FBBOX
+  \adj@dim\FBo@wd+\FBo@wadj=\hsize
+  \@tempdima\ht\@currbox\advance\@tempdima\dp\@currbox
+  \ifdim\@tempdima=\z@
+     \def\@@FBskip{}\let\FBo@frame\@gobble
+  \fi
+  \@parboxrestore\leftmargin\z@\rightmargin\z@
+  \@@FBabove
+  \FBifcaptop\@tempswatrue\@tempswafalse
+  \if@tempswa
+    \ifvoid\@floatcapt\else
+      \FB@vbox\FBc@wd\FBcheight{\FBifCAPTOP\relax\vfill
+        \unvbox\@floatcapt
+        \ifnum\FPOScnt=\@ne\vbox{\FB@foot}\fi\vfil}%
+      \@@FBskip\hrule\@height\z@\@depth\z@
+    \fi
+    \vtop{\vskip\z@\FBo@frame{\FB@vtop\FBo@wd\FBoheight
+      {\FBafil\unvbox\@currbox\FBbfil
+      \vskip\z@
+      \ifnum\FPOScnt=\z@
+        \FB@vtop\FBo@wd\FBfheight{\FB@foot\vfil}\fi}}\par
+      \vskip\z@
+      \ifnum\FPOScnt=\tw@\vskip\z@
+        \FB@vtop\FBc@wd\FBfheight{\FB@foot\vfil}\fi}%
+  \else\ifnum\FPOScnt=\z@\FPOScnt=\@ne\fi
+    \FBo@frame{\FB@vbox\FBo@wd\FBoheight{\FBafil
+       \unvbox\@currbox\FBbfil}}\par
+    \ifvoid\@floatcapt\else
+      \@@FBskip\hrule\@height\z@\@depth\z@
+      \FB@vtop\FBc@wd\FBcheight{\hsize\columnwidth\unvbox\@floatcapt
+        \ifnum\FPOScnt=\@ne\vtop{\FB@foot}%
+    \fi\par
+        \vfill\vskip\z@\vss
+        \ifnum\FPOScnt=2\FB@vtop\FBc@wd\FBfheight{\FB@foot\vfil}\fi
+        }\fi
+  \fi\@@FBbelow\FB@zskip\end@FBBOX
+  \global\setbox\@floatcapt\box\voidb@x}}
+\newcommand\flrow@FC@{\global\let\flrow@typ@tmpset\undefined
+ \FB@frame{\begin@FBBOX
+   \adj@dim\FBo@wd+\FBo@wadj=\hsize
+   \settowidth\@tempdimb{\floatcapbesidesep}\advance\hsize\@tempdimb
+   \advance\hsize\FBc@wd\@parboxrestore\leftmargin\z@\rightmargin\z@
+   \@@FBabove
+    \hbox{\floatfacing*%
+      {\ifvoid\@floatcapt\else
+         \FCc@box{\FBw@box\FBc@wd\unvbox\@floatcapt\FB@foot}%
+         \floatcapbesidesep\fi
+       \FBf@raise{\FBo@frame{\FCo@box{\FBw@box\FBc@wd\unvbox\@currbox}}}}%
+      {\FBf@raise{\FBo@frame{\FCo@box{\FBw@box\FBo@wd\unvbox\@currbox}}}%
+       \ifvoid\@floatcapt\else
+         \floatcapbesidesep\FCc@box{\FBw@box\FBc@wd
+           \unvbox\@floatcapt\FB@foot}\fi
+      }}\par\@@FBbelow\vskip\z@
+    \end@FBBOX
+    \global\setbox\@floatcapt\box\voidb@x}}
+\newcommand\FB@foot{\let\FR@ifFOOT\@firstoftwo\FB@putfoots\@@par\FB@putfnotes}
+\newcommand\FB@zskip{}
+\newcommand\float@end{\ifFBbuild\@endfloatbox
+    \global\setbox\@currbox\float@makebox\columnwidth
+    \let\@endfloatbox\relax\fi
+  \end@float}
+\newcommand\floatHpenalties{}
+\newcommand\float@endH{\@endfloatbox\par
+  \FR@iffloatHaslist
+   {\floatHpenalties\relax
+    \addpenalty\@beginparpenalty}\relax
+  \vskip\intextsep
+  \ifFBbuild\setbox\@currbox\float@makebox\columnwidth\fi
+  \box\@currbox\par
+  \FR@iffloatHaslist
+   {\addpenalty\@endparpenalty\@endpetrue}\relax
+  \vskip\intextsep\relax}
+\newcommand\float@dblend{\ifFBbuild\@endfloatbox
+    \global\setbox\@currbox\float@makebox\textwidth
+    \let\@endfloatbox\relax\fi
+  \end@dblfloat}
+\newsavebox\@floatcapt
+\newcommand*{\listof}[2]{%
+  \@ifundefined{ext@#1}{\flrow@error{Unknown float style `#1'}}{%
+    \expandafter\providecommand\csname l@#1\endcsname
+        {\@dottedtocline{1}{1.5em}{2.3em}}%
+    \float@listhead{#2}%
+    \begingroup\setlength{\parskip}{\z@}%
+      \@starttoc{\@nameuse{ext@#1}}%
+    \endgroup}}
+\providecommand*{\float@listhead}[1]{%
+  \@ifundefined{chapter}{\def\@tempa{\section*}}%
+    {\def\@tempa{\chapter*}}%
+  \@tempa{#1\@mkboth{\MakeUppercase{#1}}{\MakeUppercase{#1}}}}%
+\newcommand\float@addtolists[1]{%
+  \def\float@do##1{\addtocontents{##1}{#1}} \the\float@exts}
+\PackageInfo{floatrow}{Modified float package code loaded}
+\IfFileExists{rotating.sty}{\@tempswatrue}{\@tempswafalse}
+\if@tempswa
+  \let\rotfloat@HH\@float@HH
+  \def\@float@HH#1{%
+    \expandafter\let\csname endsideways#1\endcsname\float@endH
+    \let\end@float\relax
+    \rotfloat@HH{#1}}
+  \newcommand*\rotfloat@makebox[1]{%
+    \vbox{\def\@float##1[##2]{}\let\end@float\relax
+      \@rotfloat{}[]%
+      \ifFBbuild\rotfloat@@makebox{#1}\else\box\@currbox\fi
+      \end@rotfloat}}
+  \newcommand*\rotdblfloat@makebox[1]{%
+    \vbox{\def\@float##1[##2]{}\let\end@dblfloat\relax
+      \@rotdblfloat{}[]%
+      \ifFBbuild\rotfloat@@makebox{#1}\else\box\@currbox\fi
+      \end@rotdblfloat}}
+\PackageInfo{floatrow}{Modified rotfloat package code loaded}
+\fi
+\@ifdefinable\FR@everyfloat{\newtoks\FR@everyfloat}
+\FR@everyfloat={\let\@footnotetext\@mpfootnotetext
+  \def\@mpfn{mpfootnote}\def\thempfn{\thempfootnote}\c@mpfootnote\z@
+  \floatobjectset\floatfont}
+\@ifdefinable\FR@ifFOOT{\let\FR@ifFOOT\@secondoftwo}
+\newcommand\FB@putfnotes{%
+  \ifvoid\@mpfootins\else\FR@ifFOOT
+    {\vskip\floatfootskip\normalcolor\FBfootnoterule
+    \unvbox\@mpfootins\@@par}\relax
+  \fi}
+\@ifdefinable\flrow@foot{\newinsert\flrow@foot}
+\newcommand\FB@putfoots{%
+  \ifvoid\flrow@foot\else\FR@ifFOOT
+    {\vskip\floatfootskip\normalcolor
+    \unvbox\flrow@foot\@@par}\relax
+  \fi}
+\AtBeginDocument{\providecommand\mpfootnotemark{\@ifnextchar[%]
+   \@xmpfootnotemark{\stepcounter\@mpfn
+   \protected@xdef\@thefnmark{\thempfn}\@footnotemark}}%
+ \@ifundefined{@xmpfootnotemark}
+   {\def\@xmpfootnotemark[#1]{\begingroup\c@mpfootnote#1\relax
+    \unrestored@protected@xdef\@thefnmark{\thempfn}\endgroup
+    \@footnotemark}}{}}
+\captionsetup[floatfoot]{labelformat=empty,labelsep=none}
+\newcommand\floatfoot{\@ifstar
+    {\def\FR@tmp{\@parboxrestore\captionfootfont}\floatfoot@}%
+    {\def\FR@tmp{\captionfootfont}\floatfoot@}}
+\newcommand\floatfoot@[1]{%
+  \global\setbox\flrow@foot\vbox{%
+  \floatfoot@box{#1}}}%
+\newcommand\floatfoot@box[1]{%
+  \@ifundefined{@captype}{\def\@captype{floatfoot}}{}%
+    \if@@FS\hsize\columnwidth\linewidth\columnwidth\fi
+    \@parboxrestore\reset@font\color@begingroup
+  \caption@setoptions{\@captype}%
+  \caption@setoptions{floatfoot}%
+     \caption@@make{}{\FR@tmp#1\@finalstrut\strutbox}%
+  \color@endgroup}
+\newcommand\newfloatcommand[2]{%
+  \@ifundefined{#1}{}%
+    {\flrow@error{\string#1 already defined}}%
+  \@ifnextchar[{\FB@nc{#1}{#2}}{\FB@nc{#1}{#2}[]}}
+\newcommand\renewfloatcommand[2]{%
+  \@ifundefined{#1}{}%
+    {\PackageInfo{floatrow}{Redefining \string#1}}%
+  \@ifnextchar[{\FB@nc{#1}{#2}}{\FB@nc{#1}{#2}[]}}
+\@ifdefinable\FB@nc{}\@ifdefinable\FB@@nc{}
+\def\FB@nc#1#2[#3]{%
+  \@ifnextchar[{\FB@@nc{#1}{#2}[#3]}{\FB@@nc{#1}{#2}[#3][]}}
+\def\FB@@nc#1#2[#3][#4]{%
+  \@namedef{#1}{\begingroup
+  \def\FB@tmpset{#3}\def\@captype{#2}%
+  \@ifnextchar[{\@floatbox}{\@floatbox[#4]}}}
+\newfloatcommand{ffigbox}{figure}[\nocapbeside][]
+\newfloatcommand{ttabbox}{table}[\captop][\FBwidth]
+\newfloatcommand{fcapside}{figure}[\capbeside][]
+\@ifdefinable\FB@wd {\newdimen\FB@wd}
+\@ifdefinable\FBo@wd{\newdimen\FBo@wd}
+\@ifdefinable\FBc@wd{\newdimen\FBc@wd}
+\newlength\FBo@ht
+\newlength\FBc@ht
+\newlength\FBf@ht
+\newlength\FBo@max
+\newlength\FBc@max
+\newlength\FBf@max
+\newcommand\FR@loc@addcnt[2]{%
+  \@ifundefined{c@#1}{\@nocounterr{#1}}%
+    {\advance\csname c@#1\endcsname #2\relax}}
+\newcommand\FR@loc@refcnt[1]{%
+  \@ifundefined{c@#1}{\@nocounterr{#1}}%
+   {\advance\csname c@#1\endcsname1\relax}}
+\newcommand\FR@loc@{%
+  \let\FR@ifunloc\@gobble
+  \let\label\@gobble
+  \let\refstepcounter\FR@loc@refcnt
+  \let\stepcounter\FR@loc@refcnt
+  \let\refsteponlycounter\FR@loc@refcnt
+  \let\FR@ifcountH\@secondoftwo
+  \let\cl@@ckpt\empty\let\addtocounter\FR@loc@addcnt
+  \let\caption@kernel@addcontentsline\@gobbletwo
+  \let\caption@addcontentsline\@gobbletwo
+  \def\sf@updatecaptionlist##1##2##3##4{}}
+\def\FBtmp@cap#1[#2]#3{\sbox\@tempboxa{\captionlabel{#3}}%
+  \global\@tempdimb\wd\@tempboxa}
+\newcommand\captionlabel[1]{{\def\FR@tmp{\@captype}\ifnum\floatbox@depth>\@ne
+       \def\FR@tmp{sub\@captype}\caption@setsubtype*{\FR@tmp}\stepcounter{\FR@tmp}\fi
+   \caption@@@make{\caption@fnum\FR@tmp}{#1}}}
+\newcommand\subcaptionlabel[1]{{\floatbox@depth\tw@\captionlabel{#1}}}
+\newcommand\FBget@box[3]{%
+  \FBiffloatrow\relax
+    {\ifx\FBB@wd\relax
+      \ifdim\hsize=\z@
+        \@ifundefined{wf@@caption}{}{\let\caption\wf@@caption}%
+        \hsize.5\columnwidth\advance\hsize-.5\columnsep
+      \else
+        \edef\FBB@wd{\the\hsize}%
+      \fi
+    \else
+      \hsize\FBB@wd
+    \fi}%
+  \adj@dim\hsize-\FB@wadj=\@tempdima
+  \FBifcapbeside
+    {\FCget@@wd{#1}{#3}}%
+    {\nofilFCOhsize
+    \FBiffloatrow\relax
+      {\settowidth\@tempdimb{{\FBleftmargin}{\FBrightmargin}}%
+      \advance\@tempdima-\@tempdimb}}%
+  \FC@ifo@fil{\@tempdima\FB@wd}{\FB@wd\@tempdima}%
+  \adj@dim\@tempdima-\FBo@wadj=\FBo@wd
+  \FBiffloatrow\relax{\hsize\FBo@wd}%
+  \FBifcapbeside{\hsize\FB@wd}\relax
+  \linewidth\hsize
+  \def\reserved@a{#1}\ifx\reserved@a\empty
+    \else\FBget@@wd{#1}{#3}\fi
+  \hsize\FBo@wd\linewidth\hsize
+  \FBifcapbeside
+    {\FC@ifc@wd\relax{\advance\FBc@wd-\FB@wd}}%
+    {\FBc@wd\FB@wd}%
+  \setbox\z@\vbox{\let\FR@ifROWFILL\@secondoftwo\FR@loc@\hsize\FBo@wd\linewidth\hsize
+    \FBifcaptop
+      {\ifnum\FPOScnt=\z@\columnwidth\hsize\else\columnwidth\FBc@wd\fi}%
+      {\columnwidth\FBc@wd}%
+    #3}%
+  \FBc@ht\ht\@floatcapt\advance\FBc@ht\dp\@floatcapt
+  \FBo@ht\ht\z@\advance\FBo@ht\dp\z@\let\FBheight\FBo@ht
+  \setbox\tw@\vbox{\null\par\FB@foot\par}%
+  \FBf@ht\ht\tw@\advance\FBf@ht\dp\tw@
+  \FBiffloatrow
+    {\ifdim\FBf@ht>\FBf@max\global\FBf@max\FBf@ht\fi
+    \ifCADJ
+      \FBifcaptop
+        {\ifnum\FPOScnt=\@ne\global\advance\FBc@ht\FBf@ht\fi}%
+        {\ifnum\FPOScnt=\tw@
+          \ifdim\FBf@ht>\FBf@max
+            \global\advance\FBc@ht\FBf@ht
+          \else
+            \global\advance\FBc@ht\FBf@max
+          \fi
+        \else
+          \global\advance\FBc@ht\FBf@ht
+        \fi}%
+      \ifdim\FBc@ht>\FBc@max\global\FBc@max\FBc@ht\fi
+      \gdef\FBcheight{\FBc@ht}\gdef\FBfheight{\FBf@ht}%
+    \fi}\relax
+  \def\reserved@a{#2}\ifx\reserved@a\empty
+    \FBiffloatrow{\ifOADJ
+      \ifdim\FBo@ht>\FBo@max\global\FBo@max\FBo@ht\fi
+      \FBifcaptop
+        {\ifnum\FPOScnt=\z@
+          \ifdim\FBf@ht>\FBf@max\global\FBf@max\FBf@ht\fi
+        \fi}\relax
+      \gdef\FBoheight{\FBo@ht}\gdef\FBfheight{\FBf@ht}%
+    \fi}\relax
+  \else
+     \FBget@@ht{#2}{#3}%
+  \fi}
+\newcommand\FCget@@wd[2]{\flrow@FClist
+  \FBiffloatrow\relax
+    {\settowidth\@tempdimb{{\FCleftmargin}{\FCrightmargin}}%
+    \advance\@tempdima-\@tempdimb\advance\hsize-\@tempdimb}%
+  \settowidth\@tempdimb{\floatcapbesidesep}\advance\@tempdima-\@tempdimb
+  \FC@ifo@fil{\FB@wd\@tempdima}\relax
+  \FC@ifc@wd\@tempswatrue\@tempswafalse
+  \if@tempswa
+    \ifx\FCwidth\relax
+      \setbox\@ne\vbox{\FR@loc@
+        \let\caption\flrow@caption
+        \let\@caption\FBtmp@cap
+         #2}%
+      \FBc@wd=\@tempdimb
+    \else
+      \FBc@wd=\FCwidth
+    \fi\FC@ifo@fil{\advance\FB@wd-\FBc@wd}\relax
+  \else
+    \FBc@wd\@tempdima
+  \fi
+  \@tempdima.5\@tempdima}
+\newcommand\flrow@gobble@[2][]{\unskip\ignorespaces}
+\newcommand\flrow@gobble{%
+    \let\caption\flrow@gobble@
+    \let\floatfoot\flrow@gobble@
+    \let\footnote\flrow@gobble@
+    \let\footnotetext\flrow@gobble@
+    }
+\newcommand\FBget@@wd[2]{\@tempswafalse
+  \begingroup
+    \@tempdima-3000pt\let\FBwidth\@tempdima
+    \setlength\dimen@{#1}\ifdim\dimen@<\z@\global\@tempswatrue\fi
+  \endgroup
+  \if@tempswa
+    \setbox\z@\hbox{\let\FR@ifROWFILL\@secondoftwo\FR@loc@#2}%
+    \FBo@wd\wd\z@\let\FBwidth\FBo@wd
+    \setlength\FBo@wd{#1}%
+    \advance\FBo@wd\leftskip\advance\FBo@wd\rightskip
+    \adj@dim\FBo@wd+\FBo@wadj=\FB@wd
+    \setbox\flrow@foot\box\voidb@x
+    \setbox\@mpfootins\box\voidb@x
+  \else
+    \setlength\FB@wd{#1}%
+    \adj@dim\FB@wd-\FB@wadj=\FB@wd
+    \adj@dim\FB@wd-\FBo@wadj=\FBo@wd
+    \let\FBwidth\FBo@wd
+  \fi}
+\newcommand\FBget@@ht[2]{\@tempswafalse
+  \begingroup
+    \@tempdimb-3000pt\let\FBheight\@tempdimb
+    \setlength\dimen@{#1}\ifdim\dimen@<\z@
+      \global\@tempswatrue\fi
+  \endgroup
+  \if@tempswa
+    \setbox\z@\hbox{\let\FR@ifROWFILL\@secondoftwo\FR@loc@#2}%
+    \FBo@ht\ht\z@\advance\FBo@ht\dp\z@
+    \let\FBheight\FBo@ht\setlength\FBo@ht{#1}%
+    \adj@dim\FBo@ht+\FBo@hadj=\FBo@ht
+    \FBifcaptop{\ifnum\FPOScnt=\z@\advance\FBo@ht\FBf@ht\fi}\relax
+  \else
+    \setlength\FBo@ht{#1}%
+    \adj@dim\FBo@ht-\FBo@hadj=\FBo@ht
+    \adj@dim\FBo@ht-\FB@hadj=\FBo@ht
+    \setbox\z@\vbox{\offinterlineskip\vbox{\@@FBabove}%
+      \FBifcapbeside\relax{\@@FBskip\hrule\@height\z@\@depth\z@}%
+      \vtop{\@@FBbelow}}%
+    \global\advance\FBo@ht-\ht\z@\global\advance\FBo@ht-\dp\z@
+    \FBifcapbeside\relax\FBget@@@ht
+  \fi
+  \FBiffloatrow{\ifOADJ
+    \ifdim\FBo@ht>\FBo@max\global\FBo@max\FBo@ht\fi
+  \fi}\relax
+  \def\FBoheight{\FBo@ht}}
+\newcommand\FBget@@@ht{%
+    \ifdim\FBc@ht>\FBc@max
+      \global\advance\FBo@ht-\FBc@ht
+    \else
+      \global\advance\FBo@ht-\FBc@max
+    \fi
+    \FBifcaptop{\ifnum\FPOScnt=\@ne\else
+      \ifdim\FBf@ht>\FBf@max
+        \global\advance\FBo@ht-\FBf@ht
+      \else
+        \global\advance\FBo@ht-\FBf@max
+      \fi
+    \fi}\relax
+  }
+\newcommand\FB@writeaux[1]{%
+  \begingroup
+    \let\thepage\relax\let\protect\@unexpandable@protect
+    \edef\reserved@a{\write\@auxout{\string\gdef
+    \expandafter\string\csname @@FBset@\romannumeral
+    \the\c@FBl@b\endcsname{#1}}}\reserved@a
+  \endgroup
+  \addtocounter{FBl@b}{1}}
+\newcommand\FB@readaux[1]{%
+  \@ifundefined{@@FBset@\romannumeral\the\c@FBl@b}%
+    {#1}{\@nameuse{@@FBset@\romannumeral\the\c@FBl@b}}}
+\newcounter{FBl@b}
+\@ifdefinable\FR@ifFCBOX{\let\FR@ifFCBOX\@secondoftwo}
+\newcommand\FBs@raise{\raisebox{-\totalheight}}
+\newcommand\FBf@raise{}
+\newcommand\FCset@vpos{\@FC@vpos
+  \ifcase\count@
+    \gdef\FC@bbox{$\vcenter\@parboxto\bgroup\vskip\z@}%
+    \gdef\FC@ebox{\vskip\z@\egroup$}%
+    \gdef\FBf@raise{}%
+    \gdef\FBs@raise{\raisebox{-.5\totalheight}}%
+  \or\gdef\FC@bbox{\vtop\@parboxto\bgroup\vskip\z@}%
+    \gdef\FC@ebox{\vskip\z@\egroup}%
+    \FR@ifFCBOX{\gdef\FBf@raise{\raisebox{-\height}}}%
+     {\gdef\FBf@raise{}}%
+    \gdef\FBs@raise{\raisebox{-\totalheight}}%
+  \or\gdef\FC@bbox{\vbox\@parboxto\bgroup}\gdef\FC@ebox{\vskip\z@\egroup}%
+    \FR@ifFCBOX{\gdef\FBf@raise{\raisebox{\depth}}}%
+     {\gdef\FBf@raise{}}%
+    \gdef\FBs@raise{}\fi}
+\@ifdefinable\adj@dim{}
+\def\adj@dim#1#2#3=#4{\dimen@\z@#3\ifdim\dimen@=\z@#4#1\else
+  \adj@@dim#1#2#3{#4}\fi}
+\newcommand\adj@@dim[4]{\@tempdima#1\advance\@tempdima#2\dimen@
+  #4=\@tempdima}
+\newcommand\floatbox[2][]{\begingroup
+  \def\FB@tmpset{#1}\def\@captype{#2}%
+  \@ifnextchar[{\@floatbox}{\@floatbox[]}}
+\@ifdefinable\@floatbox{}\@ifdefinable\@@floatbox{}
+\def\@floatbox[#1]{%
+  \@ifnextchar[{\@@floatbox[#1]}{\@@floatbox[#1][]}}
+\@ifdefinable\floatbox@depth{\newcount\floatbox@depth}
+\def\@@floatbox[#1][#2]{%
+  \@ifnextchar[{\@@@floatbox[#1][#2]}{\@@@floatbox[#1][#2][]}}%]
+\@ifdefinable\@@@floatbox{}
+\long\def\@@@floatbox[#1][#2][#3]#4#5{\advance\floatbox@depth\@ne
+  \@FB@vpos{#3}%
+  \if@@FS\else\FR@redefs
+    \ifcase\floatbox@depth\or
+      \flrow@setlist{{\@captype}}\or
+      \flrow@settype{subfloat}\flrow@settype{subtype}\flrow@settype{sub\@captype}%
+    \fi
+    \FRifFBOX\@@setframe\relax\@@FStrue
+  \fi
+  \FB@tmpset
+  \FBifcapbeside\flrow@FClist\relax
+  \@parboxrestore\leftmargin\z@\rightmargin\z@
+  \floatobjectset\floatfont
+  \FBget@box{#1}{#2}{#4#5}%
+  \FBifcapbeside\FCset@vpos\relax
+  \FBiffloatrow{\FR@floatbox{\@ifundefined{capstart}{}{\capstart}#4#5}}%
+   {\adj@dim\FB@wd+\FB@wadj=\hsize\linewidth\hsize
+    \ifx\FBB@wd\relax\edef\FBB@wd{\the\hsize}\fi
+    \FBsetbox@obj{\@ifundefined{capstart}{}{\capstart}\let\FBB@wd\relax
+    #4#5}\FBbuildtrue
+    \FBifcapbeside{\flrow@FC\FBB@wd}{\flrow@FB\FBB@wd}%
+    \global\FBbuildfalse
+    \FR@iffacing{\FB@writeaux{\string\global\string\c@FBcnt\thepage}}\relax
+   }\advance\floatbox@depth\m@ne
+  \endgroup\ignorespaces}
+\newcommand\FR@floatbox[1]{\@tempswafalse
+    \ifOADJ\@tempswatrue\fi\ifCADJ\@tempswatrue\fi
+    \if@tempswa\@ifundefined{FB@@boxmax}{}{\FB@@boxmax}\fi
+    \FBsetbox@obj{#1}\begin@FBBOX
+      \FBifcapbeside\flrow@FC@\flrow@FB@
+    \end@FBBOX
+    \addtocounter{FRobj}\m@ne
+    \@tempswafalse\FR@iffacing\@tempswatrue\relax
+    \ifCADJ\@tempswatrue\fi\ifOADJ\@tempswatrue\fi
+    \advance\Xhsize-\FB@wd
+    \FBifcapbeside
+      {\advance\Xhsize-\FBc@wd
+       \FR@ifcountH{\global\advance\Zhsize-\FBc@wd}\relax
+       \settowidth\@tempdimb{\floatcapbesidesep}%
+       \advance\Xhsize-\@tempdimb
+       \FR@ifcountH{\global\advance\Zhsize-\@tempdimb}\relax}\relax
+    \ifnum\c@FRobj=\z@
+      \if@tempswa
+        \FB@writeaux{\string\c@FBcnt\thepage
+          \string\def\string\FB@@boxmax{%
+          \ifOADJ\string\FBo@ht\the\FBo@max
+          \string\FBf@ht\the\FBf@max\fi
+          \ifCADJ\string\FBc@ht\the\FBc@max\fi}}\fi
+      \global\FBbuildfalse
+    \else
+      \floatrowsep
+      \adj@dim\Xhsize-\FB@wadj={\global\Xhsize}%
+      \adj@dim\Zhsize-\FB@wadj={\global\Zhsize}%
+    \fi}
+\newcommand\FBsetbox@obj[1]{%
+  \setbox\float@box\color@vbox\normalcolor
+  \FBifcaptop
+     {\FB@vtop\FBo@wd\FBoheight\bgroup\FBafil\floatobjectset\floatfont
+      \ifnum\FPOScnt=\z@\columnwidth\FBo@wd\else\columnwidth\FBc@wd\fi}%
+     {\FB@vbox\FBo@wd\FBoheight\bgroup\FBafil\floatobjectset\floatfont
+      \columnwidth\FBc@wd}%
+  #1\FBbfil\egroup\color@endbox
+  \let\@currbox\float@box}
+\@ifdefinable\FBiffloatrow{\let\FBiffloatrow\@secondoftwo}
+\newcounter{FRobj}
+\newcounter{FRsobj}
+\newlength\Xhsize
+\newlength\sXhsize
+\newlength\Zhsize
+\newlength\sZhsize
+\newcommand\flrow@to{to\hsize}
+\newcommand\flrow@boxset[1]{#1}
+\newcommand\flrow@setrowhbox{%
+\FR@ifROWFILL{\def\flrow@left{\hskip\leftskip}\def\flrow@right{\hskip\rightskip}%
+  }{\let\flrow@to\empty\def\flrow@left{}\def\flrow@right{}}%
+}
+\newcommand\flrow@left{}\newcommand\flrow@right{}
+\newcommand\flrow@hbox@bgroup{\hbox\flrow@to
+    \bgroup\flrow@left}
+\newcommand\flrow@hbox@egroup{\flrow@right
+    \egroup}
+\newbox\flrow@rowbox
+\newcommand\floatrow[1][2]{\c@FRobj=#1\relax
+  \ifcase\floatbox@depth
+    \flrow@setlist*{{floatrow}{\@captype row}}%
+  \or
+    \flrow@settype{subfloat}\flrow@settype{subtype}\flrow@settype{sub\@captype}%
+    \flrow@settype{subfloatrow}\flrow@settype{sub\@captype row}%
+    \ifx\flrow@to\empty\def\flrow@boxset##1{}\fi
+  \fi%
+  \FB@facing\@tempswafalse\FR@iffacing\@tempswatrue\relax
+  \ifCADJ\@tempswatrue\fi\ifOADJ\@tempswatrue\fi
+  \if@tempswa\FB@readaux{\relax}\fi
+  \flrow@boxset{\ifx\FBB@wd\relax\edef\FBB@wd{\the\hsize}\else\hsize\FBB@wd\fi}%
+  \ifnum\floatbox@depth=\z@\vspace\FBaskip\else\leavevmode\fi
+  \hbox\flrow@to\bgroup%outer h box
+  \FRleftmargin
+  \flrow@boxset{\hsize\FBB@wd
+     \settowidth\@tempdima{{\FRleftmargin}{\FRrightmargin}}\advance\hsize-\@tempdima}%
+  \bgroup\ifx\FR@frame\empty\else\def\FB@frame{}\def\FB@wadj{}\def\FB@hadj{}\fi%frame set
+  \flrow@boxset{\adj@dim\hsize-\FR@wadj=\hsize}%
+  \setbox\flrow@rowbox\vbox\bgroup%v box
+        \@@FRabove
+    \flrow@setrowhbox
+    \flrow@hbox@bgroup\let\FBiffloatrow\@firstoftwo
+      \Xhsize\hsize\count@#1\advance\count@\m@ne
+      \settowidth\@tempdima{\floatrowsep}\advance\Xhsize-\count@\@tempdima
+      \@tempdimb\Xhsize
+      \FR@iftwolevel
+        {\ifnum\floatbox@depth=\z@\Zhsize\Xhsize\else
+            \ifdim\Zhsize=\z@\Zhsize\Xhsize\sZhsize\Xhsize\fi
+            \FR@ifcountH{\global\advance\Zhsize-\count@\@tempdima}\relax
+         \fi}{\@tempdimb\Xhsize\Zhsize\Xhsize}%
+      \divide\@tempdimb#1\relax\FB@wd\@tempdimb
+      \hsize\@tempdimb\ignorespaces}
+\def\endfloatrow{\ifdim\lastskip>\z@\unskip\fi
+      \flrow@hbox@egroup%h box
+    \@@FRbelow
+    \egroup%v box
+    \FR@frame{\box\flrow@rowbox}%
+    \egroup%frame set
+    \FRrightmargin\egroup%outer h box
+    \ifnum\floatbox@depth=\z@\vspace\FBbskip\fi
+  \gdef\FBaskip{\z@}\gdef\FBbskip{\z@}%
+  \global\FBf@max\z@\global\FBo@max\z@\global\FBc@max\z@
+  \gdef\begin@FBBOX{\vbox\bgroup}\gdef\end@FBBOX{\egroup}}
+\newenvironment{subfloatrow}{\capsubrowsettings
+    \captionsetup{subtype}\@nameuse{subfloatrow*}}{\@nameuse{endsubfloatrow*}}
+\newcommand\capsubrowsettings{\caption@setoptions{subfloatrow}\caption@setoptions{sub\@captype row}}
+\newenvironment{subfloatrow*}[1][2]{\let\flrow@to\empty
+    \let\Xhsize\sXhsize%\let\Zhsize\sZhsize
+    \FR@ifunloc{\let\FR@ifcountH\@firstoftwo}\let\c@FRobj\c@FRsobj
+    \def\FRleftmargin{}\def\FRrightmargin{}\let\floatrowsep\subfloatrowsep
+    \floatrow[#1]\killfloatstyle}{\ifdim\lastskip>\z@\unskip\fi
+     \@ifundefined{adjustsubfloats}\relax\adjustsubfloats\endfloatrow}
+\newcommand\subfloatrowsep{\hskip\columnsep}
+\@ifdefinable\FR@ifcountH{\let\FR@ifcountH\@firstoftwo}
+\@ifdefinable\FR@ifunloc{\let\FR@ifunloc\@firstofone}
+\@ifdefinable\FR@iftwolevel{\let\FR@iftwolevel\@secondoftwo}
+\newcommand\CommonHeightRow{\@ifstar
+    {\let\FR@iftwolevel\@firstoftwo\CommonHeightRow@
+   }{\let\FR@iftwolevel\@secondoftwo\CommonHeightRow@}}
+\newcommand\DefaultCommonHeight{25pt}
+\newcommand\CommonHeight{\DefaultCommonHeight}
+\newcommand\CommonHeightRow@[2][\DefaultCommonHeight]{\def\CommonHeight{#1}\setbox\z@
+    \hbox{\FR@loc@\let\FR@ifunloc\@firstofone#2}%
+    \ifcase\floatbox@depth\def\@tempa{\Xhsize}\def\@tempb{\Zhsize}\or
+        \def\@tempa{\sXhsize}\def\@tempb{\Zhsize}\fi
+    \FR@calc@CommonHeight#2}
+\@ifdefinable\FR@Zunitlength{\newdimen\FR@Zunitlength}
+\newcommand\FR@calc@CommonHeight{%
+    \@tempdima\@tempb\advance\@tempdima-\@tempa
+    \count@\@tempdima\relax\divide\count@16384\relax
+    \divide\@tempb\count@\relax\FR@Zunitlength\@tempb\relax
+    \@tempdima\CommonHeight\relax
+    \count@\@tempdima\relax\divide\count@16384\relax
+    \@tempdima\count@\FR@Zunitlength\relax
+    \edef\CommonHeight{\the\@tempdima}}
+\newcommand\begin@FBBOX{\vbox\bgroup}
+\def\end@FBBOX{\egroup}
+\newcommand\CenterFloatBoxes{\CADJfalse\OADJfalse
+  \buildFBBOX{\hbox\bgroup$\vcenter\bgroup\vskip\z@}%
+             {\vskip\z@\egroup$\egroup}}
+\newcommand\TopFloatBoxes{\CADJfalse\OADJfalse
+  \buildFBBOX{\vtop\bgroup\vskip\z@}{\egroup}}
+\newcommand\BottomFloatBoxes{\CADJfalse\OADJfalse
+  \buildFBBOX{\vbox\bgroup}{\vskip\z@\egroup}}
+\newcommand\PlainFloatBoxes{%
+  \gdef\begin@FBBOX{\vbox\bgroup}\gdef\end@FBBOX{\egroup}}
+\newcommand\buildFBBOX[2]{\gdef\begin@FBBOX{#1}\gdef\end@FBBOX{#2}}
+\def\newdimentocommand  #1#2#3{%
+    #1\@tempdima{#3}\@ifdefinable#2{\xdef#2{\the\@tempdima}}}
+\def\renewdimentocommand#1#2#3{%
+    #1\@tempdima{#3}\xdef#2{\the\@tempdima}}
+\def\newskiptocommand   #1#2#3{%
+    #1\@tempskipa{#3}\@ifdefinable#2{\xdef#2{\the\@tempskipa}}}
+\def\renewskiptocommand #1#2#3{%
+    #1\@tempskipa{#3}\xdef#2{\the\@tempskipa}}
+\def\newlengthtocommand{\newskiptocommand}
+\def\renewlengthtocommand{\renewskiptocommand}
+\newcommand*\flrow@setbool[1]{%
+  \expandafter\caption@set@bool\csname FR@if#1\endcsname}
+\def\floatsetup{\@ifnextchar[\flrow@setuptype\flrow@setup}
+\def\flrow@setuptype[#1]#2{%
+  \@ifundefined{flrow@typ@#1}{\@namedef{flrow@typ@#1}{#2}}%
+    {\expandafter\l@addto@macro\csname flrow@typ@#1\endcsname{,#2}}}
+\newcommand\thisfloatsetup{\floatsetup[tmpset]}
+\def\flrow@setup{\caption@setkeys[floatrow]{floatrow}}
+\def\flrow@esetup#1{%
+  \edef\FR@tmp{\noexpand\flrow@setup{#1}}\FR@tmp}
+\def\flrow@settype#1{\@ifundefined{flrow@typ@#1}{}%
+  {\flrow@esetup{\csname flrow@typ@#1\endcsname}}}%
+\newcommand\flrow@setlist{\@ifstar\flrow@setlist@@\flrow@setlist@}
+\newcommand\flrow@setlist@[1]{\@flrow@setlist#1{tmpset};%
+  \FR@ifCST{\flrow@capsetup}\relax\@cap@setlist#1;%
+  \caption@setposition{\FBifcaptop tb}}
+\newcommand\flrow@setlist@@[1]{\@flrow@setlist#1;%
+  \FR@ifCST{\flrow@capsetup}\relax\@cap@setlist#1;%
+  \caption@setposition{\FBifcaptop tb}}
+\newcommand\@flrow@setlist[1]{\flrow@settype{#1}\@ifnextchar;\@gobble
+  \@flrow@setlist}
+\@ifundefined{caption@setoptions}{\let\caption@setoptions\caption@settype}{}
+\newcommand\@cap@setlist[1]{\caption@setoptions{#1}%
+   \@ifnextchar;{\let\caption@setfloattype\@gobble\@gobble}\@cap@setlist}
+\newcommand\flrow@FClist{\flrow@setlist
+  {{floatbeside}{capbesidefloat}{\@captype beside}{capbeside\@captype}}}
+\newcommand*\clearfloatsetup[1]{\@nameundef{flrow@typ@#1}}
+\newcommand\DeclareFROpt{%
+  \@ifstar{\flrow@declopt\AtEndOfPackage}
+          {\flrow@declopt\@gobble}}
+\newcommand*\flrow@declopt[2]{%
+  #1{\undefine@key{floatrow}{#2}}\define@key{floatrow}{#2}}
+\@onlypreamble\DeclareFROpt
+\@onlypreamble\flrow@declopt
+\@ifdefinable\FR@ifrawfloats{\let\FR@ifrawfloats\@secondoftwo}
+\DeclareFROpt*{rawfloats}[0]{\flrow@setbool{rawfloats}{#1}}
+\@ifdefinable\FR@ifdoubleaswide{\let\FR@ifdoubleaswide\@secondoftwo}
+\DeclareFROpt{doublefloataswide}[0]{\flrow@setbool{doubleaswide}{#1}}
+\@ifdefinable\FR@iffloatHaslist{\let\FR@iffloatHaslist\@secondoftwo}
+\DeclareFROpt{floatHaslist}[0]{\flrow@setbool{floatHaslist}{#1}}
+\newcommand*\DeclareFloatStyle[2]{%
+  \global\@namedef{flrow@sty@#1}{#2}}
+\@onlypreamble\DeclareFloatStyle
+\newcommand*\flrow@setstyle[1]{%
+  \@ifundefined{flrow@sty@#1}%
+    {\flrow@error{Undefined float style `#1'}}%
+    {\FBstyle@reset
+     \def\flrow@capsetup{%
+        \@ifundefined{caption@sty@#1}{}{\caption@setstyle*{#1}}%
+        \caption@setoptions {#1}}%
+     \flrow@esetup{\csname flrow@sty@#1\endcsname}}}
+\DeclareFloatStyle{plain}{}
+\DeclareFloatStyle{plaintop}{capposition=top}
+\DeclareFloatStyle{boxed}{captionskip=2pt,
+  framestyle=fbox,heightadjust=object,framearound=object}
+\DeclareFloatStyle{ruled}{precode=thickrule,midcode=rule,postcode=lowrule,
+  capposition=top,heightadjust=all}
+\DeclareFloatStyle{Ruled}{style=ruled,capposition=TOP}
+\DeclareFloatStyle{Plaintop}{capposition=TOP}
+\DeclareFloatStyle{Boxed}{style=boxed,framefit=yes}
+\DeclareFloatStyle{BOXED}{framestyle=fbox,
+  framefit=yes,heightadjust=all,framearound=all}
+\DeclareFloatStyle{default}{%
+     style=plain,captionskip=10pt,
+     margins=centering,objectset=centering,
+     capbesideposition=left,facing=no,
+     floatrowsep=columnsep,capbesidesep=columnsep,
+     font=default,footfont=footnotesize}
+\DeclareFROpt{style}{\flrow@setstyle{#1}}
+\@ifdefinable\FR@ifCST{\let\FR@ifCST\@firstoftwo}
+\DeclareFROpt{relatedcapstyle}[0]{\flrow@setbool{CST}{#1}}
+\DeclareFROpt{font}{\flrow@setfont{font}{#1}}
+\DeclareFROpt{footfont}{\captionsetup[floatfoot]{font={#1}}}
+\DeclareCaptionOption{footfont}{\caption@setfont{footfont}{#1}}
+\@ifdefinable\floatfont{\let\floatfont\empty}
+\newcommand*\captionfootfont{\normalfont\footnotesize}
+\let\DeclareFloatFont\DeclareCaptionFont
+\@onlypreamble\DeclareFloatFont
+\newcommand*\flrow@setfont[2]{%
+   \caption@setfont{@tempa}{#2}%
+   \expandafter\let\csname float#1\endcsname\caption@tempa}
+\DeclareFROpt{capposition}{\flrow@cappos{#1}}
+\DeclareFROpt{position}{\flrow@cappos{#1}}
+\newcommand*\flrow@cappos[1]{%
+  \caption@ifinlist{#1}{t,top,above}{\captop\nocapbeside
+  }{\caption@ifinlist{#1}{T,TOP,ABOVE}{\CAPTOP\nocapbeside
+  }{\caption@ifinlist{#1}{b,bottom,below,default}{\capbot\nocapbeside
+  }{\caption@ifinlist{#1}{beside,side}{\caption@setposition{a}\capbeside
+  }{\flrow@error{Undefined caption position `#1'}%
+  }}}}}
+\@ifdefinable\FBifcaptop{\let\FBifcaptop\@secondoftwo}
+\newcommand\captop{\let\FBifcaptop\@firstoftwo}
+\newcommand\capbot{\let\FBifcaptop\@secondoftwo}
+\@ifdefinable\FBifCAPTOP{\let\FBifCAPTOP\@secondoftwo}
+\newcommand\CAPTOP{\captop\let\FBifCAPTOP\@firstoftwo\CADJtrue}
+\@ifdefinable\FBifcapbeside{}\let\FBifcapbeside\@secondoftwo
+\newcommand\capbeside{\let\FBifcapbeside\@firstoftwo}
+\newcommand\nocapbeside{\let\FBifcapbeside\@secondoftwo}
+\DeclareFROpt{capbesideframe}[0]{\flrow@setbool{FCBOX}{#1}}
+\DeclareFROpt{capbesidewidth}[1]{\flrow@FCc@wd{#1}}
+\@ifdefinable\FC@ifc@wd{\let\FC@ifc@wd\@secondoftwo}
+\newcommand\useFCwidth{\let\FC@ifc@wd\@firstoftwo\let\FCwidth\relax}
+\@ifdefinable\FCwidth{\let\FCwidth\relax}
+\newcommand\flrow@FCc@wd[1]{%
+  \caption@ifinlist{#1}{none,sidefil}{\let\FC@ifc@wd\@secondoftwo
+  }{\useFCwidth\def\FCwidth{#1}}}
+\DeclareFROpt{capbesideposition}{\flrow@scpos{#1}}
+\newcommand\DeclareSCPos[2]{%
+  \define@key{flrow@scpos}{#1}[]{\g@addto@macro\FR@tmp{#2}}}
+\newcommand*\flrow@scpos[1]{%
+  \let\FR@tmp\@empty
+  \begingroup\caption@setkeys[floatrow]{flrow@scpos}{#1}\endgroup
+  \FR@tmp}
+\@onlypreamble\DeclareSCPos
+\DeclareSCPos{left}{\def\@FC@hpos{\let\FR@iffacing\@secondoftwo\count@\@ne}}
+\DeclareSCPos{right}{\def\@FC@hpos{\let\FR@iffacing\@secondoftwo\count@\z@}}
+\DeclareSCPos{inside}{\def\@FC@hpos{\let\FR@iffacing\@firstoftwo
+    \count@\c@FBcnt\ifnum\count@=\z@\count@\@ne\fi
+  }}
+\DeclareSCPos{outside}{\def\@FC@hpos{\let\FR@iffacing\@firstoftwo
+    \count@\c@FBcnt\ifnum\count@=\z@\else\advance\count@\@ne\fi
+  }}
+\DeclareSCPos{center}{\def\@FC@vpos{\count@\z@}}
+\DeclareSCPos{top}{\def\@FC@vpos{\count@\@ne}}
+\DeclareSCPos{bottom}{\def\@FC@vpos{\count@\tw@}}
+\newcommand*\@FC@vpos{\count@\tw@}
+\newcommand*\@FC@hpos{\let\FR@iffacing\@secondoftwo\count@\@ne}
+\newcounter{FBcnt}
+\DeclareFROpt{footposition}{\flrow@ftpos{#1}}
+\newcommand\DeclareFtPos[2]{%
+  \define@key{flrow@ftpos}{#1}[]{\g@addto@macro\FR@tmp{#2}}}
+\newcommand*\flrow@ftpos[1]{%
+  \let\FR@tmp\@empty
+  \begingroup\caption@setkeys[floatrow]{flrow@ftpos}{#1}\endgroup
+  \FR@tmp}
+\@onlypreamble\DeclareFtPos
+\@ifdefinable\FPOScnt{\newcount\FPOScnt}
+\DeclareFtPos{caption}{\FPOScnt1\relax}
+\DeclareFtPos{bottom}{\FPOScnt2\relax}
+\DeclareFtPos{default}{\FPOScnt0\relax}
+\DeclareFROpt{heightadjust}{\flrow@htadj{#1}}
+\newcommand\DeclareHtAdj[2]{%
+  \define@key{flrow@htadj}{#1}[]{\g@addto@macro\FR@tmp{#2}}}
+\newcommand*\flrow@htadj[1]{\let\FR@tmp\@empty
+  \begingroup\caption@setkeys[floatrow]{flrow@htadj}{#1}\endgroup
+  \FR@tmp}
+\@onlypreamble\DeclareHtAdj
+\DeclareHtAdj{all}{\CADJtrue\OADJtrue}
+\DeclareHtAdj{caption}{\CADJtrue}
+\DeclareHtAdj{object}{\OADJtrue}
+\DeclareHtAdj{none}{\CADJfalse\OADJfalse}
+\DeclareHtAdj{nocaption}{\CADJfalse}
+\DeclareHtAdj{noobject}{\OADJfalse}
+\newif\ifCADJ
+\newif\ifOADJ
+\DeclareFROpt{valign}{\@FB@vpos{#1}}
+\newcommand\@FB@vpos[1]{%
+  \if#1t\def\FBafil{}\def\FBbfil{\vss}\else
+     \if#1b\def\FBafil{\vss}\def\FBbfil{}\else
+        \if#1c\def\FBafil{\vskip0ptplus1fillminus1000pt}%
+              \def\FBbfil{\vskip0ptplus1fillminus1000pt}\else
+           \if#1s\def\FBafil{\vskip0ptminus1000pt}%
+                 \def\FBbfil{\vskip0ptminus1000pt}%
+  \fi\fi\fi\fi}
+\@ifdefinable\FR@iffacing{\let\FR@iffacing\@secondoftwo}
+\DeclareFROpt{facing}[1]{\flrow@setbool{facing}{#1}}
+\newcommand\FB@facing{}
+\DeclareFROpt{margins}{\flrow@FBAlign{#1}}
+\newcommand*\flrow@FBAlign[1]{%
+  \@ifundefined{flrow@mj@#1}%
+    {\flrow@error{Undefined float alignment `#1'}}%
+    {\@nameuse{flrow@mj@#1}}}
+\newcommand*\DeclareMarginSet[2]{%
+  \global\@namedef{flrow@mj@#1}{#2}}
+\@onlypreamble\DeclareMarginSet
+\newskip\LTleft\newskip\LTright
+\DeclareMarginSet{centering}{\setfloatmargins{\hfill}{\hfill}%
+  \LTleft=\fill \LTright=\fill}
+\DeclareMarginSet{raggedright}{\setfloatmargins{}{\hfil}%
+  \LTleft=\z@ \LTright=\fill}
+\DeclareMarginSet{raggedleft}{\setfloatmargins{\hfil}{}%
+  \LTleft=\fill \LTright=\z@}
+\newskip\LTleft\newskip\LTright
+\DeclareMarginSet{hangleft}{\setfloatmargins
+    {\hskip-\marginparwidth\hskip-\marginparsep\hskip\leftskip}{\hskip\rightskip}%
+  \LTleft-\marginparwidth\advance\LTleft-\marginparsep
+  \LTright=\fill}
+\DeclareMarginSet{hangright}{\setfloatmargins
+    {\hskip\leftskip}{\hskip-\marginparwidth\hskip-\marginparsep\hskip\rightskip}%
+  \LTleft=\fill
+  \LTright-\marginparwidth\advance\LTright-\marginparsep}
+\DeclareMarginSet{hanginside}{\setfloatmargins
+    *{\hskip-\marginparwidth\hskip-\marginparsep\hskip\leftskip}{\hskip\rightskip}%
+  }
+\DeclareMarginSet{hangoutside}{\setfloatmargins
+    *{\hskip\leftskip}{\hskip-\marginparwidth\hskip-\marginparsep\hskip\rightskip}%
+  }
+\newcommand\flrow@mj@default{\flrow@mj@centering}
+\newcommand\floatfacing{\@ifstar
+  {\@FC@hpos\floatfacing@}{\FB@facing\floatfacing@}}
+\newcommand\floatfacing@[2]{\ifodd\count@#1\else#2\fi}
+\newcommand\floatboxmargins{\def\FR@tmp{FB}\FB@mset}
+\newcommand\floatrowmargins{\def\FR@tmp{FR}\FB@mset}
+\newcommand\floatcapbesidemargins{\def\FR@tmp{FC}\FB@mset}
+\newcommand\FB@mset{\@ifstar{\FB@mset@}{\FB@@mset}}
+\newcommand\FB@mset@[2]{%
+  \def\FB@facing{\let\FR@iffacing\@firstoftwo\count@\c@FBcnt}%
+  \@namedef{\FR@tmp leftmargin}{\floatfacing{#1}{#2}}%
+  \@namedef{\FR@tmp rightmargin}{\floatfacing{#2}{#1}}}
+\newcommand\FB@@mset[2]{\def\FB@facing{}%
+  \@namedef{\FR@tmp leftmargin}{#1}\@namedef{\FR@tmp rightmargin}{#2}}
+\newcommand\setfloatmargins{\@ifstar\FB@allset@\FB@@allset}
+\newcommand\FB@allset@[2]{%
+  \def\FR@tmp{FR}\FB@mset@{#1}{#2}%
+  \def\FR@tmp{FB}\FB@mset@{#1}{#2}%
+  \def\FR@tmp{FC}\FB@mset@{#1}{#2}}
+\newcommand\FB@@allset[2]{%
+  \def\FR@tmp{FR}\FB@@mset{#1}{#2}%
+  \def\FR@tmp{FB}\FB@@mset{#1}{#2}%
+  \def\FR@tmp{FC}\FB@@mset{#1}{#2}}
+\setfloatmargins\hfill\hfill
+\DeclareFROpt{objectset}{\flrow@FBoAlign{#1}}
+\DeclareFROpt{justification}{\flrow@FBoAlign{#1}}
+\let\DeclareObjectSet\DeclareCaptionJustification
+\@onlypreamble\DeclareObjectSet
+\newcommand*\flrow@FBoAlign[1]{%
+  \@ifundefined{caption@hj@#1}%
+    {\flrow@error{Undefined object setting `#1'}}%
+    {\expandafter\let\expandafter\floatobjectset
+     \csname caption@hj@#1\endcsname}}
+\newcommand*\floatobjectset{\centering}
+\DeclareFROpt{floatwidth}{\flrow@FBo@wd{#1}}
+\@ifdefinable\FC@ifo@fil{\let\FC@ifo@fil\@secondoftwo}
+\newcommand\filFCOhsize{\let\FC@ifo@fil\@firstoftwo}
+\newcommand\nofilFCOhsize{\let\FC@ifo@fil\@secondoftwo}
+\newcommand\flrow@setwd{\relax}
+\newcommand\flrow@FBo@wd[1]{%
+  \caption@ifinlist{#1}{none,sidefil}{\filFCOhsize
+  }{\nofilFCOhsize\def\flrow@setwd{\@tempdima=#1}}}
+\DeclareFROpt{floatrowsep}{\flrow@setFRsep\floatrowsep{#1}}
+\DeclareFROpt{subfloatrowsep}{\flrow@setFRsep\subfloatrowsep{#1}}
+\DeclareFROpt{capbesidesep}{\flrow@setFRsep\floatcapbesidesep{#1}}
+\let\DeclareFloatSeparators\DeclareCaptionLabelSeparator
+\@onlypreamble\DeclareFloatSeparators
+\newcommand*\flrow@setFRsep[2]{%
+  \@ifundefined{caption@lsep@#2}%
+    {\flrow@error{Undefined float separator `#2'}}%
+    {\expandafter\let\expandafter#1\csname caption@lsep@#2\endcsname}}
+\DeclareFloatSeparators{columnsep}{\hskip\columnsep}
+\DeclareFloatSeparators{qquad}{\qquad}
+\DeclareFloatSeparators{fil}{\hskip\columnsep plus1fil}
+\DeclareFloatSeparators{fill}{\hskip\columnsep plus1fill}
+\newcommand\floatrowsep{\hskip\columnsep}
+\newcommand\floatcapbesidesep{\hskip\columnsep}
+\DeclareFROpt{precode}{\flrow@FBrule\@@FRabove\@@FBabove{#1}}
+\DeclareFROpt{rowprecode}{\flrow@FRrule\@@FRabove\@@FBabove{#1}}
+\DeclareFROpt{midcode}{\flrow@FBskip{#1}}
+\DeclareFROpt{postcode}{\flrow@FBrule\@@FRbelow\@@FBbelow{#1}}
+\DeclareFROpt{rowpostcode}{\flrow@FRrule\@@FRbelow\@@FBbelow{#1}}
+\newcommand\DeclareFloatVCode[2]{\@namedef{flrow@FBr@#1}{#2}}
+\@onlypreamble\DeclareFloatVCode
+\newcommand*\flrow@FBrule[3]{%
+  \@ifundefined{flrow@FBr@#3}%
+    {\flrow@error{Undefined rule `#3'}}%
+    {\let#1\empty
+     \expandafter\let\expandafter#2\csname flrow@FBr@#3\endcsname}}
+\newcommand*\flrow@FRrule[3]{%
+  \@ifundefined{flrow@FBr@#3}%
+    {\flrow@error{Undefined rule `#3'}}%
+    {\def#2{\FBiffloatrow\relax{\@nameuse{flrow@FBr@#3}}}%
+     \expandafter\let\expandafter#1\csname flrow@FBr@#3\endcsname}}
+\newcommand*\flrow@FBskip[1]{%
+  \@ifundefined{flrow@FBr@#1}%
+    {\flrow@error{Undefined rule `#1'}}%
+    {\expandafter\let\expandafter\@@FBskip\csname flrow@FBr@#1\endcsname}}
+\DeclareFloatVCode{none}{}
+\DeclareFloatVCode{thickrule}{\par\rule{\hsize}{.8pt}\vskip2pt\par}
+\DeclareFloatVCode{rule}{\vskip2pt\hrule\vskip2pt}
+\DeclareFloatVCode{lowrule}{\par\vskip2pt\rule\hsize\@wholewidth\par}
+\DeclareFloatVCode{captionskip}{\vskip\captionskip}
+\newcommand\FBstyle@reset{\let\FRifFBOX\@secondoftwo\OADJfalse\CADJfalse\capbot
+  \def\@@FBskip{\vskip\captionskip}\def\@@FRabove{}\def\@@FRbelow{}%
+  \def\@@FBabove{}\def\@@FBbelow{}%
+  \def\FB@Bset{}\def\FB@frame{}\def\FBo@frame{}\def\FR@frame{}%
+  \def\FBo@wadj{}\def\FBo@hadj{}\def\FB@wadj{}\def\FB@hadj{}\def\FR@wadj{}\def\FR@hadj{}}
+\newcommand\@@FBskip{\vskip\captionskip}
+\@ifdefinable\@@FRabove{\def\@@FRabove{}}
+\@ifdefinable\@@FRbelow{\def\@@FRbelow{}}
+\@ifdefinable\@@FBabove{\def\@@FBabove{}}
+\@ifdefinable\@@FBbelow{\def\@@FBbelow{}}
+\@ifdefinable\FB@frame {\def\FB@frame {}}
+\@ifdefinable\FBo@frame{\def\FBo@frame{}}
+\@ifdefinable\FR@frame {\def\FR@frame {}}
+\@ifdefinable\FBo@wadj {\def\FBo@wadj {}}
+\@ifdefinable\FBo@hadj {\def\FBo@hadj {}}
+\@ifdefinable\FB@wadj  {\def\FB@wadj  {}}
+\@ifdefinable\FB@hadj  {\def\FB@hadj  {}}
+\@ifdefinable\FR@wadj  {\def\FR@wadj  {}}
+\@ifdefinable\FR@hadj  {\def\FR@hadj  {}}
+\@ifdefinable\FB@Bset  {\def\FB@Bset  {}}
+\DeclareFROpt{framestyle}{\@ifundefined{FB@#1@frame}%
+  {\let\FRifFBOX\@secondoftwo}{\let\FRifFBOX\@firstoftwo\def\FB@B@{#1}}}
+\DeclareFROpt{framearound}{\flrow@fr@round{#1}}
+\newcommand*\flrow@fr@round[1]{%
+ \caption@ifinlist{#1}{object,contents}{\let\FRifFBOX\@firstoftwo
+    \def\FB@BO@{FBo}%
+  }{\caption@ifinlist{#1}{floatbox,all}{\let\FRifFBOX\@firstoftwo
+    \def\FB@BO@{FB}%
+  }{\caption@ifinlist{#1}{row}{\let\FRifFBOX\@firstoftwo
+    \def\FB@BO@{FR}%
+  }{\caption@ifinlist{#1}{none}{\let\FRifFBOX\@secondoftwo
+  }{\flrow@error{Undefined framed object `#1'}%
+  }}}}}
+\@ifdefinable\FR@ifFIT{\let\FR@ifFIT\@secondoftwo}
+\@ifdefinable\FR@ifROWFILL{\let\FR@ifROWFILL\@secondoftwo}
+\DeclareFROpt{framefit}[0]{\flrow@setbool{FIT}{#1}}
+\@ifdefinable\flrow@@setROWFILL{}
+\@ifdefinable\flrow@leftfill{}\@ifdefinable\flrow@rightfill{}
+\DeclareFROpt{rowfill}[0]{\flrow@setbool{ROWFILL}{#1}}
+\DeclareFROpt{frameset}{\def\FB@Bset{#1}}
+\newcommand\FB@BO@{FBo}\newcommand\FB@B@{}
+\newcommand\@@setframe{%
+  \@namedef{\FB@BO@ @hadj}{\@nameuse{FB@\FB@B@ @reset}\FB@Bset
+    \@nameuse{FB@\FB@B@ @adj}}%
+  \@namedef{\FB@BO@ @wadj}{\FR@ifFIT{\@nameuse{FB@\FB@B@ @reset}\FB@Bset
+    \@nameuse{FB@\FB@B@ @adj}}\relax}%
+  \@namedef{\FB@BO@ @frame}{\@nameuse{FB@\FB@B@ @reset}\FB@Bset
+    \@nameuse{FB@\FB@B@ @frame}}%
+  \ifx\FR@frame\empty\else%\ifx\FB@frame\empty
+     \def\FB@hadj{\@nameuse{FB@\FB@B@ @reset}\FB@Bset
+       \@nameuse{FB@\FB@B@ @adj}}%
+     \def\FB@wadj{\FR@ifFIT{\@nameuse{FB@\FB@B@ @reset}\FB@Bset
+       \@nameuse{FB@\FB@B@ @adj}}\relax}%
+     \def\FB@frame{\@nameuse{FB@\FB@B@ @reset}\FB@Bset
+       \@nameuse{FB@\FB@B@ @frame}}%
+  \fi%\fi
+  }
+\@ifdefinable\FRifFBOX{\let\FRifFBOX\@secondoftwo}
+\newcommand\FB@fbox@frame[1]{\hbox{%
+  \FR@ifFIT\relax{\kern-\fboxrule\kern-\fboxsep}\fbox{#1}%
+  \FR@ifFIT\relax{\kern-\fboxrule\kern-\fboxsep}}\ignorespaces}
+\newcommand\FB@fbox@adj{\dimen@=2\fboxsep\advance\dimen@2\fboxrule}
+\newcommand\FB@fbox@reset{\fboxsep3\p@\fboxrule.4\p@}
+\newcommand\FB@colorbox@frame[1]{\hbox{%
+  \FR@ifFIT\relax{\kern-\fboxrule\kern-\fboxsep}\FB@fcolorbox{#1}%
+  \FR@ifFIT\relax{\kern-\fboxrule\kern-\fboxsep}}\ignorespaces}
+\@ifdefinable\FB@colorbox@adj{\let\FB@colorbox@adj\FB@fbox@adj}
+\newcommand\FB@colorbox@reset{\fboxsep3\p@\fboxrule.4\p@}
+\newcommand\FB@fcolorbox{\fbox}
+\newcommand\FB@fcolorcorners{}
+\@ifdefinable\FR@phantom{}\@ifdefinable\FRset@color{}
+\newcommand\FB@FRcolorbox@frame[1]{\hbox{\let\color@block\FRcolor@block
+  \let\FR@phantom\@firstofone\let\FRset@color\set@color\FB@fcolorcorners
+  \FR@ifFIT\relax{\kern-\fboxrule\kern-\fboxsep}\FB@fcolorbox{#1}%
+  \FR@ifFIT\relax{\kern-\fboxrule\kern-\fboxsep}}\ignorespaces}
+\@ifdefinable\FB@FRcolorbox@adj{\let\FB@FRcolorbox@adj\FB@fbox@adj}
+\newcommand\FB@FRcolorbox@reset{\fboxsep3\p@\fboxrule.4\p@}
+\newcommand\FB@corners@frame[1]{\hbox{\let\color@block\FRcolor@block
+  \let\FR@phantom\phantom\let\FRset@color\relax\FB@fcolorcorners
+  \FR@ifFIT\relax{\kern-\fboxrule\kern-\fboxsep}\colorbox{white}{#1}%
+  \FR@ifFIT\relax{\kern-\fboxrule\kern-\fboxsep}}\ignorespaces}
+\@ifdefinable\FB@corners@adj{\let\FB@corners@adj\FB@fbox@adj}
+\newcommand\FB@corners@reset{\fboxsep3\p@\fboxrule\z@}
+\newcommand\flrow@l@color@side[2]{{\let\unitlength\relax
+    \picture(\z@,\z@)(\z@,\z@)
+    \put(\z@,#1){{\flrow@ll@col@put}}
+    \put(\z@,#2){{\flrow@ul@col@put}}
+    \endpicture}}
+\newcommand\flrow@r@color@side[2]{{\let\unitlength\relax
+    \picture(\z@,\z@)(\z@,\z@)
+    \put(\z@,#1){{\flrow@lr@col@put}}
+    \put(\z@,#2){{\flrow@ur@col@put}}
+    \endpicture}}
+\newcommand\flrow@ll@col@put{}
+\newcommand\flrow@ul@col@put{}
+\newcommand\flrow@lr@col@put{}
+\newcommand\flrow@ur@col@put{}
+\newcommand\flrow@cboxcorners[4]{%
+    \def\flrow@ll@col@put{#1}%
+    \def\flrow@lr@col@put{#2}%
+    \def\flrow@ur@col@put{#3}%
+    \def\flrow@ul@col@put{#4}%
+    }
+\newcommand\FRcolorboxwd{\z@}
+\newcommand\FRcolorboxht{\z@}
+\newcommand\FRcolorboxdp{\z@}
+\def\FRcolor@block#1#2#3{%
+  {\FRset@color
+   \rlap{\@tempdima#1\edef\FRcolorboxwd{\the\@tempdima}\@tempdima#2\advance\@tempdima#3%
+   \edef\FRcolorboxht{\the\@tempdima}\@tempdima#3\edef\FRcolorboxdp{\the\@tempdima}%
+   \ifcolors@\else\let\FR@phantom\phantom\fi
+     \flrow@l@color@side{-\FRcolorboxdp}{\FRcolorboxht}%
+     \FR@phantom{\vrule\@width#1\@height#2\@depth#3}%
+     \flrow@r@color@side{-\FRcolorboxdp}{\FRcolorboxht}%
+    }}}
+\DeclareFROpt{colorframeset}{\flrow@fcolorbox{#1}}
+\DeclareFROpt{colorframecorners}{\flrow@fcolorcorners{#1}}
+\newcommand*\flrow@fcolorbox[1]{%
+  \@ifundefined{flrow@fcolorbox@#1}%
+    {\flrow@error{Undefined color box `#1'}}%
+    {\expandafter\let\expandafter\FB@fcolorbox
+     \csname flrow@fcolorbox@#1\endcsname}}
+\newcommand*\flrow@fcolorcorners[1]{%
+  \@ifundefined{flrow@fcolorcorners@#1}%
+    {\flrow@error{Undefined color box corners `#1'}}%
+    {\expandafter\let\expandafter\FB@fcolorcorners
+     \csname flrow@fcolorcorners@#1\endcsname}}
+\newcommand*\DeclareColorBox[2]{%
+  \@ifundefined{color}{}{\let\flrow@load@colorpackage\relax
+   \long\@namedef{flrow@fcolorbox@#1}{#2}}}
+\newcommand*\DeclareCBoxCorners[5]{%
+  \@ifundefined{color}{}{\let\flrow@load@colorpackage\relax
+   \long\@namedef{flrow@fcolorcorners@#1}{\flrow@cboxcorners{#2}{#3}{#4}{#5}}}}
+\@onlypreamble\DeclareColorBox
+\@onlypreamble\DeclareCBoxCorners
+\newcommand\flrow@load@colorpackage{\IfFileExists{color.sty}%
+    {\def\next{\RequirePackage{color}}}{\let\next\relax}\next}
+\AtBeginDocument{\flrow@load@colorpackage\let\flrow@load@colorpackage\relax}
+\DeclareFROpt{captionskip}{\def\captionskip{#1}%
+  \setlength\abovecaptionskip{#1}}
+\DeclareFROpt{footskip}{\def\floatfootskip{#1}}
+\newcommand\captionskip{10\p@}
+\newcommand\floatfootskip{\skip\@mpfootins}
+\DeclareFROpt{footnoterule}{\flrow@footrule{#1}}
+\newcommand\DeclareFloatFootnoterule[2]{%
+  \long\@namedef{flrow@fnrule@#1}{#2}}
+\newcommand*\flrow@footrule[1]{%
+  \@ifundefined{flrow@fnrule@#1}%
+    {\flrow@error{Undefined footnoterule `#1'}}%
+    {\let\@@FRabove\empty
+     \expandafter\let\expandafter\FBfootnoterule\csname
+       flrow@fnrule@#1\endcsname}}
+\@onlypreamble\DeclareFloatFootnoterule
+\DeclareFloatFootnoterule{normal}{\kern-3\p@
+  \@tempdima.4\columnwidth
+  \hrule\@width\@tempdima\kern2.6\p@}
+\DeclareFloatFootnoterule{limited}{\kern-3\p@
+  \@tempdima.4\columnwidth
+  \ifdim\@tempdima>\frulemax\@tempdima=\frulemax\fi
+  \hrule\@width\@tempdima\kern2.6\p@}
+\newcommand\frulemax{1in}
+\DeclareFloatFootnoterule{fullsize}{\kern-3\p@
+  \hrule\@width\hsize\kern2.6\p@}
+\DeclareFloatFootnoterule{none}{}
+\@ifdefinable\FBfootnoterule{\let\FBfootnoterule\footnoterule}
+\@ifdefinable\FR@iffancy{\let\FR@iffancy\@secondoftwo}
+\DeclareFROpt{fancyboxes}{\flrow@setbool{fancy}{#1}}
+\newcommand\DeclareFNOpt{%
+   \@ifstar{\flrow@declfnopt\AtBeginDocument}
+           {\flrow@declfnopt\@gobble}}
+\newcommand*\flrow@declfnopt[2]{%
+   #1{\undefine@key{newfloat}{#2}}\define@key{newfloat}{#2}}
+\@onlypreamble\DeclareFNOpt
+\@ifdefinable\flrow@types{\newtoks\flrow@types}
+\newcommand\DeclareNewFloatType[2]{\def\FB@captype{#1}%
+  \expandafter\edef\csname ftype@#1\endcsname{\the\c@float@type}%
+  \addtocounter{float@type}{\value{float@type}}%
+  \@namedef{#1name}{#1}\newcounter{#1}%
+  \expandafter\edef\csname fnum@#1\endcsname
+    {\expandafter\noexpand\csname #1name\endcsname\nobreakspace
+       \expandafter\noexpand\csname the#1\endcsname}%
+  \@namedef{the#1}{\arabic{#1}}\flnew@ext{lo#1}\@namedef{fps@#1}{tbp}%
+  \@namedef{l@#1}{\@dottedtocline{1}{1.5em}{2.3em}}%
+  \caption@setkeys[floatrow]{newfloat}{#2}\let\FR@tmp=\relax
+  \xdef\@tempa{\noexpand\flrow@types{\the\flrow@types \FR@tmp{#1}}}%
+  \@tempa}
+\@onlypreamble\DeclareNewFloatType
+\DeclareFNOpt*{placement}{\flnew@fps{#1}}
+\newcommand\flnew@fps[1]{\@namedef{fps@\FB@captype}{#1}}
+\@onlypreamble\flnew@fps
+\DeclareFNOpt*{name}{\flnew@fname{#1}}
+\newcommand\flnew@fname[1]{\@namedef{\FB@captype name}{#1}}
+\@onlypreamble\flnew@fname
+\DeclareFNOpt*{fileext}{\flnew@ext{#1}}
+\newcommand\flnew@ext[1]{\@namedef{ext@\FB@captype}{#1}%
+  \let\float@do=\relax
+  \xdef\@tempa{\noexpand\float@exts{\the\float@exts \float@do{#1}}}%
+  \@tempa}
+\@onlypreamble\flnew@ext
+\DeclareFNOpt*{within}{\flnew@within{#1}}
+\newcommand\flnew@within[1]{\@addtoreset{\FB@captype}{#1}%
+  \expandafter\edef\csname the\FB@captype\endcsname{%
+      \expandafter\noexpand\csname
+        the#1\endcsname.\noexpand\arabic{\FB@captype}}}
+\@onlypreamble\flnew@within
+\def\ProcessOptionsWithKV#1{%
+  \let\@tempc\relax
+  \let\FR@tmp\@empty
+  \@for\CurrentOption:=\@classoptionslist\do{%
+    \@ifundefined{KV@#1@\CurrentOption}%
+    {}%
+    {%
+      \@ifundefined{KV@#1@\CurrentOption @default}{%
+       \PackageInfo{#1}{Global option `\CurrentOption' ignored}%
+      }{%
+      \PackageInfo{#1}{Global option `\CurrentOption' processed}%
+      \edef\FR@tmp{\FR@tmp,\CurrentOption,}%
+      \@expandtwoargs\@removeelement\CurrentOption
+        \@unusedoptionlist\@unusedoptionlist
+        }%
+    }%
+  }%
+  \edef\FR@tmp{%
+    \noexpand\caption@setkeys[floatrow]{#1}{%
+      \FR@tmp\@ptionlist{\@currname.\@currext}%
+    }%
+  }%
+  \FR@tmp
+  \let\CurrentOption\@empty
+  \AtEndOfPackage{\let\@unprocessedoptions\relax}}
+\ProcessOptionsWithKV{floatrow}
+\FR@iffancy{\RequirePackage{fr-fancy}}\relax
+\let\ProcessOptionsWithKV\undefined
+\AtBeginDocument{
+ \FR@ifrawfloats
+  {\let\FR@tmp\flrow@Raw@restyle
+ }{\flrow@restyle{table}\flrow@restyle{figure}%
+   \let\FR@tmp\flrow@restyle
+  }\the\flrow@types
+ \@onlypreamble\flrow@restyle\@onlypreamble\flrow@Raw@restyle
+ \flrow@types={}}
+\AtBeginDocument{%
+\@ifundefined{sf@@@subfloat}{\@tempswafalse}{\@tempswatrue}
+\if@tempswa\RequirePackage{fr-subfig}\fi}
+\AtBeginDocument{%
+\@ifundefined{LT@array}{\@tempswafalse}{\@tempswatrue}
+\if@tempswa\RequirePackage{fr-longtable}\fi}
+\endinput
+%%
+%% End of file `floatrow.sty'.
diff --git a/forloop.sty b/forloop.sty
new file mode 100644 (file)
index 0000000..fec7508
--- /dev/null
@@ -0,0 +1,64 @@
+%%
+%% This is file `forloop.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% forloop.dtx  (with options: `package')
+%% 
+%% This is a generated file
+%% 
+%% This file may be distributed and/or modified under the
+%% conditions of the Limited General Product License
+%% 
+\NeedsTeXFormat{LaTeX2e}[1999/12/01]
+\ProvidesPackage{forloop}
+ [2006/09/18 v3.0 For Loops for LaTeX]
+\RequirePackage{ifthen}
+%% \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
+%%   Digits        \0\1\2\3\4\5\6\7\8\9
+%%   Exclamation   \!     Double quote  \"     Hash (number) \#
+%%   Dollar        \$     Percent       \%     Ampersand     \&
+%%   Acute accent  \'     Left paren    \(     Right paren   \)
+%%   Asterisk      \*     Plus          \+     Comma         \,
+%%   Minus         \-     Point         \.     Solidus       \/
+%%   Colon         \:     Semicolon     \;     Less than     \<
+%%   Equals        \=     Greater than  \>     Question mark \?
+%%   Commercial at \@     Left bracket  \[     Backslash     \\
+%%   Right bracket \]     Circumflex    \^     Underscore    \_
+%%   Grave accent  \`     Left brace    \{     Vertical bar  \|
+%%   Right brace   \}     Tilde         \~}
+\newcommand{\forloop}[5][1]%
+{%
+\setcounter{#2}{#3}%
+\ifthenelse{#4}%
+{%
+#5%
+\addtocounter{#2}{#1}%
+\forloop[#1]{#2}{\value{#2}}{#4}{#5}%
+}%
+{%
+}%
+}%
+\newcommand{\forLoop}[5][1]
+{%
+\setcounter{#4}{#2}%
+\ifthenelse{ \value{#4}<#3 }%
+{%
+#5%
+\addtocounter{#4}{#1}%
+\forLoop[#1]{\value{#4}}{#3}{#4}{#5}%
+}%
+{%
+\ifthenelse{\value{#4}=#3}%
+{%
+#5%
+}%
+{}%
+}%
+}
+\endinput
+%%
+%% End of file `forloop.sty'.
diff --git a/fr-subfig.sty b/fr-subfig.sty
new file mode 100644 (file)
index 0000000..3ec9313
--- /dev/null
@@ -0,0 +1,259 @@
+%%
+%% This is file `fr-subfig.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% floatrow.dtx  (with options: `frforsubfig')
+%% 
+%% IMPORTANT NOTICE:
+%% 
+%% For the copyright see the source file.
+%% 
+%% Any modified versions of this file must be renamed
+%% with new filenames distinct from fr-subfig.sty.
+%% 
+%% For distribution of the original source see the terms
+%% for copying and modification in the file floatrow.dtx.
+%% 
+%% This generated file may be distributed as long as the
+%% original source files, as listed above, are part of the
+%% same distribution. (The sources need not necessarily be
+%% in the same archive or directory.)
+\NeedsTeXFormat{LaTeX2e}[1995/06/01]
+\ProvidesPackage{fr-subfig}
+       [2007/12/24 v0.1g (beta) floatrow: additions for subfig]
+\def\@tempb{2005/06/28 ver: 1.3 subfig package}
+\expandafter\let\csname @tempa\expandafter\endcsname
+    \csname ver@subfig.\@pkgextension\endcsname
+\ifx\@tempa\@tempb\else
+    \PackageWarning{fr-subfig}{The additions cooperated with \MessageBreak
+        version `2005/06/28 ver: 1.3' of package subfig,\MessageBreak
+        but only version\MessageBreak
+        \csname ver@subfig.\@pkgextension\endcsname'\MessageBreak
+        is available}\relax
+    \fi
+\newlength\FBsc@max
+\newlength\FBso@max
+\@ifdefinable\FBsubcheight{\let\FBsubcheight\relax}
+\@ifdefinable\FBsuboheight{\let\FBsuboheight\relax}
+\newcommand\adjustsubfloats{\@tempswafalse
+  \ifCADJ\@tempswatrue\fi\ifOADJ\@tempswatrue\fi
+  \if@tempswa\FB@writeaux{%
+    \string\global\string\c@FBcnt\thepage
+    \ifCADJ\string\edef\string\FBsubcheight{\the\FBsc@max}\fi
+    \ifOADJ\string\edef\string\FBsuboheight{\the\FBso@max}\fi
+   }\fi
+  \global\let\FBsubcheight\relax\global\let\FBsuboheight\relax
+  \global\FBso@max\z@\global\FBsc@max\z@}
+\long\def\sf@@@subfloat#1[#2][#3]#4{%
+    \@ifundefined{FBsc@max}{}%
+        {\FB@readaux{\let\FBsuboheight\relax}}%
+    \@tempcnta=\@ne
+    \if@minipage
+      \@tempcnta=\z@
+    \else\ifdim \lastskip=\z@ \else
+      \@tempcnta=\tw@
+    \fi\fi
+    \ifmaincaptiontop
+      \sf@top=\sf@nearskip
+      \sf@bottom=\sf@farskip
+    \else
+      \sf@top=\sf@farskip
+      \sf@bottom=\sf@nearskip
+    \fi
+    \leavevmode
+    \setbox\@tempboxa \hbox{#4}%
+    \ifdim\wd\@tempboxa=\z@\ht\@tempboxa\z@\dp\@tempboxa\z@
+      \setbox\z@\hbox{{\caption@@@make
+           {\caption@lfmt{\@nameuse{sub\@captype name}}%
+           {\@nameuse{thesub\@captype}}\relax}{}}}\@tempdima=\wd\z@
+      \sf@top=\z@
+      \sf@bottom=\z@
+      \sf@capskip\z@
+      \sf@captopadj\z@
+      \let\sf@ifpositiontop\@firstoftwo
+    \else
+      \@tempdima=\wd\@tempboxa
+      \@ifundefined{FBsc@max}{}%
+          {\global\advance\Xhsize-\wd\@tempboxa
+           \dimen@=\ht\@tempboxa
+           \advance\dimen@\dp\@tempboxa
+           \ifdim\dimen@>\FBso@max
+             \global\FBso@max\dimen@
+           \fi}%
+    \fi
+    \vtop\bgroup
+      \vbox\bgroup
+        \ifcase\@tempcnta
+          \@minipagefalse
+        \or
+          \vskip\sf@top
+        \or
+          \ifdim \lastskip=\z@ \else
+            \@tempskipb\sf@top\relax\@xaddvskip
+          \fi
+        \fi
+        \sf@ifpositiontop{%
+          \ifx \@empty#3\relax \else
+            \sf@subcaption{#1}{#2}{#3}%
+            \vskip\sf@capskip
+            \vskip\sf@captopadj
+          \fi\egroup
+          \hrule width0pt height0pt depth0pt
+          \box\@tempboxa
+        }{%
+        \@ifundefined{FBsc@max}%
+            {\box\@tempboxa}%
+            {\ifx\FBsuboheight\relax
+               \box\@tempboxa
+             \else
+               \vbox to \FBsuboheight{\FBafil\box\@tempboxa\FBbfil}%
+             \fi}%
+          \egroup
+          \ifx \@empty#3\relax \else
+            \vskip\sf@capskip
+            \hrule width0pt height0pt depth0pt
+            \sf@subcaption{#1}{#2}{#3}%
+         \fi
+        }%
+      \vskip\sf@bottom
+    \egroup
+    \@ifundefined{FBsc@max}{}%
+        {\addtocounter{FRobj}{-1}%
+         \ifnum\c@FRobj>0%  bugfix
+           \subfloatrowsep
+         \fi}%
+    \ifmaincaptiontop\else
+      \global\advance\@nameuse{c@\@captype}\m@ne
+    \fi
+  \endgroup\ignorespaces}
+\DeclareFROpt{subcapbesideposition}{\flrow@SFbesidealign{#1}}
+\newcommand*\flrow@SFbesidealign[1]{%
+  \caption@ifinlist{#1}{t,top}{%
+     \let\flrow@SFBalign\TopFloatBoxes
+  }{\caption@ifinlist{#1}{b,bottom,default}{%
+     \let\flrow@SFBalign\BottomFloatBoxes
+  }{\caption@ifinlist{#1}{c,center}{%
+     \let\flrow@SFBalign\CenterFloatBoxes
+  }{\PackageError{floatrow}%
+     {Undefined sublabel position `#1'}{\flrow@eh}%
+  }}}}
+\newcommand\flrow@SFBalign{\BottomFloatBoxes}
+\newcommand\sidesubfloat{%
+  \ifx\@captype\@undefined
+    \@latex@error{\noexpand\subfloat outside float}\@ehd
+     \expandafter\@gobble
+  \else
+    \expandafter\@firstofone
+  \fi
+  {\flrow@sidesubfloat}}
+\def\flrow@sidesubfloat{\flrow@SFBalign
+  \begingroup
+    \@ifundefined{caption@setfloattype}%
+      \caption@settype
+      \caption@setfloattype
+          \@captype
+    \sf@ifpositiontop{%
+      \maincaptiontoptrue
+    }{%
+      \maincaptiontopfalse
+    }%
+    \caption@setoptions{subfloat}%
+    \caption@setoptions{sub\@captype}%
+    \let\sf@oldlabel=\label
+    \let\label=\subfloat@label
+    \ifmaincaptiontop\else
+      \advance\@nameuse{c@\@captype}\@ne
+    \fi
+    \refstepcounter{sub\@captype}%
+    \setcounter{sub\@captype @save}{\value{sub\@captype}}%
+    \@ifnextchar [%  %] match left bracket
+      {\flrow@@sidesubfloat}%
+      {\flrow@@sidesubfloat[\@empty]}}
+\long\def\flrow@@sidesubfloat[#1]{%
+    \@ifnextchar [%  %] match left bracket
+      {\flrow@@@sidesubfloat{sub\@captype}[{#1}]}%
+      {\flrow@@@sidesubfloat{sub\@captype}[\@empty{#1}][{#1}]}}
+\long\def\flrow@@@sidesubfloat#1[#2][#3]#4{%
+    \@ifundefined{FBsc@max}{}%
+        {\FB@readaux{\let\FBsuboheight\relax}}%
+    \@tempcnta=\@ne
+    \if@minipage
+      \@tempcnta=\z@
+    \else\ifdim \lastskip=\z@ \else
+      \@tempcnta=\tw@
+    \fi\fi
+    \sf@bottom=\z@
+    \sf@top=\z@
+    \leavevmode
+    \setbox\@tempboxa \hbox{#2}%
+    \@tempdima\wd\@tempboxa
+    \setbox\@tempboxa \hbox{#4}%
+    \advance\@tempdima\wd\@tempboxa
+    \advance\@tempdima\labelsep
+    \@ifundefined{FBsc@max}{}%
+        {\global\advance\Xhsize-\wd\@tempboxa
+         \dimen@=\ht\@tempboxa
+         \advance\dimen@\dp\@tempboxa
+         \ifdim\dimen@>\FBso@max
+           \global\FBso@max\dimen@
+         \fi}%
+    \begin@FBBOX
+        \ifcase\@tempcnta
+          \@minipagefalse
+        \or
+          \vskip\sf@top
+        \or
+          \ifdim \lastskip=\z@ \else
+            \@tempskipb\sf@top\relax\@xaddvskip
+          \fi
+        \fi
+        \hbox{%
+        \begin@FBBOX
+           \ifx \@empty#3\relax \else
+               \hbox{\caption@@@make
+                  {\caption@lfmt{\@nameuse{sub\@captype name}}%
+                  {\@nameuse{thesub\@captype}}\relax}{}}%
+        \fi
+        \end@FBBOX\hskip\labelsep\ignorespaces
+        \begin@FBBOX
+           \box\@tempboxa
+        \end@FBBOX
+        }%
+        \vskip\sf@bottom
+    \end@FBBOX
+    \@ifundefined{FBsc@max}{}%
+        {\addtocounter{FRobj}{-1}%
+         \ifnum\c@FRobj>0
+           \subfloatrowsep
+         \fi}%
+    \ifmaincaptiontop\else
+      \global\advance\@nameuse{c@\@captype}\m@ne
+    \fi
+  \endgroup\ignorespaces}
+\newcommand\subfloatlabel{\@ifnextchar[%]
+    {\flrow@subfloatlabel}{\subfloat[]{}}}
+\@ifdefinable\flrow@subfloatlabel{}
+\def\flrow@subfloatlabel[#1]{%
+  \ifx\@captype\@undefined
+    \@latex@error{\noexpand\subfloat outside float}\@ehd
+  \fi
+  \begingroup
+    \count@#1\advance\count@\m@ne
+    \csname c@sub\@captype\endcsname\count@\relax
+    \@ifnextchar[%]
+      {\flrow@@subfloatlabel[#1]}%
+      {\subfloat[]{}\endgroup}}
+\@ifdefinable\flrow@@subfloatlabel{}
+\@ifundefined{newseparatedlabel}\@tempswatrue\@tempswafalse
+\if@tempswa
+    \def\FRsf@Flabel{\label}
+\else
+    \newseparatedlabel\FRsf@Flabel{\@captype}{sub\@captype}
+\fi
+\def\flrow@@subfloatlabel[#1][#2]{%
+    \subfloat[]{\FRsf@Flabel{#2}}\endgroup}
+\endinput
+%%
+%% End of file `fr-subfig.sty'.
diff --git a/lastpage.sty b/lastpage.sty
new file mode 100644 (file)
index 0000000..c3ea955
--- /dev/null
@@ -0,0 +1,268 @@
+%%
+%% This is file `lastpage.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% lastpage.dtx  (with options: `package')
+%% 
+%% This is a generated file.
+%% 
+%% Project: lastpage
+%% Version: 2011/09/01 v1.2k
+%% 
+%% Copyright (C) 2010, 2011 by
+%%     H.-Martin M"unch <Martin dot Muench at Uni-Bonn dot de>
+%% Portions of code copyrighted by other people as marked.
+%% 
+%% The usual disclaimer applys:
+%% If it doesn't work right that's your problem.
+%% (Nevertheless, send an e-mail to the maintainer
+%%  when you find an error in this package.)
+%% 
+%% This work may be distributed and/or modified under the
+%% conditions of the LaTeX Project Public License, either
+%% version 1.3c of this license or (at your option) any later
+%% version. This version of this license is in
+%%    http://www.latex-project.org/lppl/lppl-1-3c.txt
+%% and the latest version of this license is in
+%%    http://www.latex-project.org/lppl.txt
+%% and version 1.3c or later is part of all distributions of
+%% LaTeX version 2005/12/01 or later.
+%% 
+%% This work has the LPPL maintenance status "maintained".
+%% 
+%% The Current Maintainer of this work is H.-Martin Muench.
+%% 
+%% This package was invented by Jeffrey P. Goldberg.
+%% I thought that a replacement was needed and therefore created the
+%% pageslts package,
+%% http://www.ctan.org/tex-archive/macros/latex/contrib/pageslts/pageslts.dtx
+%% or
+%% http://www.ctan.org/tex-archive/install/macros/latex/contrib/pageslts.tds.zip
+%% . Nevertheless, for compatibility with existing documents/packages as well as
+%% for the low amount of resources needed by the lastpage package (no new counter!),
+%% I updated this package.
+%% Thanks go to Jeffrey P. Goldberg for allowing me to do this.
+%% 
+%% This work consists of the main source file lastpage.dtx
+%% and the derived files
+%%    lastpage.sty, lastpage.pdf, lastpage.ins, lastpage.drv,
+%%    lastpage-example.tex.
+%% 
+\NeedsTeXFormat{LaTeX2e}[2011/06/27]
+\ProvidesPackage{lastpage}[2011/09/01 v1.2k
+            Refers to last page's name (HMM; JPG)]%
+
+%% lastpage may work with earlier versions of LaTeX,
+%% but this was not tested. Please consider updating
+%% your LaTeX (and packages) to the most recent version
+%% (if it is/they are not already the most recent version).
+
+%% Allows for things like
+%% Page \thepage\ of \pageref{LastPage}
+%% to get
+%% 'Page 7 of 9'.
+%% For LaTeX 2.09 use lastpage209.sty.
+%% For LaTeX 2e maybe consider upgrading to the pageslts package.
+%% lastpage may work with earlier versions of LaTeX2e,
+%% but this was not tested. Please consider updating your LaTeX
+%% contribution to the most recent version (if it is not already
+%% the most recent version).
+
+%% The recent version of the endfloat package is v2.4i as of 1995/10/11.
+%% The lastpage package is not fully compatible with version 2.0
+%% (and earlier) of the endfloat package, because those versions
+%% redefined the \enddocument command.
+
+\def\lastpage@one{1}
+\gdef\lastpage@hyper{0}
+\gdef\lastpage@LTS{0}
+\def\lastpage@firstpage{1}
+
+\AtBeginDocument{%
+  \@ifpackageloaded{tikz}{\gdef\lastpage@tikz{1}}{}%
+  \@ifpackageloaded{hyperref}{\gdef\lastpage@hyper{1}}{}%
+  \@ifpackageloaded{pageslts}{%
+    \PackageWarning{lastpage}{Package pageslts found.\MessageBreak%
+      Therefore the lastpage package is no longer\MessageBreak%
+      necessary.%
+      }%
+    \gdef\lastpage@LTS{1}%
+   }{\PackageInfo{lastpage}{%
+       Please have a look at the pageslts package at\MessageBreak%
+       http://www.ctan.org/tex-archive/ \MessageBreak%
+         macros/latex/contrib/pageslts/ \MessageBreak%
+       or\MessageBreak%
+       http://www.ctan.org/tex-archive/ \MessageBreak%
+         install/macros/latex/contrib/pageslts.tds.zip\MessageBreak%
+       !}%
+   }%
+  \@ifpackageloaded{pagesLTS}{%
+    \PackageWarning{lastpage}{%
+      Outdated pagesLTS package found.\MessageBreak%
+      Please replace by a recent version of\MessageBreak%
+      pageslts package, see e.g. at\MessageBreak%
+      http://www.ctan.org/tex-archive/ \MessageBreak%
+        macros/latex/contrib/pageslts/ \MessageBreak%
+      or\MessageBreak%
+      http://www.ctan.org/tex-archive/ \MessageBreak%
+        install/macros/latex/contrib/pageslts.tds.zip\MessageBreak%
+      !\MessageBreak%
+      With pagesLTS as well as pageslts package\MessageBreak%
+      the lastpage package is no longer necessary.\MessageBreak%
+     }%
+    \gdef\lastpage@LTS{1}%
+   }{}%
+  \gdef\lastpage@putlabel{\relax}%
+  }
+
+\newcommand{\lastpage@putl@bel}{%
+  \@ifundefined{Hy@Warning}{%  hyperref not loaded
+    }{\gdef\lastpage@hyper{1}% hyperref loaded
+     }%
+  \ifx\lastpage@LTS\lastpage@one%
+  \else%
+    \ifx\lastpage@hyper\lastpage@one%
+      \lastpage@putlabelhyper%
+    \else%
+      \begingroup
+        \addtocounter{page}{-1}%
+        \immediate\write\@auxout{\string\newlabel{LastPage}{{}{\thepage}}}%
+        \immediate\write\@auxout{\string\xdef\string\lastpage@lastpage{\thepage}}%
+        \immediate\write\@auxout{\string\gdef\string\lastpage@lastpageHy{}}%
+        \addtocounter{page}{+1}%
+      \endgroup
+    \fi%
+  \fi%
+  }
+
+\newcommand{\lastpage@putlabelhyper}{%
+  \ifHy@pageanchor%
+  \else%
+    \PackageError{lastpage}{hyperref option pageanchor disabled}{%
+      The \string\pageref{LastPage} link doesn't work\MessageBreak%
+      using hyperref with disabled option `pageanchor'.\MessageBreak%
+    }%
+  \fi%
+  \begingroup%
+    \addtocounter{page}{-1}%
+%% The following code is from the hyperref package          %%
+%% [2010/04/17 v6.80x; newer versions are available]        %%
+%% by Heiko Oberdiek (Big Thanks!).                         %%
+    \let\@number\@firstofone
+    \ifHy@pageanchor
+      \ifHy@hypertexnames
+        \ifHy@plainpages
+          \def\Hy@temp{\arabic{page}}%
+        \else
+          \Hy@unicodefalse
+%% Code not from hyperref package:                          %%
+%% The following lines are taken from the pageslts package, %%
+%% which in turn got them from the hyperref package and     %%
+%% modified them.                                           %%
+%% Without the modification, after the first shipout "PD1"  %%
+%% is inserted each time |\pdfstringdef\Hy@temp{\thepage}|  %%
+%% is executed.                                             %%
+          \ifnum \value{page}=1%
+            \ifx \lastpage@firstpage\lastpage@one
+              \def\Hy@temp{\thepage}%
+              \gdef\lastpage@firstpage{0}%
+            \else%
+%% Code from hyperref package again:                        %%
+                \pdfstringdef\Hy@temp{\thepage}%
+%% End of code from the hyperref package.                   %%
+          \fi%
+%% The pageslts package would even check for fnsymbol page  %%
+%% numbering scheme and adapt the code correspondingly.     %%
+          \else%
+%% Code from hyperref package again:                        %%
+            \pdfstringdef\Hy@temp{\thepage}%
+%% Code from pageslts package again:                        %%
+          \fi%
+%% Code from hyperref package again:                        %%
+        \fi
+      \else
+        \def\Hy@temp{\the\Hy@pagecounter}%
+      \fi
+    \fi
+    \immediate\write\@auxout{%
+      \string\newlabel
+        {LastPage}{{}{\thepage}{}{%
+          \ifHy@pageanchor page.\Hy@temp\fi}{}}%
+    }%
+%% End of code from the hyperref package.                   %%
+    \immediate\write\@auxout{%
+      \string\xdef\string\lastpage@lastpage{\thepage}}%
+    \ifHy@pageanchor%
+      \immediate\write\@auxout{%
+        \string\xdef\string\lastpage@lastpageHy{\Hy@temp}}%
+    \else%
+      \immediate\write\@auxout{%
+        \string\gdef\string\lastpage@lastpageHy{}}%
+    \fi%
+    \addtocounter{page}{+1}%
+  \endgroup
+  }
+
+\newcommand{\lastpage@fileswtest}[2]{%
+  \edef\lastpage@testa{#1}%
+  \edef\lastpage@testb{#2}%
+  \ifx\lastpage@testa\lastpage@testb% OK
+  \else%
+    \ifx\lastpage@tikz\lastpage@one%
+      \PackageWarning{lastpage}%
+       {The lastpage package was not allowed to write to an\MessageBreak%
+        .aux file. This package does not work without access\MessageBreak%
+        to an .aux file.\MessageBreak%
+       }%
+    \else%
+      \PackageError{lastpage}{No auxiliary file allowed}%
+       {The lastpage package was not allowed to write to an .aux file.\MessageBreak%
+        This package does not work without access to an .aux file.\MessageBreak%
+        Press Ctrl+Z to exit.\MessageBreak%
+       }%
+    \fi%
+  \fi%
+  }
+\newcommand{\lastpage@fileswtestHy}{%
+  \ifHy@pageanchor%
+    \lastpage@fileswtest{\Hy@temp}{\lastpage@lastpageHy}%
+  \else%
+    \lastpage@fileswtest{\empty}{\lastpage@lastpageHy}%
+  \fi%
+  }
+
+\AtEndDocument{%
+  \gdef\lastpage@putlabel{\relax}
+  \ifx\lastpage@LTS\lastpage@one%
+  \else%
+    \@ifundefined{lastpage@lastpage}%
+     {\gdef\lastpage@lastpage{LastpagePackageError}%
+     % If there really is a page numbered (!) "LastpagePackageError",
+     % you will get the rerun warning whether it is necessary or not.
+      \PackageWarning{lastpage}{Rerun to get the references right}%
+     }{% already defined, nothing to be done.
+     }%
+    \@ifundefined{lastpage@lastpageHy}%
+     {\gdef\lastpage@lastpageHy{LastpagePackageError}%
+     }{% already defined, nothing to be done.
+     }%
+  \fi%
+  \if@filesw%
+    \message{^^JAED: lastpage setting LastPage^^J}%
+    \clearpage\lastpage@putl@bel%
+  \else%
+    \ifx\lastpage@LTS\lastpage@one%
+    \else%
+      \lastpage@fileswtest{\thepage}{\lastpage@lastpage}%
+      \ifx\lastpage@hyper\lastpage@one%
+        \lastpage@fileswtestHy%
+      \fi%
+    \fi%
+  \fi%
+  }
+
+\endinput
+%%
+%% End of file `lastpage.sty'.
diff --git a/ltxnew.sty b/ltxnew.sty
new file mode 100644 (file)
index 0000000..f20b861
--- /dev/null
@@ -0,0 +1,198 @@
+%%
+%% This is file `ltxnew.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% ltxnew.dtx  (with options: `package')
+%% 
+%% This is a generated file.
+%% 
+%% ltxnew : provides the \new \renew and \provide prefixes for checking definitions.
+%% 
+%% This work may be distributed and/or modified under the
+%% conditions of the LaTeX Project Public License, either
+%% version 1.3 of this license or (at your option) any later
+%% version. The latest version of this license is in
+%%    http://www.latex-project.org/lppl.txt
+%% 
+%% This work consists of the main source file ltxnew.dtx
+%% and the derived files
+%%    ltxnew.sty, ltxnew.pdf, ltxnew.ins,
+%% 
+%% ltxnew : provides the \new \renew and \provide prefixes for checking definitions
+%% Copyright (C) 2009-2010 by Florent Chervet <florent.chervet@free.fr>
+%% 
+
+\NeedsTeXFormat{LaTeX2e}% LaTeX 2.09 can't be used (nor non-LaTeX)
+   [2005/12/01]% LaTeX must be 2005/12/01 or younger (see kvsetkeys.dtx).
+\ProvidesPackage{ltxnew}
+   [2011/03/02 v1.3 provides the new and renew prefixes for checking definitions]
+
+\RequirePackage{etex}
+
+% \ltxn@expandonce is the copy of \expandonce from etoolbox.sty
+\def\ltxn@expandonce#1{\unexpanded\expandafter{#1}}
+
+% This is the entry point of the prefixes scanner:
+% The whole job is done by \futurelet
+\def\ltxn@prefix{\begingroup
+   \newif\ifglobal
+   \let\ltxn@prfx\@empty
+   \let\ltxn@rubbish\relax
+   \futurelet\x\ltxn@@prefix}
+% Here is the test macro: testing each prefix token one after another:
+% It consists in a long list of \ifx
+\def\ltxn@@prefix{%
+   \let\ltxn@next@addto\ltxn@next@prefix
+   \ifx\x\@sptoken         \let\next\ltxn@space@prefix%%1
+   \else                   \let\next\ltxn@addto@prfx
+      \ifx\x\long          \def\z{\long}%%2
+      \else\ifx\x\protected\def\z{\protected}%%3
+      \else\ifx\x\global   \let\z\@empty\globaltrue%%4
+      \else\ifx\x\outer    \def\z{\outer}%%5
+      \else
+         \ifx\x\expandafter \def\z{\expandafter}%%6
+         \else\ifx\x\noexpand    \def\z{\noexpand}%%7
+         \else\ifx\x\relax       \def\z{\relax}%%8
+         \else
+                  \def\ltxn@next@addto{\expandafter\ltxn@def\noexpand}%
+            \ifx\x\let              \def\z{\let}%%9
+                                    \let\ltxn@cancel\ltxn@cancel@let
+            \else                   \let\ltxn@cancel\ltxn@cancel@def
+               \ifx\x\def           \edef\z{\ifglobal\global\fi\def}%%10
+               \else\ifx\x\edef     \edef\z{\ifglobal\global\fi\edef}%%11
+               \else\ifx\x\gdef     \def\z{\gdef}%%12
+               \else\ifx\x\xdef     \def\z{\xdef}%%13
+               \else                \let\ltxn@cancel\ltxn@cancel@new
+                  \ifx\x\count       \def\z{\newcount}%%14
+                  \else\ifx\x\countdef%%15
+                     \ifglobal\def\z{\globcount}\else\def\z{\loccount}\fi
+                  \else\ifx\x\loccount%%16
+                     \ifglobal\def\z{\globcount}\else\def\z{\loccount}\fi
+                  \else\ifx\x\globcount   \def\z{\globcount}%%17
+                  \else\ifx\x\dimen       \def\z{\newdimen}%%18
+                  \else\ifx\x\dimendef%%19
+                     \ifglobal\def\z{\globdimen}\else\def\z{\locdimen}\fi
+                  \else\ifx\x\locdimen%%20
+                     \ifglobal\def\z{\globdimen}\else\def\z{\locdimen}\fi
+                  \else\ifx\x\globdimen   \def\z{\globdimen}%%21
+                  \else\ifx\x\skip        \def\z{\newskip}%%22
+                  \else\ifx\x\skipdef%%23
+                     \ifglobal\def\z{\globskip}\else\def\z{\locskip}\fi
+                  \else\ifx\x\locskip%%24
+                     \ifglobal\def\z{\globskip}\else\def\z{\locskip}\fi
+                  \else\ifx\x\globskip    \def\z{\globskip}%%25
+                  \else\ifx\x\muskip      \def\z{\newmuskip}%%26
+                  \else\ifx\x\muskipdef%%27
+                     \ifglobal\def\z{\globmuskip}\else\def\z{\locmuskip}\fi
+                  \else\ifx\x\locmuskip%%28
+                     \ifglobal\def\z{\globmuskip}\else\def\z{\locmuskip}\fi
+                  \else\ifx\x\globmuskip  \def\z{\globmuskip}%%29
+                  \else\ifx\x\savebox     \def\z{\newsavebox}%%30
+                  \else\ifx\x\box%%31
+                     \ifglobal\def\z{\globbox}\else\def\z{\locbox}\fi
+                  \else\ifx\x\locbox%%§32
+                     \ifglobal\def\z{\globbox}\else\def\z{\locbox}\fi
+                  \else\ifx\x\globbox     \def\z{\globbox}%%33
+                  \else\ifx\x\toksdef%%34
+                     \ifglobal\def\z{\globtoks}\else\def\z{\loctoks}\fi
+                  \else\ifx\x\toks        \def\z{\newtoks}%%35
+                  \else\ifx\x\loctoks%%36
+                     \ifglobal\def\z{\globtoks}\else\def\z{\loctoks}\fi
+                  \else\ifx\x\globtoks    \def\z{\globtoks}%%37
+                  \else\ifx\x\locmarks%%38
+                     \ifglobal\def\z{\globmarks}\else\def\z{\locmarks}\fi
+                  \else\ifx\x\marks       \def\z{\newmarks}%%39   %\newmarks=\globmarks
+                  \else\ifx\x\globmarks   \def\z{\globmarks}%%40
+                  \else\ifx\x\font        \def\z{\font}%%41
+                  \else\ifx\x\write       \def\z{\newwrite}%%42
+                  \else\ifx\x\read        \def\z{\newread}%%43
+                  \else\ifx\x\char        \def\z{\chardef}%%44
+                  \else\ifx\x\chardef     \def\z{\chardef}%%45
+                  \else\ifx\x\mathchar    \def\z{\mathchardef}%%46
+                  \else\ifx\x\mathchardef \def\z{\mathchardef}%%47
+                  \else\ifx\x\protect     \ltxn@error@prefix%%48
+                  \else
+                     \let\ltxn@next@addto\ltxn@next@prefix
+                     \ifx\y\x\ltxn@error@prefix
+                     \else\let\y\x
+                     \fi
+                     \let\next\ltxn@expand@prefix
+                  \fi\fi\fi\fi\fi\fi\fi\fi\fi\fi
+                  \fi\fi\fi\fi\fi\fi\fi\fi\fi\fi
+                  \fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi
+               \fi\fi\fi\fi\fi\fi\fi\fi
+            \fi
+         \fi\fi\fi
+      \fi\fi\fi\fi% so many fees...
+   \fi\next}
+\def\ltxn@next@prefix{\futurelet\x\ltxn@@prefix}
+\def\ltxn@expand@prefix{%
+   \expandafter\futurelet\expandafter\x\expandafter\ltxn@@prefix}
+\def\ltxn@addto@prfx#1{\let\y\@undefined
+   \expandafter\expandafter\expandafter\def
+      \expandafter\expandafter\expandafter\ltxn@prfx
+         \expandafter\expandafter\expandafter{\expandafter\ltxn@prfx\z}%
+   \ltxn@next@addto}
+\expandafter\def\expandafter\ltxn@space@prefix\space{\ltxn@next@prefix}
+\def\ltxn@error@prefix{\@latex@error{A \string\def\space
+   (or \string\countdef\space or\string\toksdef\space etc.)\MessageBreak
+   was expected after \string\new\MessageBreak
+   I found a \meaning\x!\MessageBreak
+   see ltxnew documentation for more information}\@ehd}
+
+% These are the macros used in case we have to cancel definition (nonstopmode)
+% #1 is always the control sequence not to redefine
+\def\ltxn@cancel@let{\afterassignment\endgroup\let\ltxn@rubbish}
+\def\ltxn@cancel@def{\afterassignment\endgroup\def\ltxn@rubbish}
+\def\ltxn@cancel@new{\endgroup}
+
+% new: Do define or cancel, depending on the result of \@ifdefinable
+\def\ltxn@new#1{%
+   \let\next\ltxn@cancel
+   \ifdefined#1\unless\ifx#1\relax\def#1{new:error}\fi\fi
+   \expandafter\@ifdefinable\noexpand#1{%
+      \expandafter\let\noexpand#1=\relax
+      \edef\next{\endgroup\ltxn@expandonce\ltxn@prfx#1}}%
+   \next}
+
+
+% renew: Throws an error in case the control sequence is unknown or \relax
+\def\ltxn@renew#1{%
+   \edef\ltxn@name{\string#1}%
+   \ifdefined#1\ifx#1\relax\ltxn@error{renew: \ltxn@name\space undefined}\fi
+   \else       \ltxn@error{renew: \ltxn@name\space undefined}%
+   \fi
+   \let#1=\relax
+   \def\next{\ltxn@new#1}%
+   \next}
+
+% provide: Never throw an error but conditionally defines the control sequence
+\def\ltxn@provide#1{%
+   \let\next\ltxn@cancel
+   \edef\ltxn@name{\string#1}%
+   \ifdefined#1\ifx#1\relax \ltxn@provide@new\fi
+   \else \ltxn@provide@new
+   \fi
+   \next}
+\def\ltxn@provide@new{%
+   \edef\next{\noexpand\ltxn@new\csname\expandafter\@gobble\ltxn@name\endcsname}}
+
+% \new: the entry point:
+%       just let the definition macro to be \ltxn@new and start scanning prefixes.
+\protected\def\new{\let\ltxn@def\ltxn@new\ltxn@prefix}
+
+% \renew: the entry point:
+%         just let the definition macro to be \ltxn@renew and start scanning prefixes.
+\protected\def\renew{\let\ltxn@def\ltxn@renew\ltxn@prefix}
+
+% \provide: the entry point:
+%           just let the definition macro to be |\ltxn@provide| and start scanning prefixes.
+\protected\def\provide{\let\ltxn@def\ltxn@provide\ltxn@prefix}
+
+% In case of redefinition, throws an |\ehc|-type error:
+\def\ltxn@error#1{\@latex@error{#1}\@ehc}
+\endinput
+%%
+%% End of file `ltxnew.sty'.
diff --git a/pagerange.sty b/pagerange.sty
new file mode 100644 (file)
index 0000000..c6be878
--- /dev/null
@@ -0,0 +1,237 @@
+%+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++%
+% This is file 'pagerange.sty', version 0.5.                                %
+%                                                                           %
+% This work may be distributed and/or modified under the conditions         %
+% of the LaTeX Project Public License, either version 1.3 of this           %
+% license or any later version. The latest version of this license          %
+% is in http://www.latex-project.org/lppl.txt and version 1.3 or later      %
+% is part of all distributions of LaTeX version 2005/12/01 or later.        %
+%                                                                           %
+% The LPPL maintenance status of this software is 'author-maintained'.      %
+%                                                                           %
+% This software is provided 'as it is', without warranty of any kind,       %
+% either expressed or implied, including, but not limited to, the           %
+% implied warranties of merchantability and fitness for a particular        %
+% purpose.                                                                  %
+%                                                                           %
+% Copyright (c) 2010 Ahmed Musa (a.musa@rocketmail.com).                    %
+%+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++%
+\begingroup
+\catcode064 11\relax% @
+\catcode123 01\relax% {
+\catcode125 02\relax% }
+\def\prg@tempa{\endgroup
+  \edef\prg@restorecodes{%
+    \catcode035 \the\catcode035\relax% #
+    \catcode064 \the\catcode064\relax% @
+    \catcode123 \the\catcode123\relax% {
+    \catcode125 \the\catcode125\relax% }
+    \catcode061 \the\catcode061\relax% =
+    \catcode038 \the\catcode038\relax% &
+  }%
+}
+\prg@tempa
+\catcode061 12\relax% =
+\catcode035 06\relax% #
+\catcode064 11\relax% @
+\catcode123 01\relax% {
+\catcode125 02\relax% }
+\catcode038 03\relax% &
+\AtEndOfPackage{\prg@restorecodes}
+\ProvidesPackage{pagerange}%
+  [2010/02/04 v0.5 Split page ranges intelligently (Ahmed Musa)]
+\NeedsTeXFormat{LaTeX2e}[1996/12/01]
+\@ifpackageloaded{lastpage}{}{\RequirePackage{lastpage}[1994/06/25]}
+\@ifpackageloaded{xkeyval}{}{\RequirePackage{xkeyval}[2008/08/13]}
+\ifcase0%
+  \ifx\eTeXversion\@undefined 1\else\ifnum\eTeXversion<\tw@ 1\fi\fi
+\else
+  \@latex@error{eTeX not loaded or old version.\MessageBreak
+    This package requires eTeX version 2 or later.}\@ehc
+\fi
+\newcommand*\prg@ifdefinable[1]{%
+  \edef\reserved@a{\expandafter\@gobble\string#1}%
+  \begingroup
+  \ifdefined#1%
+    \aftergroup\@notdefinable
+  \else
+    \edef\reserved@b{\expandafter\@carcube\reserved@a xxx\@nil}%
+    \ifx\reserved@b\@qend
+      \aftergroup\@notdefinable
+    \else
+      \ifx\reserved@a\@qrelax
+        \aftergroup\@notdefinable
+      \else
+        \aftergroup\@firstofone
+      \fi
+    \fi
+  \fi
+  \endgroup
+}
+\prg@ifdefinable\prg@protect@relax\relax
+\prg@ifdefinable\prg@star@or@long\relax
+\prg@ifdefinable\prg@pdef\relax
+\prg@ifdefinable\prg@@def\relax
+\def\prg@star@or@long#1{%
+  \@ifstar{\let\prg@protect@relax\protected#1}%
+    {\def\prg@protect@relax{\protected\long}#1}%
+}
+\let\prg@protect@relax\protected
+\protected\def\prg@pdef{\prg@star@or@long\prg@@def}
+\def\prg@@def#1{\prg@ifdefinable#1{\prg@protect@relax\def#1}}
+\prg@pdef\prg@warn#1{\PackageWarningNoLine{pagerange}{#1}}
+\prg@pdef\prg@err#1{\PackageError{pagerange}{#1}\@ehc}
+\prg@ifdefinable\prg@tempcnta{\newcount\prg@tempcnta}
+\prg@ifdefinable\prg@tempcntb{\newcount\prg@tempcntb}
+\prg@ifdefinable\prg@tempcntc{\newcount\prg@tempcntc}
+\def\prg@c@r#1#2{%
+  \unless\ifx#2\null
+    \prg@err{Inadmissible multiple arguments '\string#1\string#2'
+      \MessageBreak for '\string\prg@ifdef' test}%
+  \fi
+}
+\prg@ifdefinable\prg@ifdef\relax
+\def\prg@ifdef#1{%
+  \prg@c@r#1\null
+  \csname @\ifdefined#1\expandafter first\else
+    \expandafter second\fi oftwo\endcsname
+}
+\prg@ifdefinable\prg@ifundef\relax
+\def\prg@ifundef#1{%
+  \prg@ifdef{#1}{\csname @\ifx#1\relax\expandafter first\else
+    \expandafter second\fi oftwo\endcsname}{\@firstoftwo}%
+}
+\def\prg@ifcsundef#1{\expandafter\prg@ifundef\csname#1\endcsname}
+\prg@pdef*\prg@check@ifdef#1{%
+  \prg@ifcsundef{#1}{}{%
+    \prg@err{\expandafter\noexpand\csname#1\endcsname already defined}%
+  }%
+  \prg@check@ifdef
+}
+\prg@check@ifdef{pagerange}{pagestart}{pageend}{getpagenumber}%
+  {pagerangeoptions}\iffalse\fi\fi\endcsname{}{}
+\prg@pdef\prg@ifblank#1{\prg@ifbl@nk#1&&\@secondoftwo\@firstoftwo:}
+\long\def\prg@ifbl@nk#1#2&#3#4#5:{#4}
+\prg@pdef\prg@xifblank#1{\begingroup
+  \protected@edef\prg@tempa{\endgroup\noexpand\prg@ifblank{#1}}%
+  \prg@tempa
+}
+\prg@pdef\prg@ifmacro#1{%
+  \begingroup
+  \edef\prg@tempa{\endgroup
+    \def\noexpand\getparameter####1\detokenize{macro}:####2&{%
+      \noexpand\prg@ifblank{####2}{\noexpand\@secondoftwo}%
+        {\noexpand\@firstoftwo}%
+    }%
+    \noexpand\expandafter\noexpand\getparameter%
+    \noexpand\meaning\noexpand#1\detokenize{macro}:&%
+  }\prg@tempa
+}
+\def\prg@ismacro@err#1{%
+  \prg@err{%
+    Illegal tie '#1'.\MessageBreak
+    Note that the 'tie' has been expanded once\MessageBreak
+    and may be different from what you submitted.\MessageBreak
+    Perhaps you've used an active character as 'tie'
+  }%
+}
+\define@cmdkey[KV]{pagerange}[prg@]{tie}[-]{%
+  \edef\@tempa{\expandafter\noexpand\prg@tie}%
+  \edef\prg@tie{\prg@tie}%
+  \let\@@protect\protect\let\protect\@empty
+  \expandafter\prg@ifmacro\expandafter{\prg@tie}{%
+    \restore@protect\prg@ismacro@err\@tempa
+  }{}%
+  \restore@protect
+}
+\define@boolkey[KV]{pagerange}[prg@]{acceptempty}[true]{}
+\define@cmdkey[KV]{pagerange}[prg@]{defaultfirstpage}[1]{}
+\define@cmdkey[KV]{pagerange}[prg@]{defaultlastpage}%
+  [\getpagenumber{LastPage}]{}
+\DeclareOptionX*{\prg@warn{Unknown option '\CurrentOption' ignored}}
+\ExecuteOptionsX<pagerange>{tie,defaultfirstpage,defaultlastpage}
+\ProcessOptionsX*<pagerange>\relax
+\long\def\pagerangeoptions#1{\setkeys[KV]{pagerange}{#1}}
+\prg@pdef\prg@forall#1#2\do#3{%
+  #3{#1}%
+  \expandafter\ifx\expandafter\@empty\detokenize{#2}\@empty%
+    \relax
+  \else
+    \prg@forall#2\do{#3}%
+  \fi
+}
+\let\pagestart\@empty
+\let\pageend\@empty
+\prg@tempcntc=\z@
+\prg@pdef*\prg@split@pagerange#1{%
+  \def\reserved@a{#1}%
+  \ifx\reserved@a\prg@tie
+    \advance\prg@tempcntc\@ne
+  \fi
+  \ifnum\prg@tempcntc=\z@
+    \g@addto@macro\pagestart{#1}%
+  \else\ifnum\prg@tempcntc=\@ne
+    \ifx\reserved@a\prg@tie\else
+      \g@addto@macro\pageend{#1}%
+    \fi
+  \else\ifnum\prg@tempcntc>\@ne
+    \prg@err{Multiple ties in page range.\MessageBreak
+      Please use only one tie}%
+  \fi\fi\fi
+}
+\prg@tempcnta=\z@\prg@tempcntb=\z@
+\def\pagerange#1{%
+  \let\pagestart\@empty
+  \let\pageend\@empty
+  \prg@tempcntc=\z@
+  \prg@xifblank{#1}{%
+    \ifprg@acceptempty
+      \prg@warn{Blank page range supplied:\MessageBreak
+        I've therefore set the range as 1-1 and continued}
+      \let\pagestart\prg@defaultfirstpage
+      \let\pageend\prg@defaultlastpage
+    \else
+      \prg@err{Blank page range.\MessageBreak
+        If you really mean blank pagerange,\MessageBreak
+        then also use 'acceptempty' boolean option
+      }%
+    \fi
+  }{%
+    \begingroup\edef\prg@tempa{\endgroup%
+      \prg@forall#1\noexpand\do{\prg@split@pagerange}}%
+    \prg@tempa
+  }%
+  \ifx\@empty\pagestart
+    \ifnum\prg@tempcntc=\@ne
+      \let\pagestart\prg@defaultfirstpage
+    \fi
+  \fi
+  \prg@tempcnta=\number\pagestart\relax
+  \ifx\@empty\pageend
+    \prg@tempcntb=\@M
+    \ifnum\prg@tempcntc=\@ne
+      \let\pageend\prg@defaultlastpage
+    \fi
+  \else
+    \prg@tempcntb=\number\pageend\relax
+  \fi
+  \ifnum\prg@tempcnta>\prg@tempcntb
+    \prg@err{Inconsistent page range: Page \pageend\space > \pagestart}%
+  \fi
+}
+\def\prg@carr#1#2#3\@nil{%
+  \expandafter\ifx\expandafter\relax\detokenize{#3}\relax
+    \prg@err{Problem with page reference}
+  \fi
+  #2%
+}
+\def\getpagenumber#1{%
+  \prg@ifcsundef{r@#1}{\prg@defaultfirstpage}{%
+    \expandafter\expandafter\expandafter\prg@carr
+    \csname r@#1\endcsname\prg@defaultfirstpage\@nil
+  }%
+}
+
+\endinput
+
+%%% End of file pagerange.sty %%%
\ No newline at end of file
diff --git a/template.tex b/template.tex
new file mode 100644 (file)
index 0000000..0ef97e7
--- /dev/null
@@ -0,0 +1,83 @@
+%%
+%% This is file `template.tex',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% drexel-thesis.dtx  (with options: `template')
+%% 
+%% This is a generated file.
+%% 
+%% Copyright (C) 2010-2012 W. Trevor King
+%% 
+%% This file may be distributed and/or modified under the conditions of
+%% the LaTeX Project Public License, either version 1.3 of this license
+%% or (at your option) any later version.  The latest version of this
+%% license is in:
+%% 
+%%    http://www.latex-project.org/lppl.txt
+%% 
+%% and version 1.3 or later is part of all distributions of LaTeX version
+%% 2003/06/01 or later.
+%% 
+\documentclass{drexel-thesis}
+
+%% Enter the appropriate information here
+\author{}    % Fullname
+\title{}     % Title Of Thesis
+\DUTmonth{}  % Name of the month of you defense
+\DUTyear{}   % Year you are defending
+\degree{}    % Your target degree, spelled out
+\advisor{}   % Advisor's full name, degree
+\copyrighttext{} % If not "All Rights Reserved."
+
+%% unsrt style give references in order of citation
+\bibliographystyle{unsrt}
+
+\begin{document}
+\begin{preamble}
+
+\begin{dedications} % OPTIONAL
+%% Type dedications here
+\end{dedications}
+
+\begin{acknowledgments} % OPTIONAL
+%% Type acknowledgments here
+\end{acknowledgments}
+
+\tableofcontents
+\listoftables  % If you have tables
+\listoffigures % If you have figures
+
+\begin{abstract}
+%% Type abstract here
+\end{abstract}
+\end{preamble}
+
+\begin{thesis}
+%% If your thesis does not use \part{}s, you may want to add a
+%% part-level PDF bookmark to set the main matter of from the front
+%% matter.
+%%\pdfbookmark[-1]{Main Matter}{Main Matter}
+
+%% Use include statements to include your main thesis code
+%% from seperate files.
+%%\include{part1}
+%%...
+\end{thesis}
+
+\bibliography{references} % Include references.bib BibTeX
+
+\appendix % If you have appendices
+%% include files with your appendicies (if any) here
+%%\include{appendixA}
+%%...
+
+\begin{vita} % Ph.D. only.
+%%Vita text.
+\end{vita}
+
+\end{document}
+\endinput
+%%
+%% End of file `template.tex'.
diff --git a/tocloft.sty b/tocloft.sty
new file mode 100644 (file)
index 0000000..64f4bee
--- /dev/null
@@ -0,0 +1,1100 @@
+%%
+%% This is file `tocloft.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% tocloft.dtx  (with options: `usc')
+%% 
+%%   Author: Peter Wilson, Herries Press
+%%   Maintainer: Will Robertson (will dot robertson at latex-project dot org)
+%%   Maintainer: Will Robertson (will dot robertson at latex-project dot org)
+%%   Copyright 1998-2003 Peter R. Wilson
+%%   Copyright 2009 Will Robertson
+%% 
+%%   This work may be distributed and/or modified under the
+%%   conditions of the LaTeX Project Public License, either
+%%   version 1.3c of this license or (at your option) any
+%%   later version: <http://www.latex-project.org/lppl.txt>
+%% 
+%%   This work has the LPPL maintenance status "maintained".
+%%   The Current Maintainer of this work is Will Robertson.
+%% 
+%%   This work consists of the files listed in the README file.
+%% 
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesPackage{tocloft}[2010/10/13 v2.3e parameterised ToC, etc., typesetting]
+\newcommand{\@cftquit}{}
+\newif\if@cfthaschapter
+\newif\if@cftkoma
+  \@cftkomafalse
+\@ifclassloaded{scrartcl}{\@cftkomatrue}{}
+\@ifclassloaded{scrreprt}{\@cftkomatrue}{}
+\@ifclassloaded{scrbook}{\@cftkomatrue}{}
+
+\@ifundefined{chapter}{%
+  \@cfthaschapterfalse
+  \@ifundefined{section}{%
+    \PackageWarning{tocloft}%
+      {I don't recognize any sectional divisions so I'll do nothing}
+    \renewcommand{\@cftquit}{\endinput}
+    }{\PackageInfo{tocloft}{The document has section divisions}}
+  }{\@cfthaschaptertrue
+    \PackageInfo{tocloft}{The document has chapter divisions}}
+\@cftquit
+\newif\if@cfttocbibind
+\AtBeginDocument{%
+  \@ifpackageloaded{tocbibind}{\@cfttocbibindtrue}{\@cfttocbibindfalse}
+  \if@cfttocbibind
+    \@ifpackagelater{tocbibind}{1998/11/16}{}{%
+      \PackageWarning{tocloft}{%
+You are using a version of the tocbibind package\MessageBreak
+that is not compatible with tocloft.\MessageBreak
+The results may be surprising.\MessageBreak
+Consider installing the current version of tocbibind.}}
+  \fi
+}
+\newif\if@cftnctoc\@cftnctocfalse
+\DeclareOption{titles}{\@cftnctoctrue}
+  %% \ProcessOptions\relax
+\newif\if@cftsubfigopt\@cftsubfigoptfalse
+\DeclareOption{subfigure}{\@cftsubfigopttrue}
+
+\ProcessOptions\relax
+
+\newcommand{\tocloftpagestyle}[1]{%
+  \def\@cftpagestyle{\thispagestyle{#1}}}
+\tocloftpagestyle{plain}
+
+\newcommand{\cftmarktoc}{%
+  \@mkboth{\MakeUppercase\contentsname}{\MakeUppercase\contentsname}}
+\newcommand{\cftmarklof}{%
+  \@mkboth{\MakeUppercase\listfigurename}{\MakeUppercase\listfigurename}}
+\newcommand{\cftmarklot}{%
+  \@mkboth{\MakeUppercase\listtablename}{\MakeUppercase\listtablename}}
+\if@cftkoma
+  \renewcommand{\cftmarktoc}{%
+    \@mkboth{\contentsname}{\contentsname}}
+  \renewcommand{\cftmarklof}{%
+    \@mkboth{\listfigurename}{\listfigurename}}
+  \renewcommand{\cftmarklot}{%
+    \@mkboth{\listtablename}{\listtablename}}
+\fi
+\providecommand{\@cfttocstart}{%
+  \if@cfthaschapter
+    \if@twocolumn
+      \@restonecoltrue\onecolumn
+    \else
+      \@restonecolfalse
+    \fi
+  \fi}
+\providecommand{\@cfttocfinish}{%
+  \if@cfthaschapter
+    \if@restonecol\twocolumn\fi
+  \fi}
+\providecommand{\phantomsection}{}
+
+\newcommand{\@cftdobibtoc}{%
+  \if@dotoctoc
+    \if@bibchapter
+      \phantomsection
+      \addcontentsline{toc}{chapter}{\contentsname}
+    \else
+      \phantomsection
+      \addcontentsline{toc}{\@tocextra}{\contentsname}
+    \fi
+  \fi}
+
+\newlength{\cftparskip}
+\setlength{\cftparskip}{0pt}
+
+\AtBeginDocument{%
+\if@cftnctoc\else
+  \renewcommand{\tableofcontents}{%
+    \@cfttocstart
+    \par
+    \begingroup
+      \parindent\z@ \parskip\cftparskip
+      \@cftmaketoctitle
+      \if@cfttocbibind
+        \@cftdobibtoc
+      \fi
+      \@starttoc{toc}%
+    \endgroup
+    \@cfttocfinish}
+\fi
+}
+\newcommand{\@cftmaketoctitle}{%
+  \addpenalty\@secpenalty
+  \if@cfthaschapter
+    \vspace*{\cftbeforetoctitleskip}
+  \else
+    \vspace{\cftbeforetoctitleskip}
+  \fi
+  \@cftpagestyle
+  {\interlinepenalty\@M
+  {\cfttoctitlefont\contentsname}{\cftaftertoctitle}
+  \cftmarktoc
+  \par\nobreak
+  \vskip \cftaftertoctitleskip
+  \@afterheading}}
+\newlength{\cftbeforetoctitleskip}
+\newlength{\cftaftertoctitleskip}
+\if@cfthaschapter
+  \setlength{\cftbeforetoctitleskip}{50pt}
+  \setlength{\cftaftertoctitleskip}{40pt}
+\else
+  \setlength{\cftbeforetoctitleskip}{3.5ex \@plus 1ex \@minus .2ex}
+  \setlength{\cftaftertoctitleskip}{2.3ex \@plus.2ex}
+\fi
+\if@cfthaschapter
+  \newcommand{\cfttoctitlefont}{\normalfont\Huge\bfseries}
+  \if@cftkoma\renewcommand{\cfttoctitlefont}{\size@chapter\sectfont}\fi
+\else
+  \newcommand{\cfttoctitlefont}{\normalfont\Large\bfseries}
+  \if@cftkoma\renewcommand{\cfttoctitlefont}{\size@section\sectfont}\fi
+\fi
+\newcommand{\cftaftertoctitle}{}
+\newcommand{\cftsetpnumwidth}[1]{\renewcommand{\@pnumwidth}{#1}}
+\newcommand{\cftsetrmarg}[1]{\renewcommand{\@tocrmarg}{#1}}
+\providecommand{\cftdot}{.}
+\providecommand{\cftdotfill}[1]{%
+  \leaders\hbox{$\m@th\mkern #1 mu\hbox{\cftdot}\mkern #1 mu$}\hfill}
+\providecommand{\cftdotsep}{4.5}
+\newcommand{\cftnodots}{10000}
+\newcommand{\cftparfillskip}{\parfillskip=0pt plus1fil}
+\renewcommand{\numberline}[1]{%
+  \hb@xt@\@tempdima{\@cftbsnum #1\@cftasnum\hfil}\@cftasnumb}
+\newcommand{\@cftbsnum}{}
+\newcommand{\@cftasnum}{}
+\newcommand{\@cftasnumb}{}
+\newif\if@cftdopart
+\newif\if@cfthaspart
+\@ifundefined{part}{\@cfthaspartfalse}{\@cfthasparttrue}
+\if@cfthaspart
+\renewcommand*{\l@part}[2]{%
+  \@cftdopartfalse
+  \ifnum \c@tocdepth >-2\relax
+    \if@cfthaschapter
+      \@cftdoparttrue
+    \fi
+    \ifnum \c@tocdepth >\m@ne
+      \if@cfthaschapter\else
+        \@cftdoparttrue
+      \fi
+    \fi
+  \fi
+  \if@cftdopart
+    \if@cfthaschapter
+      \addpenalty{-\@highpenalty}%
+    \else
+      \addpenalty\@secpenalty
+    \fi
+    \addvspace{\cftbeforepartskip}%
+    \begingroup
+      {\leftskip \cftpartindent\relax
+       \rightskip \@tocrmarg
+       \parfillskip -\rightskip
+       \parindent \cftpartindent\relax\@afterindenttrue
+       \interlinepenalty\@M
+       \leavevmode
+       \@tempdima \cftpartnumwidth\relax
+       \let\@cftbsnum \cftpartpresnum
+       \let\@cftasnum \cftpartaftersnum
+       \let\@cftasnumb \cftpartaftersnumb
+       \advance\leftskip \@tempdima \null\nobreak\hskip -\leftskip
+       {\cftpartfont \cftpartpresnum #1}%
+       \cftpartfillnum{#2}}
+      \nobreak
+      \if@cfthaschapter
+        \global\@nobreaktrue
+        \everypar{\global\@nobreakfalse\everypar{}}%
+      \else
+        \if@compatibility
+          \global\@nobreaktrue
+          \everypar{\global\@nobreakfalse\everypar{}}%
+        \fi
+      \fi
+    \endgroup
+  \fi}
+\fi
+\if@cfthaspart
+  \newlength{\cftbeforepartskip}
+    \setlength{\cftbeforepartskip}{2.25em \@plus\p@}
+  \newlength{\cftpartnumwidth}
+    \setlength{\cftpartnumwidth}{0em}
+  \newcommand{\cftpartfont}{\large\bfseries}
+  \newcommand{\cftpartpresnum}{}
+  \newcommand{\cftpartaftersnum}{}
+  \newcommand{\cftpartaftersnumb}{}
+  \newcommand{\cftpartleader}{\large\bfseries\cftdotfill{\cftpartdotsep}}
+  \newcommand{\cftpartdotsep}{\cftnodots}
+  \newcommand{\cftpartpagefont}{\large\bfseries}
+  \newcommand{\cftpartafterpnum}{}
+  \newlength{\cftpartindent}
+    \setlength{\cftpartindent}{0em}
+  \newcommand{\cftpartfillnum}[1]{%
+    {\cftpartleader}%
+    {\hb@xt@\@pnumwidth{\hss {\cftpartpagefont #1}}}\cftpartafterpnum\par}
+  \if@cftkoma
+    \setlength{\cftpartnumwidth}{2em}
+    \renewcommand{\cftpartfont}{\sectfont\large}
+    \renewcommand{\cftpartpagefont}{\sectfont\large}
+  \fi
+\fi
+
+\if@cfthaschapter
+\renewcommand*{\l@chapter}[2]{%
+  \ifnum \c@tocdepth >\m@ne
+    \addpenalty{-\@highpenalty}%
+    \vskip \cftbeforechapskip
+    {\leftskip \cftchapindent\relax
+     \rightskip \@tocrmarg
+     \parfillskip -\rightskip
+     \parindent \cftchapindent\relax\@afterindenttrue
+     \interlinepenalty\@M
+     \leavevmode
+     \@tempdima \cftchapnumwidth\relax
+     \let\@cftbsnum \cftchappresnum
+     \let\@cftasnum \cftchapaftersnum
+     \let\@cftasnumb \cftchapaftersnumb
+     \advance\leftskip \@tempdima \null\nobreak\hskip -\leftskip
+     {\cftchapfont #1}\nobreak
+     \cftchapfillnum{#2}}%
+  \fi}%
+\fi
+\if@cfthaschapter
+  \newlength{\cftbeforechapskip}
+    \setlength{\cftbeforechapskip}{1.0em \@plus\p@}
+  \newlength{\cftchapindent}
+    \setlength{\cftchapindent}{0em}
+  \newlength{\cftchapnumwidth}
+    \setlength{\cftchapnumwidth}{1.5em}
+  \newcommand{\cftchapfont}{\bfseries}
+  \newcommand{\cftchappresnum}{}
+  \newcommand{\cftchapaftersnum}{}
+  \newcommand{\cftchapaftersnumb}{}
+  \newcommand{\cftchapleader}{\bfseries\cftdotfill{\cftchapdotsep}}
+  \newcommand{\cftchapdotsep}{\cftnodots}
+  \newcommand{\cftchappagefont}{\bfseries}
+  \newcommand{\cftchapafterpnum}{}
+  \newcommand{\cftchapfillnum}[1]{%
+    {\cftchapleader}\nobreak
+    \hb@xt@\@pnumwidth{\hfil\cftchappagefont #1}\cftchapafterpnum\par}
+  \if@cftkoma
+    \renewcommand{\cftchapfont}{\sectfont}
+  \fi
+\fi
+
+\renewcommand*{\l@section}[2]{%
+  \ifnum \c@tocdepth >\z@
+    \if@cfthaschapter
+      \vskip \cftbeforesecskip
+    \else
+      \addpenalty\@secpenalty
+      \addvspace{\cftbeforesecskip}
+    \fi
+    {\leftskip \cftsecindent\relax
+     \rightskip \@tocrmarg
+     \parfillskip -\rightskip
+     \parindent \cftsecindent\relax\@afterindenttrue
+     \interlinepenalty\@M
+     \leavevmode
+     \@tempdima \cftsecnumwidth\relax
+     \let\@cftbsnum \cftsecpresnum
+     \let\@cftasnum \cftsecaftersnum
+     \let\@cftasnumb \cftsecaftersnumb
+     \advance\leftskip \@tempdima \null\nobreak\hskip -\leftskip
+     {\cftsecfont #1}\nobreak
+     \cftsecfillnum{#2}}%
+  \fi}
+\newlength{\cftbeforesecskip}
+\newlength{\cftsecindent}
+\newlength{\cftsecnumwidth}
+\newcommand{\cftsecpresnum}{}
+\newcommand{\cftsecaftersnum}{}
+\newcommand{\cftsecaftersnumb}{}
+\if@cfthaschapter
+  \setlength{\cftbeforesecskip}{\z@ \@plus.2\p@}
+  \setlength{\cftsecindent}{1.5em}
+  \setlength{\cftsecnumwidth}{2.3em}
+  \newcommand{\cftsecfont}{\normalfont}
+  \newcommand{\cftsecleader}{\normalfont\cftdotfill{\cftsecdotsep}}
+  \newcommand{\cftsecdotsep}{\cftdotsep}
+  \newcommand{\cftsecpagefont}{\normalfont}
+\else
+  \setlength{\cftbeforesecskip}{1.0em \@plus\p@}
+  \setlength{\cftsecindent}{0em}
+  \setlength{\cftsecnumwidth}{1.5em}
+  \newcommand{\cftsecfont}{\bfseries}
+  \newcommand{\cftsecleader}{\bfseries\cftdotfill{\cftsecdotsep}}
+  \newcommand{\cftsecdotsep}{\cftnodots}
+  \newcommand{\cftsecpagefont}{\bfseries}
+\fi
+\newcommand{\cftsecafterpnum}{}
+\newcommand{\cftsecfillnum}[1]{%
+  {\cftsecleader}\nobreak
+  \hb@xt@\@pnumwidth{\hfil\cftsecpagefont #1}\cftsecafterpnum\par}
+
+\renewcommand*{\l@subsection}[2]{%
+  \ifnum \c@tocdepth >\@ne
+    \vskip \cftbeforesubsecskip
+    {\leftskip \cftsubsecindent\relax
+     \rightskip \@tocrmarg
+     \parfillskip -\rightskip
+     \parindent \cftsubsecindent\relax\@afterindenttrue
+     \interlinepenalty\@M
+     \leavevmode
+     \@tempdima \cftsubsecnumwidth\relax
+     \let\@cftbsnum \cftsubsecpresnum
+     \let\@cftasnum \cftsubsecaftersnum
+     \let\@cftasnumb \cftsubsecaftersnumb
+     \advance\leftskip \@tempdima \null\nobreak\hskip -\leftskip
+     {\cftsubsecfont #1}\nobreak
+     \cftsubsecfillnum{#2}}%
+  \fi}
+\newlength{\cftbeforesubsecskip}
+  \setlength{\cftbeforesubsecskip}{\z@ \@plus.2\p@}
+\newlength{\cftsubsecindent}
+\newlength{\cftsubsecnumwidth}
+\if@cfthaschapter
+  \setlength{\cftsubsecindent}{3.8em}
+  \setlength{\cftsubsecnumwidth}{3.2em}
+\else
+  \setlength{\cftsubsecindent}{1.5em}
+  \setlength{\cftsubsecnumwidth}{2.3em}
+\fi
+\newcommand{\cftsubsecfont}{\normalfont}
+\newcommand{\cftsubsecpresnum}{}
+\newcommand{\cftsubsecaftersnum}{}
+\newcommand{\cftsubsecaftersnumb}{}
+\newcommand{\cftsubsecleader}{\normalfont\cftdotfill{\cftsubsecdotsep}}
+\newcommand{\cftsubsecdotsep}{\cftdotsep}
+\newcommand{\cftsubsecpagefont}{\normalfont}
+\newcommand{\cftsubsecafterpnum}{}
+\newcommand{\cftsubsecfillnum}[1]{%
+  {\cftsubsecleader}\nobreak
+  \hb@xt@\@pnumwidth{\hfil\cftsubsecpagefont #1}\cftsubsecafterpnum\par}
+
+\renewcommand*{\l@subsubsection}[2]{%
+  \ifnum \c@tocdepth >\tw@
+    \vskip \cftbeforesubsubsecskip
+    {\leftskip \cftsubsubsecindent\relax
+     \rightskip \@tocrmarg
+     \parfillskip -\rightskip
+     \parindent \cftsubsubsecindent\relax\@afterindenttrue
+     \interlinepenalty\@M
+     \leavevmode
+     \@tempdima \cftsubsubsecnumwidth\relax
+     \let\@cftbsnum \cftsubsubsecpresnum
+     \let\@cftasnum \cftsubsubsecaftersnum
+     \let\@cftasnumb \cftsubsubsecaftersnumb
+     \advance\leftskip \@tempdima \null\nobreak\hskip -\leftskip
+     {\cftsubsubsecfont #1}\nobreak
+     \cftsubsubsecfillnum{#2}}%
+  \fi}
+\newlength{\cftbeforesubsubsecskip}
+  \setlength{\cftbeforesubsubsecskip}{\z@ \@plus.2\p@}
+\newlength{\cftsubsubsecindent}
+\newlength{\cftsubsubsecnumwidth}
+\if@cfthaschapter
+  \setlength{\cftsubsubsecindent}{7.0em}
+  \setlength{\cftsubsubsecnumwidth}{4.1em}
+\else
+  \setlength{\cftsubsubsecindent}{3.8em}
+  \setlength{\cftsubsubsecnumwidth}{3.2em}
+\fi
+\newcommand{\cftsubsubsecfont}{\normalfont}
+\newcommand{\cftsubsubsecpresnum}{}
+\newcommand{\cftsubsubsecaftersnum}{}
+\newcommand{\cftsubsubsecaftersnumb}{}
+\newcommand{\cftsubsubsecleader}{\normalfont\cftdotfill{\cftsubsubsecdotsep}}
+\newcommand{\cftsubsubsecdotsep}{\cftdotsep}
+\newcommand{\cftsubsubsecpagefont}{\normalfont}
+\newcommand{\cftsubsubsecafterpnum}{}
+\newcommand{\cftsubsubsecfillnum}[1]{%
+  {\cftsubsubsecleader}\nobreak
+  \hb@xt@\@pnumwidth{\hfil\cftsubsubsecpagefont #1}\cftsubsubsecafterpnum\par}
+
+\renewcommand*{\l@paragraph}[2]{%
+  \ifnum \c@tocdepth >3\relax
+    \vskip \cftbeforeparaskip
+    {\leftskip \cftparaindent\relax
+     \rightskip \@tocrmarg
+     \parfillskip -\rightskip
+     \parindent \cftparaindent\relax\@afterindenttrue
+     \interlinepenalty\@M
+     \leavevmode
+     \@tempdima \cftparanumwidth\relax
+     \let\@cftbsnum \cftparapresnum
+     \let\@cftasnum \cftparaaftersnum
+     \let\@cftasnumb \cftparaaftersnumb
+     \advance\leftskip \@tempdima \null\nobreak\hskip -\leftskip
+     {\cftparafont #1}\nobreak
+     \cftparafillnum{#2}}%
+  \fi}
+\newlength{\cftbeforeparaskip}
+  \setlength{\cftbeforeparaskip}{\z@ \@plus.2\p@}
+\newlength{\cftparaindent}
+\newlength{\cftparanumwidth}
+\if@cfthaschapter
+  \setlength{\cftparaindent}{10em}
+  \setlength{\cftparanumwidth}{5em}
+\else
+  \setlength{\cftparaindent}{7.0em}
+  \setlength{\cftparanumwidth}{4.1em}
+\fi
+\newcommand{\cftparafont}{\normalfont}
+\newcommand{\cftparapresnum}{}
+\newcommand{\cftparaaftersnum}{}
+\newcommand{\cftparaaftersnumb}{}
+\newcommand{\cftparaleader}{\normalfont\cftdotfill{\cftparadotsep}}
+\newcommand{\cftparadotsep}{\cftdotsep}
+\newcommand{\cftparapagefont}{\normalfont}
+\newcommand{\cftparaafterpnum}{}
+\newcommand{\cftparafillnum}[1]{%
+  {\cftparaleader}\nobreak
+  \hb@xt@\@pnumwidth{\hfil\cftparapagefont #1}\cftparaafterpnum\par}
+
+\renewcommand*{\l@subparagraph}[2]{%
+  \ifnum \c@tocdepth >4\relax
+    \vskip \cftbeforesubparaskip
+    {\leftskip \cftsubparaindent\relax
+     \rightskip \@tocrmarg
+     \parfillskip -\rightskip
+     \parindent \cftsubparaindent\relax\@afterindenttrue
+     \interlinepenalty\@M
+     \leavevmode
+     \@tempdima \cftsubparanumwidth\relax
+     \let\@cftbsnum \cftsubparapresnum
+     \let\@cftasnum \cftsubparaaftersnum
+     \let\@cftasnumb \cftsubparaaftersnumb
+     \advance\leftskip \@tempdima \null\nobreak\hskip -\leftskip
+     {\cftsubparafont #1}\nobreak
+     \cftsubparafillnum{#2}}%
+  \fi}
+\newlength{\cftbeforesubparaskip}
+  \setlength{\cftbeforesubparaskip}{\z@ \@plus.2\p@}
+\newlength{\cftsubparaindent}
+\newlength{\cftsubparanumwidth}
+\if@cfthaschapter
+  \setlength{\cftsubparaindent}{12em}
+  \setlength{\cftsubparanumwidth}{6em}
+\else
+  \setlength{\cftsubparaindent}{10em}
+  \setlength{\cftsubparanumwidth}{5em}
+\fi
+\newcommand{\cftsubparafont}{\normalfont}
+\newcommand{\cftsubparapresnum}{}
+\newcommand{\cftsubparaaftersnum}{}
+\newcommand{\cftsubparaaftersnumb}{}
+\newcommand{\cftsubparaleader}{\normalfont\cftdotfill{\cftsubparadotsep}}
+\newcommand{\cftsubparadotsep}{\cftdotsep}
+\newcommand{\cftsubparapagefont}{\normalfont}
+\newcommand{\cftsubparaafterpnum}{}
+\newcommand{\cftsubparafillnum}[1]{%
+  {\cftsubparaleader}\nobreak
+  \hb@xt@\@pnumwidth{\hfil\cftsubparapagefont #1}\cftsubparaafterpnum\par}
+
+\newcommand{\@cftdobiblof}{%
+  \if@dotoclof
+    \if@bibchapter
+      \phantomsection
+      \addcontentsline{toc}{chapter}{\listfigurename}
+    \else
+      \phantomsection
+      \addcontentsline{toc}{\@tocextra}{\listfigurename}
+    \fi
+  \fi}
+
+\AtBeginDocument{%
+\if@cftnctoc\else
+\renewcommand{\listoffigures}{%
+  \@cfttocstart
+  \par
+  \begingroup
+    \parindent\z@ \parskip\cftparskip
+    \@cftmakeloftitle
+    \if@cfttocbibind
+      \@cftdobiblof
+    \fi
+    \@starttoc{lof}%
+  \endgroup
+  \@cfttocfinish}%
+\fi
+}
+
+\newcommand{\@cftmakeloftitle}{%
+  \addpenalty\@secpenalty
+  \if@cfthaschapter
+    \vspace*{\cftbeforeloftitleskip}
+  \else
+    \vspace{\cftbeforeloftitleskip}
+  \fi
+  \@cftpagestyle
+  {\interlinepenalty\@M
+  {\cftloftitlefont\listfigurename}{\cftafterloftitle}
+  \cftmarklof
+  \par\nobreak
+  \vskip \cftafterloftitleskip
+  \@afterheading}}
+
+\newlength{\cftbeforeloftitleskip}
+\newlength{\cftafterloftitleskip}
+\if@cfthaschapter
+  \setlength{\cftbeforeloftitleskip}{50pt}
+  \setlength{\cftafterloftitleskip}{40pt}
+\else
+  \setlength{\cftbeforeloftitleskip}{3.5ex \@plus 1ex \@minus .2ex}
+  \setlength{\cftafterloftitleskip}{2.3ex \@plus.2ex}
+\fi
+\if@cfthaschapter
+  \newcommand{\cftloftitlefont}{\normalfont\Huge\bfseries}
+  \if@cftkoma\renewcommand{\cftloftitlefont}{\size@chapter\sectfont}\fi
+\else
+  \newcommand{\cftloftitlefont}{\normalfont\Large\bfseries}
+  \if@cftkoma\renewcommand{\cftloftitlefont}{\size@section\sectfont}\fi
+\fi
+\newcommand{\cftafterloftitle}{}
+
+\renewcommand*{\l@figure}[2]{%
+  \ifnum \c@lofdepth >\z@
+    \vskip \cftbeforefigskip
+    {\leftskip \cftfigindent\relax
+     \rightskip \@tocrmarg
+     \parfillskip -\rightskip
+     \parindent \cftfigindent\relax\@afterindenttrue
+     \interlinepenalty\@M
+     \leavevmode
+     \@tempdima \cftfignumwidth\relax
+     \let\@cftbsnum \cftfigpresnum
+     \let\@cftasnum \cftfigaftersnum
+     \let\@cftasnumb \cftfigaftersnumb
+     \advance\leftskip \@tempdima \null\nobreak\hskip -\leftskip
+     {\cftfigfont #1}\nobreak
+     \cftfigfillnum{#2}}%
+   \fi
+  }
+\newlength{\cftbeforefigskip}
+  \setlength{\cftbeforefigskip}{\z@ \@plus.2\p@}
+\newlength{\cftfigindent}
+  \setlength{\cftfigindent}{1.5em}
+\newlength{\cftfignumwidth}
+  \setlength{\cftfignumwidth}{2.3em}
+\newcommand{\cftfigfont}{\normalfont}
+\newcommand{\cftfigpresnum}{}
+\newcommand{\cftfigaftersnum}{}
+\newcommand{\cftfigaftersnumb}{}
+\newcommand{\cftfigleader}{\normalfont\cftdotfill{\cftfigdotsep}}
+\newcommand{\cftfigdotsep}{\cftdotsep}
+\newcommand{\cftfigpagefont}{\normalfont}
+\newcommand{\cftfigafterpnum}{}
+\newcommand{\cftfigfillnum}[1]{%
+  {\cftfigleader}\nobreak
+  \hb@xt@\@pnumwidth{\hfil\cftfigpagefont #1}\cftfigafterpnum\par}
+
+\if@cftsubfigopt\else
+  \newcounter{lofdepth}\setcounter{lofdepth}{1}
+  \newcounter{lotdepth}\setcounter{lotdepth}{1}
+\fi
+
+\newcommand{\@cftdobiblot}{%
+  \if@dotoclot
+    \if@bibchapter
+      \phantomsection
+      \addcontentsline{toc}{chapter}{\listtablename}
+    \else
+      \phantomsection
+      \addcontentsline{toc}{\@tocextra}{\listtablename}
+    \fi
+  \fi}
+
+\AtBeginDocument{%
+\if@cftnctoc\else
+\renewcommand{\listoftables}{%
+  \@cfttocstart
+  \par
+  \begingroup
+    \parindent\z@ \parskip\cftparskip
+    \@cftmakelottitle
+    \if@cfttocbibind
+      \@cftdobiblot
+    \fi
+    \@starttoc{lot}%
+  \endgroup
+  \@cfttocfinish}%
+\fi
+}
+
+\newcommand{\@cftmakelottitle}{%
+  \addpenalty\@secpenalty
+  \if@cfthaschapter
+    \vspace*{\cftbeforelottitleskip}
+  \else
+    \vspace{\cftbeforelottitleskip}
+  \fi
+  \@cftpagestyle
+  {\interlinepenalty\@M
+  {\cftlottitlefont\listtablename}{\cftafterlottitle}
+  \cftmarklot
+  \par\nobreak
+  \vskip \cftafterlottitleskip
+  \@afterheading}}
+
+\newlength{\cftbeforelottitleskip}
+\newlength{\cftafterlottitleskip}
+\if@cfthaschapter
+  \setlength{\cftbeforelottitleskip}{50pt}
+  \setlength{\cftafterlottitleskip}{40pt}
+\else
+  \setlength{\cftbeforelottitleskip}{3.5ex \@plus 1ex \@minus .2ex}
+  \setlength{\cftafterlottitleskip}{2.3ex \@plus.2ex}
+\fi
+\if@cfthaschapter
+  \newcommand{\cftlottitlefont}{\normalfont\Huge\bfseries}
+  \if@cftkoma\renewcommand{\cftlottitlefont}{\size@chapter\sectfont}\fi
+\else
+  \newcommand{\cftlottitlefont}{\normalfont\Large\bfseries}
+  \if@cftkoma\renewcommand{\cftlottitlefont}{\size@section\sectfont}\fi
+\fi
+\newcommand{\cftafterlottitle}{}
+
+\renewcommand*{\l@table}[2]{%
+  \ifnum\c@lotdepth >\z@
+    \vskip \cftbeforetabskip
+    {\leftskip \cfttabindent\relax
+     \rightskip \@tocrmarg
+     \parfillskip -\rightskip
+     \parindent \cfttabindent\relax\@afterindenttrue
+     \interlinepenalty\@M
+     \leavevmode
+     \@tempdima \cfttabnumwidth\relax
+     \let\@cftbsnum \cfttabpresnum
+     \let\@cftasnum \cfttabaftersnum
+     \let\@cftasnumb \cfttabaftersnumb
+     \advance\leftskip \@tempdima \null\nobreak\hskip -\leftskip
+     {\cfttabfont #1}\nobreak
+     \cfttabfillnum{#2}}%
+   \fi
+  }
+\newlength{\cftbeforetabskip}
+  \setlength{\cftbeforetabskip}{\z@ \@plus.2\p@}
+\newlength{\cfttabindent}
+  \setlength{\cfttabindent}{1.5em}
+\newlength{\cfttabnumwidth}
+  \setlength{\cfttabnumwidth}{2.3em}
+\newcommand{\cfttabfont}{\normalfont}
+\newcommand{\cfttabpresnum}{}
+\newcommand{\cfttabaftersnum}{}
+\newcommand{\cfttabaftersnumb}{}
+\newcommand{\cfttableader}{\normalfont\cftdotfill{\cfttabdotsep}}
+\newcommand{\cfttabdotsep}{\cftdotsep}
+\newcommand{\cfttabpagefont}{\normalfont}
+\newcommand{\cfttabafterpnum}{}
+\newcommand{\cfttabfillnum}[1]{%
+  {\cfttableader}\nobreak
+  \hb@xt@\@pnumwidth{\hfil\cfttabpagefont #1}\cfttabafterpnum\par}
+
+\newcommand{\@cftl@subfig}{%
+\renewcommand*{\l@subfigure}[2]{%
+  \ifnum \c@lofdepth > \toclevel@subfigure
+    \vskip \cftbeforesubfigskip
+    {\leftskip \cftsubfigindent\relax
+     \rightskip \@tocrmarg
+     \parfillskip -\rightskip
+     \parindent \cftsubfigindent\relax\@afterindenttrue
+     \interlinepenalty\@M
+     \leavevmode
+     \@tempdima \cftsubfignumwidth\relax
+     \let\@cftbsnum \cftsubfigpresnum
+     \let\@cftasnum \cftsubfigaftersnum
+     \let\@cftasnumb \cftsubfigaftersnumb
+     \advance\leftskip \@tempdima \null\nobreak\hskip -\leftskip
+     {\cftsubfigfont ##1}\nobreak
+     \cftsubfigfillnum{##2}}%
+  \fi
+  }%
+}
+
+\newcommand{\@cftsetsubfig}{%
+\newlength{\cftbeforesubfigskip}
+  \setlength{\cftbeforesubfigskip}{\z@ \@plus.2\p@}
+\newlength{\cftsubfigindent}
+  \setlength{\cftsubfigindent}{3.8em}
+\newlength{\cftsubfignumwidth}
+  \setlength{\cftsubfignumwidth}{2.5em}
+\newcommand{\cftsubfigfont}{\normalfont}
+\newcommand{\cftsubfigpresnum}{}
+\newcommand{\cftsubfigaftersnum}{}
+\newcommand{\cftsubfigaftersnumb}{}
+\newcommand{\cftsubfigleader}{\normalfont\cftdotfill{\cftsubtabdotsep}}
+\newcommand{\cftsubfigdotsep}{\cftdotsep}
+\newcommand{\cftsubfigpagefont}{\normalfont}
+\newcommand{\cftsubfigafterpnum}{}
+\providecommand{\toclevel@subfigure}{1}
+\newcommand{\cftsubfigfillnum}[1]{%
+  {\cftsubfigleader}\nobreak
+  \hb@xt@\@pnumwidth{\hfil\cftsubfigpagefont ##1}\cftsubfigafterpnum\par}
+}
+
+\newcommand{\@cftl@subtab}{%
+\renewcommand*{\l@subtable}[2]{%
+  \ifnum \c@lotdepth > \toclevel@subtable
+    \vskip \cftbeforesubtabskip
+    {\leftskip \cftsubtabindent\relax
+     \rightskip \@tocrmarg
+     \parfillskip -\rightskip
+     \parindent \cftsubtabindent\relax\@afterindenttrue
+     \interlinepenalty\@M
+     \leavevmode
+     \@tempdima \cftsubtabnumwidth\relax
+     \let\@cftbsnum \cftsubtabpresnum
+     \let\@cftasnum \cftsubtabaftersnum
+     \let\@cftasnumb \cftsubtabaftersnumb
+     \advance\leftskip \@tempdima \null\nobreak\hskip -\leftskip
+     {\cftsubtabfont ##1}\nobreak
+     \cftsubtabfillnum{##2}}%
+  \fi
+  }%
+}
+\newcommand{\@cftsetsubtab}{%
+\newlength{\cftbeforesubtabskip}
+  \setlength{\cftbeforesubtabskip}{\z@ \@plus.2\p@}
+\newlength{\cftsubtabindent}
+  \setlength{\cftsubtabindent}{3.8em}
+\newlength{\cftsubtabnumwidth}
+  \setlength{\cftsubtabnumwidth}{2.5em}
+\newcommand{\cftsubtabfont}{\normalfont}
+\newcommand{\cftsubtabpresnum}{}
+\newcommand{\cftsubtabaftersnum}{}
+\newcommand{\cftsubtabaftersnumb}{}
+\newcommand{\cftsubtableader}{\normalfont\cftdotfill{\cftsubtabdotsep}}
+\newcommand{\cftsubtabdotsep}{\cftdotsep}
+\newcommand{\cftsubtabpagefont}{\normalfont}
+\newcommand{\cftsubtabafterpnum}{}
+\providecommand{\toclevel@subtable}{1}
+\newcommand{\cftsubtabfillnum}[1]{%
+  {\cftsubtableader}\nobreak
+  \hb@xt@\@pnumwidth{\hfil\cftsubtabpagefont ##1}\cftsubtabafterpnum\par}
+}
+
+
+\if@cftsubfigopt
+  \@cftsetsubfig\@cftsetsubtab
+  \AtBeginDocument{\@cftl@subfig\@cftl@subtab}
+\fi
+%%  \AtBeginDocument{\if@cftsubfigopt
+%%    \@cftsetsubfig\@cftsetsubtab
+%%    \@cftl@subfig\@cftl@subtab
+%%  \fi}
+
+\newcommand{\newlistentry}[4][\@empty]{%
+  \@ifundefined{c@#2}{%    check & set the counter
+    \ifx \@empty#1\relax
+      \newcounter{#2}
+    \else
+      \@ifundefined{c@#1}{\PackageWarning{tocloft}%
+                          {#1 has no counter for use as a `within'}
+        \newcounter{#2}}%
+      {\newcounter{#2}[#1]%
+       \expandafter\edef\csname the#2\endcsname{%
+         \expandafter\noexpand\csname the#1\endcsname.\noexpand\arabic{#2}}}
+    \fi
+    \setcounter{#2}{0}
+  }
+  {\PackageError{tocloft}{#2 has been previously defined}{\@eha}}
+
+  \@namedef{l@#2}##1##2{%
+    \ifnum \@nameuse{c@#3depth} > #4\relax
+      \vskip \@nameuse{cftbefore#2skip}
+      {\leftskip \@nameuse{cft#2indent}\relax
+       \rightskip \@tocrmarg
+       \parfillskip -\rightskip
+       \parindent \@nameuse{cft#2indent}\relax\@afterindenttrue
+       \interlinepenalty\@M
+       \leavevmode
+       \@tempdima \@nameuse{cft#2numwidth}\relax
+       \expandafter\let\expandafter\@cftbsnum\csname cft#2presnum\endcsname
+       \expandafter\let\expandafter\@cftasnum\csname cft#2aftersnum\endcsname
+       \expandafter\let\expandafter\@cftasnumb\csname cft#2aftersnumb\endcsname
+       \advance\leftskip\@tempdima \null\nobreak\hskip -\leftskip
+       {\@nameuse{cft#2font}##1}\nobreak
+       \@nameuse{cft#2fillnum}{##2}}%
+    \fi
+  }  % end of \l@#2
+
+  \expandafter\newlength\csname cftbefore#2skip\endcsname
+    \setlength{\@nameuse{cftbefore#2skip}}{\z@ \@plus .2\p@}
+  \expandafter\newlength\csname cft#2indent\endcsname
+  \expandafter\newlength\csname cft#2numwidth\endcsname
+  \ifcase #4\relax  % 0
+    \setlength{\@nameuse{cft#2indent}}{0em}
+    \setlength{\@nameuse{cft#2numwidth}}{1.5em}
+  \or               % 1
+    \setlength{\@nameuse{cft#2indent}}{1.5em}
+    \setlength{\@nameuse{cft#2numwidth}}{2.3em}
+  \or               % 2
+    \setlength{\@nameuse{cft#2indent}}{3.8em}
+    \setlength{\@nameuse{cft#2numwidth}}{3.2em}
+  \or               % 3
+    \setlength{\@nameuse{cft#2indent}}{7.0em}
+    \setlength{\@nameuse{cft#2numwidth}}{4.1em}
+  \else             % anything else
+    \setlength{\@nameuse{cft#2indent}}{10.0em}
+    \setlength{\@nameuse{cft#2numwidth}}{5.0em}
+  \fi
+  \@namedef{cft#2font}{\normalfont}
+  \@namedef{cft#2presnum}{}
+  \@namedef{cft#2aftersnum}{}
+  \@namedef{cft#2aftersnumb}{}
+  \@namedef{cft#2dotsep}{\cftdotsep}
+  \@namedef{cft#2leader}{\normalfont\cftdotfill{\@nameuse{cft#2dotsep}}}
+  \@namedef{cft#2pagefont}{\normalfont}
+  \@namedef{cft#2afterpnum}{}
+  \@namedef{toclevel@#2}{#4}
+  \@namedef{cft#2fillnum}##1{%
+    {\@nameuse{cft#2leader}}\nobreak
+    \hb@xt@\@pnumwidth{\hfil\@nameuse{cft#2pagefont}##1}\@nameuse{cft#2afterpnum}\par}
+} % end \newlistentry
+
+\newcommand{\newlistof}[4][\@empty]{%
+  \ifx \@empty#1\relax
+    \newlistentry{#2}{#3}{0}
+  \else
+    \newlistentry[#1]{#2}{#3}{0}
+  \fi
+
+  \@namedef{ext@#3}{#3}
+  \newcounter{#3depth}
+  \setcounter{#3depth}{1}
+
+  \if@cftkoma
+    \@namedef{cftmark#3}{%
+      \@mkboth{#4}{#4}}
+  \else
+    \@namedef{cftmark#3}{%
+      \@mkboth{\MakeUppercase{#4}}{\MakeUppercase{#4}}}
+  \fi
+ \if@cftnctoc
+  \@namedef{listof#2}{%
+    \@cfttocstart
+    \if@cfthaschapter
+      \chapter*{#4}
+    \else
+      \section*{#4}
+    \fi
+    \@nameuse{cftmark#3}
+    \@starttoc{#3}%
+    \@cfttocfinish}
+ \else
+  \@namedef{listof#2}{%
+    \@cfttocstart
+    \par
+    \begingroup
+      \parindent\z@ \parskip\cftparskip
+      \@nameuse{@cftmake#3title}
+      \@starttoc{#3}%
+    \endgroup
+    \@cfttocfinish}
+ \fi
+
+  \@namedef{@cftmake#3title}{%
+    \addpenalty\@secpenalty
+    \if@cfthaschapter
+      \vspace*{\@nameuse{cftbefore#3titleskip}}
+    \else
+      \vspace{\@nameuse{cftbefore#3titleskip}}
+    \fi
+    \@cftpagestyle
+    {\interlinepenalty\@M
+    {\@nameuse{cft#3titlefont}#4}{\@nameuse{cftafter#3title}}
+    \@nameuse{cftmark#3}
+    \par\nobreak
+    \vskip \@nameuse{cftafter#3titleskip}
+    \@afterheading}}
+
+   \expandafter\newlength\csname cftbefore#3titleskip\endcsname
+   \expandafter\newlength\csname cftafter#3titleskip\endcsname
+   \if@cfthaschapter
+      \setlength{\@nameuse{cftbefore#3titleskip}}{50pt}
+      \setlength{\@nameuse{cftafter#3titleskip}}{40pt}
+      \if@cftkoma
+        \@namedef{cft#3titlefont}{\size@chapter\sectfont}
+      \else
+        \@namedef{cft#3titlefont}{\normalfont\Huge\bfseries}
+      \fi
+    \else
+      \setlength{\@nameuse{cftbefore#3titleskip}}{3.5ex \@plus 1ex \@minus .2ex}
+      \setlength{\@nameuse{cftafter#3titleskip}}{2.3ex \@plus .2ex}
+      \if@cftkoma
+        \@namedef{cft#3titlefont}{\size@section\sectfont}
+      \else
+        \@namedef{cft#3titlefont}{\normalfont\Huge\bfseries}
+      \fi
+    \fi
+    \@namedef{cftafter#3title}{}
+} % end \newlistof
+
+\newcommand{\cftsetindents}[3]{%
+  \def\@cftemp{#1}
+  \ifx\@cftemp\cftchapname
+    \@cftsetindents{chap}{#2}{#3}
+  \else
+    \ifx\@cftemp\cftsecname \@cftsetindents{sec}{#2}{#3}
+    \else
+      \ifx\@cftemp\cftsubsecname \@cftsetindents{subsec}{#2}{#3}
+      \else
+        \ifx\@cftemp\cftsubsubsecname \@cftsetindents{subsubsec}{#2}{#3}
+        \else
+          \ifx\@cftemp\cftparaname \@cftsetindents{para}{#2}{#3}
+          \else
+            \ifx\@cftemp\cftsubparaname \@cftsetindents{subpara}{#2}{#3}
+            \else
+              \ifx\@cftemp\cftfigname \@cftsetindents{fig}{#2}{#3}
+              \else
+                \ifx\@cftemp\cftsubfigname \@cftsetindents{subfig}{#2}{#3}
+                \else
+                  \ifx\@cftemp\cfttabname \@cftsetindents{tab}{#2}{#3}
+                  \else
+                    \ifx\@cftemp\cftsubtabname \@cftsetindents{subtab}{#2}{#3}
+                    \else
+                      \@cftsetindents{#1}{#2}{#3}
+                    \fi
+                  \fi
+                \fi
+              \fi
+            \fi
+          \fi
+        \fi
+      \fi
+    \fi
+  \fi
+}
+
+\newcommand{\@cftsetindents}[3]{%
+  \setlength{\@nameuse{cft#1indent}}{#2}
+  \setlength{\@nameuse{cft#1numwidth}}{#3}
+}
+
+\newcommand{\@cftpnumoff}[1]{%
+  \@namedef{cft#1fillnum}##1{%
+    \cftparfillskip\@nameuse{cft#1afterpnum}\par}}
+
+\newcommand*{\cftchapname}{chapter}
+\newcommand*{\cftsecname}{section}
+\newcommand*{\cftsubsecname}{subsection}
+\newcommand*{\cftsubsubsecname}{subsubsection}
+\newcommand*{\cftparaname}{paragraph}
+\newcommand*{\cftsubparaname}{subparagraph}
+\newcommand*{\cftfigname}{figure}
+\newcommand*{\cftsubfigname}{subfigure}
+\newcommand*{\cfttabname}{table}
+\newcommand*{\cftsubtabname}{subtable}
+
+\DeclareRobustCommand{\cftpagenumbersoff}[1]{%
+  \def\@cftemp{#1}
+  \ifx\@cftemp\cftchapname
+    \@cftpnumoff{chap}
+  \else
+    \ifx\@cftemp\cftsecname \@cftpnumoff{sec}
+    \else
+      \ifx\@cftemp\cftsubsecname \@cftpnumoff{subsec}
+      \else
+        \ifx\@cftemp\cftsubsubsecname \@cftpnumoff{subsubsec}
+        \else
+          \ifx\@cftemp\cftparaname \@cftpnumoff{para}
+          \else
+            \ifx\@cftemp\cftsubparaname \@cftpnumoff{subpara}
+            \else
+              \ifx\@cftemp\cftfigname \@cftpnumoff{fig}
+              \else
+                \ifx\@cftemp\cftsubfigname \@cftpnumoff{subfig}
+                \else
+                  \ifx\@cftemp\cfttabname \@cftpnumoff{tab}
+                  \else
+                    \ifx\@cftemp\cftsubtabname \@cftpnumoff{subtab}
+                    \else
+                      \@cftpnumoff{#1}
+                    \fi
+                  \fi
+                \fi
+              \fi
+            \fi
+          \fi
+        \fi
+      \fi
+    \fi
+  \fi
+}
+
+\DeclareRobustCommand{\cftpagenumberson}[1]{%
+  \def\@cftemp{#1}
+  \ifx\@cftemp\cftchapname
+    \@cftpnumon{chap}
+  \else
+    \ifx\@cftemp\cftsecname \@cftpnumon{sec}
+    \else
+      \ifx\@cftemp\cftsubsecname \@cftpnumon{subsec}
+      \else
+        \ifx\@cftemp\cftsubsubsecname \@cftpnumon{subsubsec}
+        \else
+          \ifx\@cftemp\cftparaname \@cftpnumon{para}
+          \else
+            \ifx\@cftemp\cftsubparaname \@cftpnumon{subpara}
+            \else
+              \ifx\@cftemp\cftfigname \@cftpnumon{fig}
+              \else
+                \ifx\@cftemp\cftsubfigname \@cftpnumon{subfig}
+                \else
+                  \ifx\@cftemp\cfttabname \@cftpnumon{tab}
+                  \else
+                    \ifx\@cftemp\cftsubtabname \@cftpnumon{subtab}
+                    \else
+                      \@cftpnumon{#1}
+                    \fi
+                  \fi
+                \fi
+              \fi
+            \fi
+          \fi
+        \fi
+      \fi
+    \fi
+  \fi
+}
+
+\newcommand{\@cftpnumon}[1]{%
+  \@namedef{cft#1fillnum}##1{%
+    {\@nameuse{cft#1leader}}\nobreak
+    \hb@xt@\@pnumwidth{\hfil\@nameuse{cft#1pagefont}##1}\@nameuse{cft#1afterpnum}\par}}
+
+\newcommand{\cftchapterprecis}[1]{%
+  \cftchapterprecishere{#1}
+  \cftchapterprecistoc{#1}}
+\newcommand{\cftchapterprecishere}[1]{%
+  \vspace*{-2\baselineskip}
+  \begin{quote}\textit{#1}\end{quote}}
+\newcommand{\cftchapterprecistoc}[1]{\addtocontents{toc}{%
+  {\leftskip \cftchapindent\relax
+   \advance\leftskip \cftchapnumwidth\relax
+   \rightskip \@tocrmarg\relax
+   \textit{#1}\protect\par}}}
+
+\newcommand{\cftlocalchange}[3]{%
+  \addtocontents{#1}{\protect\cftsetpnumwidth{#2} \protect\cftsetrmarg{#3}}}
+\newcommand{\cftaddtitleline}[4]{\addtocontents{#1}{%
+  \protect\contentsline{#2}{#3}{#4}}}
+\newcommand{\cftaddnumtitleline}[5]{\addtocontents{#1}{%
+    \protect\contentsline{#2}{\protect\numberline{#3}#4}{#5}}}
+\AtBeginDocument{%
+  \@ifpackageloaded{hyperref}{%
+    \renewcommand{\cftaddtitleline}[4]{\addtocontents{#1}{%
+      \protect\contentsline{#2}{#3}{#4}{\@currentHref}}}
+    \renewcommand{\cftaddnumtitleline}[5]{\addtocontents{#1}{%
+      \protect\contentsline{#2}{\protect\numberline{#3}#4}{#5}{\@currentHref}}}
+  }{}
+}
+
+\endinput
+%%
+%% End of file `tocloft.sty'.
diff --git a/xifthen.sty b/xifthen.sty
new file mode 100644 (file)
index 0000000..a013cee
--- /dev/null
@@ -0,0 +1,222 @@
+\def \filedate    {2009/04/17}%
+\def \fileversion {v1.3}%
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesPackage{xifthen}%
+  [\filedate \space \fileversion \space Extended ifthen features]
+
+\RequirePackage{etex}
+\RequirePackage{calc}
+\RequirePackage{ifthen}
+\RequirePackage{ifmtarg}
+
+% First of all, \TE@repl (ifthen) needs to be patched. (v1.2)
+%   (viz. \newtest{\superlogique}[1]{\(\NOT#1\AND\boolean{true}\)})
+%   Pointed out by MPG and Pierre Albar\`ede [19 Mar 2009]
+
+\def \TE@repl #1#2{%
+  \long \def \@tempc ##1#1##2{%
+    \def \@tempb{\@tempc}%
+    \begingroup % Thanks MPG
+      \toks@ {##2}%
+      \edef \@tempa {\the \toks@}% <- UF v1.3
+    \expandafter \endgroup
+    \ifx \@tempa \@tempb
+      \toks@ \expandafter {\the \toks@ ##1}%
+      \expandafter \@gobble
+    \else
+      \toks@ \expandafter {\the \toks@ ##1#2}%
+      \expandafter \@tempc
+    \fi
+    ##2%
+  }%
+  \toks@ \expandafter {\expandafter}%
+  \expandafter \@tempc \the \toks@ #1\@tempc
+}
+
+% \cnttest {<counter expression>} {<relation>} {<counter expression>}
+%
+\newcommand*{\TE@cnttest}[4]{%
+  \TE@throw
+  \noexpand \calc@assign@count{\@tempcnta}{\unexpanded{#1}}%
+  \noexpand \calc@assign@count{\@tempcntb}{\unexpanded{#3}}%
+  \noexpand \if \noexpand \TE@cnttest@ {#2}%
+  #4%
+}
+
+\newcommand*{\TE@cnttest@}[1]{%
+  \ifcsname TE@cnttest@@#1\endcsname
+    \csname TE@cnttest@@#1\expandafter\expandafter\expandafter \endcsname
+    \expandafter \@gobble
+  \else
+    \expandafter \@firstofone
+  \fi
+  {FF\PackageError{xifthen}{Not a valid comparison operator "#1"}%
+                         {Valid comparisons are <, =, >, <=, and =>.}}%
+}
+
+\@namedef{TE@cnttest@@<}{\ifnum \@tempcnta<\@tempcntb AA\else AB\fi}
+\@namedef{TE@cnttest@@>}{\ifnum \@tempcnta>\@tempcntb AA\else AB\fi}
+\@namedef{TE@cnttest@@=}{\ifnum \@tempcnta=\@tempcntb AA\else AB\fi}
+\@namedef{TE@cnttest@@<=}{%
+  \ifnum \@tempcnta<\@tempcntb AA\else
+    \ifnum \@tempcnta=\@tempcntb AA\else AB\fi
+  \fi
+}
+\@namedef{TE@cnttest@@>=}{%
+  \ifnum \@tempcnta>\@tempcntb AA\else
+    \ifnum \@tempcnta=\@tempcntb AA\else AB\fi
+  \fi
+}
+
+% \dimtest {<dimension expression>} {<relation>} {<dimension expression>}
+%
+\newcommand*{\TE@dimtest}[4]{%
+  \TE@throw
+  \noexpand \calc@assign@skip{\@tempskipa}{\unexpanded{#1}}%
+  \noexpand \calc@assign@skip{\@tempskipb}{\unexpanded{#3}}%
+  \noexpand \if \noexpand \TE@dimtest@ {#2}%
+  #4%
+}
+
+\newcommand*{\TE@dimtest@}[1]{%
+  \ifcsname TE@dimtest@@#1\endcsname
+    \csname TE@dimtest@@#1\expandafter\expandafter\expandafter \endcsname
+    \expandafter \@gobble
+  \else
+    \expandafter \@firstofone
+  \fi
+  {FF\PackageError{xifthen}{Not a valid comparison operator "#1"}%
+                         {Valid comparisons are <, =, >, <=, and =>.}}%
+}
+
+\@namedef{TE@dimtest@@<}{\ifdim \@tempskipa<\@tempskipb AA\else AB\fi}
+\@namedef{TE@dimtest@@>}{\ifdim \@tempskipa>\@tempskipb AA\else AB\fi}
+\@namedef{TE@dimtest@@=}{\ifdim \@tempskipa=\@tempskipb AA\else AB\fi}
+\@namedef{TE@dimtest@@<=}{%
+  \ifdim \@tempskipa<\@tempskipb AA\else
+    \ifdim \@tempskipa=\@tempskipb AA\else AB\fi
+  \fi
+}
+\@namedef{TE@dimtest@@>=}{%
+  \ifdim \@tempskipa>\@tempskipb AA\else
+    \ifdim \@tempskipa=\@tempskipb AA\else AB\fi
+  \fi
+}
+
+% \isnamedefined {<command name>}
+%
+\newcommand*{\TE@isnamedefined}[2]{%
+  \TE@throw
+  \noexpand \ifcsname #1\endcsname
+  #2%
+}
+
+% \isempty {<content>}
+%
+\newcommand*{\TE@isempty}[2]{%
+  \TE@throw
+  \noexpand \if FF\noexpand \@nameuse{fi}%
+  \noexpand \@ifmtarg{\unexpanded{#1}}{%
+    \noexpand \@nameuse{iftrue}%
+  }{%
+    \noexpand \@nameuse{iffalse}%
+  }%
+  #2%
+}
+
+% \isequivalentto {<command>} {<command>}
+%
+\newcommand*{\TE@isequivalentto}[3]{%
+  \TE@throw
+  \noexpand \ifx \noexpand #1\noexpand#2%
+  #3%
+}
+
+% \isin {<substring>} {<string>}
+%
+\newcommand*{\TE@isin}[3]{%
+  \TE@throw
+  \unexpanded {\in@{#1}{#2}}%
+  \noexpand \ifin@
+  #3%
+}
+
+% \endswith {<string>} {<substring>}
+%
+\newcommand*{\TE@endswith}[3]{%
+  \TE@throw
+  \unexpanded {\in@{#2\@nil}{#1\@nil}}%
+  \noexpand \ifin@
+  #3%
+}
+
+% \newtest <command> [<number>] {<definition>}
+%
+\newcommand*{\newtest}[1]{%
+  \@ifnextchar[{%
+    \@newtest{#1}%
+  }{%
+    \@newtest{#1}[0]%
+  }%
+}%
+
+\newcommand*{\@newtest}{}
+\def \@newtest #1[#2]#3{%
+  \toks@ = {\(#3\)}%
+  \TE@repl \or  \TE@or
+  \TE@repl \and \TE@and
+  \TE@repl \not \TE@neg
+  \TE@repl \OR  \TE@or
+  \TE@repl \AND \TE@and
+  \TE@repl \NOT \TE@neg
+  \edef \@tempa {%
+    \unexpanded{\newcommand*{#1}[{#2}]}{\the \toks@}%
+  }%
+  \@tempa
+}%
+
+\newcommand*{\TE@hook}{%
+  \let \isequivalentto = \TE@isequivalentto
+  \let \terminateswith = \TE@endswith % For compability reasons (deprecated)
+  \let \endswith       = \TE@endswith
+  \let \isnamedefined  = \TE@isnamedefined
+  \let \isempty        = \TE@isempty
+  \let \cnttest        = \TE@cnttest
+  \let \dimtest        = \TE@dimtest
+  \let \isin           = \TE@isin
+}
+
+\renewcommand{\ifthenelse}[1]{%
+  \toks@{#1}%
+  \TE@repl \or  \TE@or
+  \TE@repl \and \TE@and
+  \TE@repl \not \TE@neg
+  \TE@repl \OR  \TE@or
+  \TE@repl \AND \TE@and
+  \TE@repl \NOT \TE@neg
+  \begingroup
+    \let \protect = \@unexpandable@protect
+    \def \@setref ##1##2##3{\ifx ##1\relax \z@ \else \expandafter ##2##1\fi}%
+    \def \value ##1{\the \csname c@##1\endcsname}%
+    \let \equal = \TE@equal
+    \let \( = \TE@lparen
+    \let \) = \TE@rparen
+    \let \isodd = \TE@odd
+    \let \lengthtest = \TE@length
+    \let \isundefined = \TE@undef
+    \TE@hook
+    \begingroup
+      \let \@tempa = \relax
+      \let \@tempb = \relax
+      \xdef \@gtempa {\expandafter \TE@eval \the \toks@ \TE@endeval}%
+    \endgroup
+    \@gtempa
+    \expandafter \endgroup
+  \ifTE@val
+    \expandafter\@firstoftwo
+  \else
+    \expandafter\@secondoftwo
+  \fi
+}
+
+\endinput