Hi everyone and thank you for reading me,

I am playing around with a phd thesis latex template and I am trying to set the Glenn chapter style from the fncychap package. The problem is that when I try to compile with it the following error comes up:

 ERROR: Undefined control sequence.

--- TeX said ---
\@mkboth ...nguage {\languagename }}\def \bbl@arg 
                                                  {#1}\ifx \bbl@arg \@empty ...l.199 \tableofcontents

                   % Prints the main table of contents

Nonetheless, I should note that this only happens when using the Glenn style, as any other does not produce the error.

A working example may be found in overleaf as this is part of a somehow complicated phd theses template: https://www.overleaf.com/latex/templates/template-for-a-masters-slash-doctoral-thesis/mkzrzktcbzfl#.Wu7w3y-mN26

Just add \usepackage[Glenn]{fncychap} to that template and you get the error.

Any one's got a clue on this one?

  • 1
    Welcome to TeX.SX! – Bobyandbob May 6 '18 at 12:48
  • 1
    Can you make a minimal working example (MWE)? – samcarter_is_at_topanswers.xyz May 6 '18 at 13:22
  • This looks like it could be an outdated babel version, so you could check for updates. But it is really hard to tell without a minimal document that reproduces the error (an MWE, see samcarter's link above). – moewe May 6 '18 at 16:12
  • I've edited the original question, thank you for your suggestions! – Alejandro Catalina May 6 '18 at 16:55
  • Class and package are not compatible. – Johannes_B Jun 12 '18 at 4:01

I had the same issue as you.

A solution working was to redefined "\tableofcontents" as :

  \null\hfill\textbf{\Large\contentsname}\hfill\null\par % line to comment if Glenn style also wanted here

By default, the title "Contents" is center, If you want it to be like others (with Glenn style) : comment the 3rd line

To call the table of contents:

\chapter*{Table of Contents} %if you want in Glenn style also


  • Welcome to TeX.SX! Your answer seems quite helpful. Nevertheless, could you eleborate on why your redefinition of \tableofcontentssolves? – Dave Jul 6 '18 at 8:07
  • 1
    @Dave It's used in .sty file : \ChTitleUpperCase It seems that this command, which makes use of the \MakeUppercase command for the title display, makes the switch command fragile. One way to overcome this difficulty is to redefined the \tableofcontents command to make the switch command robust. For what it's worth, I would probably not trust fncychap for a longer document, it has fairly rudimentary errors. I might recommend instead using the titlesec package or the memoir class (among other options) for customizing headers. – Jerome Jul 6 '18 at 9:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.