GNU bug report logs -
#78621
Pixelwise display specified spaces less precise than min-width
Previous Next
Reported by: Ship Mints <shipmints <at> gmail.com>
Date: Wed, 28 May 2025 19:46:01 UTC
Severity: normal
Tags: notabug
Done: Ship Mints <shipmints <at> gmail.com>
Bug is archived. No further changes may be made.
Full log
Message #69 received at 78621 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
On Fri, May 30, 2025 at 4:01 PM Jim Porter <jporterbugs <at> gmail.com> wrote:
> On 5/29/2025 9:39 PM, Eli Zaretskii wrote:
> > If the string's text is already in a buffer, we have
> > buffer-text-pixel-size and window-text-pixel-size for that purpose.
> > If the text is not in any buffer, then string-pixel-width should do
> > the job, and do it well. In particular, it strives to turn on/off all
> > the features that affect display as they are in the original buffer
> > (which can be passed to it as an optional argument), and applies all
> > the buffer-local settings that could matter. This includes face
> > remapping (which is how text-scaling is implemented).
> >
> > So I still don't understand the nature of the problem.
>
> The problem was simply that the original script to reproduce the issue
> didn't pass the optional buffer argument to 'string-pixel-width', so the
> relevant buffer-local settings (face remapping) weren't used. Instead,
> the original script tried to approximate the remapping using its own
> calculations which weren't quite the same as the display engine.
>
Indeed. To be fair, I was trying to make this work for Emacs < 31 but I
won't bother anymore. The new features and all the bug fixes in vtable (a
lot of them), will be Emacs 31, IMO.
[Message part 2 (text/html, inline)]
This bug report was last modified 50 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.