I am trying to edit my page titles with fancyhdr package. I want the top left of the page to present [section number]. [section name] in boldface and small caps. for example:

3.2. PYTHAGORAS THEOREM

I noticed that \leftmark puts the small-caps letter in a nice way (with proper space between them, and also straight, which doesn't happen with some other methods) but if I try to edit it

\renewcommand{\leftmark}{...}


I lose the small caps. What is the best way to achieve what I want?

An example code to build on:

\documentclass[a4paper,11pt,english]{book}
\usepackage{fancyhdr}
\usepackage[english]{babel}
\pagestyle{fancy}

\usepackage{blindtext}
\begin{document}
\chapter{My first chapter}
\blindtext
\section{My first section}
\blindtext[10]
\end{document}

-

I recommend using formatting commands within fancyhdr commands, such as in \fancyhead, instead of redefining \leftmark. More important, you need to use a font with bold small caps. The default font doesn't have small caps. This could be the reason why you notice you loose small caps when switching to bold.

In your example, with kpfonts, you would get bold small caps text in the header:

\usepackage{kpfonts}

@Andro The section name is usually in \rightmark. Try: \fancyhead[LE,LO]{\textsc{\textbf{\nouppercase{\rightmark}}}}. Regarding bold small caps in CM try: \usepackage{bold-extra} however I doubt it looks great - but see for yourself. – Stefan Kottwitz Oct 4 '11 at 19:04
The fonts in the link you provide sure look like CM. However, the text in the header line is "ordinary" bold, not small-caps bold. Some font families that feature small caps & bold glyphs are mathptmx and txfonts (Times New Roman-like fonts) and mathpazo and pxfonts (Palatino-like fonts). – Mico Oct 4 '11 at 19:23