Annotation of ttbar/p20_taujets_note/vplref.sty, revision 1.1.1.1

1.1       uid12904    1: %% `vplref.sty' 
                      2: %% -- extended line number referencing with lineno.sty. 
                      3: 
                      4: \def\filedate{2005/04/25} \def\fileversion{0.2}
                      5: 
                      6: %% Copyright (C) 2004, 2005 Uwe Lueck, 
                      7: %% http://contact-ednotes.sty.de.vu --author-maintained 
                      8: %% -- support of lineno.sty for varioref.sty. 
                      9: 
                     10: %% This file can be redistributed and/or modified under 
                     11: %% the terms of the LaTeX Project Public License; either 
                     12: %% version 1.3 of the License, or any later version.
                     13: %% The latest version of this license is in
                     14: %%   http://www.latex-project.org/lppl.txt
                     15: %% We did our best to help you, but there is NO WARRANTY. 
                     16: 
                     17: %% USAGE: 
                     18: %
                     19: % \vpagelineref{<label>} expands to 
                     20: %
                     21: % a) \ref{<label>} 
                     22: %    -- if on same page as \linelabel{<label>}
                     23: % 
                     24: % b) \LineWithPage{<label>} -- otherwise. 
                     25: % 
                     26: % \LineWithPage{<label>} expands -- by default -- to 
                     27: % 
                     28: %   \pageref{<label>}.\ref{<label>}
                     29: % 
                     30: % This can be customized by editing 
                     31: % 
                     32: %   \renewcommand*{\LineWithPage}[1]{\pageref{#1}.\ref{#1}} 
                     33: % 
                     34: % in your document preamble, after vplref.sty has been loaded 
                     35: % (which may have happened through lineno.sty with option 
                     36: % `addpageno'). 
                     37: 
                     38: %% IMPLEMENTATION: 
                     39: 
                     40: \NeedsTeXFormat{LaTeX2e}[1994/12/01] %% \Declare...* 
                     41: \ProvidesPackage{vplref}[\filedate\space v\fileversion] 
                     42: 
                     43: \AtBeginDocument{\RequirePackage{lineno,varioref}} 
                     44: 
                     45: %% Anderer Ansatz: GPNo (\FirstOnPage) 
                     46: 
                     47: \DeclareRobustCommand*\vpagelineref[1]{{% 
                     48: %   \def\reftextcurrent{\lineref{#1}}%% First vpageref arg. 
                     49:   \let\reftextfaraway\LineWithPage 
                     50:   \def\reftextafter{\reftextfaraway{#1}}% 
                     51:   \let\reftextbefore\reftextafter 
                     52:   \let\reftextfaceafter\reftextafter 
                     53:   \let\reftextfacebefore\reftextafter 
                     54: %% <- Looks somewhat stupid, but varioref.sty has its merits 
                     55: %%    as compared with the mechanism in ednotes.sty. 
                     56:   \vpageref[\ref{#1}][]{#1}%% The robust alternative. 
                     57: %% Here and with \LineWithPage, \lineref seems more appropriate 
                     58: %% than \ref, but it produces errors when labels have not been 
                     59: %% defined. This seems to be an incompatibility with lineno.sty. 
                     60: }} 
                     61: 
                     62: %% Customizable format for different page: 
                     63: \newcommand*\LineWithPage[1]{\pageref{#1}.\ref{#1}}
                     64: 
                     65: \endinput 
                     66: 
                     67: VERSION HISTORY: 
                     68: v0.1   2004/10/19  First, sent to Sergei Mariev. 
                     69: v0.11  2004/10/19  Fit to recent varioref version; 
                     70:                    sent to Sergei. 
                     71: v0.2   2005/04/25  \Require... \AtBeginDocument. 
                     72: 

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>