# HG changeset patch # User HIROSE Yuuji # Date 1330479901 -32400 # Node ID 9d022a5315492e8a987a9236bf9a4349e8460f35 # Parent 0b10d1fea265e1ae336643547296e7e7c8d1b867 Set buffer-file-coding-system for write at tfb-and-exit. diff -r 0b10d1fea265 -r 9d022a531549 yatexlib.el --- a/yatexlib.el Wed Feb 29 10:43:24 2012 +0900 +++ b/yatexlib.el Wed Feb 29 10:45:01 2012 +0900 @@ -2,7 +2,7 @@ ;;; YaTeX and yahtml common libraries, general functions and definitions ;;; yatexlib.el ;;; (c)1994-2012 by HIROSE Yuuji.[yuuji@yatex.org] -;;; Last modified Fri Feb 17 17:15:37 2012 on firestorm +;;; Last modified Wed Feb 29 09:49:30 2012 on firestorm ;;; $Id$ ;; General variables @@ -1568,7 +1568,15 @@ (lambda (arg) (find-file arg) (texinfo-format-buffer) - (basic-save-buffer))) + (cond + ((fboundp 'set-buffer-file-coding-system) + (set-buffer-file-coding-system 'sjis-dos)) + ((fboundp 'set-file-coding-system) + (set-file-coding-system '*sjis*dos)) + ((boundp 'NEMACS) + (set (make-local-variable 'kanji-fileio-code) 1))) + (let ((coding-system-for-write buffer-file-coding-system)) + (basic-save-buffer)))) command-line-args-left) (kill-emacs))))