I would like to have a chapter design like

enter image description here

So in the Box of the title, should be an image in the background and above the number of the chapter.

The packages I'm using so far, are:

\documentclass[a4paper,11pt,twoside]{scrbook} %{book}

Update: by substituting the ducks through:


I get an division by 0 error ... why? and how can I fix it?


You can do a lot of things with KOMA-Script's chapter headings, if you redefine \chapterformat and \chapterlinesformat or \chapterlineswithprefixformat. If I interpret your question as

How to use ducks in chapter headings of KOMA-Script?

I could, e.g, do:

\usepackage{lmodern}% need scalable font
\usepackage{tikzducks}% essential to use ducks



    \rule{.333\linewidth}{1pt} #2%
    \parbox[b][\dimexpr .2\linewidth-\dp\strutbox-\baselineskip]{.78\linewidth}{%
      \raggedchapter\strut\ignorespaces #3%
    \raisebox{\dimexpr -.2\linewidth+\baselineskip}[0pt][0pt]{%
%      \frame{%
%      }%

\chapter{Chapter Name}

\chapter{Another Chapter Name}

\chapter{Once more a Longer Chapter Name}


First chapter

Second chapter

Third chapter

For more information about \RedeclareSectionCommand, \chapterformat and \chapterlineswithprefixformat see the KOMA-Script manual also available in German. And don't forget the famous information about using ducks in TikZ.

And yes, instead of the tikzpicture with the \duck commands, you can use a \includegraphics command like:

\chapternumberbackground{\includegraphics[page=54,trim=30 0 30 0,clip]{example-image-duck}}

Note, the \resizebox in the code of the full example would resize such an external image too. So if you want images in another size, you have to change or remove the \resizebox.

  • 1
    tikzducks is not for demo only :) – Skillmon Sep 2 '17 at 11:13
  • 1
    @Skillmon Your absolutely right. Fixed. ;-) – Schweinebacke Sep 2 '17 at 11:24
  • 3
    I WILL USE THIS FOR MY THESIS – Paulo Cereda Sep 2 '17 at 11:45
  • 1
    +1 for the ducks! In the new package version, there will be a graduate duck -> perfect for a phd thesis! i.stack.imgur.com/x0ogv.png (and the bounding box size will also be fixed so the ducks don't get distorted) – user36296 Sep 2 '17 at 13:50
  • 2
    Another one has joined the Duck Side of the Force! <3 <3 <3 – CarLaTeX Sep 2 '17 at 14:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.