GNU bug report logs - #39656
27.0.60; ordering of fonts in fontset is ignored

Previous Next

Package: emacs;

Reported by: ynyaaa <at> gmail.com

Date: Tue, 18 Feb 2020 13:15:02 UTC

Severity: normal

Found in version 27.0.60

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


Message #8 received at 39656 <at> debbugs.gnu.org (full text, mbox):

From: Alan Third <alan <at> idiocy.org>
To: ynyaaa <at> gmail.com
Cc: 39656 <at> debbugs.gnu.org
Subject: Re: bug#39656: 27.0.60; ordering of fonts in fontset is ignored
Date: Wed, 19 Feb 2020 11:02:44 +0000
On Tue, Feb 18, 2020 at 10:13:47PM +0900, ynyaaa <at> gmail.com wrote:
> 
> If font list in fontset includes the font for ASCII,
> the ordering may be ignored and the font for ASCII is used prior to
> front fonts.
> 
> I tried to setup fontset to display "MS Gothic" as a primary font,
> and "SimHei" as a secondary font, except for ASCII characters.
> And "SimHei" is used for ASCII characters.
> ("MS Gothic" has YEN SIGN glyph for #x5C(\).)
> 
> Evaluating the form below, every character is displayed with "SimHei"
> if glyphs are defined in both "SImHei" and "MS Gothic".
> For example, most of CJK Ideographs are displayed with "SimHei".
> "MS Gothic" is not used between U+3400 and U+9FA5.
> 
> (let* ((ascii "SimHei")
>        (primary "MS Gothic")
>        (secondary ascii))
>   (setq use-default-font-for-symbols nil)
>   (set-frame-font ascii)
>   (set-fontset-font nil '(#x80 . #x10FFFF) primary)
>   (set-fontset-font nil '(#x80 . #x10FFFF) secondary nil 'append))

As I understand it the fontsets are used as fallbacks if the default
font doesn’t contain the desired glyph. Since SimHei DOES contain the
glyph and has been set as the default (set-frame-font) we would expect
to see it displayed with SimHei.
-- 
Alan Third




This bug report was last modified 4 years and 36 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.