From ccf357defee0d406f6a8b7517b7bb0b4134ac6ba Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Tue, 19 Apr 2016 21:14:51 +0000 Subject: footnotehyper (19apr16) git-svn-id: svn://tug.org/texlive/trunk@40620 c570f23f-e606-0410-a88d-b1316a301751 --- .../texmf-dist/doc/latex/footnotehyper/README.md | 97 ++++ .../doc/latex/footnotehyper/footnotehyper.pdf | Bin 0 -> 35060 bytes .../doc/latex/footnotehyper/footnotehyper.tex | 29 ++ .../source/latex/footnotehyper/footnotehyper.dtx | 575 +++++++++++++++++++++ .../source/latex/footnotehyper/footnotehyper.ins | 48 ++ .../tex/latex/footnotehyper/footnotehyper.sty | 72 +++ Master/tlpkg/bin/tlpkg-ctan-check | 2 +- Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc | 1 + Master/tlpkg/tlpsrc/footnotehyper.tlpsrc | 0 9 files changed, 823 insertions(+), 1 deletion(-) create mode 100644 Master/texmf-dist/doc/latex/footnotehyper/README.md create mode 100644 Master/texmf-dist/doc/latex/footnotehyper/footnotehyper.pdf create mode 100644 Master/texmf-dist/doc/latex/footnotehyper/footnotehyper.tex create mode 100644 Master/texmf-dist/source/latex/footnotehyper/footnotehyper.dtx create mode 100644 Master/texmf-dist/source/latex/footnotehyper/footnotehyper.ins create mode 100644 Master/texmf-dist/tex/latex/footnotehyper/footnotehyper.sty create mode 100644 Master/tlpkg/tlpsrc/footnotehyper.tlpsrc diff --git a/Master/texmf-dist/doc/latex/footnotehyper/README.md b/Master/texmf-dist/doc/latex/footnotehyper/README.md new file mode 100644 index 00000000000..d0207ec65fe --- /dev/null +++ b/Master/texmf-dist/doc/latex/footnotehyper/README.md @@ -0,0 +1,97 @@ + + + Source: footnotehyper.dtx (v0.9a 2016/04/19) + Author: Jean-Francois Burnol + Info: hyperref aware footnote.sty + License: LPPL 1.3c or later + Copyright (C) 2016 Jean-Francois Burnol . + +ABSTRACT +======== + +The `footnote` package by Mark Wooding dates back to 1997 and has +not been made `hyperref` compatible. The aim of the present +package is to do that. It is barely tested and its state is what I +found sufficiently well-working on a current LaTeX document of +mine, I have not attempted any in-depth analysis of all possible +situations. As version number is at `v0.9a`, there is room for +incorporating suggestions until reaching final `v1.0`. I promise +not to find a mathematical constant in-between and I will +certainly not play the `999..9` game à la XeTeX. + +For those who don't know: the `footnote` package allows via +`\savenotes` to gather footnotes and later release them via +`\spewnotes`. Thus footnotes emitted from tabulars or minipages +are not separated from the general document stream of footnotes, +and are printed with the others at bottom of page. This works also +for environments like `framed` (1) from the eponymous package and +avoids the `\footnotemark/\footnotetext` approach, which anyhow is +not immediately `hyperref` compatible. The `footnote` package has +a facility to patch any user-chosen environment to do the +`\savenotes/\spewnotes` automatically. + +This package provides no facility for handling footnotes from floating +environments. + +It will load `footnote` but it is up to the user to take care of +`hyperref`. + +(1): in case of multi-page content, the footnotes are delivered in +the last page. + +INSTALLATION +============ + +To extract the package (.sty) and driver (.tex) files from +footnotehyper.dtx: + +- if footnotehyper.ins is present: etex footnotehyper.ins +- without footnotehyper.ins: etex footnotehyper.dtx +- or run latex or pdflatex directly on footnotehyper.dtx + +At least three ways to produce footnotehyper.pdf (method (1) is +preferred): + +1. latex footnotehyper.tex (thrice), then dvipdfmx +2. pdflatex footnotehyper.dtx (thrice) +3. latex footnotehyper.dtx (thrice), then dvips, then ps2pdf + +Method (1) produces the smallest pdf files. +Options can be set in footnotehyper.tex: + +- scrdoc class options (paper size, font size, ...) +- with or without source code, +- with dvipdfmx or with latex+dvips or pdflatex. + +Installation: + + footnotehyper.sty -> TDS:tex/latex/footnotehyper/footnotehyper.sty + footnotehyper.dtx -> TDS:source/latex/footnotehyper/footnotehyper.dtx + footnotehyper.pdf -> TDS:doc/latex/footnotehyper/footnotehyper.pdf + README.md -> TDS:doc/latex/footnotehyper/README.md + +The other files may be discarded. + +LICENSE +======= + +This Work may be distributed and/or modified under the conditions +of the LaTeX Project Public License, version 1.3c. This version of +this license is in: + +> + +and the latest version of this license is in: + +> + +Version 1.3 or later is part of all distributions of +LaTeX version 2005/12/01 or later. + +The Author of this Work is: + +- Jean-Francois Burnol `` + +This Work consists of the main source file footnotehyper.dtx and the +derived files footnotehyper.sty, footnotehyper.ins, footnotehyper.tex, +footnotehyper.pdf, footnotehyper.dvi. diff --git a/Master/texmf-dist/doc/latex/footnotehyper/footnotehyper.pdf b/Master/texmf-dist/doc/latex/footnotehyper/footnotehyper.pdf new file mode 100644 index 00000000000..38677677268 Binary files /dev/null and b/Master/texmf-dist/doc/latex/footnotehyper/footnotehyper.pdf differ diff --git a/Master/texmf-dist/doc/latex/footnotehyper/footnotehyper.tex b/Master/texmf-dist/doc/latex/footnotehyper/footnotehyper.tex new file mode 100644 index 00000000000..5bcaa456204 --- /dev/null +++ b/Master/texmf-dist/doc/latex/footnotehyper/footnotehyper.tex @@ -0,0 +1,29 @@ +%% +%% Package: footnotehyper +%% Version: 0.9a (2016/04/19) +%% License: LPPL 1.3c +%% Copyright (C) 2016 Jean-Francois Burnol . +%% +\def\pkgname {footnotehyper} +\def\pkgdate {2016/04/19} +\def\docdate {2016/04/19} +\def\pkgversion {v0.9a} +\def\pkgdescription {hyperref aware footnote.sty (JFB)} +%% +%% run latex thrice on this file footnotehyper.tex then dvipdfmx on +%% footnotehyper.dvi to produce the documentation footnotehyper.pdf, with +%% source code included. +%% +\chardef\Withdvipdfmx 1 % replace 1 by 0 for using latex+dvips or pdflatex +\chardef\NoSourceCode 0 % replace 0 by 1 for the doc *without* the source code +\NeedsTeXFormat{LaTeX2e} +\ProvidesFile {\pkgname.tex}[Driver for \pkgname\space documentation]% +\PassOptionsToClass {a4paper,fontsize=11pt,oneside}{scrdoc} +\PassOptionsToPackage {english}{babel} +\input \pkgname.dtx +%%% Local Variables: +%%% mode: latex +%%% End: +\endinput +%% +%% End of file `footnotehyper.tex'. diff --git a/Master/texmf-dist/source/latex/footnotehyper/footnotehyper.dtx b/Master/texmf-dist/source/latex/footnotehyper/footnotehyper.dtx new file mode 100644 index 00000000000..843b5f9a01d --- /dev/null +++ b/Master/texmf-dist/source/latex/footnotehyper/footnotehyper.dtx @@ -0,0 +1,575 @@ +% -*- coding: utf-8; time-stamp-format: "%02d-%02m-%:y at %02H:%02M:%02S %Z" -*- +%<*none> +\def\dtxtimestamp {Time-stamp: <19-04-2016 at 10:06:14 CEST>} +% +%<*!readme> +%% +%% Package: footnotehyper +%% Version: 0.9a (2016/04/19) +%% License: LPPL 1.3c +%% Copyright (C) 2016 Jean-Francois Burnol . +%% +% +%<*insfile|tex> +\def\pkgname {footnotehyper} +\def\pkgdate {2016/04/19} +\def\docdate {2016/04/19} +\def\pkgversion {v0.9a} +\def\pkgdescription {hyperref aware footnote.sty (JFB)} +% +%<*none> +% Definition of \pkgLicense +\begingroup% cette méthode ne marcherait pas avec caractères en dehors de 32-127 + \long\def\firstofone #1{#1}\catcode1=14\catcode2=0 + \catcode`\%=12\catcode`\_=12\endlinechar13\catcode13=13 ^^A + \catcode32=13\catcode`\\=12^^Brelax^^A +^^Bfirstofone{^^Bendgroup^^Bdef^^BpkgLicense^^A +{% Package: footnotehyper +% Version: 0.9a (2016/04/19) +% License: LPPL 1.3c +% Copyright (C) 2016 Jean-Francois Burnol . +% +% This Work may be distributed and/or modified under the conditions +% of the LaTeX Project Public License, version 1.3c. This version of +% this license is in: +% +% > +% +% and the latest version of this license is in: +% +% > +% +% Version 1.3 or later is part of all distributions of +% LaTeX version 2005/12/01 or later. +% +% The Author of this Work is: Jean-Francois Burnol `` +% +% This Work consists of the main source file footnotehyper.dtx and the +% derived files footnotehyper.sty, footnotehyper.ins, footnotehyper.tex, +% footnotehyper.pdf, footnotehyper.dvi. +}}% +\begingroup\catcode1 0 \catcode`\\ 12 +^^Aiffalse +% +%<*readme> + + + Source: footnotehyper.dtx (v0.9a 2016/04/19) + Author: Jean-Francois Burnol + Info: hyperref aware footnote.sty + License: LPPL 1.3c or later + Copyright (C) 2016 Jean-Francois Burnol . + + +ABSTRACT +======== + +The `footnote` package by Mark Wooding dates back to 1997 and has +not been made `hyperref` compatible. The aim of the present +package is to do that. It is barely tested and its state is what I +found sufficiently well-working on a current LaTeX document of +mine, I have not attempted any in-depth analysis of all possible +situations. As version number is at `v0.9a`, there is room for +incorporating suggestions until reaching final `v1.0`. I promise +not to find a mathematical constant in-between and I will +certainly not play the `999..9` game à la XeTeX. + +For those who don't know: the `footnote` package allows via +`\savenotes` to gather footnotes and later release them via +`\spewnotes`. Thus footnotes emitted from tabulars or minipages +are not separated from the general document stream of footnotes, +and are printed with the others at bottom of page. This works also +for environments like `framed` (1) from the eponymous package and +avoids the `\footnotemark/\footnotetext` approach, which anyhow is +not immediately `hyperref` compatible. The `footnote` package has +a facility to patch any user-chosen environment to do the +`\savenotes/\spewnotes` automatically. + +This package provides no facility for handling footnotes from floating +environments. + +It will load `footnote` but it is up to the user to take care of +`hyperref`. + +(1): in case of multi-page content, the footnotes are delivered in +the last page. + + +INSTALLATION +============ + +To extract the package (.sty) and driver (.tex) files from +footnotehyper.dtx: + +- if footnotehyper.ins is present: etex footnotehyper.ins +- without footnotehyper.ins: etex footnotehyper.dtx +- or run latex or pdflatex directly on footnotehyper.dtx + +At least three ways to produce footnotehyper.pdf (method (1) is +preferred): + +1. latex footnotehyper.tex (thrice), then dvipdfmx +2. pdflatex footnotehyper.dtx (thrice) +3. latex footnotehyper.dtx (thrice), then dvips, then ps2pdf + +Method (1) produces the smallest pdf files. +Options can be set in footnotehyper.tex: + +- scrdoc class options (paper size, font size, ...) +- with or without source code, +- with dvipdfmx or with latex+dvips or pdflatex. + +Installation: + + footnotehyper.sty -> TDS:tex/latex/footnotehyper/footnotehyper.sty + footnotehyper.dtx -> TDS:source/latex/footnotehyper/footnotehyper.dtx + footnotehyper.pdf -> TDS:doc/latex/footnotehyper/footnotehyper.pdf + README.md -> TDS:doc/latex/footnotehyper/README.md + +The other files may be discarded. + + +LICENSE +======= + +This Work may be distributed and/or modified under the conditions +of the LaTeX Project Public License, version 1.3c. This version of +this license is in: + +> + +and the latest version of this license is in: + +> + +Version 1.3 or later is part of all distributions of +LaTeX version 2005/12/01 or later. + +The Author of this Work is: + +- Jean-Francois Burnol `` + +This Work consists of the main source file footnotehyper.dtx and the +derived files footnotehyper.sty, footnotehyper.ins, footnotehyper.tex, +footnotehyper.pdf, footnotehyper.dvi. +% +%<*tex>------------------------------------------------------------------------- +%% +%% run latex thrice on this file footnotehyper.tex then dvipdfmx on +%% footnotehyper.dvi to produce the documentation footnotehyper.pdf, with +%% source code included. +%% +\chardef\Withdvipdfmx 1 % replace 1 by 0 for using latex+dvips or pdflatex +\chardef\NoSourceCode 0 % replace 0 by 1 for the doc *without* the source code +\NeedsTeXFormat{LaTeX2e} +\ProvidesFile {\pkgname.tex}[Driver for \pkgname\space documentation]% +\PassOptionsToClass {a4paper,fontsize=11pt,oneside}{scrdoc} +\PassOptionsToPackage {english}{babel} +\input \pkgname.dtx +%%% Local Variables: +%%% mode: latex +%%% End: +%------------------------------------------------------------------------- +%<*insfile>--------------------------------------------------------------------- +%% +%% Run etex on this file to extract from footnotehyper.dtx: +%% footnotehyper.sty, footnotehyper.tex, and README.md +%% +%% Refer to README.md for installation instructions, if needed. +%% +\input docstrip.tex +\askforoverwritefalse +\def\pkgpreamble{\defaultpreamble^^J\MetaPrefix^^J% +\string\NeedsTeXFormat{LaTeX2e}^^J% +\string\ProvidesPackage{\pkgname}\perCent^^J% +\space[\pkgdate\space\pkgversion\space\pkgdescription]}% +\generate{\nopreamble\nopostamble +\file{README.md}{\from{\pkgname.dtx}{readme}}% +\usepostamble\defaultpostamble +\file{\pkgname.tex}{\from{\pkgname.dtx}{tex}}% +\usepreamble\pkgpreamble +\file{\pkgname.sty}{\from{\pkgname.dtx}{package}}}% +\catcode32=13\relax% active space +\let =\space% +\Msg{************************************************************************} +\Msg{*} +\Msg{* To finish the installation you have to move the following} +\Msg{* file into a directory searched by TeX:} +\Msg{*} +\Msg{* \pkgname.sty} +\Msg{*} +\Msg{* To produce the documentation run latex thrice on file \pkgname.tex} +\Msg{* and then run dvipdfmx on file \pkgname.dvi.} +\Msg{*} +\Msg{* Happy TeXing!} +\Msg{*} +\Msg{************************************************************************} +\endbatchfile +%--------------------------------------------------------------------- +%<*none>------------------------------------------------------------------------ +^^Afi^^Aendgroup +% +\chardef\noetex 0 +\ifx\numexpr\undefined\chardef\noetex 1 \fi +\ifnum\noetex=1 \chardef\extractfiles 0 % extract files, then stop +\else + \ifx\ProvidesFile\undefined + \chardef\extractfiles 0 % etex etc.. on \pkgname.dtx, only file extraction. + \else % latex/pdflatex on \pkgname.tex or on \pkgname.dtx + \ifx\Withdvipdfmx\undefined + % latex/pdflatex run is on \pkgname.dtx + \chardef\extractfiles 1 % 1 = extract files and typeset manual, 2 = only typeset + \chardef\Withdvipdfmx 0 % 0 = pdflatex or latex+dvips, 1 = dvipdfmx + \chardef\NoSourceCode 0 % 0 = include source code, 1 = do not + \NeedsTeXFormat {LaTeX2e}% + \PassOptionsToClass {a4paper,fontsize=11pt,oneside}{scrdoc}% + \PassOptionsToPackage {english}{babel}% + \else % latex run is on \pkgname.tex + \chardef\extractfiles 2 % do not extract files, only typeset + \fi + \ProvidesFile{\pkgname.dtx}% + [\pkgname\space source and documentation (\dtxtimestamp)]% + \fi +\fi +\ifnum\extractfiles<2 % extract files +\def\MessageDeFin{\newlinechar10 \let\Msg\message +\Msg{********************************************************************^^J}% +\Msg{*^^J}% +\Msg{* To finish the installation you have to move the following^^J}% +\Msg{* file into a directory searched by TeX:^^J}% +\Msg{*^^J}% +\Msg{*\space\space\space\space \pkgname.sty^^J}% +\Msg{*^^J}% +\Msg{* To produce the documentation with source code included run latex^^J}% +\Msg{* thrice on file \pkgname.tex and then dvipdfmx on \pkgname.dvi^^J}% +\Msg{*^^J}% +\Msg{* Happy TeXing!^^J}% +\Msg{*^^J}% +\Msg{********************************************************************^^J}% +}% +\begingroup + \input docstrip.tex + \askforoverwritefalse + \def\pkgpreamble{\defaultpreamble^^J\MetaPrefix^^J% + \string\NeedsTeXFormat{LaTeX2e}^^J% + \string\ProvidesPackage{\pkgname}\perCent^^J% + \space[\pkgdate\space\pkgversion\space\pkgdescription]}% + \generate{\nopreamble\nopostamble + \file{README.md}{\from{\pkgname.dtx}{readme}}% + \usepostamble\defaultpostamble + \file{\pkgname.ins}{\from{\pkgname.dtx}{insfile}}% + \file{\pkgname.tex}{\from{\pkgname.dtx}{tex}}% + \usepreamble\pkgpreamble + \file{\pkgname.sty}{\from{\pkgname.dtx}{package}}}% +\endgroup +\fi % end of file extraction (from etex/latex/pdflatex run on \pkgname.dtx) +\ifnum\extractfiles=0 % tex/etex/xetex/etc on \pkgname.dtx, files extracted, stop + \MessageDeFin\expandafter\end +\fi +% From this point on, run is necessarily with e-TeX. +% Check if \MessageDeFin got defined, if yes put it at end of run. +\ifdefined\MessageDeFin\AtEndDocument{\MessageDeFin}\fi +%------------------------------------------------------------------------------- +% START OF USER MANUAL TEX SOURCE +\documentclass[abstract]{scrdoc} + +\ifnum\NoSourceCode=1 \OnlyDescription\fi + +\usepackage{ifpdf} +\ifpdf\chardef\Withdvipdfmx 0 \fi + +\makeatletter +\ifnum\Withdvipdfmx=1 + \@for\@tempa:=hyperref,bookmark,graphicx,xcolor,pict2e\do + {\PassOptionsToPackage{dvipdfmx}\@tempa} + % + \PassOptionsToPackage{dvipdfm}{geometry} + \PassOptionsToPackage{bookmarks=true}{hyperref} + \PassOptionsToPackage{dvipdfmx-outline-open}{hyperref} + \PassOptionsToPackage{dvipdfmx-outline-open}{bookmark} + % + \def\pgfsysdriver{pgfsys-dvipdfm.def} +\else + \PassOptionsToPackage{bookmarks=true}{hyperref} +\fi +\makeatother + +\usepackage[T1]{fontenc} +\usepackage[utf8]{inputenc} +\usepackage {babel} + +\usepackage[hscale=0.7,vscale=0.7]{geometry} + +\def\MacroFont{\ttfamily\small\hyphenchar\font45 \baselineskip11pt\relax} + +\usepackage{amsmath} +\usepackage{newtxtext, newtxmath} +\usepackage[straightquotes]{newtxtt} +\usepackage{xspace} + +\usepackage[dvipsnames]{xcolor} +\definecolor{joli}{RGB}{225,95,0} +\definecolor{JOLI}{RGB}{225,95,0} +\definecolor{BLUE}{RGB}{0,0,255} +\colorlet{niceone}{green!35!blue!75} + +\usepackage{framed} + +\usepackage[pdfencoding=pdfdoc]{hyperref} +\hypersetup{% +linktoc=all,% +breaklinks=true,% +colorlinks,% +linkcolor=RoyalBlue,% +urlcolor=OliveGreen,% +pdfauthor={Jean-Fran\c cois Burnol},% +pdftitle={The \pkgname\space package},% +pdfsubject={\pkgdescription},% +pdfkeywords={LaTeX, footnotes},% +pdfstartview=FitH,% +pdfpagemode=UseOutlines} +% added usage of package bookmark 2013/10/10 +\usepackage{bookmark} + +\usepackage{\pkgname} + +\newcommand\fnh{% + \texorpdfstring{{\color{joli}\ttfamily\bfseries \pkgname}}{\pkgname}\xspace} + +\DeclareRobustCommand\csa [1] {{\ttfamily\hyphenchar\font45 \char`\\ #1}} + +\DeclareRobustCommand\csb [1] + {\hyperref[#1] {\ttfamily\hyphenchar\font45 \char`\\ #1}} + +\newcommand\cshyp[1]{\texorpdfstring{\csa{#1}}{\textbackslash #1}} + +\newcommand\csbhyp[1]{\texorpdfstring{\csa{#1}}{\textbackslash #1}} + +\frenchspacing + +\renewcommand\familydefault\sfdefault +\pagestyle{headings} + +\begin{document}\thispagestyle{empty} +\rmfamily +\bookmark[named=FirstPage,level=1]{Title page} + +\begin{center} + {\normalfont\LARGE The \fnh package}\\ +\textsc{\small Jean-François Burnol}\par + \footnotesize \ttfamily + jfbu (at) free (dot) fr\par + \let\thefootnote\empty + Package version: \pkgversion\ (\pkgdate)\par + From source file \texttt{\pkgname.dtx} of \dtxtimestamp.\par +\end{center} + +\MakeShortVerb{\`}% global effect ! +\begin{abstract} + The `footnote` package by \textsc{Mark Wooding} dates back to 1997 and + has not been made `hyperref` compatible. The aim of the present + package is to do that. It is barely tested and its state is what + I found sufficiently well-working on a current LaTeX document of + mine, I have not attempted any in-depth analysis of all possible + situations. As version number is at `v0.9a`, there is room for + incorporating suggestions until reaching final `v1.0`. I promise + not to find a mathematical constant in-between and I will + certainly not play the `999..9` game à la XeTeX. + + For those who don't know: the `footnote` package allows via + `\savenotes` to gather footnotes and later release them via + `\spewnotes`. Thus footnotes emitted from tabulars or minipages are not + separated from the general document stream of footnotes, and are + printed with the others at bottom of page. This works also for + environments like `framed`% +% +%\footnote +\space({in case of multi-page content, the footnotes are delivered in the last +page}) +% +from the eponymous package and avoids the `\footnotemark/\footnotetext` +approach, which anyhow is not immediately `hyperref` compatible. The +`footnote` package has a facility to patch any user-chosen environment to +do the `\savenotes/\spewnotes` automatically. + +This package provides no facility for handling footnotes from floating +environments. + +It will load `footnote` but it is up to the user to take care of +`hyperref`. +\end{abstract} +\DeleteShortVerb{\`} + +\section{License} + +\begingroup\ttfamily\small\hyphenchar\font -1 + \parindent0pt + \obeyspaces\obeylines % +\pkgLicense\endgroup + +\section{Usage} + +\savenotes +\begin{framed} +Please refer to the documentation of the |footnote| package.% +\footnote{\url{http://ctan.org/pkg/footnote}} + +Particularly you may check its |\makesavenoteenv| command.% +\footnote{This won't handle floating environments, though.} +\end{framed} +\spewnotes + +We can try some normal footnote.\footnote{Here it is.} + +\savenotes +\begin{framed} +{\centering\DeleteShortVerb{\|}% + \begin{tabular}{|c|c|} +\hline + The above was & coded\footnote{Notice that if the present frame + extended to next page, + the \cs{spewnotes} command would then (try to) deliver its + footnotes to that + page.} as:\\\hline +\end{tabular}\par}\MakeShortVerb{\|} +\begin{verbatim} +\savenotes +\begin{framed} + Please refer to the documentation of the |footnote| package.% + \footnote{\url{http://ctan.org/pkg/footnote}} + + Particularly you may check its |\makesavenoteenv| command.% + \footnote{This won't handle floating environments, though.} +\end{framed} +\spewnotes +\end{verbatim} +and the present frame (which has a \cs{footnote} from inside a +|tabular|) also is surrounded by +|\savenotes/\spewnotes|. Let's test an |amsmath| environment. As +\begin{align} + E&=mc^2\;, +\intertext{was too easy,\footnote{there is also $E=h\nu$.}, let's + try:} + F&=nd^3\;. +\end{align} +\end{framed} +\spewnotes + +And the final one.\footnote{Nothing left to say.} + +\StopEventually{\end{document}\endinput} +\makeatletter + \let\check@percent\original@check@percent +\makeatother + +\clearpage +\section{Implementation} + +\small + +\makeatletter +\noindent +\begingroup +\topsep\MacrocodeTopsep +\trivlist\parskip\z@\item[] +\macro@font +\leftskip\@totalleftmargin \advance\leftskip\MacroIndent +\rightskip\z@ \parindent\z@ \parfillskip\@flushglue +\global\@newlistfalse \global\@minipagefalse +\ifcodeline@index + \everypar{\global\advance\c@CodelineNo\@ne + \llap{\theCodelineNo\ \hskip\@totalleftmargin}}% +\fi +\string\NeedsTeXFormat\string{LaTeX2e\string}\par +\string\ProvidesPackage\string{\pkgname\string}\@percentchar\par +\noindent\space [\pkgdate\space\pkgversion\space\pkgdescription]\par +\nointerlineskip +\global\@inlabelfalse +\endtrivlist +\endgroup +\makeatother + +% The catcode hackery next is to avoid to have <*package> to be listed +% in the commented source code... +% (c) 2012/11/19 jf burnol ;-) + +\MakePercentIgnore + +% +% \catcode`\<=0 \catcode`\>=11 \catcode`\*=11 \catcode`\/=11 +% \let\relax +% \def<*package>{\catcode`\<=12 \catcode`\>=12 \catcode`\*=12 \catcode`\/=12} +% +% +%<*package> +% \begin{macro}{no options} +% \begin{macrocode} +\DeclareOption*{\PackageWarning{footnotehyper}{Option `\CurrentOption' is unknown.}} +\ProcessOptions\relax +% \end{macrocode} +% \end{macro} +% We load |footnote| but let the |hyperref| handling to the user. +% \begin{macrocode} +\RequirePackage{footnote} +\AtBeginDocument{\@ifpackageloaded{hyperref}{}{\PackageWarning{footnotehyper} + {hyperref package not loaded!^^J This + will surely end up in zillions of error messages.}}} +% \end{macrocode} +% \begin{macro}{\fn@fntext} +% Some |amsmath| complications. I change the coding, but same effect as +% original. +% \begin{macrocode} +\def\fn@fntext {\ifx\ifmeasuring@\undefined\expandafter\@secondoftwo + \else\expandafter\@firstofone\fi + {\ifmeasuring@\expandafter\@gobbletwo\fi}% + \FNH@fn@fntext } +% \end{macrocode} +% \end{macro} +% \begin{macro}{\FNH@fn@fntext} +% Original \cs{fn@fntext} has no \cs{long}. +% The patched version does the \cs{ifHy@nesting} test although hyperref's manual +% says ``Allows links to be nested; no drivers currently support this.'' +% \begin{macrocode} +\long\def\FNH@fn@fntext #1{% + \global\setbox\fn@notes\vbox + {\unvbox\fn@notes + \fn@startnote + \@makefntext + {\rule\z@\footnotesep\ignorespaces + \ifHy@nesting\expandafter\ltx@firstoftwo + \else\expandafter\ltx@secondoftwo + \fi + {\expandafter\hyper@@anchor\expandafter{\Hy@footnote@currentHref}{#1}}% + {\Hy@raisedlink + {\expandafter\hyper@@anchor\expandafter{\Hy@footnote@currentHref}% + {\relax}}% + \let\@currentHref\Hy@footnote@currentHref + \let\@currentlabelname\@empty + #1}% + \@finalstrut\strutbox }% + \fn@endnote }% +} +% \end{macrocode} +% \end{macro} +% The final touch in our hack is to patch the original +% \cs{spewnotes} for it to use the original, non-hyperref +% modified, version of \cs{@footnotetext}. +% \begin{macro}{\spewnotes} +% \begin{macrocode} +\def\spewnotes {\endgroup + \if@savingnotes\else\ifvoid\fn@notes\else + \begingroup\let\@makefntext\@empty + \let\@finalstrut\@gobble + \let\rule\@gobbletwo + \H@@footnotetext{\unvbox\fn@notes}% + \endgroup\fi\fi +} +\endinput +% \end{macrocode} +% \end{macro} +% Let me repeat I have barely tested on a few examples that it +% does at all work! One of the main test being the present documentation\dots +% \MakePercentComment +\Finale +%% +%% End of file `footnotehyper.dtx'. diff --git a/Master/texmf-dist/source/latex/footnotehyper/footnotehyper.ins b/Master/texmf-dist/source/latex/footnotehyper/footnotehyper.ins new file mode 100644 index 00000000000..2becd4d543a --- /dev/null +++ b/Master/texmf-dist/source/latex/footnotehyper/footnotehyper.ins @@ -0,0 +1,48 @@ +%% +%% Package: footnotehyper +%% Version: 0.9a (2016/04/19) +%% License: LPPL 1.3c +%% Copyright (C) 2016 Jean-Francois Burnol . +%% +\def\pkgname {footnotehyper} +\def\pkgdate {2016/04/19} +\def\docdate {2016/04/19} +\def\pkgversion {v0.9a} +\def\pkgdescription {hyperref aware footnote.sty (JFB)} +%% +%% Run etex on this file to extract from footnotehyper.dtx: +%% footnotehyper.sty, footnotehyper.tex, and README.md +%% +%% Refer to README.md for installation instructions, if needed. +%% +\input docstrip.tex +\askforoverwritefalse +\def\pkgpreamble{\defaultpreamble^^J\MetaPrefix^^J% +\string\NeedsTeXFormat{LaTeX2e}^^J% +\string\ProvidesPackage{\pkgname}\perCent^^J% +\space[\pkgdate\space\pkgversion\space\pkgdescription]}% +\generate{\nopreamble\nopostamble +\file{README.md}{\from{\pkgname.dtx}{readme}}% +\usepostamble\defaultpostamble +\file{\pkgname.tex}{\from{\pkgname.dtx}{tex}}% +\usepreamble\pkgpreamble +\file{\pkgname.sty}{\from{\pkgname.dtx}{package}}}% +\catcode32=13\relax% active space +\let =\space% +\Msg{************************************************************************} +\Msg{*} +\Msg{* To finish the installation you have to move the following} +\Msg{* file into a directory searched by TeX:} +\Msg{*} +\Msg{* \pkgname.sty} +\Msg{*} +\Msg{* To produce the documentation run latex thrice on file \pkgname.tex} +\Msg{* and then run dvipdfmx on file \pkgname.dvi.} +\Msg{*} +\Msg{* Happy TeXing!} +\Msg{*} +\Msg{************************************************************************} +\endbatchfile +\endinput +%% +%% End of file `footnotehyper.ins'. diff --git a/Master/texmf-dist/tex/latex/footnotehyper/footnotehyper.sty b/Master/texmf-dist/tex/latex/footnotehyper/footnotehyper.sty new file mode 100644 index 00000000000..4e518e025c8 --- /dev/null +++ b/Master/texmf-dist/tex/latex/footnotehyper/footnotehyper.sty @@ -0,0 +1,72 @@ +%% +%% This is file `footnotehyper.sty', +%% generated with the docstrip utility. +%% +%% The original source files were: +%% +%% footnotehyper.dtx (with options: `package') +%% +%% IMPORTANT NOTICE: +%% +%% For the copyright see the source file. +%% +%% Any modified versions of this file must be renamed +%% with new filenames distinct from footnotehyper.sty. +%% +%% For distribution of the original source see the terms +%% for copying and modification in the file footnotehyper.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.) +%% +\NeedsTeXFormat{LaTeX2e} +\ProvidesPackage{footnotehyper}% + [2016/04/19 v0.9a hyperref aware footnote.sty (JFB)] +%% +%% Package: footnotehyper +%% Version: 0.9a (2016/04/19) +%% License: LPPL 1.3c +%% Copyright (C) 2016 Jean-Francois Burnol . +%% +\DeclareOption*{\PackageWarning{footnotehyper}{Option `\CurrentOption' is unknown.}} +\ProcessOptions\relax +\RequirePackage{footnote} +\AtBeginDocument{\@ifpackageloaded{hyperref}{}{\PackageWarning{footnotehyper} + {hyperref package not loaded!^^J This + will surely end up in zillions of error messages.}}} +\def\fn@fntext {\ifx\ifmeasuring@\undefined\expandafter\@secondoftwo + \else\expandafter\@firstofone\fi + {\ifmeasuring@\expandafter\@gobbletwo\fi}% + \FNH@fn@fntext } +\long\def\FNH@fn@fntext #1{% + \global\setbox\fn@notes\vbox + {\unvbox\fn@notes + \fn@startnote + \@makefntext + {\rule\z@\footnotesep\ignorespaces + \ifHy@nesting\expandafter\ltx@firstoftwo + \else\expandafter\ltx@secondoftwo + \fi + {\expandafter\hyper@@anchor\expandafter{\Hy@footnote@currentHref}{#1}}% + {\Hy@raisedlink + {\expandafter\hyper@@anchor\expandafter{\Hy@footnote@currentHref}% + {\relax}}% + \let\@currentHref\Hy@footnote@currentHref + \let\@currentlabelname\@empty + #1}% + \@finalstrut\strutbox }% + \fn@endnote }% +} +\def\spewnotes {\endgroup + \if@savingnotes\else\ifvoid\fn@notes\else + \begingroup\let\@makefntext\@empty + \let\@finalstrut\@gobble + \let\rule\@gobbletwo + \H@@footnotetext{\unvbox\fn@notes}% + \endgroup\fi\fi +} +\endinput +%% +%% End of file `footnotehyper.sty'. diff --git a/Master/tlpkg/bin/tlpkg-ctan-check b/Master/tlpkg/bin/tlpkg-ctan-check index efc0c15f671..39cd69f4aa4 100755 --- a/Master/tlpkg/bin/tlpkg-ctan-check +++ b/Master/tlpkg/bin/tlpkg-ctan-check @@ -256,7 +256,7 @@ my @TLP_working = qw( fontawesome font-change font-change-xetex fontaxes fontbook fontch fontinst fontmfizz fontools fonts-tlwg fontspec fonttable fontwrap - footbib footmisc footnotebackref footnoterange footnpag + footbib footmisc footnotebackref footnotehyper footnoterange footnpag forarray foreign forest forloop formlett formation-latex-ul formular fouridx fourier fouriernc fp fpl diff --git a/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc b/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc index bc5f869b58a..abf408787de 100644 --- a/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc +++ b/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc @@ -410,6 +410,7 @@ depend fontaxes depend fonttable depend footmisc depend footnotebackref +depend footnotehyper depend footnoterange depend footnpag depend forarray diff --git a/Master/tlpkg/tlpsrc/footnotehyper.tlpsrc b/Master/tlpkg/tlpsrc/footnotehyper.tlpsrc new file mode 100644 index 00000000000..e69de29bb2d -- cgit v1.2.3