\usepackage{titling}
itself generates this error in a document that compiles fine
otherwise. Interestingly, the author of the package mentions similar
error being reported by another user but does not give any clue as to
what to do to solve it.
Here is the error I get:
! Argument of \reserved@a has an extra }.
<inserted text>
\par
l.261 ...sion for thier use in typographic work.}}
?
Regards,
Tariq
\documentclass{article}
\usepackage{titling}
\begin{document}
Ipsum
\end{document}
works for me. Supply a minimal example showing your perceived problem.
Peter W.
Peter
Thanks for looking into it. Here is the minimal example that gives me
problem. I noticed that the problem has to do with \footnote{} within
the \title{}. Unfortunately, I am not sure why this should be an issue
because \footnote is a legitimate command and I happen to have most of
my documents with \footnote within \title. If this cannot be resolved,
I will have to redefine my own \title macro.
%% Min exmpl showing problem; remove \footnote{} to solve.
\documentclass{article}
\usepackage{titling}
\title{Title\footnote{A footnote}}
\begin{document}
\maketitle
Some text.
\end{document}
Regards,
Tariq
\footnote is fragile. Just put \protect in front of it, and you'll be
fine. I don't know why the redefinition in the titling package changes
the regular behaviour, though. It seems like it shouldn't.
Alan
> On May 18, 5:11�pm, peter wilson <herries.pr...@earthlink.net> wrote:
>> Tariq wrote:
>> > Here is the error I get:
>>
>> > ! Argument of \reserved@a has an extra }.
>> > <inserted text>
>> > � � � � � � � � \par
>> > l.261 ...sion for thier use in typographic work.}}
>>
>> > ?
>>
>> \documentclass{article}
>> \usepackage{titling}
>> \begin{document}
>> Ipsum
>> \end{document}
>> works for me. Supply a minimal example showing your perceived problem.
>
> Thanks for looking into it. Here is the minimal example that gives me
> problem. I noticed that the problem has to do with \footnote{} within
> the \title{}. Unfortunately, I am not sure why this should be an issue
> because \footnote is a legitimate command and I happen to have most of
> my documents with \footnote within \title. If this cannot be resolved,
> I will have to redefine my own \title macro.
>
> %% Min exmpl showing problem; remove \footnote{} to solve.
> \documentclass{article}
> \usepackage{titling}
> \title{Title\footnote{A footnote}}
> \begin{document}
> \maketitle
> Some text.
> \end{document}
\protect before \footnote, perhaps.
(it's always a good idea to provide the min example in the first post.
you get an answer more quickly, then.)
--
Robin Fairbairns, Cambridge
>\footnote is fragile. Just put \protect in front of it, and you'll be
>fine. I don't know why the redefinition in the titling package changes
>the regular behaviour, though. It seems like it shouldn't.
The titling package provides a means to save the
value of the title. It does so in a way that omits
footnotes _provided they are obtained with \thanks{}_
It does this with
\protected@xdef\thetitle{\@title}
after temporarily redefining \thanks to gobble its
argument. This makes \title a moving argument and
produces an error for most unprotected fragile commands.
It would appear that one should always enter footnotes
with \thanks in titles when titling.sty is used. One can
use \thanks even when titling is not in use. Because the
standard classes start their titles with
\let\footnote\thanks
one is using \thanks whether one knows it or not.
Dan
To reply by email, change LookInSig to luecking
> On Wed, 19 May 2010 14:16:08 -0400, Alan Munn <am...@msu.edu> wrote:
>
> >\footnote is fragile. Just put \protect in front of it, and you'll be
> >fine. I don't know why the redefinition in the titling package changes
> >the regular behaviour, though. It seems like it shouldn't.
>
> The titling package provides a means to save the
> value of the title. It does so in a way that omits
> footnotes _provided they are obtained with \thanks{}_
> It does this with
> \protected@xdef\thetitle{\@title}
> after temporarily redefining \thanks to gobble its
> argument. This makes \title a moving argument and
> produces an error for most unprotected fragile commands.
>
That makes sense. I'd forgotten that titling preserves the title, and
I hadn't bothered to check the code. So the fix of \protect before the
footnote will work, but isn't advisable if Tariq wants to reuse the
title.
> It would appear that one should always enter footnotes
> with \thanks in titles when titling.sty is used. One can
> use \thanks even when titling is not in use. Because the
> standard classes start their titles with
> \let\footnote\thanks
> one is using \thanks whether one knows it or not.
:-)
Alan
And in any event, putting footnotes in a title is Very Poor Style.
///Peter
>
> And in any event, putting footnotes in a title is Very Poor Style.
Except that it's required in some form or other by many, many journals.
(Unless what you meant was "putting \footnote{} in a \title{} is very
poor LaTeX style (i.e., you should use \thanks)"?
Alan
>
> ///Peter
Indeed it is, but that doesn't make it any better style :-)
///Peter