Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

How can I have a chapter title page like the following?

Note that, I'm using book document class

enter image description here

share|improve this question
    
It would be great if you could show what you have tried so far, and then let us know which particular part is causing you problems :) Have a look at How to get a colored box as the header? for a possible starting point... –  cmhughes Jan 4 '13 at 0:36
    
I exactly want the above figure, except table of contents part –  smh Jan 4 '13 at 0:39
4  
Please provide and minimal working example (MWE). It will be fun and challenging at the same time for many solvers here to answer your question but you can help them get started by providing a MWE. Providing one also shows that you are willing to contribute more to the learning effort here in the TeX-Sx community. :) –  hpesoj626 Jan 4 '13 at 0:40
    
In addition to the link suggested by @cmhughes, check out [tex.stackexchange.com/a/78848/22413]. Doesn't do quite what you want, but it's close. –  A.Ellett Jan 4 '13 at 0:50
3  
Just do it for me... –  Werner Jan 4 '13 at 3:09

1 Answer 1

up vote 16 down vote accepted

It is a good practice to show that you have done your own part to solve your problem before trying to ask. That way, you will appreciate more what is happening in the solution that you are provided.

I would have to admit thought that this figure requires a lot if you are just beginning in LaTeX. The usual book class would have sufficed for many beginners like me.

I hope this answer will help you put up your own MWE. Then we will see from there. Be patient since what you are asking for is not trivial. There are some considerations here.

If memoir is an option, then I advise you to read: Mini table of contents inside TikZ node on chapter start page

If you are using others (may not work for all, I haven't tried), then you have to use some titlesec magic.

You can combine use titlesec and use the tikz technique used in How to get a colored box as the header? and perhaps some textpos solution.

I have taken the following tikz code from 1.

\begin{tikzpicture}[overlay, remember picture]
    \draw let \p1 = (current page.west), \p2 = (current page.east) in
      node[minimum width=\x2-\x1, minimum height=2cm, draw, rectangle, fill=blue!20, anchor=north west, align=left, text width=\x2-\x1] at ($(current page.north west)$) {\Large\bfseries \quad #1};
  \end{tikzpicture}

But I would trim it down to something that you will need for your background like so:

\begin{tikzpicture}[overlay, remember picture]
    \path let \p1 = (current page.west), \p2 = (current page.east) in
      node[minimum width=\x2-\x1, minimum height=2cm, rectangle, fill=cyan, anchor=north west, align=left, text width=\x2-\x1] at ($(current page.north west)$) {};
  \end{tikzpicture}

You will need the cyan-like color at the bottom of the page so we will further modify it like this:

\begin{tikzpicture}[overlay, remember picture]
    \path let \p1 = (current page.west), \p2 = (current page.east) in
      node[minimum width=\x2-\x1, minimum height=2.5in, rectangle, fill=cyan, anchor=north west, align=left, text width=\x2-\x1] at ($(current page.north west)$) {};
    \path let \p1 = (current page.west), \p2 = (current page.east) in
      node[minimum width=\x2-\x1, minimum height=1in, rectangle, fill=cyan!50, anchor=north west, align=left, text width=\x2-\x1] at ($(current page.south west)$) {};
  \end{tikzpicture}

Then you could use this in combination with titlesec to have something in my preamble like

\documentclass[10pt]{book}
\usepackage{titlesec}
\usepackage{tikz}
\usetikzlibrary{calc}
\titleformat{\chapter}[display]{\normalsize}{
\begin{tikzpicture}[overlay, remember picture]
    \path let \p1 = (current page.west), \p2 = (current page.east) in
          node[minimum width=\x2-\x1, minimum height=5cm, rectangle, fill=cyan, anchor=north west, align=left, text width=\x2-\x1] at ($(current page.north west)$) {};
    \path let \p1 = (current page.west), \p2 = (current page.east) in
          node[minimum width=\x2-\x1, minimum height=0.8in, rectangle, fill=cyan!50, anchor=south west, align=left, text width=\x2-\x1] at ($(current page.south west)$) {};
\end{tikzpicture}
}{-1.75in}{}[\vspace*{1in}]

\begin{document}
\chapter{Background}
\end{document}

You can see the specifications for the \titleformat{<>}[<>]{<>}{<>}{<>}{<>}[<>] starting from page 3 of the titlesec manual.

The Chapter title looks small

And we want to remove the page number at the bottom in the chapter page. So we can also put \pagestyle{empty} somewhere. We can change the format as follows:

\titleformat{\chapter}[display]{\Huge\bfseries\sffamily\color{white}}{% Changed \normalfont
\thispagestyle{empty}
\begin{tikzpicture}[overlay, remember picture]
     \path let \p1 = (current page.west), \p2 = (current page.east) in
           node[minimum width=\x2-\x1, minimum height=5cm, rectangle, fill=cyan, anchor=north west, align=left, text width=\x2-\x1] at ($(current page.north west)$) {};
     \path let \p1 = (current page.west), \p2 = (current page.east) in
           node[minimum width=\x2-\x1, minimum height=0.8in, rectangle, fill=cyan!50, anchor=south west, align=left, text width=\x2-\x1] at ($(current page.south west)$) {};
\end{tikzpicture}
}{-1.5in}{}[\vspace*{1in}]

Some Final Touches

And we then finally added \chaptername and the \thechapter so that the chapter and the chapter number will appear. You can use textpos so that you can manually position them.

Finally, an MWE that you can work on

It is a terrible hack, but it works for me in many instances. Here is the code:

\documentclass[10pt]{book}
\usepackage{titlesec}
\usepackage{tikz}
\usetikzlibrary{calc}
\usepackage{textpos}
\usepackage{calc}

\DeclareFixedFont{\chapternumberfont}{T1}{ppl}{}{}{1.5in}
\titleformat{\chapter}[display]{\Huge\bfseries\sffamily\color{white}}{
\thispagestyle{empty}
\begin{tikzpicture}[overlay, remember picture]
        \path let \p1 = (current page.west), \p2 = (current page.east) in
              node[minimum width=\x2-\x1, minimum height=5cm, rectangle, fill=cyan, anchor=north west, align=left, text width=\x2-\x1] at ($(current page.north west)$) {
                \begin{textblock*}{5in}(\dimexpr\x2-4.5in,\dimexpr0.25\headheight-1in)
                    \tikz \node [white,text width=2in, align=right, font=\sffamily] {{\normalsize DIGITAL MEDIA PRIMER}\\[12pt] \raisebox{50pt}{{\large \chaptertitlename}} \raisebox{-12pt}{\chapternumberfont \thechapter}};
                \end{textblock*}
              };
        \path let \p1 = (current page.west), \p2 = (current page.east) in
              node[minimum width=\x2-\x1, minimum height=0.8in, rectangle, fill=cyan!50, anchor=south west, align=left, text width=\x2-\x1] at ($(current page.south west)$) {};
\end{tikzpicture}
}{-1.75in}{}[\vspace*{1in}]

\begin{document}
\chapter{Background}
\end{document}

Output

enter image description here


If you have some more time, you can combine the procedure I have outline here with the answer of Peter Grill in Using fancyhdr to create an image based header and footer

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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