Question

Specifically, I'm looking for something that will bridge the English-Japanese problem: Japanese is most easily and quickly output with platex %b and dvipdf %b.dvi, which uses pLaTeX (specifically for Japanese text), but this breaks English PDF outputs that work using the default org-process-as-pdf variable (which uses pdflatex). Is there a way to define this per-file, or modify the exporter interface to separate these without rewriting a huge portion of it? I'm on org-mode 7.9.3 right now but will migrate probably by February.

Was it helpful?

Solution

The answer is to use XeLaTeX. The following general process should cover most every base:

xelatex -interaction nonstopmode -output-directory %o %f
biber %b # or bibtex, or your favorite bibliography handler
xelatex -interaction nonstopmode -output-directory %o %f
xelatex -interaction nonstopmode -output-directory %o %f

Additionally, you will need the following headers in the org file:

#+LATEX_HEADER: \usepackage{xeCJK}
#+LATEX_HEADER: \setCJKmainfont{TakaoExMincho} % for \rmfamily

I tested this on a full document including all kinds of embeddings and links, and it just worked.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top