emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[RFC] LaTeX - automatically configure encoding when exporting non-Latin


From: Ihor Radchenko
Subject: [RFC] LaTeX - automatically configure encoding when exporting non-Latin languages
Date: Fri, 02 Feb 2024 16:00:01 +0000

Pedro Andres Aranda Gutierrez <paaguti@gmail.com> writes:

> some days ago I sent a proof-of-concept for customising the coding for the
> fontenc package. Before continuing with this, I'd like to know what other
> people think and/or need.
>
> The simplest approach was in the PoC: a custom variable you can set in your
> document/workspace/emacs configuration. AN alternative approach would be to
> derive it from language.
>
> What would be the best way to go forward?

Let me provide some context for this.

Org mode export to PDF should ideally work for any document language,
once it is specified:

#+title: چون عهده نمی‌شود کسی فردا را
#+LATEX_COMPILER: lualatex
#+LANGUAGE: fa

However, it is not entirely the case yet.

We do load correct punctuation rules, but the output pdf encoding and
fonts have to be configured manually, as discussed in
https://list.orgmode.org/orgmode/87h6z7jq4o.fsf@localhost/

Pedro is proposing a step towards full automatic language configuration
- selecting the correct pdf output encoding:

https://list.orgmode.org/orgmode/CAO48Bk9Eo9zrgU7i7jMDcEAY120VZSHF70PdXOXKFCuKZGKGcg@mail.gmail.com/

The following should be enough to (1) load punctuation rules; (2) set
the correct pdf encoding.

#+title: چون عهده نمی‌شود کسی فردا را
#+LATEX_COMPILER: lualatex
#+LANGUAGE: fa
#+LaTeX_Header: \usepackage[AUTO]{polyglossia}
#+latex_header: \usepackage[AUTO]{fontspec}

(setting the correct font is still not done - it is tricky since we
don't easily know which fonts are installed locally)

Pedro, correct me if I misunderstood something.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>



reply via email to

[Prev in Thread] Current Thread [Next in Thread]