GNU bug report logs - #72485
Support 'visual-wrap-prefix-mode' in SHR/EWW

Previous Next

Package: emacs;

Reported by: Jim Porter <jporterbugs <at> gmail.com>

Date: Tue, 6 Aug 2024 03:49:02 UTC

Severity: normal

Done: Jim Porter <jporterbugs <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


Message #8 received at 72485 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Jim Porter <jporterbugs <at> gmail.com>
Cc: 72485 <at> debbugs.gnu.org
Subject: Re: bug#72485: Support 'visual-wrap-prefix-mode' in SHR/EWW
Date: Sat, 17 Aug 2024 11:55:57 +0300
> Date: Mon, 5 Aug 2024 20:47:52 -0700
> From: Jim Porter <jporterbugs <at> gmail.com>
> 
> This patch is an extension of bug#71605, and the first place to 
> explicitly use the new variable-pitch support for 
> 'visual-wrap-prefix-mode'. While implementing this, I found two small 
> bugs in the new 'visual-wrap-prefix-mode' code:
> 
> 1. When setting the min-width for the first line prefix, we should use 
> 'add-display-text-property' so as not to clobber other display properties.
> 
> 2. My attempts to be "helpful" by special-casing wrap-prefixes of all 
> spaces ended up just interfering with more complex cases (like SHR), so 
> I removed it. The code is now simpler (one fewer condition) and just 
> works more smoothly overall.
> 
> There's one limitation to this patch though: since SHR uses absolute 
> pixel-widths for indenting internally, things can look mis-indented if 
> you scale the text in the buffer. However, SHR has exactly the same 
> issue when *not* using 'visual-wrap-prefix-mode', so it's really just a 
> more-general bug in SHR. (It'd be nice to fix that, but I'd have to get 
> a better understanding of how indentation and <table> elements interact.)

Thanks.  This lacks a NEWS entry, but other than that, feel fee to
install on master when ready.




This bug report was last modified 335 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.