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.

I'm writing a constitution-type document for a sports competition. I want each chapter heading to be preceded by the word "Article", viz: "Article 1 Rules of the competition", "Article 2 blah blah blah". So I added the following at the start of the document:

\renewcommand{\chapter}{\@startsection{chapter}{1}{0mm}{\baselineskip}{0.5\baselineskip}{\textsc{Article} \centering\sc\large}}

Unfortunately, this has also added the word "Article" to the title of the table of contents itself , so that it is now titled "Article Contents" instead of just "Contents".

How can I stop the word Article appearing in the title of the ToC? Or, is there a better way for me to add the word "article" to the header title for each chapter, but not the title of the ToC?

share|improve this question
    
Maybe this one could give some hint to solve your question. –  Benedikt Bauer Oct 8 '12 at 12:08

1 Answer 1

up vote 10 down vote accepted

One way is to get \tableofcontents to add the word for you after it has used the original definition

\makeatletter
\let\oldtableofcontents\tableofcontents
\def\tableofcontents{\oldtableofcontents\gdef\addarticle{\textsc{Article} }}
\gdef\addarticle{}

\renewcommand{\chapter}{\@startsection{chapter}{1}{0mm}{\baselineskip}{0.5\baselineskip}{\addarticle\centering\sc\large}}

\makeatother
share|improve this answer
    
which works in the usual case when ToC is at the beginning ;) –  tohecz Oct 8 '12 at 12:16
    
@tohecz well yes, otherwise you just need to move the \gdef\addarticle{} into the start of the \tableofcontents definition so that it resets it and then sets it back, and initialise it to say Article rather than nothing. –  David Carlisle Oct 8 '12 at 12:22

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.