diff options
author | Karl Berry <karl@freefriends.org> | 2006-01-13 00:00:29 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2006-01-13 00:00:29 +0000 |
commit | 8b8fbae5990dee3b8ab739df0de8b7c365e4d227 (patch) | |
tree | 824392c1bb07fe8c8b620efd3992cc0daa3e433a /Master/texmf-dist/tex/latex/ncctools/watermark.sty | |
parent | e9351f8ac4f8603d6020be78e092e939e24d89d0 (diff) |
ncctools
git-svn-id: svn://tug.org/texlive/trunk@1132 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/ncctools/watermark.sty')
-rw-r--r-- | Master/texmf-dist/tex/latex/ncctools/watermark.sty | 83 |
1 files changed, 83 insertions, 0 deletions
diff --git a/Master/texmf-dist/tex/latex/ncctools/watermark.sty b/Master/texmf-dist/tex/latex/ncctools/watermark.sty new file mode 100644 index 00000000000..38ca43c445f --- /dev/null +++ b/Master/texmf-dist/tex/latex/ncctools/watermark.sty @@ -0,0 +1,83 @@ +%% +%% This is file `watermark.sty', +%% generated with the docstrip utility. +%% +%% The original source files were: +%% +%% watermark.dtx (with options: `package') +%% +%% IMPORTANT NOTICE: +%% +%% This file is a generated file from the sources of the `ncctools' +%% bundle. +%% +%% You are not allowed to modify this file. +%% +%% You are allowed to distribute this file if and only if +%% it is distributed with the corresponding source files in +%% the `ncctools' bundle. +%% +%% For the copying and distribution conditions of the source files, +%% see the README file distributed with the ncctools bundle. +%% +%% File: watermark.dtx Copyright (C) 2002--2004 by Alexander I. Rozhenko +%% +\NeedsTeXFormat{LaTeX2e} +\ProvidesPackage{watermark} + [2004/12/09 v1.1 Watermarks (NCC)] +\AtBeginDocument{ + \let\WMK@begindvi\@begindvi + \def\@begindvi{% + \WMK@begindvi + \WMK@insert + \global\let\WMK@begindvi\@begindvi + \gdef\@begindvi{\WMK@begindvi\WMK@insert}% + }% +} +\def\WMK@insert{% + \let\WMK@head\@thehead + \def\@thehead{\WMK@hook\WMK@head}% +} +\def\WMK@hook{% + \begin{picture}(0,0)\relax + \ifx\WMK@this\relax + \if@twoside + \ifodd\c@page\WMK@odd\else\WMK@even\fi + \else + \WMK@odd + \fi + \else + \WMK@this \global\let\WMK@this\relax + \fi + \end{picture}% + \ifx\WMK@thishead\relax \else + \let\WMK@head\WMK@thishead + \global\let\WMK@thishead\relax + \fi + \ifx\WMK@head\@empty \hfil + \else + \def\@tempa{\@oddhead}% + \ifx\WMK@head\@tempa + \ifx\@oddhead\@empty \hfil \fi + \fi + \fi +} +\let\WMK@thishead\relax +\let\WMK@this\relax +\let\WMK@odd\@empty +\let\WMK@even\@empty +\newcommand{\watermark}[1]{\leftwatermark{#1}\rightwatermark{#1}} +\newcommand{\leftwatermark}[1]{\gdef\WMK@even{#1}} +\newcommand{\rightwatermark}[1]{\gdef\WMK@odd{#1}} +\newcommand{\thiswatermark}[1]{\gdef\WMK@this{#1}} +\newcommand{\thispageheading}[1]{% + \def\@tempa{#1}% + \ifx\@tempa\@empty + \global\let\WMK@thishead\@empty + \else + \gdef\WMK@thishead{\parbox[t]\textwidth{#1}}% + \fi +} +\endinput +%% +%% End of file `watermark.sty'. |