From e02235dda0e68d2131b9cf111af5448fa125ad58 Mon Sep 17 00:00:00 2001
From: Karl Berry <karl@freefriends.org>
Date: Sun, 29 Jan 2017 22:32:58 +0000
Subject: koma-script (29jan17)

git-svn-id: svn://tug.org/texlive/trunk@43084 c570f23f-e606-0410-a88d-b1316a301751
---
 .../texmf-dist/tex/latex/koma-script/scrextend.sty | 135 ++++++++++++---------
 1 file changed, 81 insertions(+), 54 deletions(-)

(limited to 'Master/texmf-dist/tex/latex/koma-script/scrextend.sty')

diff --git a/Master/texmf-dist/tex/latex/koma-script/scrextend.sty b/Master/texmf-dist/tex/latex/koma-script/scrextend.sty
index 9edeffc09b7..664bbc62983 100644
--- a/Master/texmf-dist/tex/latex/koma-script/scrextend.sty
+++ b/Master/texmf-dist/tex/latex/koma-script/scrextend.sty
@@ -76,7 +76,7 @@
   }%
   \expandafter\endinput
 \fi
-%%% From File: $Id: scrkernel-version.dtx 2461 2016-05-19 07:17:15Z kohm $
+%%% From File: $Id: scrkernel-version.dtx 2491 2016-07-29 08:03:57Z kohm $
 \begingroup
   \catcode`\@11\relax
   \ifx\KOMAScriptVersion\undefined
@@ -98,7 +98,7 @@
       \fi
     }
   \fi
-  \@CheckKOMAScriptVersion{2016/06/14 v3.21 KOMA-Script}%
+  \@CheckKOMAScriptVersion{2017/01/03 v3.22 KOMA-Script}%
 \endgroup
 \providecommand*{\scr@pkgextension}{\@pkgextension}
 \AtBeginDocument{%
@@ -106,7 +106,7 @@
 }
 %%% From File: $Id: scrextend.dtx 1980 2015-03-09 12:46:05Z kohm $
 \ProvidesPackage{scrextend}[%
-  2016/06/14 v3.21 KOMA-Script
+  2017/01/03 v3.22 KOMA-Script
   package (extend other classes with features of KOMA-Script classes)%
 ]
 \newcommand*{\scr@ext@activate}[1]{%
@@ -130,9 +130,9 @@
     \expandafter\g@addto@macro\csname scr@ext@activate@#1\endcsname
   }%
 }
-%%% From File: $Id: scrkernel-basics.dtx 2467 2016-05-27 18:35:47Z kohm $
+%%% From File: $Id: scrkernel-basics.dtx 2490 2016-07-29 06:29:45Z kohm $
 \RequirePackage{scrkbase}[\KOMAScriptVersion]
-%%% From File: $Id: scrkernel-sections.dtx 2477 2016-06-12 09:52:43Z kohm $
+%%% From File: $Id: scrkernel-sections.dtx 2565 2016-12-21 17:25:47Z kohm $
 %%%            (run: prepare)
 \newcommand*{\sectfont}{\normalcolor\@gr@gsffamily\bfseries}
 %%% From File: $Id: scrextend.dtx 1980 2015-03-09 12:46:05Z kohm $
@@ -158,7 +158,7 @@
     \def\FamilyKeyState{Option `extendedfeature' too late}%
   }%
 }
-%%% From File: $Id: scrkernel-compatibility.dtx 2461 2016-05-19 07:17:15Z kohm $
+%%% From File: $Id: scrkernel-compatibility.dtx 2491 2016-07-29 08:03:57Z kohm $
 \providecommand*
   {\scr@compatibility}{\scr@v@last}
 \KOMA@key{version}[last]{%
@@ -264,7 +264,8 @@
 \@namedef{scr@v@3.19a}{15}
 \@namedef{scr@v@3.20}{15}
 \@namedef{scr@v@3.21}{15}
-\@namedef{scr@v@last}{15}
+\@namedef{scr@v@3.22}{16}
+\@namedef{scr@v@last}{16}
 \newcommand*{\scr@v@is@lt}[1]{%
   \scr@compatibility<\@nameuse{scr@v@#1}
 }
@@ -304,7 +305,7 @@
 \newcommand*{\@gr@gsffamily}{%
   \if@egregdoesnotlikesansseriftitles\else\sffamily\fi
 }
-%%% From File: $Id: scrkernel-fonts.dtx 2428 2016-04-12 10:31:07Z kohm $
+%%% From File: $Id: scrkernel-fonts.dtx 2501 2016-09-28 05:55:32Z kohm $
 \providecommand*{\@fontsizefilebase}{scrsize}
 \KOMA@key{fontsize}{%
     \expandafter\@defaultunits\expandafter\@tempdima#1 pt\relax\@nnil
@@ -383,7 +384,7 @@
 \KOMA@DeclareStandardOption%
   [scrextend]%
   {notitlepage}{titlepage=false}
-%%% From File: $Id: scrkernel-sections.dtx 2477 2016-06-12 09:52:43Z kohm $
+%%% From File: $Id: scrkernel-sections.dtx 2565 2016-12-21 17:25:47Z kohm $
 %%%            (run: option)
 %%% From File: $Id: scrkernel-pagestyles.dtx 2304 2015-12-12 08:55:47Z kohm $
 \KOMA@key{cleardoublepage}{%
@@ -466,8 +467,8 @@
   {\pagestyle{#1}\cleardoublestandardpage}}
 \newcommand*{\cleardoubleemptypage}{\cleardoublepageusingstyle{empty}}
 \newcommand*{\cleardoubleplainpage}{\cleardoublepageusingstyle{plain}}
-%%% From File: $Id: scrkernel-floats.dtx 2468 2016-05-31 11:27:28Z kohm $
-%%% From File: $Id: scrkernel-footnotes.dtx 2180 2015-08-24 09:28:16Z kohm $
+%%% From File: $Id: scrkernel-floats.dtx 2498 2016-09-01 19:44:10Z kohm $
+%%% From File: $Id: scrkernel-footnotes.dtx 2571 2017-01-03 13:04:47Z kohm $
 \KOMA@key{footnotes}{%
   \ifx\@footnotemark\scr@saved@footnotemark
   \else
@@ -537,13 +538,13 @@
   \csname FN@mf@prepare\endcsname
   \ifhmode\spacefactor\@x@sf\fi
   \relax}
-%%% From File: $Id: scrkernel-listsandtabulars.dtx 2318 2016-01-29 11:40:15Z kohm $
-%%% From File: $Id: scrkernel-sections.dtx 2477 2016-06-12 09:52:43Z kohm $
+%%% From File: $Id: scrkernel-listsandtabulars.dtx 2503 2016-10-21 08:54:46Z kohm $
+%%% From File: $Id: scrkernel-sections.dtx 2565 2016-12-21 17:25:47Z kohm $
 %%%            (run: execoption)
 %%% From File: $Id: scrkernel-miscellaneous.dtx 2463 2016-05-19 07:27:47Z kohm $
 \KOMAProcessOptions\relax
-%%% From File: $Id: scrkernel-compatibility.dtx 2461 2016-05-19 07:17:15Z kohm $
-%%% From File: $Id: scrkernel-fonts.dtx 2428 2016-04-12 10:31:07Z kohm $
+%%% From File: $Id: scrkernel-compatibility.dtx 2491 2016-07-29 08:03:57Z kohm $
+%%% From File: $Id: scrkernel-fonts.dtx 2501 2016-09-28 05:55:32Z kohm $
 \newcommand*\scr@setlength[4]{%
   \expandafter\ifnum\scr@v@is@lt{3.12}\relax
     \setlength{#1}{#2 \@plus#3 \@minus#4}%
@@ -1210,7 +1211,7 @@
 \newkomafont{dedication}{\Large}
 \newcommand*{\scr@fnt@title}{\titlefont}%
 \newcommand*{\scr@fnt@subject}{\subject@font}%
-%%% From File: $Id: scrkernel-sections.dtx 2477 2016-06-12 09:52:43Z kohm $
+%%% From File: $Id: scrkernel-sections.dtx 2565 2016-12-21 17:25:47Z kohm $
 %%%            (run: body)
 \newcommand*{\scr@fnt@disposition}{\sectfont}
 \aliaskomafont{sectioning}{disposition}
@@ -1297,34 +1298,52 @@
   {\m@th\ensuremath{_{\mbox{\fontsize\sf@size\z@#1}}}}%
 }
 %%% From File: $Id: scrkernel-pagestyles.dtx 2304 2015-12-12 08:55:47Z kohm $
-%%% From File: $Id: scrkernel-floats.dtx 2468 2016-05-31 11:27:28Z kohm $
+%%% From File: $Id: scrkernel-floats.dtx 2498 2016-09-01 19:44:10Z kohm $
 \newcommand\marginline[1]{%
   \marginpar[\raggedleft{#1}]{\raggedright #1}%
 }
-%%% From File: $Id: scrkernel-footnotes.dtx 2180 2015-08-24 09:28:16Z kohm $
+%%% From File: $Id: scrkernel-footnotes.dtx 2571 2017-01-03 13:04:47Z kohm $
 \newcommand\deffootnote[4][]{%
-  \long\def\@makefntext##1{%
-    \setlength{\@tempdimc}{#3}%
-    \def\@tempa{#1}\ifx\@tempa\@empty
-      \@setpar{\@@par
-        \@tempdima = \hsize
-        \addtolength{\@tempdima}{-#2}%
-        \parshape \@ne #2 \@tempdima}%
-    \else
-      \addtolength{\@tempdimc}{#2}%
-      \addtolength{\@tempdimc}{-#1}%
-      \@setpar{\@@par
-        \@tempdima = \hsize
-        \addtolength{\@tempdima}{-#1}%
-        \@tempdimb = \hsize
-        \addtolength{\@tempdimb}{-#2}%
-        \parshape \tw@ #1 \@tempdima #2 \@tempdimb
+  \expandafter\ifnum\scr@v@is@ge{3.22}\relax
+    \long\def\@makefntext##1{%
+      \leftskip #2
+      \l@addto@macro\@trivlist{%
+        \ifnum\@listdepth=\@ne\advance\leftmargin #2\relax\fi
       }%
-    \fi
-    \par
-    \parindent\@tempdimc\noindent
-    \ftn@font\hbox to \z@{\hss\@@makefnmark}##1%
-  }%
+      \parindent #3\noindent
+      \IfArgIsEmpty{#1}{}{%
+        \hskip \dimexpr #1-#2\relax
+      }%
+      \ftn@font\hbox to \z@{\hss\@@makefnmark}##1%
+    }%
+  \else
+    \PackageInfo{scrextend}{%
+      Using old \string\@makefntext\space due to compatibility
+      level\MessageBreak
+      less than 3.22}%
+    \long\def\@makefntext##1{%
+      \setlength{\@tempdimc}{#3}%
+      \def\@tempa{#1}\ifx\@tempa\@empty
+        \@setpar{\@@par
+          \@tempdima = \hsize
+          \addtolength{\@tempdima}{-#2}%
+          \parshape \@ne #2 \@tempdima}%
+      \else
+        \addtolength{\@tempdimc}{#2}%
+        \addtolength{\@tempdimc}{-#1}%
+        \@setpar{\@@par
+          \@tempdima = \hsize
+          \addtolength{\@tempdima}{-#1}%
+          \@tempdimb = \hsize
+          \addtolength{\@tempdimb}{-#2}%
+          \parshape \tw@ #1 \@tempdima #2 \@tempdimb
+        }%
+      \fi
+      \par
+      \parindent\@tempdimc\noindent
+      \ftn@font\hbox to \z@{\hss\@@makefnmark}##1%
+    }%
+  \fi
   \def\@@makefnmark{\hbox{\ftnm@font{#4}}}%
 }
 \newcommand*{\ftn@font}{\normalfont}
@@ -1412,7 +1431,7 @@
   \endgroup
   \@footnotemark
 }
-%%% From File: $Id: scrkernel-listsandtabulars.dtx 2318 2016-01-29 11:40:15Z kohm $
+%%% From File: $Id: scrkernel-listsandtabulars.dtx 2503 2016-10-21 08:54:46Z kohm $
 \newenvironment{labeling}[2][]{%
   \def\sc@septext{#1}%
   \list{}{\settowidth{\labelwidth}{{%
@@ -1437,22 +1456,24 @@
 }
 \newenvironment{addmargin*}{%
   \@tempswafalse
-  \if@twoside\is@thispageodd[]\ifthispagewasodd\else\@tempswatrue\fi\fi
-  \edef\scr@addmargin@startpage{\csname tpo@\scr@tpo\endcsname}%
+  \if@twoside\is@thispageodd[]\ifthispagewasodd\else\@tempswatrue\fi
+    \edef\scr@addmargin@startpage{\csname tpo@\scr@tpo\endcsname}\fi
   \@addmargin
 }{%
-  \unskip\nobreak\ifthispageodd{}{}%
-  \expandafter\ifx\csname tpo@\scr@tpo\endcsname\scr@addmargin@startpage\else
-  \PackageWarning{scrextend}{%
-      page break inside `addmargin*' environment.\MessageBreak
-      A `addmargin*' environment starting on page
-      \scr@addmargin@startpage\MessageBreak
-      ends on page \csname tpo@\scr@tpo\endcsname.\MessageBreak
-      This will result in potential wrong margins on\MessageBreak
-      every other page.\MessageBreak
-      So maybe you should change the `addmargin*'\MessageBreak
-      environment, that ends%
-    }%
+  \if@twoside
+    \unskip\nobreak\ifthispageodd{}{}%
+    \expandafter\ifx\csname tpo@\scr@tpo\endcsname\scr@addmargin@startpage\else
+    \PackageWarning{scrextend}{%
+        page break inside `addmargin*' environment.\MessageBreak
+        A `addmargin*' environment starting on page
+        \scr@addmargin@startpage\MessageBreak
+        ends on page \csname tpo@\scr@tpo\endcsname.\MessageBreak
+        This will result in potential wrong margins on\MessageBreak
+        every other page.\MessageBreak
+        So maybe you should change the `addmargin*'\MessageBreak
+        environment, that ends%
+      }%
+    \fi
   \fi
   \advance\@listdepth\@ne
   \endlist
@@ -1471,13 +1492,19 @@
     \setlength{\listparindent}{\parindent}%
     \setlength{\itemsep}{\parskip}%
     \setlength{\itemindent}{\z@}%
+    \setlength{\@tempskipa}{\topsep}%
     \setlength{\topsep}{\z@}%
     \setlength{\parsep}{\parskip}%
+    \setlength{\@tempskipb}{\partopsep}%
     \setlength{\partopsep}{\z@}%
     \let\makelabel\@gobble
     \setlength{\labelwidth}{\z@}%
     \advance\@listdepth\m@ne
   }%
+  \expandafter\ifnum\scr@v@is@ge{3.22}%
+    \setlength{\topsep}{\@tempskipa}%
+    \setlength{\partopsep}{\@tempskipb}%
+  \fi
   \item\is@thispageodd@setlabel\nobreak\ignorespaces
 }
 \newkomafont{labelinglabel}{}
-- 
cgit v1.2.3

