summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex/koma-script/scrhack.dtx
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/source/latex/koma-script/scrhack.dtx')
-rw-r--r--Master/texmf-dist/source/latex/koma-script/scrhack.dtx283
1 files changed, 16 insertions, 267 deletions
diff --git a/Master/texmf-dist/source/latex/koma-script/scrhack.dtx b/Master/texmf-dist/source/latex/koma-script/scrhack.dtx
index df88da9a8c0..d48e642218f 100644
--- a/Master/texmf-dist/source/latex/koma-script/scrhack.dtx
+++ b/Master/texmf-dist/source/latex/koma-script/scrhack.dtx
@@ -62,7 +62,7 @@
% Right brace \} Tilde \~}
%
% \iffalse
-%%% From File: $Id: scrhack.dtx 2960 2018-03-16 08:39:32Z kohm $
+%%% From File: $Id: scrhack.dtx 3019 2018-09-06 15:45:33Z kohm $
%<package&identify>%%% using: package,identify
%<package&option>%%% using: package,option
%<package&body>%%% using: package,body
@@ -71,13 +71,12 @@
\ifx\ProvidesFile\undefined\def\ProvidesFile#1[#2]{}\fi
\begingroup
\def\filedate$#1: #2-#3-#4 #5${\gdef\filedate{#2/#3/#4}}
- \filedate$Date: 2018-03-16 09:39:32 +0100 (Fri, 16 Mar 2018) $
+ \filedate$Date: 2018-09-06 17:45:33 +0200 (Thu, 06 Sep 2018) $
\def\filerevision$#1: #2 ${\gdef\filerevision{r#2}}
\filerevision$Revision: 1962 $
\endgroup
\ProvidesFile{scrhack.dtx}[\filedate\space\filerevision\space
%</dtx>
-%<manual>\ProvidesFile{scrhack.tex}[%
%<package&identify>\ProvidesPackage{scrhack}[%
%<hyperref&identify>\ProvidesFile{hyperref.hak}[%
%<float&identify>\ProvidesFile{float.hak}[%
@@ -86,7 +85,7 @@
%<setspace&identify>\ProvidesFile{setspace.hak}[%
%<lscape&identify>\ProvidesFile{lscape.hak}[%
%<nomencl&identify>\ProvidesFile{nomencl.hak}[%
-%<*dtx|manual|identify>
+%<*dtx|identify>
%!KOMAScriptVersion
package
%<*dtx>
@@ -95,7 +94,7 @@
%<*!identify>
(hacking other packages)%
%</!identify>
-%</dtx|manual|identify>
+%</dtx|identify>
%<hack&identify> (hacking package
%<hyperref&identify> hyperref)%
%<float&identify> float)%
@@ -104,9 +103,9 @@
%<setspace&identify> setspace)%
%<lscape&identify> lscape)%
%<nomencl&identify> nomencl)%
-%<*dtx|manual|identify>
+%<*dtx|identify>
]
-%</dtx|manual|identify>
+%</dtx|identify>
%<*dtx>
\ifx\documentclass\undefined
\input scrdocstrip.tex
@@ -176,8 +175,7 @@
\DocInput{scrhack.dtx}
\end{document}
%</dtx>
-% \fi
-%
+%\fi
%
% \selectlanguage{english}
%
@@ -195,266 +193,17 @@
% \author{Markus Kohm\thanks{mailto:komascript(at)gmx.info}}
% \maketitle
% \begin{abstract}
-% \iffalse
-%<*manual|dtx>
-%<*manual>
-\chapter{Hacks for Third-Party Packages by Package \Package{scrhack}}
-\labelbase{scrhack}
-%</manual>
-% \fi
-Some packages from other authors may have problems with \KOMAScript{}. In my
-opinion some packages could be improved. With some packages this makes only
-sense, if \KOMAScript{} was used. With some other packages the package author
-has another opinion. Sometimes proposals was never answered. Package
-\Package{scrhack} contains all those improvement proposals for other
-packages. This means, \Package{scrhack} redefines macros of packages from
-other authors! The redefinitions are only activated, if those packages were
-loaded. Users may prevent \Package{scrhack} from redefining macros of
-individual packages.
-%\iffalse
-%<*dtx>
-%\fi
+% Some packages from other authors may have problems with \KOMAScript{}. In
+% my opinion some packages could be improved. With some packages this makes
+% only sense, if \KOMAScript{} was used. With some other packages the
+% package author has another opinion. Sometimes proposals was never
+% answered. Package \Package{scrhack} contains all those improvement
+% proposals for other packages. This means, \Package{scrhack} redefines
+% macros of packages from other authors! The redefinitions are only
+% activated, if those packages were loaded. Users may prevent
+% \Package{scrhack} from redefining macros of individual packages.
% \end{abstract}
% \tableofcontents
-%\iffalse
-%</dtx>
-%\fi
-
-\section{The \Package{float} hack}
-\label{sec:scrhack.float}
-
-Package \Package{float} uses macros \Macro{float@listhead} to set the headings
-of a float listing and \Macro{float@addtolists} to add informations to all
-float listings. These macros where proposed by the \KOMAScript{} author for
-some years. In theory those macros may be used by several class and package
-authors to deligate some parts of the creation of a float listing to the
-class. This would increase the compatiblity of packages and classes. But
-unfortunately some package authors, even the author of package
-\Package{float}, implemented the commands in such a way, that these packages
-will become incompatible to each other.
-
-Because of this \KOMAScript\ stopped support for \Macro{float@addtolists} and
-\Macro{float@listhead} with version 3. Instead of this \KOMAScript\ supports
-several improvements for package authors using \KOMAScript\ package
-\Package{tocbasic}.
-
-Package \Package{scrhack} redefines some macros of package \Package{float} to
-not longer use \Macro{float@addtolists} and \Macro{float@listhead} but use the
-interface of package \Package{tocbasic}. This does not only improve the
-compatibility of \KOMAScript\ and package \Package{float}, but also improves
-the compatibility of packages \Package{babel} and \Package{float}.
-
-% \iffalse
-\begin{Declaration}
- \KOption{float}{switch}
-\end{Declaration}
-% \fi
-You may switch off the \Package{float} hack loading package \Package{scrhack}
-with option \OptionValue{float}{false}. You may also switch off the
-\Package{float} hack using \Macro{KOMAoptions}\PParameter{float=false} or
-\Macro{KOMAoption}\PParameter{float}\PParameter{false} somewhere after loading
-package \Package{scrhack}, but before loading package \Package{float}.
-
-\section{The \Package{floatrow} hack}
-\label{sec:scrhack.floatrow}
-
-Package \Package{floatrow} uses macros \Macro{float@listhead} to set the
-headings of a float listing and \Macro{float@addtolists} to add informations
-to all float listings. These macros where proposed by the \KOMAScript{} author
-for some years. In theory those macros may be used by several class and package
-authors to deligate some parts of the creation of a float listing to the
-class. This would increase the compatiblity of packages and classes. But
-unfortunately some package authors, even the author of package
-\Package{floatrow}, implemented the commands in such a way, that these packages
-will become incompatible to each other.
-
-Because of this \KOMAScript\ stopped support for \Macro{float@addtolists} and
-\Macro{float@listhead} with version 3. Instead of this \KOMAScript\ supports
-several improvements for package authors using \KOMAScript\ package
-\Package{tocbasic}.
-
-Package \Package{scrhack} redefines some macros of package \Package{floatrow}
-to not longer use \Macro{float@addtolists} and \Macro{float@listhead} but use
-the interface of package \Package{tocbasic}. This does not only improve the
-compatibility of \KOMAScript\ and package \Package{floatrow}, but also
-improves the compatibility of packages \Package{babel} and \Package{floatrow}.
-
-% \iffalse
-\begin{Declaration}
- \KOption{floatrow}{switch}
-\end{Declaration}
-% \fi
-You may switch off the \Package{floatrow} hack loading package
-\Package{scrhack} with option \OptionValue{floatrow}{false}. You may also
-switch off the \Package{floatrow} hack using
-\Macro{KOMAoptions}\PParameter{floatrow=false} or
-\Macro{KOMAoption}\PParameter{floatrow}\PParameter{false} somewhere after
-loading package \Package{scrhack}, but before loading package
-\Package{floatrow}.
-
-\section{The \Package{hyperref} hack}
-\label{sec:scrhack.hyperref}
-
-Before version~6.79h package \Package{hyperref} does behave different at part,
-chapter, and section headings that get no number. If they get no number,
-because of to low counter \Counter{secnumdepth} \Package{hyperref} sets an
-anchor for links and bookmarks before the heading. Same would be, if the
-headings have a number. But if the headings get no number because of usage of
-the star version of the commands, e.g., \Macro{part*}, \Macro{chapter*} or
-\Macro{section*}, the anchor for links and bookmarks are set after the
-headings. The anchors for numbered headings are always set before the
-headings.
-
-Package \Package{scrhack} redefines some macros of some hyperref driver files,
-e.g., \File{hpdftex.def}, after loading the hyperref driver file. With this
-redefinitions the anchor of not numbered headings will be set always before
-the headings, too.
-
-% \iffalse
-\begin{Declaration}
- \KOption{hyperref}{switch}
-\end{Declaration}
-% \fi
-You may switch off the \Package{hyperref} hack loading package
-\Package{scrhack} with option \OptionValue{hyperref}{false}. You may also
-switch off the \Package{hyperref} hack using
-\Macro{KOMAoptions}\PParameter{hyperref=false} or
-\Macro{KOMAoption}\PParameter{hyperref}\PParameter{false} somewhere after
-loading package \Package{scrhack}, but before loading the hyperref driver
-package, that is by default after loading the package.
-
-\section{The \Package{listings} hack}
-\label{sec:scrhack.listings}
-
-Package \Package{listings} uses macros \Macro{float@listhead} to set the
-headings of a float listing, if defined, and \Macro{float@addtolists} to add
-informations to all float listings. These macros where proposed by the
-\KOMAScript{} author for some years. In theory those macros may be used by
-several class and package authors to deligate some parts of the creation of a
-float listing to the class. This would increase the compatiblity of packages
-and classes. But unfortunately some package authors, even the author of
-package \Package{float}, impemented the commands in such a way, that these
-packages may become incompatible to each other.
-
-Because of this \KOMAScript\ stopped support for \Macro{float@addtolists} and
-\Macro{float@listhead} with version 3. Instead of this \KOMAScript\ supports
-several improvements for package authors using \KOMAScript\ package
-\Package{tocbasic}.
-
-Package \Package{scrhack} redefines some macros of package \Package{listings} to
-not longer use \Macro{float@addtolists} and \Macro{float@listhead} but use the
-interface of package \Package{tocbasic}. This does not only improve the
-compatibility of \KOMAScript\ and package \Package{listings}, but also improves
-the compatibility of packages \Package{babel} and \Package{listings}.
-
-Note: A significant change with \Package{scrhack} is, that \KOMAScript{} options
-like \OptionValue{lists}{totoc} or \OptionValue{lists}{totocnumbered} does only
-change the behaviour of \Macro{listoflistings}, if they are set after loading
-package \Package{listings}.
-
-% \iffalse
-\begin{Declaration}
- \KOption{listings}{switch}
-\end{Declaration}
-% \fi
-You may switch off the \Package{listings} hack loading package
-\Package{scrhack} with option \OptionValue{listings}{false}. You may also
-switch off the \Package{listings} hack using
-\Macro{KOMAoptions}\PParameter{listings=false} or
-\Macro{KOMAoption}\PParameter{listings}\PParameter{false} somewhere after
-loading package \Package{scrhack}, but before loading package
-\Package{listings}.
-
-\section{The \Package{lscape} hack}
-\label{sec:scrhack.lscape}
-
-% \begingroup\let\Length\cs
-Package \Package{lscape} defines an environment \Environment{landscape} to set
-the page contents but not head and foot landscape. Inside this environment it
-changes \Length{textheight} to the value of \Length{textwidth}, but it does
-not change \Length{textwidth} to the former value of \Length{textheight}.
-This is inconsistent. As far a I know, \Length{textwidth} is unchanged because
-setting it to \Length{textheight} could blame other packages or user
-commands. But changing \Length{textheight} could also blame other packages or
-user commands and indeed it breaks, e.\,g., \Package{showframe} and
-\Package{scrlayer}. So best would be, not to change \Length{textheight},
-too. \Package{scrhack} uses package \Package{xpatch} to modify the
-environment start macro \Macro{landscape} appropriately.
-% \endgroup
-
-% \iffalse
-\begin{Declaration}
- \KOption{lscape}{switch}
-\end{Declaration}
-% \fi
-You can switch of the \Package{lscape} hack loading package \Package{scrhack}
-with option \OptionValue{lscape}{false}. You can also change option
-\Option{lscape} afterwards. If the option is \PValue{false} while loading
-\Package{lscape}, \Package{scrhack} will not patch \Macro{landscape} and later
-changes of the option have no effect. But if the option is \PValue{true} while
-loading \Package{lscape} or if \Package{scrhack} is loaded after
-\Package{lscape} without option \OptionValue{lscape}{false}, every later
-change of the option using \Macro{KOMAoption} or \Macro{KOMAoptions} will have
-the expected effect.
-
-\section{The \Package{nomencl} hack}
-\label{sec:scrhack.nomencl}
-
-Package \Package{nomencl} provides an option \Option{intoc} to add an
-nomenclature entry into the table of contents. This option uses
-\Macro{addcontentsline} to add the entry. Unfortunately this means that
-\KOMAScript{} option \OptionValue{toc}{indentunnumbered} would be
-ignored. A minimal solution would be to patch \Macro{thenomenclature} to use
-\Macro{addxcontentsline} instead of \Macro{addcontentsline}. With this the
-\Package{tocbasic} features for the entry will already be available.
-
-But if we already patch the package why not also register the extensions and
-add running heads and make other \Package{tocbasic} features available.
-
-% \iffalse
-\begin{Declaration}
- \KOption{nomencl}{switch}
-\end{Declaration}
-% \fi
-You may switch off the \Package{nomencl} hack loading package
-\Package{scrhack} with option \OptionValue{nomencl}{false}. You may also
-switch off the \Package{nomencl} hack using
-\Macro{KOMAoptions}\PParameter{nomencl=false} or
-\Macro{KOMAoption}\PParameter{nomenc}\PParameter{false} somewhere after loading
-package \Package{scrhack}, but before loading package \Package{listings}.
-
-
-\section{The \Package{setspace} hack}
-\label{sec:scrhack.setspace}
-
-Package \Package{setspace} defines macros \Macro{onehalfspacing} and
-\Macro{doublespacing} using \Macro{@ptsize} as an argument of
-\Macro{ifcase}. But if \Macro{@ptsize} is not an integer but a real number,
-this failes, because the digits from the decimal points are interpreted as
-text of that case. Several solutions for this are thinkable. I've decides to
-redefine \Macro{onehalfspacing} and \Macro{doublespacing}. The new definition
-is more general and somehow more exact.
-
-% \iffalse
-\begin{Declaration}
- \KOption{setspace}{switch}
-\end{Declaration}
-% \fi
-You can switch of the \Package{setspace} hack loading package
-\Package{scrhack} with option \OptionValue{setspace}{false}. You may also
-switch of the \Package{setspace} hack using
-\Macro{KOMAoptions}\PParameter{setspace=false} or
-\Macro{KOMAoption}\PParameter{setspace}\PParameter{false} somewhere after
-loading package \Package{scrhack}, but before loading package
-\Package{setspace}.
-
-Note: If you want to use \Package{setspace} with package option
-\Option{onehalfspacing} or \Option{doublespacing} you have to load
-\Package{scrhack} before \Package{setspace}.
-
-% \iffalse
-%</manual|dtx>
-% \fi
%
% \selectlanguage{ngerman}
% \StopEventually{\PrintIndex\PrintChanges}