[Top][All Lists]

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

Re: MULE shows gibberish; now what?

From: Kai Großjohann
Subject: Re: MULE shows gibberish; now what?
Date: Thu, 26 Sep 2002 10:23:12 +0200
User-agent: Gnus/5.090008 (Oort Gnus v0.08) Emacs/21.3.50 (i686-pc-linux-gnu)

Ilya Zakharevich <address@hidden> writes:

> [A complimentary Cc of this posting was sent to
> Kai
>  =?iso-8859-15?q?Gro=DFjohann?=
> <address@hidden>], who wrote in article <address@hidden>:
>> > Of course it does, what else could it be!  But how would I detect it
>> > and/or fix it?
>> With C-u C-x =, as I said.
> Would it show the font and the codepoint chosen in the font?  [I'm not
> on X, so cannot check myself]

Here is an example output of C-u C-x =.   I think it will clear up a
lot of things.

|   character: € (07444, 3876, 0xf24)
|     charset: latin-iso8859-15
|              (Right-Hand Part of Latin Alphabet 9 (ISO/IEC 8859-15): 
|  code point: 36
|      syntax: w        which means: word
|    category: l:Latin  
| buffer code: 0x8E 0xA4
|   file code: 0x8E 0xA4 (encoded by coding system emacs-mule)
|     Unicode: 20AC
|        font: -Misc-Fixed-Medium-R-Normal--14-130-75-75-C-70-ISO8859-15
| There are text properties here:
|   fontified            t

In the above output, it is easy to see if the glyph matches what it
should be.  I can do "man iso-8859-15" to look up what character has
code 128+36, and then I can compare it with the glyph.  And if the
"man" command told me to expect a Euro sign, but I'm seeing a
currency sign, then I know that something is wrong.

>> >> Put point on a Cyrillic character and type C-u C-x =, this tells you
>> >> stuff, including the charset that Emacs thinks this character is in.
>> >
>> > Hmm?  You mean that doing "Hello world" demo, one gets different
>> > results of your test on different machines?  Now I'm completely
>> > confused...
>> If I now set the X11 resource Emacs.font to a Latin-9 font, then
>> Emacs will display Latin-1 characters with that font!  This means, if
>> the HELLO file includes that currency sign, I would wrongly see a euro
>> sign, but C-u C-x = would tell me that Emacs thinks it is displaying
>> a Latin-1 character.
> What you say is: the "hello world" example will have the same result
> of C-u C-x = on all the machines.  So I do not see how it would help me...

No, I did NOT say that the output of C-u C-x = is the same on all
machines.  What I said is that C-u C-x = tells you which character
Emacs thinks it is displaying.

As you can easily see, the font name can be different.  And the glyph
(directly after "character: ") is of course also different.

Other parts of the output are system-independent, obviously.

>> This is a misconfiguration of Emacs, and can be corrected.
>> Maybe you have a similar misconfiguration of Emacs.
>> (It is also arguably a bug since Emacs should know from the font name
>> that it is not a Latin-1 font.  But not all fonts specify
>> "iso8859-15" in their names, so it is difficult to know.)
> You are discussing a default font; which is not under the control of
> Emacs.  I'm discussing Cyrillic font, which is not under *my* control
> (as far as I know now).

You can tell Emacs to use the foo font for the bar encoding.  Maybe
you have (accidentally) told Emacs to use a KOI-R font for the
iso-8859-5 encoding, or something like this.  This would explain the
strange output.  And if you use C-u C-x = you can immediately see if
this is the case.

If all else fails, you can of course also install fonts in your home
dir and tell X11 about them, and then tell Emacs to use one of those...

~/.signature is: umop ap!sdn    (Frank Nobis)

reply via email to

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