diff options
author | Karl Berry <karl@freefriends.org> | 2016-06-11 23:18:53 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2016-06-11 23:18:53 +0000 |
commit | d68a92426a296573336399c1252f21da178f1b75 (patch) | |
tree | d9fd917bd4dfa7c73eb636b05562c2c0c6bd6a0c /Master/texmf-dist/tex/latex/marginnote | |
parent | 9b684b3b2ac7c400604e24a6702815e16f51ea87 (diff) |
marginnote (2jun16)
git-svn-id: svn://tug.org/texlive/trunk@41382 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/marginnote')
-rw-r--r-- | Master/texmf-dist/tex/latex/marginnote/marginnote.sty | 69 |
1 files changed, 37 insertions, 32 deletions
diff --git a/Master/texmf-dist/tex/latex/marginnote/marginnote.sty b/Master/texmf-dist/tex/latex/marginnote/marginnote.sty index 1f13ac1d3cf..2ea2b24b315 100644 --- a/Master/texmf-dist/tex/latex/marginnote/marginnote.sty +++ b/Master/texmf-dist/tex/latex/marginnote/marginnote.sty @@ -6,36 +6,25 @@ %% %% marginnote.dtx (with options: `package') %% -%% IMPORTANT NOTE: +%% IMPORTANT NOTICE: %% -%% This is a generated file and you are not allowed to distribute it -%% without the source ot the work. See below about more informations -%% about the files the work consists of. +%% For the copyright see the source file. %% -%% Copyright (c) Markus Kohm 2005-2012 -%% -%% 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 2003/12/01 or later. -%% -%% This work has the LPPL maintenance status "maintained". -%% -%% The author of the initial version of these work was -%% Markus Kohm <komascript@gmx.info> -%% -%% This work consists of the files marginnote.dtx, marginnote.ins, -%% and REAMDE. -%% -%% Important Recommendation: -%% The LPPL requires that distributions of the Work contain all the files of -%% the Work (see ``Important Recommendations'' at lppl.txt). -%% +%% Any modified versions of this file must be renamed +%% with new filenames distinct from marginnote.sty. +%% +%% For distribution of the original source see the terms +%% for copying and modification in the file marginnote.dtx. +%% +%% This generated file may be distributed as long as the +%% original source files, as listed above, are part of the +%% same distribution. (The sources need not necessarily be +%% in the same archive or directory.) +%%% From File: $Id: marginnote.dtx 5 2016-06-02 09:05:56Z mjk $ +\NeedsTeXFormat{LaTeX2e}[1995/12/01] \ProvidesPackage{marginnote}[% - 2012/03/29 v1.1i non floating margin notes for LaTeX] + 2016/06/02 v1.2 + non floating margin notes for LaTeX] \begingroup \def\@tempb{}% \def\@tempa{% @@ -117,9 +106,16 @@ \ProcessOptions\relax \newcommand*{\newmarginnote}{\@newl@bel{mn}} \newif\if@mn@pdfmode\@mn@pdfmodefalse +\newcommand*{\@mn@mode@prefix}{pdf} \AtBeginDocument{% \begingroup\expandafter\expandafter\expandafter\endgroup - \expandafter\ifx\csname pdflastxpos\endcsname\relax\else % bg or 1 + \expandafter\ifx\csname pdflastxpos\endcsname\relax + \begingroup\expandafter\expandafter\expandafter\endgroup + \expandafter\ifx\csname lastxpos\endcsname\relax\else + \@mn@pdfmodetrue + \renewcommand*{\@mn@mode@prefix}{}% + \fi + \else % bg or 1 \begingroup\expandafter\expandafter\expandafter\endgroup \expandafter\ifx\csname pdftexversion\endcsname\relax % bg 2 \begingroup\expandafter\expandafter\expandafter\endgroup @@ -146,7 +142,8 @@ \if@mn@verbose \if@mn@pdfmode \PackageInfo{marginnote}{% - \string\pdfoutput\space not 0 and \string\pdflastxpos\space + \string\pdfoutput\space not 0 or unimportant and\MessageBreak + \string\pdflastxpos\space or \string\lastxpos\space available.\MessageBreak Extended position detection mode activated\@gobble }% @@ -185,10 +182,10 @@ \let\@mn@currpage\relax \let\@mn@currxpos\relax \if@mn@pdfmode - \pdfsavepos + \@nameuse{\@mn@mode@prefix savepos}% \protected@write\@auxout{\let\themn@abspage\relax}{% \string\newmarginnote{note.\@mn@thispage.\@mn@atthispage}{% - {\themn@abspage}{\noexpand\number\pdflastxpos sp}}% + {\themn@abspage}{\noexpand\number\@nameuse{\@mn@mode@prefix lastxpos}sp}}% }% \else \protected@write\@auxout{\let\themn@abspage\relax}{% @@ -219,7 +216,15 @@ \begingroup\expandafter\expandafter\expandafter\endgroup \expandafter\ifx\csname pdfhorigin\endcsname\relax\else \begingroup\expandafter\expandafter\expandafter\endgroup - \expandafter\ifx\csname pdfoutput\endcsname\relax\else + \expandafter\ifx\csname pdfoutput\endcsname\relax + \begingroup\expandafter\expandafter\expandafter\endgroup + \expandafter\ifx\csname outputmode\endcsname\relax\else + \ifnum \outputmode=1 % + \edef\@mn@currxpos{\the\dimexpr \@mn@currxpos -\pdfhorigin + +1in\relax}% + \fi + \fi + \else \ifnum \pdfoutput=1 % \edef\@mn@currxpos{\the\dimexpr \@mn@currxpos -\pdfhorigin +1in\relax}% |