GNU bug report logs - #35797
26.2; Adaptive Wrap does not respect Whitespace Mode faces

Previous Next

Package: emacs;

Reported by: Andrew T <summerfallsaway <at> gmail.com>

Date: Sun, 19 May 2019 06:06:01 UTC

Severity: minor

Found in version 26.2

Full log


View this message in rfc822 format

From: Eli Zaretskii <eliz <at> gnu.org>
To: Stephen Berman <stephen.berman <at> gmx.net>
Cc: 35797 <at> debbugs.gnu.org, summerfallsaway <at> gmail.com
Subject: bug#35797: 26.2; Adaptive Wrap does not respect Whitespace Mode faces
Date: Wed, 22 May 2019 09:04:03 +0300
> From: Stephen Berman <stephen.berman <at> gmx.net>
> Date: Sun, 19 May 2019 23:50:59 +0200
> Cc: 35797 <at> debbugs.gnu.org
> 
> On Sat, 18 May 2019 20:18:54 -0700 Andrew T <summerfallsaway <at> gmail.com> wrote:
> 
> > Appears to be similar to bug #15155: "24.3; wrap-prefix in adaptive-
> > wrap-prefix-mode with variable-pitch has wrong face"
> 
> That bug was fixed, but the fix does not prevent your problem, so it
> seems to be a different issue.

Yes, I think it's a different issue.

> >   emacs -Q
> >   M-x package-install RET adaptive-wrap RET
> >   M-x adaptive-wrap-prefix-mode RET
> >   M-x whitespace-mode RET
> >
> > ...Then write a long indented line so that it will wrap, and see see
> > how the wrap prefix is a different color from the default whitespace
> > display characters.
> >
> > I'll also include some screenshots here:
> > <https://imgur.com/a/znbU0s3>
> 
> Whitespace mode displays dots where there are spaces by altering the
> buffer's display table.  This also affects the spaces added by
> adaptive-wrap-prefix-mode, but as you have seen, those spaces are not
> affected by customizing whitespace-mode faces.  I suspect this has to do
> with how wrap-prefix is implemented in the display engine and may not be
> easy to fix.

I don't think there's anything special about wrap-prefix
implementation: it just acts as if a display string was specified at
the proper buffer location.

I think the problem here is entirely different: both the
whitespace-space face used for the space characters and the
whitespace-line face used for the wrapped line specify background
colors.  When we merge these faces, the background of one of them must
win.  You can see that if you avoid specifying the background color
for the whitespace-line face, the whitespace in the wrap-prefix has
the expected face.

So I don't think there's a problem here.  Emacs behaves as expected.




This bug report was last modified 6 years and 24 days ago.

Previous Next


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