0

I'm trying to get this chapter format. enter image description here Unsuccessfully.

I'm using koma-sciript class. Based on How to place the chapter number behind the chapter title in KOMA script

I've created:

    \makeatletter
\renewcommand\chapterlinesformat[3]{%
  \ifstr{#1}{chapter}
    {\hfill\makebox[0pt][r]{#2}\makebox[0.5\textwidth][l]{\parbox[b]{0.5\textwidth}{#3}}}%
    {\@hangfrom{#3}{#2}}% original definition for other commands with style=chapter
}
\makeatother

Should I put the chapter number and chapter title in separate minipages? If so, in what way?

1 Answer 1

2

You could use

\documentclass{scrbook}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\renewcommand*\familydefault{\sfdefault}

\makeatletter
\renewcommand\chapterlinesformat[3]{%
  \ifstr{#1}{chapter}
    {\hfill{\upshape#2}\parbox[b]{0.5\textwidth}{\raggedchapter #3}}%
    {\@hangfrom{#2}{#3}}% original definition for other commands with style=chapter
}
\makeatother
\addtokomafont{chapter}{\slshape}

\usepackage{lipsum}
\begin{document}
\chapter{Short title}
\lipsum[1-2]
\chapter{Long, long, long chapter title}
\lipsum[1-2]
\end{document}

Result:

enter image description here

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .