From 2a067cc5db2ba195fbddc0d1ca943956193c3838 Mon Sep 17 00:00:00 2001
From: Karl Berry <karl@freefriends.org>
Date: Tue, 26 Jul 2011 21:10:40 +0000
Subject: koma-script 3.09a (16jun11)

git-svn-id: svn://tug.org/texlive/trunk@23235 c570f23f-e606-0410-a88d-b1316a301751
---
 .../source/latex/koma-script/tocbasic.dtx          | 36 +++++++++++++++++-----
 1 file changed, 28 insertions(+), 8 deletions(-)

(limited to 'Master/texmf-dist/source/latex/koma-script/tocbasic.dtx')

diff --git a/Master/texmf-dist/source/latex/koma-script/tocbasic.dtx b/Master/texmf-dist/source/latex/koma-script/tocbasic.dtx
index 055b5b8382e..17cdb2bafa6 100644
--- a/Master/texmf-dist/source/latex/koma-script/tocbasic.dtx
+++ b/Master/texmf-dist/source/latex/koma-script/tocbasic.dtx
@@ -1,4 +1,4 @@
-% \CheckSum{1211}
+% \CheckSum{1233}
 % \iffalse meta-comment
 % ======================================================================
 % tocbasic.dtx
@@ -66,7 +66,7 @@
 %%% From File: tocbasic.dtx
 %<*dtx|package|driver|doc|load>
 % \fi
-\def\tocbasicversion{2011/03/23 v3.09}
+\def\tocbasicversion{2011/05/30 v3.09a}
 % \iffalse
 %</dtx|package|driver|doc|load>
 %<*dtx>
@@ -1738,6 +1738,7 @@ be defined and used in \Macro{tocbasic@listhead}.
 %
 % \begin{macro}{\tocbasic@listhead}
 %   \changes{v3.02a}{2009/01/20}{no explicite marks if ``numbered''}
+%   \changes{v3.09a}{2011/04/12}{again no explicite marks if ``numbered''}
 %   Setting the headings of a list of something. The heading is the only
 %   argument.
 %    \begin{macrocode}
@@ -1758,7 +1759,7 @@ be defined and used in \Macro{tocbasic@listhead}.
           }%
         }{%
           \iftocfeature{\@currext}{numbered}{%
-            \section[##1]{##1\@mkboth{##1}{##1}}%
+            \section[##1]{##1}%
           }{%
             \section*{##1}%
             \@mkboth{\MakeMarkcase{##1}}{\MakeMarkcase{##1}}%
@@ -1782,7 +1783,7 @@ be defined and used in \Macro{tocbasic@listhead}.
           }%
         }{%
           \iftocfeature{\@currext}{numbered}{%
-            \chapter[##1]{##1\@mkboth{##1}{##1}}%
+            \chapter[##1]{##1}%
           }{%
             \chapter*{##1}%
             \@mkboth{\MakeMarkcase{##1}}{\MakeMarkcase{##1}}%
@@ -2194,6 +2195,7 @@ be defined and used in \Macro{tocbasic@listhead}.
   \@tempswafalse
 %    \end{macrocode}
 % The float environments:
+% \changes{v3.09a}{2011/05/30}{fixed: floats may have an optional argument}
 %    \begin{macrocode}
   \iftb@float
     \expandafter\newcommand\expandafter*\csname fps@\tb@nt@type\expandafter
@@ -2204,15 +2206,19 @@ be defined and used in \Macro{tocbasic@listhead}.
       \edef\@tempa{%
         \noexpand\endgroup
         \noexpand\newenvironment{\tb@nt@type}{%
-          \noexpand\@float{\tb@nt@type}%
-          \noexpand\csname \tb@nt@type @atbegin\noexpand\endcsname
+          \noexpand\@ifnextchar[%]
+          {\noexpand\tb@atbegin@after\noexpand\@float{\tb@nt@type}}%
+          {\noexpand\tb@atbegin@after\noexpand\@float{\tb@nt@type}%
+            [\expandafter\noexpand\csname fps@\tb@nt@type\endcsname]}%
         }{%
           \noexpand\csname \tb@nt@type @atend\noexpand\endcsname
           \noexpand\end@float
         }%
         \noexpand\newenvironment{\tb@nt@type*}{%
-          \noexpand\@dblfloat{\tb@nt@type}%
-          \noexpand\csname \tb@nt@type @atbegin\noexpand\endcsname
+          \noexpand\@ifnextchar[%]
+          {\noexpand\tb@atbegin@after\noexpand\@dblfloat{\tb@nt@type}}%
+          {\noexpand\tb@atbegin@after\noexpand\@dblfloat{\tb@nt@type}%
+            [\expandafter\noexpand\csname fps@\tb@nt@type\endcsname]}%
         }{%
           \noexpand\csname \tb@nt@type @atend\noexpand\endcsname
           \noexpand\end@dblfloat
@@ -2284,6 +2290,20 @@ be defined and used in \Macro{tocbasic@listhead}.
   \fi
 }
 %    \end{macrocode}
+% \begin{macro}{\tb@atbegin@after}
+%   \changes{v3.09a}{2011/05/30}{new internal}%
+%   Processes command \#1 with argument \#2 and optional argument \#3 and than
+%   \verb|\csname #2@atbegin\endcsname|. This is used to add
+%   \verb|csname #2@atbegin\endcsname| at begin part of a float (but after
+%   optional argument of the float).
+%    \begin{macrocode}
+\newcommand*{\tb@atbegin@after}[3]{}
+\def\tb@atbegin@after#1#2[#3]{%
+  #1{#2}[#3]%
+  \csname #2@atbegin\endcsname
+}
+%    \end{macrocode}
+% \end{macro}
 % \begin{macro}{\tb@ifvalueisnotempty}
 %   \changes{v3.06}{2010/05/21}{new internal}%
 %   This is only a helper for defining some of the keys.
-- 
cgit v1.2.3

