Re: Name of table of contents in headers
On Wednesday 07 March 2012 15:55:44 Richard Heck wrote: > What document class is this? What page style are you using? Do you want > to change how this looks only in the TOC, or in the rest of the document > as well? Sorry for the confusion about this but the solution was posted out of thread; here it is again: {\pagestyle{plain} \fancyhead[LE,RO]{\thepage} \fancyhead[LO,RE]{Contents} \renewcommand{\contentsname}{Contents}\tableofcontents{} \cleardoublepage} best, Bill -- William Seager University of Toronto Scarborough www.utsc.utoronto.ca/~seager
Re: Name of table of contents in headers
On 03/04/2012 12:22 AM, William Seager wrote: Hi all. This is more a latex problem than a lyx problem, but since I'm using lyx I thought I'd ask here. I have a complex document in which the table of contents spans several pages. My problem is that in the header the name of the table of contents, (which is "Contents") appears capitalized and emphasized (italics). What document class is this? What page style are you using? Do you want to change how this looks only in the TOC, or in the rest of the document as well? In book.cls, this would be controlled by two things: the definition of the page style, and this: \newcommand\tableofcontents{% \if@twocolumn \@restonecoltrue\onecolumn \else \@restonecolfalse \fi \chapter*{\contentsname \@mkboth{% \MakeUppercase\contentsname}{\MakeUppercase\contentsname}}% \@starttoc{toc}% \if@restonecol\twocolumn\fi } As you see, the \@mkboth command is what's giving you the uppercase. But the italics are probably coming from the page style. Richard
Re: Name of table of contents in headers
On 03/04/2012 12:01 PM, William Seager wrote: Sorry to spam the group and reply to my own message. The solution is very simple: {\pagestyle{plain} \fancyhead[LE,RO]{\thepage} \fancyhead[LO,RE]{Contents} \renewcommand{\contentsname}{Contents}\tableofcontents{} \cleardoublepage} (If a moderator sees this, this and my previous message can be deleted.) There's no moderator, but someone else might actually find this useful. Richard
Name of table of contents in headers
Sorry to spam the group and reply to my own message. The solution is very simple: {\pagestyle{plain} \fancyhead[LE,RO]{\thepage} \fancyhead[LO,RE]{Contents} \renewcommand{\contentsname}{Contents}\tableofcontents{} \cleardoublepage} (If a moderator sees this, this and my previous message can be deleted.) -- William Seager University of Toronto Scarborough www.utsc.utoronto.ca/~seager
Name of table of contents in headers
Hi all. This is more a latex problem than a lyx problem, but since I'm using lyx I thought I'd ask here. I have a complex document in which the table of contents spans several pages. My problem is that in the header the name of the table of contents, (which is "Contents") appears capitalized and emphasized (italics). I found a bizarre way to turn off the capitalization in the header by adding: \let\stdtoc\tableofcontents \renewcommand*\tableofcontents{{% \renewcommand*\MakeUppercase[1]{##1}\stdtoc}} to the preamble. But the header remains emphasized. I *can* turn off the emphasis by using this command: \renewcommand{\contentsname}{\em Contents} but then, of course, "Contents" appears emphasized in the main body of the text. Or, if I add the table of contents with this: \renewcommand{\contentsname}{\textnormal {Contents}}\tableofcontents{} then the header is perfect, but I lose the bold face I want "Contents" to be in in the body of the text. The headers throughout the rest of the document are perfect and I don't want to mess with them. It's a minor problem but it is bothering me. TIA, -- William Seager University of Toronto Scarborough www.utsc.utoronto.ca/~seager