Achim Gratz <strom...@nexgo.de> writes:

> It doesn't fix the problem when I want to export the file in
> a different encoding (for instance by customizing Org Export Latex
> Coding System), that would require a second step of re-setting the
> buffer-file-coding-system before using it to determine what to write
> into the inputenc option.

Would the following patch work?


Regards,

-- 
Nicolas Goaziou
>From 2f2591719cc41e7312401ce7368b4bbbdde2c8ad Mon Sep 17 00:00:00 2001
From: Nicolas Goaziou <n.goaz...@gmail.com>
Date: Sat, 23 Feb 2013 11:29:45 +0100
Subject: [PATCH] ox-latex: Set inputenc option according to
 `org-export-coding-system'

* lisp/ox-latex.el (org-latex-guess-inputenc): Set inputenc option
  according to `org-export-coding-system'.
---
 lisp/ox-latex.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/ox-latex.el b/lisp/ox-latex.el
index cbeaa4e..4047aa2 100644
--- a/lisp/ox-latex.el
+++ b/lisp/ox-latex.el
@@ -946,7 +946,7 @@ when specified inputenc option is \"AUTO\".
 Return the new header, as a string."
   (let* ((cs (or (ignore-errors
 		   (latexenc-coding-system-to-inputenc
-		    buffer-file-coding-system))
+		    (or org-export-coding-system buffer-file-coding-system)))
 		 "utf8")))
     (if (not cs) header
       ;; First translate if that is requested.
-- 
1.8.1.4

Reply via email to