[latex3-commits] [git/LaTeX3-latex3-latex2e] develop: suggested fix for TOC by Ulrike (63ef4aef)

Frank Mittelbach frank.mittelbach at latex-project.org
Thu Jan 30 12:11:59 CET 2020


Repository : https://github.com/latex3/latex2e
On branch  : develop
Link       : https://github.com/latex3/latex2e/commit/63ef4aef8c9e073d887c663c0a8e8fc349ba3e85

>---------------------------------------------------------------

commit 63ef4aef8c9e073d887c663c0a8e8fc349ba3e85
Author: Frank Mittelbach <frank.mittelbach at latex-project.org>
Date:   Thu Jan 30 12:11:59 2020 +0100

    suggested fix for TOC by Ulrike


>---------------------------------------------------------------

63ef4aef8c9e073d887c663c0a8e8fc349ba3e85
 base/doc/ltnews.tex | 22 ++++++----------------
 1 file changed, 6 insertions(+), 16 deletions(-)

diff --git a/base/doc/ltnews.tex b/base/doc/ltnews.tex
index 779c1575..13e283c5 100644
--- a/base/doc/ltnews.tex
+++ b/base/doc/ltnews.tex
@@ -28,11 +28,13 @@
 %  * LaTeX Project version
 % 2015/02/16 v1.4b:
 %  * Fix TOC issue
+% 2020/01/30 v1.4b:
+%  * Fix TOC issue more generally and add page numbers
 % \fi
 
 \NeedsTeXFormat{LaTeX2e}
 \ProvidesFile{ltnews.tex}%
-  [2020/01/09 v1.4c Master file for ltnews*.tex (LaTeX Project)]
+  [2020/01/30 v1.4c Master file for ltnews*.tex (LaTeX Project)]
 
 \providecommand*{\lastissue}{31}
 
@@ -181,8 +183,6 @@
 
 %%% Issues
 
-
-
 \begingroup
   \makeatletter
   \renewcommand*{\usepackage}[2][]{%
@@ -237,15 +237,7 @@
          \let\protect\l at paragraph\protect\l at subsection
        }%
     \fi
-    %
-    % Just a temporary fix for now (we drop the tocs of individual issues)
-    % the file should use titletoc and partial tocs instead
-    % but that needs coding!
-    %
-\let\tableofcontents\relax   % no tocs in individual issues for now
-\let\pagebreak\relax         % used in 31 and invalid if there aren't any tocs
-\iffalse
-    \ifnum\@issue=\lastissue\space
+    \ifnum\@issue >20\space
       \addtocontents{toc}{%
         \let\protect\l at paragraph\protect\saved at l@paragraph
       }%
@@ -254,7 +246,7 @@
       \addtocontents{toc}{\protect\setcounter{tocdepth}{4}}%
       \renewcommand*{\tableofcontents}{%
         \section*{\contentsname}%
-        \@starttoc{toc\lastissue}%
+        \@starttoc{toc\theissue}%
       }%
       \let\saved at addtocontents\addtocontents
       \renewcommand*{\addtocontents}[2]{%
@@ -262,7 +254,7 @@
         \def\temp at toc{toc}%
         \def\temp at param{##1}%
         \ifx\temp at toc\temp at param
-          \saved at addtocontents{toc\lastissue}{##2}%
+          \saved at addtocontents{toc\theissue}{##2}%
         \fi
       }%
       \let\l at subsubsection\l at subsection
@@ -270,8 +262,6 @@
       \let\l at section\l at part
       \let\l at part\@gobbletwo
     \fi
-\fi
-%
     \def\twocolumn[{%
       \let\twocolumn\org at twocolumn
       \org at twocolumn[%





More information about the latex3-commits mailing list.