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.

So I downloaded a nice looking article template which has a custom look for section titles. But now the number next to the References header is the same as that of the last section.

How do I fix this? Showing no number at all has my preference, but showing the correct section number is fine too.

\documentclass[twoside]{article}
\usepackage{titlesec}% Allows customization of titles
\titleformat{\section}[block]{\large\scshape\centering{\Roman{section}.}}{}{1em}{} % Change the look of the section titles 

\begin{document}

\section{Introduction}
\subsection{Problem description}

Blah blah blah.
\subsection{Another section}

Another section.
\begin{thebibliography}{9}

\bibitem{ref}
  some reference.
\end{thebibliography}

\end{document}
share|improve this question
add comment

1 Answer

up vote 4 down vote accepted

Use \titleformat{name=\section,numberless} to change the format of unnumbered sections (here: the bibliography).

\documentclass[twoside]{article}
\usepackage{titlesec}
\titleformat{\section}[block]{\large\scshape\centering{\Roman{section}.}}{}{1em}{}
\titleformat{name=\section,numberless}[block]{\large\scshape\centering}{}{0pt}{}

\begin{document}

\section{Introduction}
\subsection{Problem description}

Blah blah blah.
\subsection{Another section}

Another section.
\begin{thebibliography}{9}

\bibitem{ref}
  some reference.
\end{thebibliography}

\end{document}

enter image description here

share|improve this answer
    
Hey, cool output image. How did you do that, just a screenshot or can StackExchange interpret LaTeX? –  Maarten Dec 6 '12 at 12:36
    
@Maarten Just a cropped screenshot. –  lockstep Dec 6 '12 at 12:37
add comment

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.