diff options
author | Karl Berry <karl@freefriends.org> | 2012-09-18 23:41:02 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2012-09-18 23:41:02 +0000 |
commit | cf73759c7df7a7750abb011e26039e3b0b2cee5a (patch) | |
tree | 04b35bd94c08d0a36f2d47bc3e42f94e9c874edd /Master/texmf-dist/source/latex | |
parent | bc26712b3009a6da7880bf1718125a08c03f05c2 (diff) |
tikzpagenodes (16sep12)
git-svn-id: svn://tug.org/texlive/trunk@27723 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/latex')
-rw-r--r-- | Master/texmf-dist/source/latex/tikzpagenodes/tikzpagenodes.dtx | 177 | ||||
-rw-r--r-- | Master/texmf-dist/source/latex/tikzpagenodes/tikzpagenodes.ins | 3 |
2 files changed, 132 insertions, 48 deletions
diff --git a/Master/texmf-dist/source/latex/tikzpagenodes/tikzpagenodes.dtx b/Master/texmf-dist/source/latex/tikzpagenodes/tikzpagenodes.dtx index 94fd9b07c86..4192608102c 100644 --- a/Master/texmf-dist/source/latex/tikzpagenodes/tikzpagenodes.dtx +++ b/Master/texmf-dist/source/latex/tikzpagenodes/tikzpagenodes.dtx @@ -1,29 +1,38 @@ % \iffalse meta-comment -% -% Copyright (C) 2011 by Martin Scharrer <martin@scharrer.me> -% --------------------------------------------------------------------------- -% 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 -% and version 1.3 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 Martin Scharrer. -% -% This work consists of the files tikzpagenodes.dtx and tikzpagenodes.ins -% and the derived filebase tikzpagenodes.sty. -% +%<=*COPYRIGHT> +%% Copyright (C) 2011-2012 by Martin Scharrer <martin@scharrer-online.de> +%% ---------------------------------------------------------------------- +%% 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 +%% and version 1.3 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 Martin Scharrer. +%% +%% This work consists of the files tikzpagenodes.dtx and tikzpagenodes.ins +%% and the derived filebase tikzpagenodes.sty. +%% +%<=/COPYRIGHT> % \fi % % \iffalse %<*driver> -\ProvidesFile{tikzpagenodes.dtx}[2011/09/15 v1.0 DTX file for tikzpagenodes package] +\ProvidesFile{tikzpagenodes.dtx}[% +%<=*DATE> + 2012/09/16 +%<=/DATE> +%<=*VERSION> + v1.1 +%<=/VERSION> + DTX file for tikzpagenodes package] \documentclass{ydoc} -\usepackage{tikzpagenodes} +\GetFileInfo{tikzpagenodes.dtx} +\usepackage{tikzpagenodes}[\filedate] \EnableCrossrefs \CodelineIndex \RecordChanges @@ -35,7 +44,7 @@ %</driver> % \fi % -% \CheckSum{188} +% \CheckSum{308} % % \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 @@ -55,6 +64,7 @@ % % % \changes{v1.0}{2011/09/15}{First version.} +% \changes{v1.1}{2012/09/16}{Corrected positions of 'marginpar area' nodes.} % % \DoNotIndex{\newcommand,\newenvironment} % @@ -62,9 +72,7 @@ % \GetFileInfo{tikzpagenodes.dtx} % \title{The \textsf{tikzpagenodes} package} % \author{Martin Scharrer\\ \url{martin@scharrer.me}} -% \makeatletter -% \def\@homepage{\url{http://www.ctan.org/pkg/tikzpagenodes}\\[\medskipamount]\url{https://bitbucket.org/martin_scharrer/tikzpagenodes}} -% \makeatother +% \repository{https://bitbucket.org/martin_scharrer/tikzpagenodes} % % \maketitle % \section{Introduction} @@ -142,13 +150,19 @@ % \iffalse %<*tikzpagenodes.sty> % \fi -% \subsection{Package Header} -% % \begin{macrocode} -\NeedsTeXFormat{LaTeX2e} -\ProvidesPackage{tikzpagenodes}[2011/09/15 v1.0 Special PGF/TikZ nodes for areas of the page] +%<!COPYRIGHT> +\NeedsTeXFormat{LaTeX2e}[1999/12/01] +\ProvidesPackage{tikzpagenodes}[% +%<!DATE> +%<!VERSION> +%<*DRIVER> + 2099/01/01 develop +%</DRIVER> + Special PGF/TikZ nodes for areas of the page] % \end{macrocode} % +% % \begin{macrocode} \RequirePackage{tikz} \RequirePackage{ifoddpage} @@ -191,58 +205,127 @@ % \end{macrocode} % \end{macro} % +% \subsection{Node Definition Macro} +% Most required macros can be |\let| to the |current page| node. +% \begin{macrocode} +\def\@newtikzpagenode#1{% + \expandafter\let\csname pgf@sh@ns@#1\expandafter\endcsname\csname pgf@sh@ns@current page\endcsname + \expandafter\let\csname pgf@sh@nt@#1\expandafter\endcsname\csname pgf@sh@nt@current page\endcsname + \expandafter\let\csname pgf@sh@pi@#1\expandafter\endcsname\csname pgf@sh@pi@current page\endcsname + \expandafter\def\csname pgf@sh@np@#1\endcsname +} +% \end{macrocode} % % \subsection{Current Page Text Area Node} % \begin{macrocode} -\expandafter\def\csname pgf@sh@ns@current page text area\endcsname{rectangle} -\expandafter\def\csname pgf@sh@np@current page text area\endcsname{% +\@newtikzpagenode{current page text area}{% \def\southwest{\pgfpoint{\current@textarea@left}{\paperheight-\current@textarea@top-\textheight}}% \def\northeast{\pgfpoint{\current@textarea@left+\textwidth}{\paperheight-\current@textarea@top}}% } -\expandafter\let\csname pgf@sh@nt@current page text area\expandafter\endcsname\csname pgf@sh@nt@current page\endcsname -\expandafter\let\csname pgf@sh@pi@current page text area\expandafter\endcsname\csname pgf@sh@pi@current page\endcsname % \end{macrocode} % % % \subsection{Current Page Marginpar Area Node} % \begin{macrocode} -\expandafter\def\csname pgf@sh@ns@current page marginpar area\endcsname{rectangle} -\expandafter\def\csname pgf@sh@np@current page marginpar area\endcsname{% +\@newtikzpagenode{current page marginpar area}{% \def\southwest{\pgfpoint - {\current@textarea@left\ifoddpageoroneside+\textwidth+\marginparsep\else-\marginparsep\fi}% + {\current@textarea@left\ifoddpageoroneside+\textwidth+\marginparsep\else-\marginparsep-\marginparwidth\fi}% {\paperheight-\current@textarea@top-\textheight}% }% \def\northeast{\pgfpoint - {\current@textarea@left\ifoddpageoroneside+\textwidth+\marginparsep+\marginparwidth\else-\marginparsep-\marginparwidth\fi}% + {\current@textarea@left\ifoddpageoroneside+\textwidth+\marginparsep+\marginparwidth\else-\marginparsep\fi}% {\paperheight-\current@textarea@top}% }% } -\expandafter\let\csname pgf@sh@nt@current page marginpar area\expandafter\endcsname\csname pgf@sh@nt@current page\endcsname -\expandafter\let\csname pgf@sh@pi@current page marginpar area\expandafter\endcsname\csname pgf@sh@pi@current page\endcsname % \end{macrocode} % % % \subsection{Current Page Header Area Node} % \begin{macrocode} -\expandafter\def\csname pgf@sh@ns@current page header area\endcsname{rectangle} -\expandafter\def\csname pgf@sh@np@current page header area\endcsname{% +\@newtikzpagenode{current page header area}{% \def\southwest{\pgfpoint{\current@textarea@left}{\paperheight-\current@textarea@top+\headsep}}% \def\northeast{\pgfpoint{\current@textarea@left+\textwidth}{\paperheight-\current@textarea@top+\headsep+\headheight}}% } -\expandafter\let\csname pgf@sh@nt@current page header area\expandafter\endcsname\csname pgf@sh@nt@current page\endcsname -\expandafter\let\csname pgf@sh@pi@current page header area\expandafter\endcsname\csname pgf@sh@pi@current page\endcsname % \end{macrocode} % % % \subsection{Current Page Footer Area Node} % \begin{macrocode} -\expandafter\def\csname pgf@sh@ns@current page footer area\endcsname{rectangle} -\expandafter\def\csname pgf@sh@np@current page footer area\endcsname{% +\@newtikzpagenode{current page footer area}{% \def\southwest{\pgfpoint{\current@textarea@left}{\paperheight-\current@textarea@top-\textheight-\footskip}}% \def\northeast{\pgfpoint{\current@textarea@left+\textwidth}{\paperheight-\current@textarea@top-\textheight-\footskip+\headheight}}% } -\expandafter\let\csname pgf@sh@nt@current page footer area\expandafter\endcsname\csname pgf@sh@nt@current page\endcsname -\expandafter\let\csname pgf@sh@pi@current page footer area\expandafter\endcsname\csname pgf@sh@pi@current page\endcsname +% \end{macrocode} +% +% \subsection{Current Page Column Areas} +% \begin{macrocode} +\@newtikzpagenode{current page column 1 area}{% + \def\southwest{\pgfpoint{\current@textarea@left}{\paperheight-\current@textarea@top-\textheight}}% + \def\northeast{\pgfpoint{\current@textarea@left+\columnwidth}{\paperheight-\current@textarea@top}}% +} +% \end{macrocode} +% +% \begin{macrocode} +\@newtikzpagenode{current page column 2 area}{% + \def\southwest{\pgfpoint{\current@textarea@left+\columnwidth+\columnsep}{\paperheight-\current@textarea@top-\textheight}}% + \def\northeast{\pgfpoint{\current@textarea@left+2\columnwidth+\columnsep}{\paperheight-\current@textarea@top}}% +} +% \end{macrocode} +% +% \begin{macrocode} +\@newtikzpagenode{current page column 3 area}{% + \def\southwest{\pgfpoint{\current@textarea@left+2\columnwidth+2\columnsep}{\paperheight-\current@textarea@top-\textheight}}% + \def\northeast{\pgfpoint{\current@textarea@left+3\columnwidth+2\columnsep}{\paperheight-\current@textarea@top}}% +} +% \end{macrocode} +% +% \begin{macrocode} +\@newtikzpagenode{current page column 4 area}{% + \def\southwest{\pgfpoint{\current@textarea@left+3\columnwidth+3\columnsep}{\paperheight-\current@textarea@top-\textheight}}% + \def\northeast{\pgfpoint{\current@textarea@left+4\columnwidth+3\columnsep}{\paperheight-\current@textarea@top}}% +} +% \end{macrocode} +% +% \begin{macrocode} +\@newtikzpagenode{current page column 5 area}{% + \def\southwest{\pgfpoint{\current@textarea@left+4\columnwidth+4\columnsep}{\paperheight-\current@textarea@top-\textheight}}% + \def\northeast{\pgfpoint{\current@textarea@left+5\columnwidth+4\columnsep}{\paperheight-\current@textarea@top}}% +} +% \end{macrocode} +% +% \begin{macrocode} +\@newtikzpagenode{current page column 6 area}{% + \def\southwest{\pgfpoint{\current@textarea@left+5\columnwidth+5\columnsep}{\paperheight-\current@textarea@top-\textheight}}% + \def\northeast{\pgfpoint{\current@textarea@left+6\columnwidth+5\columnsep}{\paperheight-\current@textarea@top}}% +} +% \end{macrocode} +% +% \begin{macrocode} +\@newtikzpagenode{current page column 7 area}{% + \def\southwest{\pgfpoint{\current@textarea@left+6\columnwidth+6\columnsep}{\paperheight-\current@textarea@top-\textheight}}% + \def\northeast{\pgfpoint{\current@textarea@left+7\columnwidth+6\columnsep}{\paperheight-\current@textarea@top}}% +} +% \end{macrocode} +% +% \begin{macrocode} +\@newtikzpagenode{current page column 8 area}{% + \def\southwest{\pgfpoint{\current@textarea@left+7\columnwidth+7\columnsep}{\paperheight-\current@textarea@top-\textheight}}% + \def\northeast{\pgfpoint{\current@textarea@left+8\columnwidth+7\columnsep}{\paperheight-\current@textarea@top}}% +} +% \end{macrocode} +% +% \begin{macrocode} +\@newtikzpagenode{current page column 9 area}{% + \def\southwest{\pgfpoint{\current@textarea@left+8\columnwidth+8\columnsep}{\paperheight-\current@textarea@top-\textheight}}% + \def\northeast{\pgfpoint{\current@textarea@left+9\columnwidth+8\columnsep}{\paperheight-\current@textarea@top}}% +} +% \end{macrocode} +% +% \begin{macrocode} +\@newtikzpagenode{current page column 10 area}{% + \def\southwest{\pgfpoint{\current@textarea@left+9\columnwidth+9\columnsep}{\paperheight-\current@textarea@top-\textheight}}% + \def\northeast{\pgfpoint{\current@textarea@left+10\columnwidth+9\columnsep}{\paperheight-\current@textarea@top}}% +} % \end{macrocode} % % \iffalse @@ -250,4 +333,4 @@ % \fi % % \Finale -\endinput +% \endinput diff --git a/Master/texmf-dist/source/latex/tikzpagenodes/tikzpagenodes.ins b/Master/texmf-dist/source/latex/tikzpagenodes/tikzpagenodes.ins index 48da9378fdb..ec542b22e46 100644 --- a/Master/texmf-dist/source/latex/tikzpagenodes/tikzpagenodes.ins +++ b/Master/texmf-dist/source/latex/tikzpagenodes/tikzpagenodes.ins @@ -1,9 +1,10 @@ % See file 'tikzpagenodes.dtx' for copyright and licence. % -\input docstrip.tex +\input ydocstrip.tex \keepsilent \askforoverwritefalse \generate{% \file{tikzpagenodes.sty}{\nopreamble\from{tikzpagenodes.dtx}{tikzpagenodes.sty}}% } \endbatchfile +% vim: ft=tex |