"Stephen J. Turnbull" <stephen(a)xemacs.org> writes:
>>>>> "Mike" == Mike Fabian
<mfabian(a)suse.de> writes:
Mike> But when starting XEmacs like
Mike> LC_CTYPE=ja_JP.UTF-8 xemacs
Mike> I can switch to Japanese input mode using Shift-Space and
Mike> enter Japanese, but when committing the Japanese string with
Mike> RET, it is inserted as mojibake into the XEmacs buffer.
Works correctly for me in 21.4.7, my current version (21.4.9) isn't
xim-enabled. But I can't imagine anything that changed since 21.4.7
would affect this.
I found that including
(set-coding-priority-list '(utf-8))
(set-coding-category-system 'utf-8 'utf-8))
in my ~/.xemacs/init.el or evaluating these two lines manually in the
scratch buffer makes it work. Why these two lines? And why don't
(set-keyboard-coding-system 'utf-8)
(set-terminal-coding-system 'utf-8)
(set-default-coding-systems 'utf-8)
have any influence?
I wrote that
mfabian@gregory:/tmp$ echo '-*- coding: utf-8 -*-' > test-file
mfabian@gregory:/tmp$ LC_CTYPE=ja_JP.UTF-8 xemacs -q -eval "(require
'un-define) (set-keyboard-coding-system 'utf-8) (set-terminal-coding-system
'utf-8) (set-default-coding-systems 'utf-8) (set-buffer-file-coding-system
'utf-8) (set-coding-priority-list '(utf-8)) (set-coding-category-system 'utf-8
'utf-8)" test-file
doesn't work. I can still reproduce this, Japanese input with XIM
doesn't work on my system when I start xemacs using '-q' and
evaluating (set-coding-priority-list '(utf-8)) and
(set-coding-category-system 'utf-8 'utf-8)) on the command line.
Why does it make a difference whether I evaluate these functions on
the command line or in my ~/.xemacs/init.el?
--
Mike Fabian <mfabian(a)suse.de>
http://www.suse.de/~mfabian
睡眠不足はいい仕事の敵だ。