unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Jesse Sheidlower <jester@panix.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 51277@debbugs.gnu.org
Subject: bug#51277: 27.1; menu-set-font not loading correct font
Date: Tue, 19 Oct 2021 09:08:20 -0400	[thread overview]
Message-ID: <YW7DRKnyxUA28Txb@panix.com> (raw)
In-Reply-To: <83a6j5chh9.fsf@gnu.org>

On Tue, Oct 19, 2021 at 03:43:46PM +0300, Eli Zaretskii wrote:
> [Please use Reply All to reply, so that the discussion gets recorded
> on the bug tracker.]

Sorry about that.

> > Date: Tue, 19 Oct 2021 08:20:38 -0400
> > From: Jesse Sheidlower <jester@panix.com>
> > 
> > > What happens if you invoke Emacs like this:
> > > 
> > >   emacs -Q -fn 'Operator Mono SSm'
> > > 
> > > and then type this:
> > > 
> > >   M-x (set-face-attribute 'default nil :weight 'book) RET
> > > 
> > > Does that produce the expected effect?
> > 
> > Depends on what I should expect!
> 
> You should expect to see the "book" variant of the font.  Isn't that
> what you wanted?

Yes, and forgive me for a poor attempt at humor--I was joking about
whether I should expect it to be broken in the same way the original
was.

> > At the first command, Emacs starts with the bold variant; running the second command returns '[No match]', and we stay in the bold variant.
> 
> Sorry, I meant to say "M-:" instead of "M-x".  It was a typo.

OK, in this case, yes, it produces the, um, desired effect: Emacs
displays with the "Book", rather than the "Bold", version of that font.

> > > Sounds like some problem with that font.  Does this work correctly
> > > with other fonts that have the "book" variant?
> > 
> > No, it doesn't, but the only other font I have with a "book" variant happens to be from the same foundry. Hoefler Decimal Book in fact opens the file for Decimal-XBlack, even though there is a file for Decimal-Book.
> > 
> > I did ask someone at Hoefler Type Foundry about this, and they said they weren't aware of anything that could be causing it.
> 
> Then I suggest to try with some other fonts.

Yes, it works correctly with certain other fonts. For example, DejaVu
Sans Mono Book is correctly displayed by menu-set-font and correctly
loaded by Emacs.

I do note that the filename of the "Book" variant of DejaVu Sans Mono
does not contain the word "Book"; the filename is simply DejaVuSans.ttf.
I don't know if that's relevant.

> > I don't know how Emacs does this under the hood
> 
> No one does, unfortunately.
> 
> > but the fact that menu-set-font does correctly display all the variants with their correct names, but then loads something different, suggested that there might be a problem with Emacs (which is why I filed a bug report, instead of just assuming that I'm the one fucking something up).
> 
> No, that doesn't necessarily mean anything.  the font selection dialog
> is something implemented in GTK, I believe, and it just shows the
> fonts that GTK knows about.  When Emacs tries to use that font, it
> could find some problems with it, and that could lead to what you see.

Huh, OK.

Given that the recipe "emacs -Q -fn 'Operator Mono SSm'" followed by
"M-: (set-face-attribute 'default nil :weight 'book) RET" does produce
the desired result, does that tell us anything useful about what's going
on, to either fix Emacs or to communicate something with Hoefler about
fixing their font?

Thank you.





  reply	other threads:[~2021-10-19 13:08 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 [this message]
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
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

  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=YW7DRKnyxUA28Txb@panix.com \
    --to=jester@panix.com \
    --cc=51277@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    /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).