[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [w32] TrueType font with multibyte name
From: |
Satomi I. |
Subject: |
Re: [w32] TrueType font with multibyte name |
Date: |
Mon, 18 Oct 2004 10:33:17 +0900 |
User-agent: |
Wanderlust/2.11.24 (Wonderwall) Emacs/21.3 Mule/5.0 (SAKAKI) |
Dear Jason,
On Sat, 16 Oct 2004 12:37:37 +0100, "Jason Rumney" wrote:
> I don't think fast_c_string_match_ignore_case() is supposed to
> handle multibyte (ie Emacs internal encoding) strings. I think the
> proper fix is to do the conversion to "unibyte" in the function that
> calls it, or use fast_string_match with a Lisp string instead.
Okay, I understood.
Now I have confirmed that w32_font_match() in w32fns.c has been
modified to encode the font name. Thank you for your support.
Unfortunately, however, the fix would not completely solve the
problem. It does solve the issue on font-name matching, but not on
fontset-name matching.
Please consider the following case:
(create-fontset-from-fontset-spec
"-*-MS ゴシック-normal-r-normal-*-12-*-*-*-C-*-fontset-test,
japanese-jisx0208:-*-MS ゴシック-normal-r-*-*-12-*-*-*-c-*-jisx0208-sjis,
katakana-jisx0201:-*-MS ゴシック-normal-r-*-*-12-*-*-*-c-*-jisx0208-sjis"
t)
(fontset-list)
=> ("-*-MS ゴシック-normal-r-normal-*-12-*-*-*-c-*-fontset-test"
"-*-courier new-normal-r-*-*-13-*-*-*-c-*-fontset-standard"
"-*-*-*-*-*-*-*-*-*-*-*-*-fontset-default")
(query-fontset "*test*")
=> "-*-courier new-normal-r-normal-*-12-*-*-*-c-*-fontset-test"
;; try choosing a fontset interactively.
(setq w32-use-w32-font-dialog nil)
Using menu bar: Options -> Set Font/Fontset
error--> Invalid fontset: nil
;; test some other functions.
(list-fontsets nil)
error--> Invalid fontset: nil
(fontset-plain-name (query-fontset "*test*"))
error--> Invalid fontset: nil
Apparently the multibyte string in the first font-pattern is doing
something bad.
These errors did not occur when I modified
fast_c_string_match_ignore_case(). Maybe there are some other callers
that need to be fixed -- possibly in fontset.c?
Regards,
Sato