summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/curve
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2010-12-14 23:18:34 +0000
committerKarl Berry <karl@freefriends.org>2010-12-14 23:18:34 +0000
commit27de50ad58993af1b9751d0f2ef6691f692304ca (patch)
treed28573f8e28025f3d7f5a66969956d9ff588b8f3 /Master/texmf-dist/tex/latex/curve
parentb8b55a100110782bb066a4471211ecb691e2399e (diff)
curve 1.16 (15dec10)
git-svn-id: svn://tug.org/texlive/trunk@20745 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/curve')
-rw-r--r--Master/texmf-dist/tex/latex/curve/curve.cls375
1 files changed, 302 insertions, 73 deletions
diff --git a/Master/texmf-dist/tex/latex/curve/curve.cls b/Master/texmf-dist/tex/latex/curve/curve.cls
index 41381662b30..928f324b3e8 100644
--- a/Master/texmf-dist/tex/latex/curve/curve.cls
+++ b/Master/texmf-dist/tex/latex/curve/curve.cls
@@ -4,12 +4,14 @@
%%
%% The original source files were:
%%
-%% curve.dtx
+%% curve.dtx (with options: `header,curve')
%%
%% Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007 Didier Verna
+%% Copyright (C) 2010 Didier Verna
+
%% This file is part of CurVe.
%% CurVe may be distributed and/or modified under the
@@ -38,12 +40,12 @@
%% Grave accent \` Left brace \{ Vertical bar \|
%% Right brace \} Tilde \~}
\NeedsTeXFormat{LaTeX2e}
-\ProvidesClass{curve}[2008/02/25 v1.15
- Curriculum Vitae class for LaTeX2e]
+\ProvidesClass{curve}[2010/12/14 v1.16 Curriculum Vitae class for LaTeX2e]
\RequirePackage{ltxtable}
\RequirePackage{ifthen}
\RequirePackage{calc}
+\RequirePackage{filehook}
\gdef\@nextentry{}
@@ -76,7 +78,6 @@
\let\@key\@alwayskey
\DeclareOption{skipsamekey}{\let\@key\@maybekey}
-
\newcommand\@entry[2][]{%
\gdef\@nextentry{}\@key{#1}%
\egroup% end of \noalign opened in \entry.
@@ -92,6 +93,24 @@
\noalign\bgroup\gdef\@beforespace{\subrubricbeforespace}%
\@ifstar{\@sentry}{\@entry}}
+\newlength{\@almosttextwidth}
+\AtBeginDocument{\setlength\@almosttextwidth{\textwidth-\hfuzz}}
+
+\newcommand\@text[1]{%
+ \gdef\@nextentry{}%
+ \egroup% end of \noalign opened in \text.
+ \multicolumn{3}{@{}p{\@almosttextwidth}@{}}{#1}\\}
+
+\newcommand\@stext{%
+ \gdef\@nextentry{\egroup\\\par}%
+ \egroup% end of \noalign opened in \text.
+ \multicolumn{3}{@{}p{\@almosttextwidth}@{}}\bgroup}
+
+\newcommand\text{%
+ \@nextentry
+ \noalign\bgroup\gdef\@beforespace{\subrubricbeforespace}%
+ \@ifstar{\@stext}{\@text}}
+
\newcommand\noentry[1]{\@nextentry
\noalign{\gdef\@nextentry{}}#1&&\kill}
@@ -111,9 +130,9 @@
{\@subrubricfont#1}
\@subrubricmark{#1}}
-
\def\@clcccolsep{\hspace{\tabcolsep}\ifx\@prefix\@empty~\fi}
+
\def\@subrubric@l#1{\multicolumn{3}{@{}l@{}}{\@@subrubric{#1}}}
\def\@subrubric@c#1{\multicolumn{3}{@{}c@{}}{\@@subrubric{#1}}}
\def\@subrubric@r#1{\multicolumn{3}{@{}r@{}}{\@@subrubric{#1}}}
@@ -138,9 +157,6 @@
\noalign{\gdef\@nextentry{}}%
\@subrubric{#1}\\*[\subrubricspace]\par}
-\newlength{\@almosttextwidth}
-\AtBeginDocument{\setlength\@almosttextwidth{\textwidth-\hfuzz}}
-
\def\@rubricfont{\Large\bfseries}
\newcommand\rubricfont[1]{\gdef\@rubricfont{#1}}
@@ -158,15 +174,12 @@
\let\@rubrichead\@rubrichead@c
\newcommand\rubricalignment[1]{%
- \def\@curve@temp@a{\let\@rubrichead}
- \expandafter\@curve@temp@a\csname @rubrichead@#1\endcsname
- \@ifundefined{@rubrichead}{%
+ \def\@curve@temp@a{\let\@rubrichead} \expandafter\@curve@temp@a\csname
+ @rubrichead@#1\endcsname \@ifundefined{@rubrichead}{%
\ClassError{curve}{Invalid rubric alignment}{%
You have called \protect\rubricalignment\space with an invalid value.%
- \MessageBreak
- Valid options include l, c, r, cl and cc.\MessageBreak
- Type X <return> to quit, fix the typo, and rerun LaTeX.}}
-}
+ \MessageBreak Valid options include l, c, r, cl and cc.\MessageBreak
+ Type X <return> to quit, fix the typo, and rerun LaTeX.}} }
\newlength\rubricafterspace
\setlength\rubricafterspace{0pt}
@@ -273,8 +286,7 @@
\newlength\rightheader@width
\def\makeheaders@l#1{%
- \setlength\photo@width{\photo@scale\textwidth}
- \setlength\leftheader@width{%
+ \setlength\photo@width{\photo@scale\textwidth} \setlength\leftheader@width{%
(\textwidth - \photo@width - \photosep) * \real{\header@scale}}
\setlength\rightheader@width{%
\textwidth - \photo@width - \photosep - \leftheader@width}
@@ -355,9 +367,8 @@
\newcommand\titlealignment[1]{\@titlealignment{titlealignment}{#1}}
\def\@@maketitle{%
- \bgroup\trivlist\@title@lignment\item\relax
- {\@titlefont\@title}
- \ifx\@subtitle\@undefined\else\\\@subtitlefont\@subtitle\fi
+ \bgroup\trivlist\@title@lignment\item\relax {\@titlefont\@title}
+ \ifx\@subtitle\@undefined\else\\\@subtitlefont\@subtitle\fi
\endtrivlist\egroup
\vspace\titlespace}
@@ -366,8 +377,7 @@
\newcommand\maketitle{\@ifnextchar[%]
\@maketitle\@@maketitle}
-\let\@flavor\empty
-\newcommand\flavor[1]{\gdef\@flavor{#1}
+\let\@flavor\empty \newcommand\flavor[1]{\gdef\@flavor{#1}
\ifx\@flavor\empty\else\edef\@flavor{.\@flavor}\fi}
\DeclareOption{ask}{%
@@ -380,69 +390,74 @@
\IfFileExists{#1.ltx}{\@iinput{#1.ltx}}{%
\IfFileExists{#1.tex}{\@iinput{#1.tex}}{%
\@iinput{#1}}}}}}
-
\renewcommand\input{\@ifnextchar\bgroup\@curveinput\@@input}
\newcommand\makerubric[1]{\LTXtable{\linewidth}{#1}}
-\let\newblock\par
+\PassOptionsToPackage{export}{splitbib}
+
+\let\newblock\empty
+\DeclareOption{openbib}{\let\newblock\par}
+
\newcounter{bibcount}
\newcounter{bibtotal}
-
\newif\ifcurve@revbib\curve@revbibfalse
-\DeclareOption{revbib}{\curve@revbibtrue}
-
-\AtBeginDocument{
- \@ifpackageloaded{multibbl}{
- %% multibbl version
- \def\bibliography#1#2#3{%
- \@ifundefined{#1@auxfile}{}{\expandafter\immediate%
-\write\csname #1@auxfile\endcsname{\string\bibdata{#2}}}%
- \def\bibname{#3}%
- \def\refname{#3}%
- \IfFileExists{#1.bbl}{\makerubric{#1.bbl}}{%
-\typeout{No file #1.bbl.}}}
- }{ %% standard version
- \def\bibliography#1{%
- \if@filesw
-\immediate\write\@auxout{\string\bibdata{#1}}%
- \fi
- \IfFileExists{\jobname.bbl}{\makerubric{\jobname.bbl}}{%
-\typeout{No file \jobname.bbl.}}}
- }
-}
-
-\AtBeginDocument{
- \@ifpackageloaded{bibentry}{}{
- \def\@lbibitem[#1]#2{\@sentry[\@biblabel{#1}]%
- \if@filesw{%
-\let\protect\noexpand%
-\immediate\write\@auxout{\string\bibcite{#2}{#1}}}
- \fi%
- \ignorespaces}
- \def\@bibitem#1{\stepcounter{bibcount}%
- \@sentry[\@biblabel{\ifcurve@revbib\thebibtotal\else\thebibcount\fi}]%
- \ifcurve@revbib\addtocounter{bibtotal}{-1}\fi%
- \if@filesw%
-\immediate\write\@auxout{\string\bibcite{#1}{\thebibcount}}%
- \fi%
- \ignorespaces}
- \renewcommand\bibitem{%
- %% #### FIXME: Dirty code duplication from \entry
- \@nextentry
- \noalign\bgroup\gdef\@beforespace{\subrubricbeforespace}%
- \@ifnextchar[%]
- \@lbibitem\@bibitem}
- }
-}
-
-\AtEndDocument{%
- \if@filesw%
+\AtEndDocument{
+ \if@filesw
\immediate\write\@auxout{\string\setcounter{bibtotal}{\thebibcount}}%
\fi}
+\DeclareOption{revbib}{\curve@revbibtrue}
\newcommand\listpubname[1]{\gdef\@listpubname{#1}}
+\def\@curve@input@#1{%
+ \IfFileExists{#1}{\makerubric{#1}}{\typeout{No file #1.}}}
+
+\let\@curveltx@lbibitem\@lbibitem
+\def\@curve@lbibitem[#1]#2{\@sentry[\@biblabel{#1}]%
+ \if@filesw
+ {\let\protect\noexpand%
+ \immediate\write\@auxout{\string\bibcite{#2}{#1}}}%
+ \fi%
+ \ignorespaces}
+\let\@lbibitem\@curve@lbibitem
+
+\let\@curveltx@bibitem\@bibitem
+\def\@curve@bibitem#1{\stepcounter{bibcount}%
+ \@sentry[\@biblabel{\ifcurve@revbib\thebibtotal\else\thebibcount\fi}]%
+ \ifcurve@revbib\addtocounter{bibtotal}{-1}\fi%
+ \if@filesw
+ \immediate\write\@auxout{\string\bibcite{#1}{\thebibcount}}%
+ \fi%
+ \ignorespaces}
+\let\@bibitem\@curve@bibitem
+
+\let\@curveltxbibitem\bibitem
+\def\@curvebibitem{%
+ %% #### FIXME: Dirty code duplication from \entry.
+ \@nextentry
+ \noalign\bgroup\gdef\@beforespace{\subrubricbeforespace}%
+ \@ifnextchar[%]
+ \@lbibitem\@bibitem}
+\let\bibitem\@curvebibitem
+
+\AtBeginOfFile{bibentry.sty}{
+ \let\@lbibitem\@curveltx@lbibitem
+ \let\@bibitem\@curveltx@bibitem
+ \let\bibitem\@curveltxbibitem}
+
+\AtBeginOfFile{splitbib.sty}{
+ \let\@lbibitem\@curveltx@lbibitem
+ \let\@bibitem\@curveltx@bibitem
+ \let\bibitem\@curveltxbibitem}
+
+\AtBeginOfFile{hyperref.sty}{
+ \let\@curveprevious@lbibitem\@lbibitem
+ \let\@curveprevious@bibitem\@bibitem}
+\AtEndOfFile{hyperref.sty}{
+ \let\@lbibitem\@curveprevious@lbibitem
+ \let\@bibitem\@curveprevious@bibitem}
+
\newenvironment{thebibliography}[1]{%
\let\@key\@alwayskey
\def\@prefix{}
@@ -453,6 +468,212 @@
\end{rubric}
}
+\let\@curveltxbibliography\bibliography
+\def\bibliography#1{%
+ \if@filesw
+ \immediate\write\@auxout{\string\bibdata{#1}}%
+ \fi%
+ \@curve@input@{\jobname.bbl}}
+
+\AtEndOfFile{multibbl.sty}{
+ \def\bibliography##1##2##3{%
+ \@ifundefined{##1@auxfile}{}{%
+ \expandafter\immediate\write\csname ##1@auxfile\endcsname%
+ {\string\bibdata{##2}}}%
+ \def\bibname{##3}%
+ \def\refname{##3}%
+ \@curve@input@{##1.bbl}}}
+
+\AtBeginOfFile{splitbib.sty}{
+ \let\bibliography\@curveltxbibliography}
+
+\AtEndOfFile{splitbib.sty}{
+ \def\NMSB@writeentry##1##2##3##4##5,{\ifx\relax ##5\relax
+ \else
+ \def\NMSB@currcat{##1##2##3##4}%
+ \def\NMSB@currcatlevelone{##1##2}%
+ \ifx\NMSB@currcatlevelone\NMSB@prevcatlevelone\else
+ \expandafter\ifx\csname NMSBtitle@\NMSB@currcatlevelone
+ \endcsname\relax
+ \else
+ \if@filesw
+ \expandafter\let\expandafter\NMSB@tempentry
+ \csname NMSBtitle@\NMSB@currcatlevelone\endcsname
+ \edef\NMSB@tempentry{\@backslashchar subrubric{\NMSB@tempentry}}
+ \expandafter\NMSB@writecatbib\expandafter{\NMSB@tempentry}
+ \expandafter\ifx\csname
+ NMSBcomment@\NMSB@currcatlevelone\endcsname\relax
+ \else
+ \immediate\write\NMSB@catbib{\string\vskip2ex^^J%
+ \string\hspace{-\leftmargin}\string\relax^^J%
+ \string\begin{minipage}{\textwidth}^^J%
+ \string\addtolength\string\parindent{20pt}^^J%
+ \string\noindent}
+ \expandafter\let\expandafter\NMSB@tempentry
+ \csname NMSBcomment@\NMSB@currcatlevelone\endcsname
+ \expandafter\NMSB@writecatbib\expandafter{%
+ \NMSB@tempentry^^J}%
+ \immediate\write\NMSB@catbib{\string\end{minipage}^^J%
+ \string\par\string\addpenalty{\NMSB@penalty}
+ \string\vskip2ex}
+ \fi
+ \fi
+ \fi
+ \xdef\NMSB@prevcatlevelone{##1##2}%
+ \ifnum\theSBresetdepth>0\relax
+ \setcounter{\@listctr}{0}%
+ \fi
+ \expandafter\ifx\csname NMSBprefix@\NMSB@prevcatlevelone
+ \endcsname\relax
+ \NMSB@currprefixlevelonetok{\relax}%
+ \else
+ \expandafter\expandafter\expandafter\NMSB@currprefixlevelonetok
+ \expandafter\expandafter\expandafter{%
+ \csname NMSBprefix@\NMSB@prevcatlevelone\endcsname}%
+ \fi
+ \fi
+ \ifx\NMSB@currcat\NMSB@prevcat\else
+ \ifnum\NMSB@currcat=9999\else
+ \expandafter\ifx\csname NMSBtitle@\NMSB@currcat\endcsname
+ \relax
+ \else
+ \if@filesw
+ \immediate\write\NMSB@catbib{%
+ \string\par\string\addpenalty{-\NMSB@halfpenalty}%
+ \string\relax^^J%
+ \string\item[]%
+ \string\SBsubtitle}%
+ \expandafter\let\expandafter\NMSB@tempentrya
+ \csname NMSBtitle@\NMSB@currcatlevelone\endcsname
+ \expandafter\let\expandafter\NMSB@tempentryb
+ \csname NMSBtitle@\NMSB@currcat\endcsname
+ \expandafter\NMSB@writecatbib\expandafter{%
+ \expandafter{\NMSB@tempentrya}}
+ \expandafter\NMSB@writecatbib\expandafter{%
+ \expandafter{\NMSB@tempentryb}}
+ \immediate\write\NMSB@catbib{\string\relax^^J%
+ \string\par\string\addpenalty{\NMSB@penalty}%
+ \string\relax}%
+ \expandafter\ifx\csname
+ NMSBcomment@\NMSB@currcat\endcsname\relax
+ \else
+ \immediate\write\NMSB@catbib{\string\vskip2ex^^J%
+ \string\hspace{-\leftmargin}\string\relax^^J%
+ \string\begin{minipage}{\textwidth}^^J%
+ \string\addtolength\string\parindent{20pt}^^J%
+ \string\noindent}
+ \expandafter\let\expandafter\NMSB@tempentry
+ \csname NMSBcomment@\NMSB@currcat\endcsname
+ \expandafter\NMSB@writecatbib\expandafter{%
+ \NMSB@tempentry^^J}%
+ \immediate\write\NMSB@catbib{\string\end{minipage}^^J%
+ \string\par\string\addpenalty{\NMSB@penalty}%
+ \string\vskip2ex}
+ \fi
+ \fi
+ \fi
+ \fi
+ \xdef\NMSB@prevcat{##1##2##3##4}%
+ \ifnum\theSBresetdepth>1\relax
+ \setcounter{\@listctr}{0}%
+ \fi
+ \expandafter\ifx\csname NMSBprefix@\NMSB@currcat\endcsname\relax
+ \expandafter\NMSB@currprefixtok\expandafter{%
+ \the\NMSB@currprefixlevelonetok}%
+ \else
+ \expandafter\expandafter\expandafter\NMSB@currprefixtok
+ \expandafter\expandafter\expandafter{%
+ \csname NMSBprefix@\NMSB@currcat\endcsname}
+ \fi
+ \fi
+ \expandafter\ifx\csname NMSBlabel@##5\endcsname\relax
+ \if@filesw
+ \stepcounter\@listctr
+ \expandafter\ifx\expandafter\relax\the\NMSB@currprefixtok
+ \def\NMSB@tempentry{}%
+ \else
+ \expandafter\expandafter\expandafter\def
+ \expandafter\expandafter\expandafter\NMSB@tempentry
+ \expandafter\expandafter\expandafter{%
+ \expandafter\the\expandafter\NMSB@currprefixtok
+ \the\value{\@listctr}}%
+ \edef\NMSB@tempentry{[\NMSB@tempentry]}
+ \fi
+ \edef\NMSB@tempentry{%
+ \@backslashchar bibitem%
+ \NMSB@tempentry{\csname NMSBkey@##5\endcsname}}%
+ \expandafter\NMSB@writecatbib\expandafter{%
+ \NMSB@tempentry}
+ \expandafter\let\expandafter\NMSB@tempentry
+ \csname NMSBentry@##5\endcsname%
+ \expandafter\NMSB@writecatbib\expandafter{%
+ \NMSB@tempentry}
+ \fi
+ \setbox\@tempboxa=\hbox{\the\NMSB@currprefixtok\the\value{\@listctr}}%
+ \ifdim\NMSB@reallylongest<\wd\@tempboxa
+ \setlength{\NMSB@reallylongest}{\wd\@tempboxa}%
+ \xdef\NMSB@reallylongestlabel{%
+ \expandafter\ifx\expandafter\relax\the\NMSB@currprefixtok
+ \else\the\NMSB@currprefixtok\fi\the\value{\@listctr}}%
+ \fi
+ \else
+ \if@filesw
+ \immediate\write\NMSB@catbib{%
+ \string\bibitem}
+ \expandafter\let\expandafter\NMSB@tempentry
+ \csname NMSBlabel@##5\endcsname
+ \expandafter\NMSB@writecatbib\expandafter{%
+ \expandafter[\NMSB@tempentry]}%
+ \immediate\write\NMSB@catbib{%
+ {\csname NMSBkey@##5\endcsname}}%
+ \expandafter\let\expandafter\NMSB@tempentry
+ \csname NMSBentry@##5\endcsname%
+ \expandafter\NMSB@writecatbib\expandafter{%
+ \NMSB@tempentry^^J^^J}
+ \fi
+ \setbox\@tempboxa=\hbox{\csname NMSBlabel@##5\endcsname}%
+ \ifdim\NMSB@reallylongest<\wd\@tempboxa
+ \setlength{\NMSB@reallylongest}{\wd\@tempboxa}%
+ \expandafter\let\expandafter\NMSB@reallylongestlabel\csname
+ NMSBlabel@##5\endcsname
+ \fi
+ \fi
+ \fi
+ }
+ \def\endthebibliography{%
+ \usecounter{enumiv}%
+ \edef\NMSB@sortedvaluelist{%
+ \expandafter\NMSBsortlt\expandafter{\NMSB@valuelist}}%
+ \expandafter\NMSB@writelist\expandafter{\NMSB@sortedvaluelist}%
+ \if@filesw
+ \immediate\write\NMSB@catbib{%
+ \string\end{thebibliography}}
+ \immediate\closeout\NMSB@catbib
+ \fi
+ \begingroup
+ \ifNMSB@newchap\else
+ \@ifundefined{chapter}{\def\section####1####2{}}{%
+ \def\chapter####1####2{}}%
+ \fi
+ \let\thebibliography\@NMSBorig@thebibliography
+ \let\endthebibliography\@NMSBorig@endthebibliography
+ \let\bibitem\@curvebibitem
+ \let\@lbibitem\@curve@lbibitem
+ \let\@bibitem\@curve@bibitem
+ \@curve@input@{\jobname.sbb}
+ \endgroup
+ \ifx\NMSB@missingcat\NMSB@empty\else
+ \expandafter\NMSB@warnnocateg\NMSB@missingcat\end
+ \fi
+ \ifNMSB@strict
+ \ifx\NMSB@doublecat\NMSB@empty\else
+ \expandafter\NMSB@warndblcateg\NMSB@doublecat\end
+ \fi
+ \fi
+ \ifdim\NMSB@reallylongest=\NMSB@longest\relax\else
+ \NMSB@warnwronglongest
+ \fi}}
+
\DeclareOption{english}{%
\continuedname{~(continued)}
\listpubname{List of Publications}}
@@ -598,6 +819,14 @@
\let\@subrubricmark\@gobble
}
+\DeclareOldFontCommand{\rm}{\normalfont\rmfamily}{\mathrm}
+\DeclareOldFontCommand{\sf}{\normalfont\sffamily}{\mathsf}
+\DeclareOldFontCommand{\tt}{\normalfont\ttfamily}{\mathtt}
+\DeclareOldFontCommand{\bf}{\normalfont\bfseries}{\mathbf}
+\DeclareOldFontCommand{\it}{\normalfont\itshape}{\mathit}
+\DeclareOldFontCommand{\sl}{\normalfont\slshape}{\@nomath\sl}
+\DeclareOldFontCommand{\sc}{\normalfont\scshape}{\@nomath\sc}
+
\endinput
%%
%% End of file `curve.cls'.