Lyx lets us mark words/sentences with another language - very useful for
spellchecking of multi-lingual documents.
This works well for words in "standard text", and cause problems
otherwise. The typical symptom is that view->PDF fails with an
"Undefined control sequence"
Using foregin language in a section heading (or in a footnote in a
section heading) have exactly this problem. Example of the code lyx
generates for a british foootnote in a section heading:
\section{Om dhcp%
\footnote{DHCP: \foreignlanguage{british}{Dynamic Host Configuration
Protocol}%
}}
This looks fine - perhaps this is a latex limitation. It certainly
doesn't work.
If this is a latex limitation, then I suggest that LyX still allow the
construct, and just don't create the \foreignlanguage command when
inside headings. Having spellchecker support for foreign words in
headings too is really nice, as the spellchecker don't stumble over
foreign words all the time.
And the text prints just fine without the \foreignlanguage command anyway.