emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* accented letters in pdf export
@ 2013-01-02 20:28 Tyler Smith
  2013-01-02 21:13 ` Thomas S. Dye
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Tyler Smith @ 2013-01-02 20:28 UTC (permalink / raw)
  To: Emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 374 bytes --]

Hi,

I'm using org 7.9.2, with the new exporter dispatcher from org-export. When
I try to include accented letters, such as \'e, they don't work. When I
export to pdf using C-c C-e p, the resulting tex file shows $\backslash$'e
where I had \'e in the org file. Other macros, like \alpha, work fine.

How do I include accented letters in my pdflatex exports?

Thanks,

Tyler

[-- Attachment #2: Type: text/html, Size: 498 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: accented letters in pdf export
  2013-01-02 20:28 accented letters in pdf export Tyler Smith
@ 2013-01-02 21:13 ` Thomas S. Dye
  2013-01-02 21:22 ` Doug Lewan
  2013-01-02 21:24 ` Nick Dokos
  2 siblings, 0 replies; 5+ messages in thread
From: Thomas S. Dye @ 2013-01-02 21:13 UTC (permalink / raw)
  To: Tyler Smith; +Cc: Emacs-orgmode

Tyler Smith <tyler.smith@mail.mcgill.ca> writes:

> Hi,
>
> I'm using org 7.9.2, with the new exporter dispatcher from org-export. When
> I try to include accented letters, such as \'e, they don't work. When I
> export to pdf using C-c C-e p, the resulting tex file shows $\backslash$'e
> where I had \'e in the org file. Other macros, like \alpha, work fine.
>
> How do I include accented letters in my pdflatex exports?

Please see the variable org-entities (C-h v org-entities).  You'll want
something like \eacute instead of \'e, etc.

There is also org-entities-user for additions to the entity lookup
table.  I have this:

  (setq org-entities-user nil)
  (add-to-list 'org-entities-user '("space" "\\ " nil " " " " " " "–"))
  (add-to-list 'org-entities-user '("amacron" "\\={a}" nil "&#0257" "a" "a" "ā"))
  (add-to-list 'org-entities-user '("emacron" "\\={e}" nil "&#0275" "e" "e" "ē"))
  (add-to-list 'org-entities-user '("imacron" "\\={i}" nil "&#0299" "i" "i" "ī"))
  (add-to-list 'org-entities-user '("omacron" "\\={o}" nil "&#0333" "o" "o" "ō"))
  (add-to-list 'org-entities-user '("umacron" "\\={u}" nil "&#0363" "u" "u" "ū"))
  (add-to-list 'org-entities-user '("Amacron" "\\={A}" nil "&#0256" "A" "A" "Ā"))
  (add-to-list 'org-entities-user '("Emacron" "\\={E}" nil "&#0274" "E" "E" "Ē"))
  (add-to-list 'org-entities-user '("Imacron" "\\={I}" nil "&#0298" "I" "I" "Ī"))
  (add-to-list 'org-entities-user '("Omacron" "\\={O}" nil "&#0332" "O" "O" "Ō"))
  (add-to-list 'org-entities-user '("Umacron" "\\={U}" nil "&#0362" "U" "U" "Ū"))
  (define-key org-mode-map (kbd "C-c e") 'org-export-dispatch)

Also, note that C-c C-e p is typically bound to the old exporter, so you
might be using the old exporter, rather than the new one.  The
(define-key ...) above calls the new exporter with C-c e.

hth,
Tom

-- 
Thomas S. Dye
http://www.tsdye.com

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: accented letters in pdf export
  2013-01-02 20:28 accented letters in pdf export Tyler Smith
  2013-01-02 21:13 ` Thomas S. Dye
@ 2013-01-02 21:22 ` Doug Lewan
  2013-01-02 21:24 ` Nick Dokos
  2 siblings, 0 replies; 5+ messages in thread
From: Doug Lewan @ 2013-01-02 21:22 UTC (permalink / raw)
  To: Tyler Smith, Emacs-orgmode@gnu.org

Exporting to LaTeX or PDF includes this line:

    \usepackage[utf8]{inputenc}

And that seems to cope quite well with the actual accented characters.

If you learn an input method (latin-1-prefix is probably a good place to start), then accented characters just fall through to the LaTeX and the right thing happens.

`C-u C-\ latin-1-prefix' will set the input method. `C-h I' will get you help on it.

,Douglas
Douglas Lewan
Shubert Ticketing
(201) 489-8600 ext 224

When I do good, I feel good. When I do bad, I feel bad and that's my religion. - Abraham Lincoln

From: emacs-orgmode-bounces+dougl=shubertticketing.com@gnu.org [mailto:emacs-orgmode-bounces+dougl=shubertticketing.com@gnu.org] On Behalf Of Tyler Smith
Sent: Wednesday, 2013 January 02 15:28
To: Emacs-orgmode@gnu.org
Subject: [O] accented letters in pdf export

Hi,

I'm using org 7.9.2, with the new exporter dispatcher from org-export. When I try to include accented letters, such as \'e, they don't work. When I export to pdf using C-c C-e p, the resulting tex file shows $\backslash$'e where I had \'e in the org file. Other macros, like \alpha, work fine.
How do I include accented letters in my pdflatex exports?
Thanks,

Tyler

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: accented letters in pdf export
  2013-01-02 20:28 accented letters in pdf export Tyler Smith
  2013-01-02 21:13 ` Thomas S. Dye
  2013-01-02 21:22 ` Doug Lewan
@ 2013-01-02 21:24 ` Nick Dokos
  2013-01-02 21:44   ` Nick Dokos
  2 siblings, 1 reply; 5+ messages in thread
From: Nick Dokos @ 2013-01-02 21:24 UTC (permalink / raw)
  To: Tyler Smith; +Cc: Emacs-orgmode

Tyler Smith <tyler.smith@mail.mcgill.ca> wrote:

> I'm using org 7.9.2, with the new exporter dispatcher from
> org-export. When I try to include accented letters, such as \'e, they
> don't work. When I export to pdf using C-c C-e p, the resulting tex
> file shows $\backslash$'e where I had \'e in the org file. Other
> macros, like \ alpha, work fine.

> How do I include accented letters in my pdflatex exports?
> 

That looks like a bug in the new exporter (the old exporter handles it
properly).  You can get accented letters by entering the character in
e.g. utf-8 and arranging for tex to do the right thing (which I think
it does by default with unicode in org's latex export).  You can use an
input method to simplify entering such things as well.

Here's a quick intro (there are many other ways to accomplish this):

o Set your language environment to utf-8

  (set-language-environment "UTF-8")

o Open a new org file in an emacs buffer: C-x C-f foo.org RET
  The new file should have a U:--- designation on the mode line.

o Set your default input method to TeX:

  (set-input-method "TeX")

  The mode line should now show \U:---

o Enter some text with accented characters - the TeX input method allows
  you to enter an accented e with \'e or \`e for example, but what ends up
  in the buffer is the accented character itself (in utf-8 encoding).

o Export to latex/pdf. Assuming the tex file  includes

  \usepackage[utf8]{inputenc}
  \usepackage[T1]{fontenc}

  then TeX will do the right thing.


For more on the TeX aspects, see the TeX FAQ http://www.tex.ac.uk/cgi-bin/texfaq2html
and search for inputenc.

Nick

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: accented letters in pdf export
  2013-01-02 21:24 ` Nick Dokos
@ 2013-01-02 21:44   ` Nick Dokos
  0 siblings, 0 replies; 5+ messages in thread
From: Nick Dokos @ 2013-01-02 21:44 UTC (permalink / raw)
  Cc: Tyler Smith, Emacs-orgmode

Nick Dokos <nicholas.dokos@hp.com> wrote:

> Tyler Smith <tyler.smith@mail.mcgill.ca> wrote:
> 
> > How do I include accented letters in my pdflatex exports?
> > 
> 
> That looks like a bug in the new exporter (the old exporter handles it
> properly).

Eh, I rushed to judgment. It's probably by design, given Tom's mail and
after doing some reading on org-entities.

Nick

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2013-01-02 21:44 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-01-02 20:28 accented letters in pdf export Tyler Smith
2013-01-02 21:13 ` Thomas S. Dye
2013-01-02 21:22 ` Doug Lewan
2013-01-02 21:24 ` Nick Dokos
2013-01-02 21:44   ` Nick Dokos

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).