[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#39115: 26.3; eww consecutive links look like one link with mouse-ove
From: |
Stephen Berman |
Subject: |
bug#39115: 26.3; eww consecutive links look like one link with mouse-over |
Date: |
Wed, 22 Jan 2020 20:15:10 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
On Wed, 22 Jan 2020 18:31:21 +0200 Eli Zaretskii <eliz@gnu.org> wrote:
>> From: Lars Ingebrigtsen <larsi@gnus.org>
>> Date: Wed, 22 Jan 2020 16:16:05 +0100
>> Cc: 39115@debbugs.gnu.org
>>
>> I don't know how to fix it, though. Is there a way to make two
>> consecutive mouse-face regions not light up at the same time when the
>> mouse pointer is over a part of one of the regions?
>
> Not without changes to C-level code, no. It currently traverses the
> glyphs looking for the first one that doesn't have the mouse-face, so
> if two stretches of text one after the other have that face, it won't
> notice.
That appears to be so only if the respective face values of the
mouse-face properties have the same name; if the face names are
different, even if one inherits from the other so they are visually
indistinguishable, then each propertized string gets highlighted
independently when the mouse pointer hovers over it, e.g. here:
(insert (propertize "one" 'mouse-face 'highlight)
(propertize "two" 'mouse-face 'header-line-highlight)
(propertize "three" 'mouse-face 'highlight) ".")
I don't know if it's easy to make e.g. buttons take advantage of this so
you can have consecutive buttons or links with independent mouse
highlighting.
Steve Berman
bug#39115: 26.3; eww consecutive links look like one link with mouse-over, Eli Zaretskii, 2020/01/22
bug#39115: 26.3; eww consecutive links look like one link with mouse-over, Eli Zaretskii, 2020/01/23
bug#39115: 26.3; eww consecutive links look like one link with mouse-over, Lars Ingebrigtsen, 2020/01/23
bug#39115: 26.3; eww consecutive links look like one link with mouse-over, ynyaaa, 2020/01/22