[Top][All Lists]

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

Re: Weird problem with inital frame sizing

From: Stefan Monnier
Subject: Re: Weird problem with inital frame sizing
Date: Thu, 13 Sep 2018 21:14:23 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

>> >>       (set-face-attribute 'default nil
>> >>                           :family "DejaVu Sans Mono" :height 140)
>> I'd recommend you move away from set-face-attribute.
> What's the reason for that?

It's a low-level tool that's designed to modify the face for a particular
frame, and not some user-level preference.

>>     (face-spec-set 'default
>>                    '((((type x)) :family "DejaVu Sans Mono" :height 140)
>>                      (((type ns)) :family "Monaco" :height 100)
>>                      (t :family :height 120)))
> Why is this preferable?

Because it lets you set your face-preferences before knowing whether
they will apply to a frame under the X11 GUI, or under a tty, or ...

This started being important when we added the multi-tty support, so the
same Emacs session can have both GUI frames and tty frames (where some
tty frames offer 8 colors, other 256 color, others no colors at all),
but the problem existed before already since previous Emacsen could also
have several GUI frames on different X server, some limited to
a monochrome display, and others not.

> And what does it have to do with the overall problem I'm having?

Nothing directly.  You just pulled on one of the loose threads ;-)


reply via email to

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