From: "Jihyun Cho" <jihyun.jo@gmail.com>
To: emacs-devel@gnu.org
Subject: [PATCH] Incorrect message in hanja-list-show()
Date: Tue, 24 Jun 2008 11:32:38 +0900 [thread overview]
Message-ID: <9d644d9b0806231932o6582ea0apf265192ffe823915@mail.gmail.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 198 bytes --]
When the coding system is not UTF-8, the message of 'hanja-list-show'
does not look right.
This problem occurs in most of the the Korean Windows.
The patch is decoding from encoded string by UTF-8.
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: emacs-hanja-list-decoding.diff --]
[-- Type: text/x-diff; name=emacs-hanja-list-decoding.diff, Size: 1355 bytes --]
? emacs-hanja-list-decoding.diff
Index: emacs/lisp/language/hanja-util.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/language/hanja-util.el,v
retrieving revision 1.5
diff -u -8 -p -r1.5 hanja-util.el
--- emacs/lisp/language/hanja-util.el 9 Jun 2008 01:18:11 -0000 1.5
+++ emacs/lisp/language/hanja-util.el 23 Jun 2008 16:48:15 -0000
@@ -6541,17 +6541,21 @@ character. This variable is initialized
(put-text-property
(+ 2 (string-match (format "%d\\.[^ ]*" idx) msg))
(match-end 0)
'face 'highlight msg)
(setq char-meaning (cdr (car partial-hanja-list))))
(setq idx (1+ idx)
partial-hanja-list (cdr partial-hanja-list)))
(if char-meaning
- (setq msg (format "%s (뜻 : %s)" msg char-meaning)))
+ (setq msg
+ (format "%s (%s : %s)"
+ msg
+ (decode-coding-string "뜻" 'utf-8)
+ (decode-coding-string char-meaning 'utf-8))))
(message "%s" msg)))
(defun hanja-list-terminate ()
"Exit from the hanja listing mode with the currently selected character."
(let ((base (aref hanja-conversions 0))
(offset (aref hanja-conversions 1))
(hanja-list (aref hanja-conversions 2)))
(throw 'exit-input-loop
next reply other threads:[~2008-06-24 2:32 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-06-24 2:32 Jihyun Cho [this message]
2008-06-24 8:58 ` [PATCH] Incorrect message in hanja-list-show() Jason Rumney
2008-06-24 16:35 ` Jihyun Cho
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=9d644d9b0806231932o6582ea0apf265192ffe823915@mail.gmail.com \
--to=jihyun.jo@gmail.com \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).