summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/memoir/memhfixc.sty
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex/memoir/memhfixc.sty')
-rw-r--r--Master/texmf-dist/tex/latex/memoir/memhfixc.sty67
1 files changed, 64 insertions, 3 deletions
diff --git a/Master/texmf-dist/tex/latex/memoir/memhfixc.sty b/Master/texmf-dist/tex/latex/memoir/memhfixc.sty
index 16341bb79cc..122c994c50a 100644
--- a/Master/texmf-dist/tex/latex/memoir/memhfixc.sty
+++ b/Master/texmf-dist/tex/latex/memoir/memhfixc.sty
@@ -7,7 +7,9 @@
%% mempatch.dtx (with options: `hyper')
%%
%% Author: Peter Wilson (Herries Press) herries dot press at earthlink dot net
-%% Copyright 2001 --- 2008 Peter R. Wilson
+%% Copyright 2001 --- 2010 Peter R. Wilson
+%% Copyright 2011 --- 2013 Peter R. Wilson
+%% Maintainer: Lars Madsen (daleif at imf dot au dot dk)
%%
%% This work may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either
@@ -18,7 +20,7 @@
%% and version 1.3 or later is part of all distributions of
%% LaTeX version 2003/06/01 or later.
%%
-%% This work has the LPPL maintenance status "author-maintained".
+%% This work has the LPPL maintenance status "maintained".
%%
%% This work consists of the files listed in the README file.
%%
@@ -38,6 +40,7 @@
%% With thanks to Heiko Oberdiek, if you use hyperref dated 2006/11/15
%% or later, memhfixc will be automatically loaded after hyperref.
%%
+%% Version 1.16 2013/05/16
%% Version 1.15 2010/08/17
%% Version 1.14 2010/06/10
%% Version 1.13 2010/04/19
@@ -55,7 +58,7 @@
%% Version 1.1 2003/01/22
%% Version 1.0 2002/10/22
%%
-\ProvidesPackage{memhfixc}[2010/08/17 v1.15 nameref/hyperref package fixes for memoir class]
+\ProvidesPackage{memhfixc}[2013/05/16 v1.16 nameref/hyperref package fixes for memoir class]
\let\M@hfixcfinish\relax
\@ifclassloaded{memoir}{}%
{\let\M@hfixcfinish\endinput
@@ -285,6 +288,64 @@
\AtBeginDocument{%
\let\printpageinnotes\printpageinnoteshyperref%
}
+\ifHy@hyperfootnotes
+ \def\@footnotemark{%
+ \leavevmode
+ \ifhmode\edef\@x@sf{\the\spacefactor}%
+ \m@mmf@check% <--- added
+ \nobreak\fi
+ \stepcounter{Hfootnote}%
+ \global\let\Hy@saved@currentHref\@currentHref
+ \hyper@makecurrent{Hfootnote}%
+ \global\let\Hy@footnote@currentHref\@currentHref
+ \global\let\@currentHref\Hy@saved@currentHref
+ \hyper@linkstart{link}{\Hy@footnote@currentHref}%
+ \@makefnmark
+ \hyper@linkend
+ \m@mmf@prepare% <--- added
+ \ifhmode\spacefactor\@x@sf\fi
+ \relax
+ }%
+\fi
+
+\Hy@AtBeginDocument{%
+ \ifx\hyper@last\@undefined
+ \def\@starttoc#1{%
+ \begingroup\makeatletter
+ \IfFileExists{\jobname.#1}{%
+ \Hy@WarningNoLine{%
+ old #1 file detected, not used; run LaTeX again%
+ }%
+ }{}%
+ \if@filesw
+ \AtEndDocument{%
+ \expandafter\ifx\csname tf@#1\endcsname\relax
+ \expandafter\newwrite\csname tf@#1\endcsname
+ \immediate\openout \csname tf@#1\endcsname \jobname.#1\relax
+ \fi
+ }
+ \fi
+ \@nobreakfalse
+ \endgroup
+ }%
+ \fi
+}
+
+\ifHy@hyperfootnotes
+ \let\m@m@pnwrite@fourtharg\m@m@pnwrite@fourtharg@hyperref
+ \let\pagenoteanchor\pagenotehyperanchor
+ \newcounter{Hpagenote}
+ \@namedef{mem@pnmm@start@hook}{%
+ \stepcounter{Hpagenote}%
+ \global\let\Hy@saved@currentHref\@currentHref
+ \hyper@makecurrent{Hpagenote}%
+ \global\let\Hy@pagenote@currentHref\@currentHref
+ \global\let\@currentHref\Hy@saved@currentHref
+ \hyper@linkstart{link}{\Hy@pagenote@currentHref}%
+ }
+ \@namedef{mem@pnmm@end@hook}{\hyper@linkend}
+\fi
+
\endinput
%%
%% End of file `memhfixc.sty'.