From: Jean Louis <bugs@gnu.support>
To: Eli Zaretskii <eliz@gnu.org>
Cc: help-gnu-emacs@gnu.org
Subject: Re: Visual font looping setup
Date: Sat, 21 Nov 2020 15:51:51 +0300 [thread overview]
Message-ID: <X7kNZ8Imq6WA3LqL@protected.rcdrun.com> (raw)
In-Reply-To: <83ft53yxg0.fsf@gnu.org>
* Eli Zaretskii <eliz@gnu.org> [2020-11-21 10:36]:
> > Date: Sat, 21 Nov 2020 00:20:22 +0300
> > From: Jean Louis <bugs@gnu.support>
> > Cc: help-gnu-emacs@gnu.org
> >
> > > emacs -fn FONT-NAME
> >
> > Sure it is possible to set it.
> >
> > After long time of using some fonts I can see that there is certain
> > pleasure effect to change the fonts, like relaxation. Process of
> > selecting various fonts is tedious. Imagine starting emacs with emacs
> > -fn for 30 times just to see which font is maybe better or not.
>
> If you need to do that many times, "M-x set-frame-font RET" is better.
>
> > Default font how I see it is always Courier and I wonder why Emacs
> > selects that one by default.
>
> Because that's how Emacs was programmed to work by default, if no
> other user preferences are found.
>
> > On every computer I have that font comes by default. It appears too
> > small and too tiny to be readable.
>
> The font and its default size are two different parameters. You can
> change the size without changing the font by having in your init file
> something like
>
> (set-face-attribute 'default nil :height 150)
>
> or alternatively something like
>
> (add-to-list 'default-frame-alist '(font . "..."))
>
> where the string which specifies font is constructed from what
> (face-font 'default) returns, with the pixel-size value (the number
> after "mono" in the XLFD-formatted font name) replaced by a larger
> number, as you see fit.
>
> > How could I change font only for dired mode? There is no face like
> > dired-default or similar.
>
> See buffer-face-mode.
>
> > I can see that fixed-pitch is monospace but Dired is not monospace if
> > I choose default font that is not monospace.
>
> You are well-advised not to pick variable-pitch fonts for any default
> face in any buffer or mode: they will not work well in Emacs. Where
> variable-pitch fonts are reasonable, Emacs generally uses them
> automatically (for example, when displaying Web pages in EWW). You
> can specify which variable-pitch font to use in those cases by
> customizing the variable-pitch face.
>
> > Somehow I expect to have fixed font in those modes where it is
> > necesary. Manual says fixed-pitch, I was thinking Dired would use
> > fixed-pitch settings, but it uses default font as it inherits.
>
> Don't change the default face to use a font that is not fixed-pitch,
> you will be shooting yourself in the foot.
This is so far alright for selection. Which font do you use?
(defun loop-fonts ()
(let* ((fonts (x-list-fonts "-*-*-medium-r-normal-*-*-*-*-*-*-iso10646-1" 'default (selected-frame))))
(dolist (font fonts)
(if (string-match "mono" font)
(progn
(message font)
(set-frame-font font)
(read-char font))))))
(loop-fonts)
next prev parent reply other threads:[~2020-11-21 12:51 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-20 19:26 Visual font looping setup Jean Louis
2020-11-20 20:00 ` Eli Zaretskii
2020-11-20 20:16 ` Jean Louis
2020-11-20 20:30 ` Eli Zaretskii
2020-11-20 21:20 ` Jean Louis
2020-11-21 7:35 ` Eli Zaretskii
2020-11-21 12:51 ` Jean Louis [this message]
2020-11-21 13:23 ` Eli Zaretskii
2020-11-20 21:03 ` Jean Louis
2020-11-21 7:19 ` Eli Zaretskii
2020-11-21 11:23 ` Jean Louis
2020-11-22 0:53 ` David Masterson
2020-11-22 3:42 ` 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=X7kNZ8Imq6WA3LqL@protected.rcdrun.com \
--to=bugs@gnu.support \
--cc=eliz@gnu.org \
--cc=help-gnu-emacs@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 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.