help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: Using different fonts depending on character set


From: Oliver Scholz
Subject: Re: Using different fonts depending on character set
Date: Wed, 11 Aug 2004 11:02:14 +0200
User-agent: Gnus/5.1006 (Gnus v5.10.6) Emacs/21.3.50 (windows-nt)

Paul Moore <pf_moore@yahoo.co.uk> writes:

> Emacs 21.3 on Windows, No Gnus from CVS. For 99.99% of my email/news I
> get ASCII (or maybe latin-1) text, and I use the default Courier New
> font. However, just occasionally, I get messages with odd characters -
> often encoded in UTF-8, not always using characters available in
> Courier New. For example, I recently saw a message with a short piece
> of Japanese text - the rest was basically ASCII.
>
> Is there a way to set a different font which can be used for such "out
> of range" characters? I'd have though not, and yet my email at work
> (Outlook - ack, spit) managed to switch fonts just for the Japanese
> message (it switched for the whole message, not just for the Japanese
> characters, but that's OK).
>
> This is a very minor issue (after all, it's extremely rare that I get
> mail like this, other than spam) but it's a matter of pride - I don't
> like to think that Outlook can do something that Gnus can't!
[...]

It is as you suspect: you can define different fonts for
different character sets. A collection of fonts and
specifications for which characters to use that font is called
a "fontset". For instance, this would adjust the
fontset "fontset-standard" to use "palatino linotype"
(on MS Windows XP) for a certain range of UCS characters:

(set-fontset-font "fontset-standard"
                  'mule-unicode-0100-24ff
                  "-*-palatino linotype-*-*-r-*-14-*-*-*-*-*-iso10646-1")

;; Use "fontset-standard"
(set-face-font 'default "fontset-standard")

You can find out to which charset a character in a buffer belongs by
hitting `C-u C-x =' with point before that character.

See also:
(info "(emacs)Defining Fontsets")

Does that help?

> I suspect this is more of an Emacs question than a Gnus one, hence the
> crosspost. Does anyone have any suggestions?

It is an Emacs question, follow-up set accordingly to gnu.emacs.help.

    Oliver
-- 
25 Thermidor an 212 de la Révolution
Liberté, Egalité, Fraternité!


reply via email to

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