0

I have a long document (thesis) and I would like to use two different fonts. For the first part, containing the front page and table of contents, I would like to use mathpazo. After that, I would like to switch to the default font of TeX. Here is a MWE showing the structure and where I want to switch:

\documentclass{memoir}
\usepackage[sc]{mathpazo}

\begin{document}  
    Front page

  \clearpage
  \tableofcontents
  \clearpage

    %%
    %The default font of LaTeX should be used from here and onwards
    %%

    \section{Main section 1}
    Text ....
    \section{Main section 2}
    Text ....
    \section{Main section 3}
    Text ....1

\end{document}

What is the best way to do this? And how do I switch to the normal font after the ToC?

2
  • 1
    Mixing two serif fonts so different from each other is really a very dubious thing to do. Note the understatement. :-;
    – egreg
    Oct 22, 2016 at 7:50
  • @egreg What do you mean? Is it considered bad practice? Cosmetically, I think it looks nice to have this font on the front page, but maybe there is something else I am not taking into account?
    – BillyJean
    Oct 22, 2016 at 12:47

1 Answer 1

2

One way can be not to touch the global font commands by loading mathpazo in your preamble. You can switch the font locally inside a group:

\documentclass{memoir}

\begin{document}  

\begingroup
  \renewcommand{\rmdefault}{pplx}
  \normalfont
  Front page

  \clearpage
  \tableofcontents
  \clearpage
\endgroup

\section{Main section 1}
Text ....
\section{Main section 2}
Text ....
\section{Main section 3}
Text ....1

\end{document}
4
  • That is a very elegant solution. Is pplx an alias for mathpazo?
    – BillyJean
    Oct 21, 2016 at 8:10
  • 1
    @BillyJean - mathpazo is the name of the package you load via \usepackage, i.e. the file mathpazo.sty on your HD. pplx is the name of the font family mathpazo loads when the option sc is issued. Oct 21, 2016 at 8:22
  • Just \fontfamily{pplx}\selectfont suffices.
    – egreg
    Oct 22, 2016 at 7:52
  • @egreg - Yes, you're right. Thanks for the reminder. Oct 23, 2016 at 19:40

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.