[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] exporting α/β to latex/pdf
From: |
Nick Dokos |
Subject: |
Re: [O] exporting α/β to latex/pdf |
Date: |
Tue, 06 May 2014 18:33:20 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.4.50 (gnu/linux) |
"Clément B." <address@hidden> writes:
>> The *easiest* solution is to just say \alpha and \beta in the org file
>> instead of α and β. But biting the bullet and adopting XeTeX or LuaTeX is
>> probably the *best* way to go (he says without ever having used either...)
>
> For those who stick with pdflatex, you can also use "α" directly in
> the org document, and define
>
> #+latex_header: \usepackage[utf8]{inputenc}
> #+latex_header: \declareunicodecharacter{03b1}{α}
>
> Provided your file is indeed encoded in utf-8 (but why would you use
> any other encoding?)
>
> This simply tells the compiler to bind "α" to the unicode character
> "greek small letter alpha" (U+03B1). If there is a lot of unicode in
> the document, XeTeX/LuaTeX are definitely better choices.
>
>
But that's not quite right: you end up with a circular definition (and
both pdflatex and plain latex think so: they infloop).
One way to fix it using a math alpha:
--8<---------------cut here---------------start------------->8---
#+LATEX_HEADER: \DeclareUnicodeCharacter{03b1}{\(\alpha\)}
--8<---------------cut here---------------end--------------->8---
Another is to use \textalpha and a package that defines it:
--8<---------------cut here---------------start------------->8---
#+LATEX_HEADER: \usepackage{textgreek}
#+LATEX_HEADER: \DeclareUnicodeCharacter{03b1}{\textalpha}
--8<---------------cut here---------------end--------------->8---
but then you have to install the package (and possibly some fonts as
well).
Nick
PS. So happy that gmane is back :-)
Re: [O] exporting α/β to latex/pdf, Sharon Kimble, 2014/05/04