emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Rasmus <rasmus@gmx.us>
To: emacs-orgmode@gnu.org
Subject: Re: #+LATEX_HEADER:\newcommand{\orgtitle}{{{{TITLE}}}}
Date: Thu, 20 Mar 2014 00:25:33 +0100	[thread overview]
Message-ID: <8761n9n53m.fsf@gmx.us> (raw)
In-Reply-To: loom.20140319T180144-518@post.gmane.org

Luke Crook <luke@balooga.com> writes:

> Rasmus <rasmus <at> gmx.us> writes:
>
>> 
>> I've used this snip to recover such fields
>> 
>> \makeatletter
>> \let\Title\ <at> title
>> \let\Author\ <at> author
>> \let\Date\ <at> date
>> \makeatother
>> 
>> Obviously, this is only good for LaTeX. 
>> 
>
> How would I implement this?  Is including in the .tex file sufficient?  
> Having these in the Org-mode file itself?  When I try in the .tex file, it 
> appears almost verbatim as;

For some reason your "@" (the sign from email address) becomes "<at>".
It needs to be "@".  See the gmane version if you are in doubt.

Here's a working example.

#+TITLE: title
#+AUTHOR: name
#+LATEX: \newcommand{\myname}{\Author}
Remember to escape latex macros like
~\myname~ as ~@@latex:\myname@@~ in Org to get "\myname"


* make some latex commands                                         :noexport:
# Local Variables:
# org-latex-title-command: "\\makeatletter\n \
# \\let\\Title\\@title\n \
# \\let\\Author\\@author\n \
# \\let\\Date\\@date\\makeatother\n \
# \\maketitle"
# End:



-- 
In theory, practice and theory are the same. In practice they are not

  reply	other threads:[~2014-03-19 23:23 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-18  1:14 #+LATEX_HEADER:\newcommand{\orgtitle}{{{{TITLE}}}} Luke Crook
2014-03-18 15:22 ` #+LATEX_HEADER:\newcommand{\orgtitle}{{{{TITLE}}}} Bastien
2014-03-18 17:14   ` #+LATEX_HEADER:\newcommand{\orgtitle}{{{{TITLE}}}} Luke Crook
2014-03-18 20:33     ` #+LATEX_HEADER:\newcommand{\orgtitle}{{{{TITLE}}}} Luke Crook
2014-03-18 20:43       ` #+LATEX_HEADER:\newcommand{\orgtitle}{{{{TITLE}}}} Bastien
2014-03-19 15:02         ` #+LATEX_HEADER:\newcommand{\orgtitle}{{{{TITLE}}}} Nicolas Goaziou
2014-03-19 15:35           ` #+LATEX_HEADER:\newcommand{\orgtitle}{{{{TITLE}}}} Bastien
2014-03-19 16:00             ` #+LATEX_HEADER:\newcommand{\orgtitle}{{{{TITLE}}}} Nicolas Goaziou
2014-03-19 16:10               ` #+LATEX_HEADER:\newcommand{\orgtitle}{{{{TITLE}}}} Bastien
2014-03-19 21:23                 ` #+LATEX_HEADER:\newcommand{\orgtitle}{{{{TITLE}}}} Nicolas Goaziou
2014-03-21  9:04                   ` #+LATEX_HEADER:\newcommand{\orgtitle}{{{{TITLE}}}} Bastien
2014-03-19  8:34       ` #+LATEX_HEADER:\newcommand{\orgtitle}{{{{TITLE}}}} Eric S Fraga
2014-03-19 10:30         ` #+LATEX_HEADER:\newcommand{\orgtitle}{{{{TITLE}}}} Rasmus
2014-03-19 17:03           ` #+LATEX_HEADER:\newcommand{\orgtitle}{{{{TITLE}}}} Luke Crook
2014-03-19 23:25             ` Rasmus [this message]
2014-03-19 16:51         ` #+LATEX_HEADER:\newcommand{\orgtitle}{{{{TITLE}}}} Luke Crook

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8761n9n53m.fsf@gmx.us \
    --to=rasmus@gmx.us \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).