From 39eee492a47dc496a406cd7d0cc34a8530d8f5ce Mon Sep 17 00:00:00 2001
From: Karl Berry <karl@freefriends.org>
Date: Sat, 11 Jun 2016 23:21:54 +0000
Subject: limap (29may16)

git-svn-id: svn://tug.org/texlive/trunk@41390 c570f23f-e606-0410-a88d-b1316a301751
---
 Master/texmf-dist/tex/latex/limap/limap.sty | 307 +++++++++++++++++-----------
 1 file changed, 184 insertions(+), 123 deletions(-)

(limited to 'Master/texmf-dist/tex/latex/limap/limap.sty')

diff --git a/Master/texmf-dist/tex/latex/limap/limap.sty b/Master/texmf-dist/tex/latex/limap/limap.sty
index 6ce83d9952a..86a2ae143df 100644
--- a/Master/texmf-dist/tex/latex/limap/limap.sty
+++ b/Master/texmf-dist/tex/latex/limap/limap.sty
@@ -21,28 +21,23 @@
 %% same distribution. (The sources need not necessarily be
 %% in the same archive or directory.)
 %%^^A%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%%^^A $Id: limap.dtx 1.2 2000/03/01 20:11:42 gene Exp gene $
-%%^^A%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 %% Purpose:
 %%      A package for typesetting Information Maps.
 %%
 %% Documentation:
 %%      The documentation  can be generated  from  the  original  file
-%%      limap.dtx with the doc style/package. LaTeX the file limap.tex
-%%      to get the full documentation in \textsc{dvi} format.
+%%      limap.dtx with the doc class/package. LaTeX the file limap.tex
+%%      to get the full documentation in pdf format.
 %%
 %% Author: Gerd Neugebauer
-%%         Mainzer Str. 8
-%%         56321 Rhens (Germany)
-%% Mail:   gerd.neugebauer@sdm.de
-%%    gerd.neugebauer@gmx.de
+%%         Im Lerchelsb\"ohl 5
+%%         64521 Gro\ss-Gerau (Germany)
+%% Mail:   gene@gerd-neugebauer.de
 %%
-%% Copyright (C) 1999-2000 Gerd Neugebauer
+%% Copyright (C) 1999-2016 Gerd Neugebauer
 %%
 %% limap.dtx may be  distributed under the terms of  the LaTeX Project
-%% Public  License,  as  described  in  lppl.txt  in  the  base  LaTeX
-%% distribution.   Either version 1.0  or, at  your option,  any later
-%% version.
+%% Public License version  1.3c, as described in lppl.txt.
 %%
 %% This class is still under development and  may be replaced with a
 %% new version which provides an enhanced functionality.
@@ -64,14 +59,36 @@
 %%   Grave accent  \`     Left brace    \{     Vertical bar  \|
 %%   Right brace   \}     Tilde         \~}
 %%
-\def\LIMAP@RCS$#1: #2 #3${#2}
 \def\filename{limap.dtx}
-\xdef\fileversion{\LIMAP@RCS$Revision: 1.2 $}
-\xdef\filedate{\LIMAP@RCS$Date: 2000/03/01 20:11:42 $}
+\def\fileversion{2.1}
+\def\filedate{2016/05/29}
 \let\docversion=\fileversion
 \let\docdate=\filedate
 \NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{limap}[\filedate\space  gene]
+\ProvidesPackage{limap}[\filedate\space Gerd Neugebauer]
+\def\defineLimapLanguage#1#2#3#4#5{%
+  \expandafter\def\csname LIMAP@SelectLanguage@#1\endcsname{%
+    \def\MapContinued{#2}%
+    \def\MapContinuing{#3}%
+    \def\MapTOCname{#4}%
+    \def\MapTOCpage{#5}%
+  }%
+}
+\defineLimapLanguage{austrian}%
+  { Fortsetzung}{Fortsetzung\dots}%
+  {Titel}{Seite}
+\defineLimapLanguage{german}%
+  { Fortsetzung}{Fortsetzung\dots}%
+  {Titel}{Seite}
+\defineLimapLanguage{english}%
+  { Continued}{Continuing\dots}%
+  {Title}{Page}
+\defineLimapLanguage{USenglish}%
+  { Continued}{Continuing\dots}%
+  {Title}{Page}
+\defineLimapLanguage{french}%
+  { continuation}{continuation\dots}%
+  {Intitulé}{Page}
 \providecommand\LIMAP@Language{english}
 \DeclareOption{austrian}{\renewcommand\LIMAP@Language{austrian}}
 \DeclareOption{german}{\renewcommand\LIMAP@Language{german}}
@@ -80,21 +97,25 @@
 \DeclareOption{USenglish}{\renewcommand\LIMAP@Language{USenglish}}
 \newif\ifLIMAP@strict \LIMAP@stricttrue
 \DeclareOption{nonstrict}{\LIMAP@strictfalse}
+\DeclareOption{nolines}{\def\MapRuleWidth{0pt}\ignorespaces}
 \ProcessOptions
 \RequirePackage{longtable}
+\RequirePackage{etoolbox}
 \RequirePackage{booktabs}
 \raggedbottom
-\newcommand\MapRuleWidth{.25pt}
+\providecommand\MapRuleWidth{.25pt}
+\newcommand\MapRuleStart{}
 \newcommand\MapContinued{}
 \newcommand\MapContinuing{}
 \newcommand\MapContinuingFormat[1]{\textit{\footnotesize #1}}
-\newcommand\MapContinuedFormat[1]{, {\MapTitleContinuedSize #1}}
+\newcommand\MapContinuedFormat[1]{, {\MapTitleContinuedFont #1}}
 \let\MapFont\textsf
-\let\MapTitleSize\Large
-\let\MapTitleContinuedSize\small
+\let\MapTitleFont\Large
+\let\MapTitleContinuedFont\small
+\def\MapBlockLabelFont{}
 \newcommand\MapParskip{2ex}
-\newcommand\MapTitlefraction{.2}
-\newcommand\MapTextfraction{.75}
+\newcommand\MapTitleFraction{.2}
+\newcommand\MapTextFraction{.75}
 \let\MapNewpage\newpage
 \newcommand\MapTOC[1]{%
   \refstepcounter{\@nameuse{Map@TOC@name\the\Map@level}}%
@@ -102,35 +123,50 @@
 }
 \newcommand\MapTOCname{}
 \newcommand\MapTOCpage{}
-\let\MapTOCemph=\emph
-\providecommand\LIMAP@SelectLanguage@austrian{%
-  \renewcommand\MapContinued{ Fortsetzung}%
-  \renewcommand\MapContinuing{Fortsetzung\dots}
-  \renewcommand\MapTOCname{Titel}
-  \renewcommand\MapTOCpage{Seite}
-}
-\providecommand\LIMAP@SelectLanguage@german{%
-  \renewcommand\MapContinued{ Fortsetzung}%
-  \renewcommand\MapContinuing{Fortsetzung\dots}
-  \renewcommand\MapTOCname{Titel}
-  \renewcommand\MapTOCpage{Seite}
-}
-\providecommand\LIMAP@SelectLanguage@english{%
-  \renewcommand\MapContinued{ Continued}%
-  \renewcommand\MapContinuing{Continuing\dots}
-  \renewcommand\MapTOCname{Title}
-  \renewcommand\MapTOCpage{Page}
-}
-\providecommand\LIMAP@SelectLanguage@USenglish{%
-  \renewcommand\MapContinued{ Continued}%
-  \renewcommand\MapContinuing{Continuing\dots}
-  \renewcommand\MapTOCname{Title}
-  \renewcommand\MapTOCpage{Page}
-}
+\newcommand\MapTOCheadfont{\scriptsize\emph}
 \newlength{\Map@length}
 \newcount\Map@level
 \Map@level=0
 \newcount\Map@blockcount
+\def\LT@final@warn{%
+  \AtEndDocument{%
+    \PackageWarning{limap}%
+    {Table \@width s have changed. Rerun LaTeX.\@gobbletwo}}%
+  \global\let\LT@final@warn\relax}
+\def\Map#1{%
+  \def\LT@err{\PackageError{limap}}%
+  \def\LT@warn{\PackageWarning{limap}}%
+  \let\Block\Map@Block
+  \let\endBlock\Map@endBlock
+  \Map@blockcount=0
+  \global\advance\Map@no1
+  \ifx\Map@UP\empty\else
+    \immediate\write\@auxout
+      {\string\expandafter\string\xdef\string\csname\space
+        Map@parts@\Map@UP\string\endcsname{\string\csname\space
+          Map@parts@\Map@UP\string\endcsname\the\Map@no:}}%
+  \fi
+  \edef\Map@UP{\the\Map@no}%
+  \ifnum\Map@level>0
+    \xdef\Map@@up{\Map@UP}% Just to save the value across blocks.
+    \endgroup
+    \Map@end
+    \begingroup
+    \edef\Map@UP{\Map@@up}%
+    \def\@currenvir{Map}%
+  \fi
+  \edef\Map@this{\the\Map@no}%
+  \immediate\write\@auxout
+    {\string\global\string\@namedef{Map@parts@\the\Map@no}{}}%
+  \global\advance\Map@level1
+  \def\Map@TITLE{#1}%
+  \Map@start
+  }
+\def\endMap{%
+  \Map@end
+  \global\advance\Map@level-1
+  \ignorespaces
+}
 \newif\ifMap@open@
 \Map@open@false
 \@namedef{Map@TOC@name0}{chapter}
@@ -147,33 +183,40 @@
 \@namedef{Map@TOC@name11}{subsubparagraph}
 \@namedef{Map@TOC@name12}{subsubparagraph}
 \newcommand\Map@start{%
+  \advance\Map@counter1
   \setlength{\Map@length}{\textwidth}%
-  \addtolength{\Map@length}{-\MapTitlefraction\textwidth}%
-  \addtolength{\Map@length}{-\MapTextfraction\textwidth}%
-  \MapTOC{\Map@TITLE}%
+  \addtolength{\Map@length}{-\MapTitleFraction\textwidth}%
+  \addtolength{\Map@length}{-\MapTextFraction\textwidth}%
+  \ifx\Map@TITLE\empty\else
+    \MapTOC{\Map@TITLE}%
+  \fi
   \longtable
-    {@{}p{\MapTitlefraction\textwidth}@{\hspace{\Map@length}}
-        p{\MapTextfraction\textwidth}@{}}%
+    {@{}p{\MapTitleFraction\textwidth}@{\hspace{\Map@length}}
+        p{\MapTextFraction\textwidth}@{}}%
       \multicolumn{2}{@{}p{\textwidth}@{}}{%
-        \MapFont{\MapTitleSize\rule{0pt}{3ex}%
+        \MapFont{\MapTitleFont\rule{0pt}{3ex}%
           \Map@TITLE}}
     \endfirsthead
       \multicolumn{2}{@{}p{\textwidth}@{}}{%
-        \MapFont{\MapTitleSize\rule{0pt}{3ex}%
+        \MapFont{\MapTitleFont\rule{0pt}{3ex}%
           \Map@TITLE\MapContinuedFormat{\MapContinued}}}%
     \endhead
-      \par\vspace*{-\parskip}\vspace*{-2ex}\\
-      &\rule{\MapTextfraction\textwidth}{\MapRuleWidth}\newline
-      \mbox{}\hfill\raisebox{3pt}{\MapContinuingFormat{\MapContinuing}}
+    \\
+      &\MapRuleStart
+       \rule{\MapTextFraction\textwidth}{\MapRuleWidth}\newline
+       \mbox{}\hfill
+       \raisebox{3pt}{\MapContinuingFormat{\MapContinuing}}
     \endfoot
-      &\rule{\MapTextfraction\textwidth}{\MapRuleWidth}%
+      &\MapRuleStart
+       \rule{\MapTextFraction\textwidth}{\MapRuleWidth}%
        \vspace{\MapParskip}
     \endlastfoot
     \xdef\@currentlabel{\Map@TITLE}%
+    \label{Map@\the\Map@no}%
     \global\Map@open@true
 }
 \newcommand\Map@end{%
-  \ifMap@open@
+  \ifMap@open@\vspace*{1.5ex}
     \global\Map@open@false
     \endlongtable
     \MapNewpage
@@ -181,7 +224,8 @@
   \iftrue
    \ifnum\Map@blockcount>9
     \PackageWarning{limap}%
-    {*** The current map contains too much blocks: \the\Map@blockcount}%
+    {*** The current map contains too much blocks:
+         \the\Map@blockcount}%
    \else\ifnum\Map@blockcount>7
     \PackageWarning{limap}%
     {--- The current map contains \the\Map@blockcount blocks.}%
@@ -190,97 +234,114 @@
 }
 \newcommand\Map@UP{}
 \newcount\Map@no
+\newcount\Map@counter
+\Map@counter=0
 \@namedef{Map@parts@}{}
-\newenvironment{Map}[1]{%
-  \def\LT@err{\PackageError{limap}}%
-  \def\LT@warn{\PackageWarning{limap}}%
-  \let\Block\Map@Block
-  \let\endBlock\Map@endBlock
-  \Map@blockcount=0
-  \global\advance\Map@no1
-  \ifx\Map@UP\empty\else
-    \immediate\write\@auxout
-      {\string\expandafter\string\xdef\string\csname\space
-        Map@parts@\Map@UP\string\endcsname{\string\csname\space
-          Map@parts@\Map@UP\string\endcsname\the\Map@no:}}%
-  \fi
-  \edef\Map@UP{\the\Map@no}%
-  \ifnum\Map@level>0
-    \xdef\Map@@up{\Map@UP}% Just to save the value across blocks.
-    \endgroup
-    \Map@end
-    \begingroup
-    \edef\Map@UP{\Map@@up}%
-    \def\@currenvir{Map}%
-  \fi
-  \edef\Map@this{\the\Map@no}%
-  \immediate\write\@auxout
-    {\string\global\string\@namedef{Map@title@\the\Map@no}{#1}}%
-  \immediate\write\@auxout
-    {\string\global\string\@namedef{Map@page@\the\Map@no}{\the\c@page}}%
-  \immediate\write\@auxout
-    {\string\global\string\@namedef{Map@parts@\the\Map@no}{}}%
-  \global\advance\Map@level1
-  \def\Map@TITLE{#1}%
-  \Map@start
-  }{%
-  \Map@end
-  \global\advance\Map@level-1
-}
-\newenvironment{Map@Block}[1]{\par\vspace*{-\parskip}\vspace*{-2ex}%
+\newenvironment{Map@Block}[1]{\par
+  \vspace*{-\parskip}\vspace*{-1ex}%
   \\\null\par
   \vspace*{\MapParskip}%
-  \raggedright\hspace{0pt}\MapFont{#1}%
+  \raggedright\hspace{0pt}\MapFont{\MapBlockLabelFont{#1}}%
   \gdef\@currentlabel{#1}%
   &\parskip=\MapParskip
-  \rule{\MapTextfraction\textwidth}{\MapRuleWidth}\par
+  {\MapRuleStart
+    \rule{\MapTextFraction\textwidth}{\MapRuleWidth}}\par
 }{%
 }
-\newcommand\Wide@Block{\\\multicolumn2{@{}l@{}}}{}
-\newcommand\MapTableOfContents{%
-  \medskip\par
-  \xdef\Map@@{\csname Map@parts@\the\Map@no\endcsname}%
-  \gdef\Map@@@{}%
+\newcommand\Block[1]{\PackageWarning{limap}{The sectioning command
+      `Block' has been encountered outside the scope of a Map
+      environment.}}
+\newcommand\WideBlock{\\\multicolumn2{@{}l@{}}}
+\newif\if@Map@toc@sep@
+\def\MapTableOfContents@open{%
   \centering
   \begin{tabular}{p{.6\textwidth}r}\toprule
-    \MapTOCemph{\MapTOCname}&\MapTOCemph{\MapTOCpage}\\
-    \midrule
-    \expandafter\Map@toc@loop \Map@@:%
-    \\\bottomrule
+    \MapTOCheadfont{\MapTOCname}&
+    \MapTOCheadfont{\MapTOCpage}\\\midrule
+    \ifcsdef{Map@parts@\the\Map@no}{
+      \edef\Map@tmp@{\csname Map@parts@\the\Map@no\endcsname:}%
+      \expandafter\Map@toc@loop\Map@tmp@
+      \\\bottomrule
+    }{}
+  \end{tabular}
+}
+\def\MapTableOfContents@boxed{%
+  \centering
+  \begin{tabular}{|p{.6\textwidth}|r|}\hline
+    \MapTOCheadfont{\MapTOCname}&
+    \MapTOCheadfont{\MapTOCpage}\\\hline
+    \ifcsdef{Map@parts@\the\Map@no}{
+      \edef\Map@tmp@{\csname Map@parts@\the\Map@no\endcsname:}%
+      \expandafter\Map@toc@loop\Map@tmp@
+      \\\hline
+    }{}
   \end{tabular}
 }
+\newcommand\MapTableOfContentsStyle{open}
+\newcommand\MapTableOfContents{\par
+  \global\@Map@toc@sep@false
+  \csname MapTableOfContents@\MapTableOfContentsStyle\endcsname
+  \vspace*{-1.5\parskip}\par\ignorespaces
+}
 \def\Map@toc@loop#1:{%
-  \def\Map@@{#1}%
-  \ifx\Map@@\empty
-    \global\let\Map@@=\relax
+  \def\Map@tmp@{#1}%
+  \ifx\Map@tmp@\empty
+    \global\let\Map@next@=\relax
   \else
-    \gdef\Map@@{\Map@@@\@nameuse{Map@title@#1}&\@nameuse{Map@page@#1}%
-      \global\let\Map@@@=\\%
-      \Map@toc@loop}%
+    \if@Map@toc@sep@
+    \gdef\Map@next@{\\
+    \ref{Map@#1}&\pageref{Map@#1}%
+    \Map@toc@loop}%
+    \else
+    \gdef\Map@next@{%
+    \ref{Map@#1}&\pageref{Map@#1}%
+    \Map@toc@loop}%
+    \global\@Map@toc@sep@true
+    \fi
   \fi
-  \Map@@
+  \Map@next@
+}
+\newcommand\MapTabularFraction{.95}
+\newenvironment{MapTabular}{%
+  \begin{center}
+    \begin{tabular*}{\MapTabularFraction\linewidth}%
+}{%
+    \end{tabular*}
+  \end{center}\ignorespaces
 }
 \newcommand\MakeTitle{\thispagestyle{empty}
   \rule{0pt}{.25\textheight}\par
   \mbox{}\hfill
-  \begin{minipage}{\MapTextfraction\textwidth}
+  \begin{minipage}{\MapTextFraction\textwidth}
     \raggedright
-    \rule{\textwidth}{1pt}\par
-    \vspace*{5ex}%
+    \rule{\textwidth}{2pt}\par
+    \vspace*{2.5\MapParskip}%
     \sf{\huge \@title\par}%
-    \vspace*{5ex}%
-    \rule{\textwidth}{1pt}\par
-    \vspace*{5ex}%
+    \vspace*{2.5\MapParskip}%
+    \rule{\textwidth}{2pt}\par
+    \vspace*{2.5\MapParskip}%
     \MapFont{\large \@author} \par
-    \vspace*{10ex}%
+    \vspace*{2.5\MapParskip}%
     \MapFont{\footnotesize \@date}
-    \vspace*{10ex}%
+    \vspace*{\MapParskip}%
+  \end{minipage}%
+  \vspace*{-22ex}%
+  \par
+}
+\newenvironment{Abstract}{\vfill
+  \par
+  \mbox{}\hfill
+  \begin{minipage}{\MapTextFraction\textwidth}\parskip=1ex
+    \rule{\textwidth}{1pt}\medskip\par
+}{\par\rule{\textwidth}{1pt}
   \end{minipage}%
   \par
 }
 \InputIfFileExists{limap.cfg}{}{}
 \csname LIMAP@SelectLanguage@\LIMAP@Language\endcsname
 \ifLIMAP@strict
+  \def\chapter{\PackageWarning{limap}{The sectioning command
+      `chapter' is not available.}}
   \def\subsection{\PackageWarning{limap}{The sectioning command
       `subsection' is not available.}}
   \def\subsubsection{\PackageWarning{limap}{The sectioning command
-- 
cgit v1.2.3

