diff options
author | Takeshi KOMIYA <i.tkomiya@gmail.com> | 2021-01-28 00:13:17 +0900 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-28 00:13:17 +0900 |
commit | 62dad2f13331d15d94b36b8f125f08fd4304b68b (patch) | |
tree | 6cb40c1d070135d1c1aff3a75f5568159ebda795 | |
parent | fb4dde3fdb03750f702c66f482f8c4e2e1a20279 (diff) | |
parent | 9d706b6fb58fddebad22be549027f411d871d841 (diff) | |
download | sphinx-git-62dad2f13331d15d94b36b8f125f08fd4304b68b.tar.gz |
Merge pull request #8765 from jfbu/latex_memoir_french_footnote
LaTeX: sync with upstream footnotehyper
-rw-r--r-- | CHANGES | 2 | ||||
-rw-r--r-- | sphinx/texinputs/footnotehyper-sphinx.sty | 23 |
2 files changed, 19 insertions, 6 deletions
@@ -100,6 +100,8 @@ Bugs fixed * #8683: :confval:`html_last_updated_fmt` generates wrong time zone for %Z * #1112: ``download`` role creates duplicated copies when relative path is specified +* #7576: LaTeX with French babel and memoir crash: "Illegal parameter number + in definition of ``\FNH@prefntext``" * #8214: LaTeX: The :rst:role:`index` role and the glossary generate duplicate entries in the LaTeX index (if both used for same term) * #8735: LaTeX: wrong internal links in pdf to captioned code-blocks when diff --git a/sphinx/texinputs/footnotehyper-sphinx.sty b/sphinx/texinputs/footnotehyper-sphinx.sty index b6692cfb8..c66e9a548 100644 --- a/sphinx/texinputs/footnotehyper-sphinx.sty +++ b/sphinx/texinputs/footnotehyper-sphinx.sty @@ -1,9 +1,9 @@ \NeedsTeXFormat{LaTeX2e} \ProvidesPackage{footnotehyper-sphinx}% - [2017/10/27 v1.7 hyperref aware footnote.sty for sphinx (JFB)] + [2021/01/26 v1.1b hyperref aware footnote.sty for sphinx (JFB)] %% %% Package: footnotehyper-sphinx -%% Version: based on footnotehyper.sty 2017/03/07 v1.0 +%% Version: based on footnotehyper.sty 2021/01/26 v1.1b %% as available at https://www.ctan.org/pkg/footnotehyper %% License: the one applying to Sphinx %% @@ -16,7 +16,7 @@ %% 3. use of \sphinxunactivateextrasandspace from sphinx.sty, %% 4. macro definition \sphinxfootnotemark, %% 5. macro definition \sphinxlongtablepatch -%% 6. replaced an \undefined by \@undefined +%% 6. replaced some \undefined by \@undefined \DeclareOption*{\PackageWarning{footnotehyper-sphinx}{Option `\CurrentOption' is unknown}}% \ProcessOptions\relax \newbox\FNH@notes @@ -206,9 +206,20 @@ \FNH@@@1.2!3?4,\FNH@@@\relax }% \long\def\FNH@check@a #11.2!3?4,#2\FNH@@@#3{% - \ifx\relax#3\expandafter\@firstoftwo\else\expandafter\@secondoftwo\fi - \FNH@bad@makefntext@alert - {\def\FNH@prefntext{#1}\def\FNH@postfntext{#2}\FNH@check@b}% + \ifx\relax#3\FNH@bad@makefntext@alert + \else + \edef\FNH@restore@{\catcode`\noexpand\@\the\catcode`\@\relax}% + \makeatletter + \ifx\@makefntextFB\@undefined + \expandafter\@gobble\else\expandafter\@firstofone\fi + {\@ifclassloaded{memoir}% + {\ifFBFrenchFootnotes\expandafter\@gobble\fi}% + {}}% + \@secondoftwo + \scantokens{\def\FNH@prefntext{#1}\def\FNH@postfntext{#2}}% + \FNH@restore@ + \expandafter\FNH@check@b + \fi }% \def\FNH@check@b #1\relax{% \expandafter\expandafter\expandafter\FNH@check@c |