1

My question is related to this one.

I want to produce a header like this (for unnumbered and numbered chapters):

enter image description here

enter image description here

The code I already have produces this:

enter image description here

enter image description here

That is, the vertical line is missing and the style is different. Most importantly, we want the numbers to appear bigger, but changing the font size and tuning the other parameters does not help so far. Here is the MWE:

\documentclass[
ngerman,
a4paper,     
12pt,       
openright, titlepage=firstiscover 
]{scrbook}

\usepackage{blindtext}

% Space from top
\renewcommand*\chapterheadstartvskip{\vspace*{-4.1cm}}
\renewcommand*\chapterheadendvskip{\vspace*{2.5\baselineskip}}

\renewcommand*{\chapterformat}{\chapternumber{\thechapter}}
\renewcommand{\chapterlinesformat}[3]{\chaptertitle{#3}#2}

% Chapter rule and number

\newcommand{\chapternumber}[1]{%
    \usekomafont{chapter}%
    \begin{minipage}[b]{0.1\paperwidth}%
        \vspace*{-5.39cm}%
        \raggedleft{%
            {\color{black}\rule[-15pt]{0.5pt}{7cm}}%
            \hspace{10mm}%
            {\fontsize{60cm}{80cm}\selectfont #1}%
        }%
    \end{minipage}%
}

% Chapter title
\newcommand{\chaptertitle}[1]{%
    \usekomafont{chapter}\normalfont\Huge %
    \vspace*{5.39cm}%
    \leavevmode\smash{\begin{minipage}[b]{0.72\paperwidth}%
            \begin{flushright}
                #1
            \end{flushright}
    \end{minipage}}%
}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\usepackage{pdfpages}


\usepackage[headsepline]{scrlayer-scrpage}


% Dokumentenanfang
\begin{document}



\begin{titlepage}
    \Huge My fancy title
\end{titlepage}


\chapter*{Unnumbered chapter}

\blindtext

\chapter{This is an awesome chapter}

\blindtext

\section{Some section}

\blindtext

\section{Some section}

\blindtext
\section{Some section}

\blindtext


\end{document}

Does anyone have a clue about this? Many thanks in advance.

P.S.: This code also did not help.

esdd
  • 85,675

1 Answers1

1

You have to use a scalable font, eg. lmodern.

The following suggestion bases on your second link:

\documentclass[12pt,openright,titlepage=firstiscover]{scrbook}
\usepackage{blindtext}
\usepackage{lmodern}% use a scalable font

\RedeclareSectionCommand[
  beforeskip=0pt,
  afterindent=false,
  afterskip=2.5\baselineskip,
  font=\normalfont\Huge
]{chapter}

\renewcommand*\chapterformat{%
  \fontsize{60pt}{60pt}\selectfont\thechapter%
}%

\renewcommand*\chapterlinesformat[3]{%
    \parbox[b]{\textwidth}{\raggedchapter #3}%
    \makebox[0pt][l]{%
      \hspace{1ex}%
      \smash{\rule[-15pt]{1pt}{10cm}}%
      \hspace{1ex}
      #2
    }%
}

\renewcommand*\raggedchapter{\raggedleft}

\begin{document}
\begin{titlepage}
  \Huge My fancy title
\end{titlepage}
\tableofcontents
\addchap*{Unnumbered chapter}
\blindtext
\chapter{This is an awesome chapter}
\blindtext
\section{Some section}
\blindtext
\section{Some section}
\blindtext
\section{Some section}
\blindtext
\end{document}

enter image description here

esdd
  • 85,675