unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Alan Third <alan@idiocy.org>
To: ynyaaa@gmail.com
Cc: 39656@debbugs.gnu.org
Subject: bug#39656: 27.0.60; ordering of fonts in fontset is ignored
Date: Wed, 19 Feb 2020 11:02:44 +0000	[thread overview]
Message-ID: <20200219110244.GA39672@breton.holly.idiocy.org> (raw)
In-Reply-To: <86pnec6nsk.fsf@gmail.com>

On Tue, Feb 18, 2020 at 10:13:47PM +0900, ynyaaa@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





  reply	other threads:[~2020-02-19 11:02 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-18 13:13 bug#39656: 27.0.60; ordering of fonts in fontset is ignored ynyaaa
2020-02-19 11:02 ` Alan Third [this message]
2020-02-19 15:51   ` Eli Zaretskii
2021-06-14 14:26     ` Lars Ingebrigtsen

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=20200219110244.GA39672@breton.holly.idiocy.org \
    --to=alan@idiocy.org \
    --cc=39656@debbugs.gnu.org \
    --cc=ynyaaa@gmail.com \
    /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).