Skip to content

Commit

Permalink
feat: add command to avoid a page break after a space
Browse files Browse the repository at this point in the history
As example if in a description environment the nested one is on the next page

Signed-off-by: Martin Dünkelmann <nc-duenkekl3@netcologne.de>
  • Loading branch information
MartinX3 committed Jun 13, 2024
1 parent 7636901 commit 20919d1
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
7 changes: 7 additions & 0 deletions abschnitte/Stand_Forschung.tex
Original file line number Diff line number Diff line change
@@ -1 +1,8 @@
\chapter{Stand der Forschung}\label{ch:stand-der-forschung}

\begin{description}
\item[Materialanalyse]~\avoidpagebreak{}
\begin{description}
\item[Forschungslücken] Hoch
\end{description}
\end{description}
5 changes: 5 additions & 0 deletions aussehen/hbrs-inf.sty
Original file line number Diff line number Diff line change
Expand Up @@ -118,3 +118,8 @@

% Behebt Warnungen durch die verbesserte Zusammenarbeit diverser Pakete mit den KOMA-Scripten via Macros
\RequirePackage{scrhack}

% Verhindert, dass die nächste Zeile auf einer neuen Seite landet. Z.B. ein Titel am Ende einer Seite und dessen Inhalt auf der nächsten.
\makeatletter
\newcommand{\avoidpagebreak}{\par\nobreak\@afterheading}
\makeatother

0 comments on commit 20919d1

Please sign in to comment.