2

I bought a recent math book, and it was clearly made using TeX. Here's an example from the chapter page:

Chapter Page

I wanted to reproduce this chapter style for other texts I'm working on (same fonts, sizes, lines, spacing). So, could you help me with that? I'm terrible when it comes to re-defining chapters, sections... (oh, and I hope the text being in Portuguese is not a problem)

  • 2
    Hmmm, the style of the chapter header suggests the document was created using the memoir document class and a somewhat customized form of either the bianchi or the demo2 chapter style. For more information about designing chapter headers using the memoir document class, do have a good look at Appendix B of the memman user guide. – Mico Mar 6 '16 at 2:01
  • Hmmm I'll sure take a look at that. I'm currently using "book" as class. Is there a way to change the chapter style within that class? And @Mico thanks already for giving me that hint. – Italo Marinho Mar 6 '16 at 2:21
3

With the book class, you can use this as a starting point:

\documentclass{book}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[portuges]{babel}

\makeatletter
\def\@makechapterhead#1{%
  \vspace*{50\p@}%
  {\parindent \z@ \raggedright \normalfont
    \ifnum \c@secnumdepth >\m@ne
      \if@mainmatter
      \par\centering % <-- added
        \sffamily\huge \MakeUppercase{\@chapapp}\space \thechapter % <-- changed
        \par\nobreak
        \vskip 60\p@ % <-- changed
      \fi
    \fi
    \interlinepenalty\@M
    \hrule\bigskip % <-- added
    \huge #1\par\nobreak
    \bigskip %       <-- added 
    \hrule\par\nobreak % <-- added
    \vskip 40\p@
  }}
\makeatother

\begin{document}

\chapter{Progressões Artiméticas}

São comuns, na vida real, grandezas que sofrem aumentos iguais em
intervalos de tempos iguais. Por exemplo, \ldots

\end{document}
|improve this answer|||||
  • I wasn't understanding what these macro codes meant, now with this starting point I finally did. Did some rules of three here, and then got the final values. – Italo Marinho Mar 6 '16 at 5:28
  • 1
    @ItaloMarinho -- The underlying code for chapter and section divisions is not always easy to understand, but it does become more comprehensible with time. – jon Mar 6 '16 at 5:54

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.