Skip to content
Snippets Groups Projects
Commit a1af51a0 authored by Jan Wille's avatar Jan Wille
Browse files

patch abstract enviroment to not produce double clearpages

this happend when using `\include` (which produces the first clearpage)  for the abstract (which clears the page when entering the env)
as the chapter started inside the `\quotation`, both pageclears executed fully and an empty page was shipped to the pdf.
parent da011f1b
Branches development
No related tags found
No related merge requests found
......@@ -298,8 +298,8 @@
}{}
}
\RequirePackage{scrhack}
\AddToHook{package/siunitx/before}{\RequirePackage{xcolor}}
\AddToHook{package/siunitx/after}{
\AddToHook{package/listings/before}{\RequirePackage{xcolor}}
\AddToHook{package/listings/after}{
\lstset{
commentstyle=\color{gray},
keywordstyle=\color{FireBrick}\bfseries,
......@@ -479,9 +479,13 @@
\renewcommand{\labelitemiii}{\raisebox{-.1ex}{\scalebox{1.3}{$\cdot$}}}
\renewcommand{\labelitemiv}{\raisebox{.1ex}{-}}
\renewenvironment{abstract}{
\begingroup
\edef\raggedsection{\raggedsection%
\hskip\leftmargini}
\HsH@abstract@heading{\abstractname}
\endgroup
\quotation
\setparsizes{\z@}{\z@}{.25\linewidth \@plus 1fil}\selectfont
\HsH@abstract@heading{\abstractname}
}{%
\ifx\@keywords\@empty\else\if@HsH@option@abstract@show@keywords
\par\bigskip
......
......@@ -1582,13 +1582,20 @@ http://www.latex-project.org/lppl.txt
% \end{macrocode}
%
% \paragraph{Abstract}
% We define some custom behavior for the abstract.
% We define some custom behavior for the abstract. Its typeset as a quote, so
% its a little smaller than the rest of the text. We also indent the heading to
% match that.
% \begin{macrocode}
%<*!standalone>
\renewenvironment{abstract}{
\begingroup
%<article> \edef\raggedsection{\raggedsection%
%<report> \edef\raggedchapter{\raggedchapter%
\hskip\leftmargini}
\HsH@abstract@heading{\abstractname}
\endgroup
\quotation
\setparsizes{\z@}{\z@}{.25\linewidth \@plus 1fil}\selectfont
\HsH@abstract@heading{\abstractname}
}{%
\ifx\@keywords\@empty\else\if@HsH@option@abstract@show@keywords
\par\bigskip
......
No preview for this file type
......@@ -298,8 +298,8 @@
}{}
}
\RequirePackage{scrhack}
\AddToHook{package/siunitx/before}{\RequirePackage{xcolor}}
\AddToHook{package/siunitx/after}{
\AddToHook{package/listings/before}{\RequirePackage{xcolor}}
\AddToHook{package/listings/after}{
\lstset{
commentstyle=\color{gray},
keywordstyle=\color{FireBrick}\bfseries,
......@@ -492,9 +492,13 @@
\renewcommand{\labelitemiii}{\raisebox{-.1ex}{\scalebox{1.3}{$\cdot$}}}
\renewcommand{\labelitemiv}{\raisebox{.1ex}{-}}
\renewenvironment{abstract}{
\begingroup
\edef\raggedchapter{\raggedchapter%
\hskip\leftmargini}
\HsH@abstract@heading{\abstractname}
\endgroup
\quotation
\setparsizes{\z@}{\z@}{.25\linewidth \@plus 1fil}\selectfont
\HsH@abstract@heading{\abstractname}
}{%
\ifx\@keywords\@empty\else\if@HsH@option@abstract@show@keywords
\par\bigskip
......
......@@ -141,8 +141,8 @@
}{}
}
\RequirePackage{scrhack}
\AddToHook{package/siunitx/before}{\RequirePackage{xcolor}}
\AddToHook{package/siunitx/after}{
\AddToHook{package/listings/before}{\RequirePackage{xcolor}}
\AddToHook{package/listings/after}{
\lstset{
commentstyle=\color{gray},
keywordstyle=\color{FireBrick}\bfseries,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment