bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#38699: `text-scale-increase', `menu-set-font', and sexps


From: Eduardo Ochs
Subject: bug#38699: `text-scale-increase', `menu-set-font', and sexps
Date: Tue, 24 Dec 2019 15:36:02 -0300

Hi all,

Let me take Dan Jacobson's proposal one step further. I changed the
subject of the thread, so here is a link to his message:

  https://lists.gnu.org/archive/html/bug-gnu-emacs/2019-12/msg00897.html

I use a laptop with a screen resolution that is low compared to modern
standards - 1280x800 - and because of that I prefer to choose my Emacs
fonts by hand from the ones listed by:

  xlsfonts | grep -v ^- | sort | uniq

When I want to change to another font I usually run `M-x font', that
displays a temporary buffer with the sexps below (plus some cruft):

  (set-frame-font "5x7")
  (set-frame-font "fixed")
  (set-frame-font "6x13")
  (set-frame-font "9x15")
  (set-frame-font "10x20")
  (set-frame-font "Monospace 7")
  (set-frame-font "Monospace 9")
  (set-frame-font "Monospace 10")
  (set-frame-font "Monospace 11")
  (set-frame-font "Monospace 12")
  (set-frame-font "Monospace 22")

and I choose a font, or try the fonts, from there by typing `M-e' on a
sexp; my `M-e' is roughly equivalent `C-e C-x C-e'.

I spent about one hour playing with the functions in
lisp/face-remap.el - `text-scale-increase' and friends - a few days
ago, but I didn't get very far...

Please, please, PLEASE, make them more hacker-friendly! AFAICT the
current comments in lisp/face-remap.el don't even say how we can play
with `face-remapping-alist' in low-level ways...

By the way, I just played a bit with the source code of
`menu-set-font' at

  (describe-function 'menu-set-font)

using this,

  (fboundp     'x-select-font)
  (setq myfont (x-select-font))
  (setq myfont (mouse-select-font))
  myfont

and I realized that I don't know how to convert the value of myfont -
a #<font-spec ...> thing - into something that has a read-able syntax.
Hints very welcome, and sorry if this is something that everybody is
supposed to know =).

  Cheers & thanks in advance,
    Eduardo Ochs
    http://angg.twu.net/#eev
    http://angg.twu.net/emacsconf2019.html
    http://angg.twu.net/e/emacs.e.html#menu-set-font
    http://angg.twu.net/e/emacs.e.html#text-scale-increase


On Sat, 21 Dec 2019 at 21:44, 積丹尼 Dan Jacobson <jidanni@jidanni.org> wrote:
>
> >>>>> "EZ" == Eli Zaretskii <eliz@gnu.org> writes:
>
> EZ> There are: "C-x C-+" and "C-x C--".  In Emacs 27, there's also
> EZ> C-wheel-up and C-wheel-down.
>
> OK very good.
> Problem is: User uses it. Says "Ah, now I've got it perfect."
> But there is no additional command to spit out some lisp that he can
> paste in his .emacs file to make his changes permanent to the next
> session.
>
> No consideration is made that the user might want to save his changes.





reply via email to

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