4

I'm using the minted package, which uses the float package. When I add the 'List of Listings' in my thesis, the \listoflistings command calls the \listofcommand from the float package.

My problem is that this command modifies the headings of subsequent pages, and shows 'LIST OF LISTINGS' in the header of the following pages, up to my second chapter. How can I prevent it from redefining the headers defined in my .cls file?

Savara
  • 244
  • 2
  • 10

1 Answers1

2

Ok, I figured out:

\makeatletter
\renewcommand*{\float@listhead}[1]{%
  \@ifundefined{chapter}{\def\@tempa{\section*}}%
    {\def\@tempa{\chapter*}}\@tempa{#1}}
\makeatother

And in bonus, I learned a little bit more about LaTeX internals.

  • Your solution worked like a charm for me, my issue was with list of frames. Only difference is that I replaced the #1 with \centering\bfseries\MakeTextUppercase{#1} t suit my needs. Thanks. – G. Bay Oct 29 '15 at 20:23