[Top][All Lists]

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

[AUCTeX-devel] preview-latex coding problem

From: Masayuki Ataka
Subject: [AUCTeX-devel] preview-latex coding problem
Date: Tue, 07 Feb 2006 11:56:16 +0900 (JST)


Ikumi-San reported me that preview-latex put preview-image in
wrong place, if the buffer coding system is different from process
coding system (Hmm, Japanese have 3 coding system Xp).

He sent me a patch below.
This patch works fine with Japanese document.
I want to know this works fine with document in European languages.
If ok, I will commit.

email: address@hidden
Name:: Masayuki Ataka // (Japan)

--- preview/preview.el-11.82    Sun Sep 25 04:15:55 2005
+++ preview/preview.el  Sun Jan 22 23:49:03 2006
@@ -2583,7 +2583,10 @@
            string (substring string (match-end 0))))
     (setq output (concat output (regexp-quote string)))
     (if (featurep 'mule)
-       (decode-coding-string output buffer-file-coding-system)
+       (decode-coding-string output
+                             (or (and (boundp 
+                                 buffer-file-coding-system))
 (defun preview-parse-messages (open-closure)
@@ -3424,8 +3427,10 @@
          (setq TeX-sentinel-function 'preview-TeX-inline-sentinel)
          (when (featurep 'mule)
            (setq preview-coding-system
-                 (with-current-buffer commandbuff
-                   buffer-file-coding-system))
+                 (or (and (boundp 'TeX-japanese-process-output-coding-system)
+                          TeX-japanese-process-output-coding-system)
+                     (with-current-buffer commandbuff
+                       buffer-file-coding-system)))
            (when preview-coding-system
              (setq preview-coding-system

reply via email to

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