diff options
Diffstat (limited to 'Master/texmf-dist/tex/latex/cdpbundl/cdpaddon.sty')
-rw-r--r-- | Master/texmf-dist/tex/latex/cdpbundl/cdpaddon.sty | 128 |
1 files changed, 87 insertions, 41 deletions
diff --git a/Master/texmf-dist/tex/latex/cdpbundl/cdpaddon.sty b/Master/texmf-dist/tex/latex/cdpbundl/cdpaddon.sty index 44c9edd9999..32fd290baae 100644 --- a/Master/texmf-dist/tex/latex/cdpbundl/cdpaddon.sty +++ b/Master/texmf-dist/tex/latex/cdpbundl/cdpaddon.sty @@ -9,7 +9,8 @@ %% This is a generated file. %% It is part of a work named "C.D.P. Bundle". %% -%% Copyright (C) 1999-2006 by Gustavo MEZZETTI <mezzetti@math.unipd.it>. +%% Copyright (C) 1999-2015 by Gustavo MEZZETTI +%% <gustavo.mezzetti@istruzione.it>. %% %% The C.D.P. Bundle may be distributed and/or modified under the %% conditions of the LaTeX Project Public License, either version 1.3 @@ -17,7 +18,7 @@ %% 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/12/01 or later. +%% version 2005/12/01 or later. %% %% The C.D.P. Bundle has the LPPL maintenance status %% "author-maintained". @@ -29,7 +30,9 @@ %% %% Note that the distribution of this file alone is "distribution of %% only part of the Work" in the sense of the LaTeX Project Public -%% License, and is not allowed. +%% License, and should be avoided. +%% +%% February 8, 2015 (vers. 0.36) %% %% \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 @@ -48,12 +51,13 @@ %% Right brace \} Tilde \~} \NeedsTeXFormat{LaTeX2e}[1998/06/01] % LaTeX2e is required! \ProvidesPackage{cdpaddon} - [2006/01/01 v0.34 (development)] + [2015/02/08 v0.36 (development)] \@ifdefinable\@cdpaddon{\def\@cdpaddon{cdpaddon}} \def\do#1{\@ifdefinable#1{\newif#1}} \do\if@using@cdp@ \do\if@use@color@ \do\if@use@hyper@ +\do\if@custom@lh@ \@ifdefinable\@cdpaddon@printer{\let\@cdpaddon@printer\@empty} \@ifdefinable\@temp@cdpaddon@a{} \@ifdefinable\@temp@cdpaddon@b{} @@ -83,10 +87,15 @@ \@unknownoptionerror \fi } -\DeclareOption{bw}{\@use@color@false} -\DeclareOption{color}{\@use@color@true} -\DeclareOption{hypertext}{\@use@hyper@true} -\DeclareOption{plaintext}{\@use@hyper@false} +\DeclareOption{bw}{\@use@color@false\@custom@lh@false} +\DeclareOption{color}{\@use@color@true\@custom@lh@false} +\DeclareOption{hypertext}{\@use@hyper@true\@custom@lh@false} +\DeclareOption{plaintext}{\@use@hyper@false\@custom@lh@false} +\DeclareOption{customletterhead}{% + \@use@color@false + \@use@hyper@false + \@custom@lh@true +} \DeclareOption*{% \expandafter\@temp@cdpaddon@a\CurrentOption,printer:,\@@@% } @@ -96,39 +105,12 @@ \ifx\@cdpaddon@printer\@temp@cdpaddon@a \let\@cdpaddon@printer\@empty \fi -\def\@temp@cdpaddon@a#1#2#3#4#5{% - \IfFileExists{#1.sty}{% - \RequirePackage[#2]{#1}% - }{% - \@nameuse{@use@#3@false} - \PackageWarningNoLine{\@cdpaddon}{% - Can't find the #1 package;\MessageBreak - option #4 ignored (converted to #5)% - }% - }% -} \if@use@color@ - \@temp@cdpaddon@a{color}{}{color}{color}{bw} + \RequirePackage[dvipsnames]{color} \fi \if@use@hyper@ - \@temp@cdpaddon@a{hyperref}{}{hyper}{hypertext}{plaintext} + \RequirePackage{hyperref} \fi -\@ifdefinable\@back@folding@tag{\def\@back@folding@tag{% - \if@do@fold@ - \raisebox{\@lh@folding@ht}[\z@][\z@]{% - \makebox[\z@][l]{% - \color{strong@col}% - \dimen@ -\@lh@right@margin - \advance\dimen@ 1cm% - \kern\dimen@ \vbox{% - \kern -.1\p@ - \hrule \@height .1\p@ \@depth .1\p@ \@width 5mm% - \kern -.1\p@ - }% - }% - }% - \fi -}} \if@using@cdp@ \def\@temp@cdpaddon@a#1{% \@ifundefined{#1}{% @@ -141,7 +123,7 @@ is actually undefined.\MessageBreak Probably, you are using an old or modified version of that class.\MessageBreak - Proceed, but some of the colors won't come out right.% + Proceed, but keep your fingers crossed!% }% }% } @@ -202,8 +184,9 @@ \sbox{\@nameuse{#1}}{{\color{strong@col}\unhbox\z@}}% }% } - \@temp@cdpaddon@a{@folding@tag}{% - \let\@folding@tag\@back@folding@tag + \renewcommand*\foldingtagrule{% + \color{strong@col}% + \CDPFactoryFoldingTagRule } \@temp@cdpaddon@a{@logo@box@base}{% \savebox\@logo@box@base[\z@][r]{\setlength\unitlength{.625mm}% @@ -271,6 +254,67 @@ }\hss }} \fi + \newsavebox\@cdp@custom@lhead@box + \newsavebox\@cdp@custom@lfoot@box + \newsavebox\@cdp@custom@llogo@box + \def\@temp@cdpaddon@b#1#2#3#4{% + \newenvironment*{customletter#1}[1]{% + \setbox\@nameuse{@cdp@custom@l#1@box}\vbox to\z@ \bgroup + \hsize ##1\relax + \parskip \z@skip + #3% either \vss or nothing + \everypar{}% + \noindent\minipage[#2]{##1}% + \null + }{% + \par + \vskip -\baselineskip + \null + \endminipage + #4% either \vss or nothing + \egroup + \global \setbox \@ne \box \@nameuse{@cdp@custom@l#1@box}% + \xdef\@cdp@reserved{% + \setbox \@nameuse{@cdp@custom@l#1@box}\box \@ne + }% + \aftergroup \@cdp@reserved + }% + }% + \@temp@cdpaddon@b{head}{b}{\vss}{} + \@temp@cdpaddon@b{foot}{t}{}{\vss} + \@temp@cdpaddon@b{logo}{b}{\vss}{} + \newcommand*\ruleacrossheadorfoot[1][\z@]{\par + \setlength\@tempdima{#1}% + \@ifnextchar [% ] bracket matching + \@cdp@rule@across@x + {% + \@tempdimb \@tempdima + \@cdp@rule@across + }% + } + \@ifdefinable\@cdp@rule@across@x{\def\@cdp@rule@across@x[#1]{% + \setlength\@tempdimb{#1}% + \@cdp@rule@across + }} + \@ifdefinable\@cdp@rule@across{\def\@cdp@rule@across{ + \nobreak + \vskip -\baselineskip + \hb@xt@ \hsize {% + \kern \@tempdima \hrulefill \kern \@tempdimb + }% + }} + \if@custom@lh@ + \@temp@cdpaddon@a{@cdp@head}{\def\@cdp@head{% + \hss\copy\@cdp@custom@lhead@box\hss + }} + \@temp@cdpaddon@a{@cdp@foot}{\def\@cdp@foot{% + \hss\copy\@cdp@custom@lfoot@box\hss + }} + \@temp@cdpaddon@a{@cdp@logo}{\def\@cdp@logo{% + \hb@xt@ \z@ {\hss\copy\@cdp@custom@llogo@box}% + }} + \setlength\longindentation{.5\textwidth} + \fi \if@use@hyper@ \AtBeginDocument{% \@temp@cdpaddon@a{@name@and@WWW@box}{% @@ -302,7 +346,9 @@ \let\if@use@hyper@\@undefined \let\@use@hyper@true\@undefined \let\@use@hyper@false\@undefined -\let\@back@folding@tag\@undefined +\let\if@custom@lh@\@undefined +\let\@custom@lh@true\@undefined +\let\@custom@lh@false\@undefined \let\@cdpaddon@printer\@undefined \let\@temp@cdpaddon@b\@undefined \DeclareRobustCommand*\facesmile{\@face\smile} |