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

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

Re: How to get the actual face attribute?


From: Stefan Monnier
Subject: Re: How to get the actual face attribute?
Date: Mon, 22 Jun 2020 17:05:08 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

> How should I recompute the text scale? Currently I calculate it from
>
> (expt text-scale-mode-step text-scale-mode-amount)
>
> Which is what text-scale-mode uses. (Face remap is hard to calculate so
> I thought I can just support text-scale-mode.)

You shouldn't look at `text-scale-*` at all and instead ask the display
code which font it will use.

[ But note that there's the issue of *computing* and then there's the
  issue of *re*computing (i.e. how to detect when it needs to be
  refreshed and how to make sure it is refreshed then).  ]


-- Stefan




reply via email to

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