all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Lars Ingebrigtsen <larsi@gnus.org>
To: Robert Pluim <rpluim@gmail.com>
Cc: Jesse Sheidlower <jester@panix.com>, 51277@debbugs.gnu.org
Subject: bug#51277: 27.1; menu-set-font not loading correct font
Date: Thu, 21 Oct 2021 04:11:56 +0200	[thread overview]
Message-ID: <87ee8fktxv.fsf@gnus.org> (raw)
In-Reply-To: <87ee8f3fk0.fsf@gmail.com> (Robert Pluim's message of "Wed, 20 Oct 2021 17:02:23 +0200")

Robert Pluim <rpluim@gmail.com> writes:

> Iʼve installed the fonts in question, and I can reproduce the
> issue. What I see:
>
> - the GTK font selector lets us choose 'Operator Mono Book'
> - the resulting weight according to Pango is '330', which we map to
>   'normal' [1]

Selecting Operator Mono Light reports back a weight of 300 (which is
according to spec).

Book reports 330 (but should be 380).

Medium reports 350 (but should be 500).

Bold reports 400 (but should be 700).

So for this font, the PangoWeights returned by the Gtk selector are
totally out of whack with the spec in pango-font.h.  So I'm wondering
whether this font is just buggy.

I'm trying to compare with what other programs are displaying.  It would
be convenient to test with a program that understands fonts on the
command line, but if I say

xfce4-terminal --font "Operator Mono SSm:weight=book"

then I get something that looks very wrong indeed.  Anybody know a
program that understands these things?

> I then cavalierly hardcoded the weight we request to '200', which
> results in us asking for 'light', and then we correctly use the 'Book'
> version of the font.
>
> This means we should adjust XG_WEIGHT_TO_SYMBOL. It currently assigns
> anything in the range <100-200] to 'light', which just seems wrong. It
> all depends whether the fixed values are the start or the end of the
> range, but would it not make more sense to have 'light' be used for
> the range [300-350> which corresponds to
> [PANGO_WEIGHT_LIGHT-PANGO_WEIGHT_SEMILIGHT> ? [2]

Well,

  PANGO_WEIGHT_THIN = 100,

and

  PANGO_WEIGHT_ULTRAHEAVY = 1000

so it kinda sounds like <=, not >= is the intended semantic (which is
what Emacs does).

> [2]  Iʼll note that 'w32_to_fc_weight' uses the various FW_* constants
>      as the start of the respective range, not the end

Hm...

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





  parent reply	other threads:[~2021-10-21  2:11 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-18 22:08 bug#51277: 27.1; menu-set-font not loading correct font Jesse Sheidlower
2021-10-19 11:08 ` Eli Zaretskii
     [not found]   ` <YW64Fi5/BIFRQ0R5@panix.com>
2021-10-19 12:43     ` Eli Zaretskii
2021-10-19 13:08       ` Jesse Sheidlower
2021-10-19 15:58         ` Eli Zaretskii
2021-10-19 16:47           ` Jesse Sheidlower
2021-10-19 17:29             ` Eli Zaretskii
2021-10-19 18:08               ` Jesse Sheidlower
2021-10-19 18:14                 ` Eli Zaretskii
2021-10-19 18:17                   ` Jesse Sheidlower
2021-10-20  8:50                     ` Robert Pluim
2021-10-20 11:30                       ` Jesse Sheidlower
2021-10-20 12:36                         ` Eli Zaretskii
2021-10-20 15:02                           ` Robert Pluim
2021-10-20 15:12                             ` Lars Ingebrigtsen
2021-10-20 15:20                               ` Robert Pluim
2021-10-20 16:22                               ` Eli Zaretskii
2021-10-21  2:13                                 ` Lars Ingebrigtsen
2021-10-21  2:11                             ` Lars Ingebrigtsen [this message]
2021-10-21  7:40                               ` Robert Pluim
2021-10-21 12:59                                 ` Lars Ingebrigtsen
2021-10-21 15:37                                   ` Robert Pluim
2021-10-22 14:27                                     ` Lars Ingebrigtsen
2021-10-20 12:31                       ` Eli Zaretskii

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87ee8fktxv.fsf@gnus.org \
    --to=larsi@gnus.org \
    --cc=51277@debbugs.gnu.org \
    --cc=jester@panix.com \
    --cc=rpluim@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 external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.