diff options
author | Karl Berry <karl@freefriends.org> | 2009-06-24 16:35:13 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2009-06-24 16:35:13 +0000 |
commit | d73a503687f31a927aea191ec9ed3cf1c950fd8f (patch) | |
tree | 7dc5b70b51a539ac785341bad4387d836bb371c2 /Master/texmf-dist/tex/latex/disser/disser.cls | |
parent | 3c2360d0385b88c9a20bd20ac33c71d9cec07294 (diff) |
disser update (23jun09)
git-svn-id: svn://tug.org/texlive/trunk@13941 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/disser/disser.cls')
-rw-r--r-- | Master/texmf-dist/tex/latex/disser/disser.cls | 349 |
1 files changed, 204 insertions, 145 deletions
diff --git a/Master/texmf-dist/tex/latex/disser/disser.cls b/Master/texmf-dist/tex/latex/disser/disser.cls index 960daf88995..2e33f682d9d 100644 --- a/Master/texmf-dist/tex/latex/disser/disser.cls +++ b/Master/texmf-dist/tex/latex/disser/disser.cls @@ -44,11 +44,12 @@ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \NeedsTeXFormat{LaTeX2e} -\ProvidesClass{disser}[2008/04/08 1.1.1 Document class for dissertations.] +\ProvidesClass{disser}[2009/06/11 1.1.2 Document class for dissertations] \def\substyle@ext{.rtx} \RequirePackage{ifpdf} + \newif\if@restonecol \newif\if@titlepage\@titlepagetrue \newif\if@openright\@openrightfalse @@ -68,13 +69,9 @@ \RequirePackage{kvoptions}[2006/08/17] \DeclareOption{href}{\Dis@hreftrue} - \DeclareOption{subf}{\Dis@subftrue} - \DeclareOption{libcat}{\Dis@libcattrue} - \DeclareOption{facsimile}{\Dis@facsimiletrue} - \DeclareOption{noams}{\Dis@amsfalse} \SetupKeyvalOptions{ @@ -181,7 +178,7 @@ \Dis@autoreftrue } -\ExecuteOptions{a4paper,14pt,oneside,titlepage,onecolumn,final,openany} +\ExecuteOptions{a4paper,14pt,oneside,titlepage,onecolumn,final,openany,candidate} \ProcessOptions \ProcessKeyvalOptions{Dis} @@ -263,32 +260,35 @@ \DeclareRobustCommand*\cal{\@fontswitch\relax\mathcal} \DeclareRobustCommand*\mit{\@fontswitch\relax\mathnormal} +\providecommand\deflength[2]{\newlength{#1}\setlength{#1}{#2}} + \setlength\lineskip{1\p@} \setlength\normallineskip{1\p@} + \newcommand\singlespacing {\renewcommand\baselinestretch{1}\normalsize} \newcommand\onehalfspacing{\renewcommand\baselinestretch{1.5}\normalsize} \newcommand\doublespacing {\renewcommand\baselinestretch{2}\normalsize} \onehalfspacing + +\setlength\parindent{1cm} + \setlength\parskip{0\p@ \@plus \p@} \setlength\columnsep{10\p@} -\setlength\columnseprule{0\p@} -\def\@seccntformat#1{% - \csname prethe#1\endcsname% - \csname the#1\endcsname% - \csname postthe#1\endcsname% -} -\def\@tocseccntformat#1{% - \csname tocprethe#1\endcsname% - \csname tocthe#1\endcsname% - \csname tocpostthe#1\endcsname% -} +\setlength\columnseprule{0\p@} \@lowpenalty 51 \@medpenalty 151 \@highpenalty 301 +\let\@afterindentfalse\@afterindenttrue +\@afterindenttrue + +\lccode`\-=`\- +\defaulthyphenchar=127 + + %%% From File: counters.dtx \setcounter{tocdepth}{1} @@ -371,6 +371,18 @@ \def\partpagestyle#1{\gdef\@partpagestyle{#1}} \partpagestyle{empty} +\def\@seccntformat#1{% + \csname prethe#1\endcsname% + \csname the#1\endcsname% + \csname postthe#1\endcsname% +} + +\def\@tocseccntformat#1{% + \csname tocprethe#1\endcsname% + \csname tocthe#1\endcsname% + \csname tocpostthe#1\endcsname% +} + \newcommand\part{ \if@openright \cleardoublepage @@ -421,8 +433,7 @@ \if@tempswa\twocolumn\fi } -\newcommand*\l@part[2] -{% +\newcommand*\l@part[2]{% \ifnum \c@tocdepth >-2\relax \addpenalty{-\@highpenalty}% \addvspace{2.25em \@plus\p@}% @@ -460,6 +471,7 @@ \providecommand\chapterfont{\Large\bfseries} \providecommand\beforechapter{} \providecommand\afterchapter{\par\nobreak\vskip 20\p@} +\providecommand\chapterindent{0pt} \newcommand*\chaptermark[1]{} \newcommand\chapter{% @@ -491,16 +503,15 @@ \@afterheading \fi } -\def\@makechapterhead#1{% - {% - \parindent \z@ \raggedright \normalfont - \ifnum \c@secnumdepth >\m@ne - {\thechapterfont\thechapteralign\@seccntformat{chapter}} - \fi - \interlinepenalty\@M - \chapterfont\chapteralign\beforechapter #1\afterchapter - } -} +\def\@makechapterhead#1{{% + \parindent\z@ + \normalfont\hskip\chapterindent% + \ifnum \c@secnumdepth >\m@ne + {\thechapterfont\thechapteralign\@seccntformat{chapter}} + \fi + \interlinepenalty\@M + \chapterfont\chapteralign\beforechapter #1\afterchapter +}} \def\@schapter#1{ \if@twocolumn @@ -511,13 +522,12 @@ \fi } -\def\@makeschapterhead#1{% - {% - \parindent \z@ \raggedright - \normalfont\interlinepenalty\@M - \chapteralign{\chapterfont\beforechapter #1\afterchapter} - } -} +\def\@makeschapterhead#1{{% + \parindent\z@ + \normalfont\hskip\chapterindent% + \interlinepenalty\@M + \chapteralign\chapterfont\beforechapter #1\afterchapter +}} \newcommand*\l@chapter[2]{% \ifnum \c@tocdepth >\m@ne \addpenalty{-\@highpenalty} @@ -554,6 +564,7 @@ \providecommand\appendixfont{\Large\bfseries} \providecommand\beforeappendix{} \providecommand\afterappendix{\par\nobreak\vskip 20\p@} +\providecommand\appendixindent{0pt} \newcommand\appendix{ \setcounter{chapter}{0} \setcounter{section}{0} @@ -573,6 +584,7 @@ \let\oldchapteralign=\chapteralign \let\oldchapterfont=\chapterfont + \let\oldchapterindent=\chapterindent \let\oldbeforechapter=\afterchapter \let\oldafterchapter=\afterchapter \let\oldthechapter=\thechapter @@ -594,6 +606,7 @@ \renewcommand\chapterfont{\appendixfont} \renewcommand\beforechapter{\beforeappendix} \renewcommand\afterchapter{\afterappendix} + \renewcommand\chapterindent{\appendixindent} \gdef\thechapter{\theappendix} } @@ -723,9 +736,45 @@ \providecommand\postthesubparagraph{.~} \providecommand\subparagraphindent{\parindent} +\providecommand\subparagraphalign{\raggedright} \providecommand\beforesubparagraph{3.25ex \@plus1ex \@minus .2ex} \providecommand\aftersubparagraph{-1em} -\providecommand\subparagraphalign{\raggedright} + +\def\@startsection#1#2{% + \if@noskipsec \leavevmode \fi + \par + \@tempskipa \csname before#1\endcsname\relax + \@afterindenttrue + \ifdim \@tempskipa <\z@ + \@tempskipa -\@tempskipa \@afterindentfalse + \fi + \if@nobreak + \everypar{}% + \else + \addpenalty\@secpenalty\addvspace\@tempskipa + \fi + \@ifstar + {\@ssect{\csname #1indent\endcsname}% + {\csname before#1\endcsname}{\csname after#1\endcsname}% + {\csname #1font\endcsname\csname #1align\endcsname}}% + {\@dblarg{\@sect{#1}{#2}{\csname #1indent\endcsname}% + {\csname before#1\endcsname}{\csname after#1\endcsname}% + {\csname #1font\endcsname\csname #1align\endcsname}}}% +} + +\def\@ssect#1#2#3#4#5{% + \@tempskipa #3\relax + \ifdim \@tempskipa>\z@ + \begingroup + #4{% + \@hangfrom{\hskip #1}% + \interlinepenalty \@M #5\@@par}% + \endgroup + \else + \def\@svsechd{#4{\hskip #1\relax #5}}% + \fi + \@xsect{#3}% +} \def\@sect#1#2#3#4#5#6[#7]#8{% \ifnum #2>\c@secnumdepth @@ -760,54 +809,41 @@ \fi \@xsect{#5}% } -\def\@tocline#1#2#3#4#5#6{% + +\def\@tocline#1#2#3#4{% \ifnum #2>\c@tocdepth \else \vskip \z@ \@plus.2\p@ - {\leftskip #3\relax \rightskip \@tocrmarg \parfillskip -\rightskip - \parindent #3\relax\@afterindenttrue + {\leftskip \csname toc#1indent\endcsname\relax% + \rightskip \@tocrmarg \parfillskip -\rightskip + \parindent \csname toc#1indent\endcsname\relax% + \@afterindenttrue \interlinepenalty\@M \leavevmode - \@tempdima #4\relax + \@tempdima \csname toc#1nameindent\endcsname\relax \csname toc#1font\endcsname \advance\leftskip \@tempdima \null\nobreak\hskip -\leftskip - {#5}\nobreak + {#3}\nobreak \csname toc#1fillfont\endcsname \csname toc#1fill\endcsname\hfill - \nobreak\hb@xt@\@pnumwidth{\hfil\csname toc#1numfont\endcsname #6}% + \nobreak\hb@xt@\@pnumwidth{\hfil\csname toc#1numfont\endcsname #4}% \par% }% \fi } +\newcommand\section{\@startsection{section}{1}} +\newcommand*\l@section{\@tocline{section}{1}} -\newcommand\section{\@startsection{section}{1} - {\sectionindent}{\beforesection}% - {\aftersection}{\sectionfont\sectionalign}} -\newcommand*\l@section{\@tocline{section}{1}{\tocsectionindent}% -{\tocsectionnameindent}} - -\newcommand\subsection{\@startsection{subsection}{2} - {\subsectionindent}{\beforesubsection}% - {\aftersubsection}{\subsectionfont\subsectionalign}} -\newcommand*\l@subsection{\@tocline{subsection}{2}{\tocsubsectionindent}% -{\tocsubsectionnameindent}} +\newcommand\subsection{\@startsection{subsection}{2}} +\newcommand*\l@subsection{\@tocline{subsection}{2}} -\newcommand\subsubsection{\@startsection{subsubsection}{3} - {\subsubsectionindent}{\beforesubsubsection}% - {\aftersubsubsection}{\subsubsectionfont\subsubsectionalign}} -\newcommand*\l@subsubsection{\@tocline{subsubsection}{3}{\tocsubsubsectionindent}% -{\tocsubsubsectionnameindent}} +\newcommand\subsubsection{\@startsection{subsubsection}{3}} +\newcommand*\l@subsubsection{\@tocline{subsubsection}{3}} -\newcommand\paragraph{\@startsection{paragraph}{4} - {\paragraphindent}{\beforeparagraph}% - {\afterparagraph}{\paragraphfont\paragraphalign}} -\newcommand*\l@paragraph{\@tocline{paragraph}{4}{\tocparagraphindent}% -{\tocparagraphnameindent}} +\newcommand\paragraph{\@startsection{paragraph}{4}} +\newcommand*\l@paragraph{\@tocline{paragraph}{4}} -\newcommand\subparagraph{\@startsection{subparagraph}{5} - {\subparagraphindent}{\beforesubparagraph}% - {\aftersubparagraph}{\subparagraphfont\subparagraphalign}} -\newcommand*\l@subparagraph{\@tocline{subparagraph}{5}{\tocsubparagraphindent}% -{\tocsubparagraphnameindent}} +\newcommand\subparagraph{\@startsection{subparagraph}{5}} +\newcommand*\l@subparagraph{\@tocline{subparagraph}{5}} %%% From File: lists.dtx @@ -863,10 +899,8 @@ \renewcommand\floatpagefraction{.5} \renewcommand\dbltopfraction{.7} \renewcommand\dblfloatpagefraction{.5} -\newlength\abovecaptionskip -\setlength\abovecaptionskip{10\p@} -\newlength\belowcaptionskip -\setlength\belowcaptionskip{0\p@} +\deflength\abovecaptionskip{10\p@} +\deflength\belowcaptionskip{0\p@} \newcommand\captionlabeldelim{.} \newcommand\captionfont{\small} \newcommand\captionlabelfont{\small\selectfont} @@ -908,15 +942,29 @@ %%% From File: footnote.dtx -\renewcommand\footnoterule{% +\def\thefootnote{\@arabic\c@footnote} + +\def\thempfootnote{{\itshape\@alph\c@mpfootnote}} + +\def\footnoterule{% \kern-3\p@\hrule\@width.4\columnwidth\kern2.6\p@ } + +\providecommand\prethefootnote{} +\providecommand\postthefootnote{} +\providecommand\prefootnote{\;} +\deflength{\footnoteindent}{\parindent} + +\def\@makefnmark{\hbox{\prethefootnote% +\@textsuperscript{\normalfont\@thefnmark}% +\postthefootnote}} + \newcommand\@makefntext[1]{% - \parindent 1em% - \noindent - \hb@xt@1.8em{\hss\@makefnmark}#1 + \noindent\hspace{\footnoteindent}% + \@makefnmark\prefootnote #1 } + %%% From File: env.dtx \newenvironment{description} @@ -951,6 +999,7 @@ \fi }{\if@twocolumn\else\endquotation\fi} \fi + \newenvironment{quotation}{ \list{}{ \listparindent 1.5em @@ -960,10 +1009,12 @@ } \item\relax }{\endlist} + \newenvironment{quote}{ \list{}{\rightmargin\leftmargin} \item\relax }{\endlist} + \newenvironment{titlepage}{ \if@twocolumn \@restonecoltrue\onecolumn @@ -976,6 +1027,7 @@ \if@restonecol\twocolumn\else\newpage\fi \if@twoside\else\setcounter{page}\@ne\fi } + \newenvironment{figure}{\@float{figure}}{\end@float} \newenvironment{figure*}{\@dblfloat{figure}}{\end@dblfloat} \newenvironment{table}{\@float{table}}{\end@float} @@ -986,7 +1038,7 @@ \global\@namedef{#1style}{\itshape} \global\@namedef{the#1style}{\bfseries} \global\@namedef{postthe#1}{.} - \global\@namedef{oparg#1style}{\rm} + \global\@namedef{oparg#1style}{\upshape} \global\@namedef{preoparg#1}{(} \global\@namedef{postoparg#1}{)} } @@ -999,19 +1051,20 @@ \@opargbegintheorem{#1}{#2}{#3}\ignorespaces} \def\@begintheorem#1#2{\trivlist - \item[\hskip \labelsep{\csname the#1style\endcsname #2\ % - \csname the#1\endcsname\unskip% - \csname postthe#1\endcsname}]% - \csname #1style\endcsname} + \item[\hskip\labelsep% + {\csname the#1style\endcsname #2\ % + \csname the#1\endcsname\unskip\csname postthe#1\endcsname}]% + \csname #1style\endcsname% +} \def\@opargbegintheorem#1#2#3{\trivlist - \item[\hskip \labelsep{% - {\csname the#1style\endcsname #2}\ % - \csname the#1\endcsname\ % + \item[\hskip\labelsep% + {\csname the#1style\endcsname #2\ \csname the#1\endcsname}\ % {\csname oparg#1style\endcsname% \csname preoparg#1\endcsname #3% - \csname postoparg#1\endcsname}}]% - \csname #1style\endcsname} + \csname postoparg#1\endcsname}]% + \csname #1style\endcsname% +} \def\@endtheorem{\endtrivlist} @@ -1130,6 +1183,8 @@ \newcommand\today{} +\input{titledefs\substyle@ext} + \if@titlepage \newcommand\titlefont{\Large\bfseries} \newcommand\topiclabelfont{\large} @@ -1137,7 +1192,6 @@ \newcommand\instfont{\normalfont} \newcommand\cdsep{~-- } - \input{titledefs\substyle@ext} \newcommand\maketitle{ \thispagestyle{empty} \vspace*{-2cm} @@ -1160,29 +1214,6 @@ \setcounter{footnote}{0} \else %\if@titlepage \newcommand\maketitle{% - \par - \begingroup - \renewcommand\thefootnote{\@fnsymbol\c@footnote}% - \def\@makefnmark{\rlap{\@textsuperscript{\normalfont\@thefnmark}}}% - \long\def\@makefntext##1{% - \parindent 1em\noindent - \hb@xt@1.8em{\hss\@textsuperscript{\normalfont\@thefnmark}}##1% - }% - \if@twocolumn - \ifnum \col@number=\@ne - \@maketitle - \else - \twocolumn[\@maketitle]% - \fi - \else - \newpage - \global\@topnum\z@ - \@maketitle - \fi - \thispagestyle{plain} - \endgroup - \setcounter{footnote}{0}% - \global\let\thanks\relax \global\let\maketitle\relax \global\let\@maketitle\relax @@ -1288,27 +1319,35 @@ %%% From File: custom.dtx -\let\@afterindentfalse\@afterindenttrue -\@afterindenttrue -\lccode`\-=`\- -\defaulthyphenchar=127 -\hyphenchar\font=127 \ifDis@ams \usepackage[intlimits]{amsmath} \usepackage{amssymb,amsfonts} \fi + \ifDis@times + \AtBeginDocument{ + \DeclareRobustCommand{\English}{% + \expandafter\set@hyphenmins\englishhyphenmins + \language\l@english}% + \let\Eng=\English + } \ifDis@mtpro \AtBeginDocument{% \IfFileExists{mtpro.sty}{ \usepackage[subscriptcorrection,nofontinfo,boldalphabet]{mtpro} - }{\PackageWarning{disser}{Unable to find mtpro package. Font is unchanged.}} + }{ + \PackageWarning{disser}% + {Unable to find mtpro package. Font is unchanged.} + } } \else \AtEndOfPackage{% \IfFileExists{txfonts.sty}{ \usepackage{txfonts} - }{\PackageWarning{disser}{Unable to find txfonts package. Font is unchanged.}} + }{ + \PackageWarning{disser}% + {Unable to find txfonts package. Font is unchanged.} + } } \fi \AtEndOfPackage{% @@ -1319,10 +1358,14 @@ }{ \IfFileExists{cyrtimes.sty}{ \usepackage{cyrtimes} - }{\PackageWarning{disser}{Unable to find pscyr or cyrtimes package. Font is unchanged.}} + }{ + \PackageWarning{disser}% + {Unable to find pscyr or cyrtimes package. Font is unchanged.} + } } } \fi + \ifDis@fixint \DeclareSymbolFont{EulerExtension}{U}{euex}{m}{n} \DeclareMathSymbol\intop\mathop{EulerExtension}{"52} @@ -1347,33 +1390,9 @@ \renewcommand{\idotsint}{\DOTSI\protect\MultiIntegral{0}} }{} \fi + \usepackage[square, comma, sort&compress, numbers]{natbib} -\def\metaphantom#1{% - \ifDis@href - \Hy@GlobalStepCount\Hy@linkcounter - \xdef\@currentHref{#1*.\the\Hy@linkcounter}% - \Hy@raisedlink{\hyper@anchorstart{\@currentHref}\hyper@anchorend}% - \fi -} -\newcommand\nchapter[1]{% - \chapter*{% - \metaphantom{chapter}\addcontentsline{toc}{chapter}{#1}% - #1% - \@mkboth{\MakeUppercase{#1}}{\MakeUppercase{#1}} - } -} -\newcommand\nsection[1]{% - \section*{\metaphantom{section}% - \addcontentsline{toc}{section}{#1}#1} -} -\newcommand\nsubsection[1]{% - \subsection*{\metaphantom{subsection}% - \addcontentsline{toc}{subsection}{#1}#1} -} -\newcommand\nsubsubsection[1]{% - \subsection*{\metaphantom{subsubsection}% - \addcontentsline{toc}{subsubsection}{#1}#1} -} + \renewcommand\bibsection{\nchapter{\bibname}} \renewenvironment{thebibliography}[1]{% @@ -1397,6 +1416,7 @@ \def\@noitemerr{\PackageWarning{natbib}{Empty `thebibliography' environment}} \endlist\vskip-\lastskip% } + \usepackage{wrapfig} \ifDis@subf \usepackage[config,font=small,labelsep=period]{caption,subfig} @@ -1404,6 +1424,7 @@ \providecommand\thefigsubsep{,~} \def\p@subfigure{\@nameuse{thefigure}\thefigsubsep} \fi + \ifpdf \ifDis@href \usepackage[pdftex,unicode,hyperfigures=true]{hyperref} @@ -1429,6 +1450,44 @@ \usepackage{hypernat} \usepackage[all]{hypcap} \fi + +\def\metaphantom#1{% + \ifDis@href + \Hy@GlobalStepCount\Hy@linkcounter + \xdef\@currentHref{#1*.\the\Hy@linkcounter}% + \Hy@raisedlink{\hyper@anchorstart{\@currentHref}\hyper@anchorend}% + \fi +} + +\newcommand\nchapter[1]{% + \if@openright + \cleardoublepage + \else + \clearpage + \fi + \thispagestyle{\@chapterpagestyle}% + \global\@topnum\z@ + \metaphantom{chapter} + {\def\\{ }\addcontentsline{toc}{chapter}{#1}}% + \@afterindentfalse + \@schapter{#1} +} +\newcommand\nsection[1]{% + \metaphantom{section}% + \addcontentsline{toc}{section}{#1} + \section*{#1} +} +\newcommand\nsubsection[1]{% + \metaphantom{subsection}% + \addcontentsline{toc}{subsection}{#1} + \subsection*{#1} +} +\newcommand\nsubsubsection[1]{% + \metaphantom{subsubsection}% + \addcontentsline{toc}{subsubsection}{#1} + \subsubsection*{#1} +} + \endinput %% %% End of file `disser.cls'. |