9

I want to make all section headings in LaTeX document bigger by a given scale. For example, I want all of them have 150% of size that they have now.

Can I do that somehow? (Ideally using sectsty)

doncherry
  • 54,637

2 Answers2

8

The solution with sectsty should be

\documentclass{article}
\usepackage{relsize}
\usepackage{sectsty}

\allsectionsfont{\larger[2]} 

\begin{document}
\section{Section title}
\subsection{Subsection title}
\end{document}

I wouldn't recommend it. The size of section titles in the standard classes is already quite large.

egreg
  • 1,121,712
  • OK, the error was my mistake. It seems like it worked, thanks! – Karel Bílek Aug 15 '12 at 21:47
  • Even though I've posted my own solution, this one is obviously better. – yo' Aug 15 '12 at 21:50
  • @tohecz: I actually have some more changes to the font, using \sectsty, which is making it appear too small, that's why I asked for \sectsty specifically. Thanks for your answer though – Karel Bílek Aug 15 '12 at 22:05
6

I don't know the package sectsty, but the following dirty trick using titlesec should work. Just add these lines into your preamble (and do not use sectsty at the same time...):

\usepackage{titlesec}
\usepackage{relsize}
\titlelabel{\larger\larger\thetitle\quad\aftergroup\larger\aftergroup\larger}

The trick is that \larger multiplies the current font size by 1.2 (in most cases). Applied twice it makes 1.44, which is very close to 1.5. The command \titlelabel change the way how the section numbers are printed. The sequence \aftergroup\larger makes sure that the magnification is applied to the section title as well.

yo'
  • 51,322