TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

This question already has an answer here:

I'm writing a beamer document, and using the following definition for author

\author[O. Castillo]{Oscar Castillo}

As far as I know, \@author returns the value Oscar Castillo


Is there a command that return the value O. Castillo?


share|improve this question

marked as duplicate by zeroth, Werner, Claudio Fiandrino, Marco Daniel, lockstep Mar 14 '13 at 19:39

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

See for example »Macro for formatting names (initials or full name)« – clemens Mar 14 '13 at 18:18
up vote 3 down vote accepted

Since you are using beamer, you have \insertshortauthor and \insertauthor:


\author[O. Castillo]{\'Oscar Castillo}




enter image description here

After a comment, it seems that the idea is to use this to generate some meta-data information for the PDF; in this case one could use \beamer@shortauthor:

\title{The Title}
\author[O. Castillo]{\'Oscar Castillo}




share|improve this answer
Thanks @gonzalo-medina, very nice! However, it seems that this commands cannot be used in the preamble, and these are not accepted for generating metadata. :-P – Dox Mar 14 '13 at 18:40
@Dox of course they can be used in the preamble: \documentclass{beamer} \author[O. Castillo]{\'Oscar Castillo} \setbeamertemplate{footline}{\insertshortauthor} \setbeamertemplate{headline}{\insertauthor} \begin{document} \begin{frame} test \end{frame} \end{document}. If something is not working for you, you need to be more specific. – Gonzalo Medina Mar 14 '13 at 18:44
I tried it again (using the command \hypersetup{pdftitle={\@title},pdfauthor={\insertshortauthor}}), but I get no author in the matadata info. Could it be a bug? – Dox Mar 14 '13 at 18:50
@Dox -- What about using \beamer@shortauthor? Probably need to wrap it in the \makeatletter ... \makeatother.... – jon Mar 14 '13 at 19:06
@Dox jon is right in his comment, you can use \beamer@shortauthor, as in my updated answer. – Gonzalo Medina Mar 14 '13 at 19:15

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