From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.bugs Subject: bug#4911: mouse-face property should merge face attributes, not replace Date: Sun, 26 Apr 2020 10:22:09 -0700 (PDT) Message-ID: References: <8452d0c8-afc3-bdb8-2c88-f66dc770c3c4@gmail.com> <0955d0dd-c4fe-4feb-b68b-0ed212ccf291@default> <35268628-9ef1-8dd2-ab93-05ca1cae06be@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="34896"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Lars Ingebrigtsen To: =?UTF-8?Q?Cl=C3=A9ment?= Pit-Claudel , 4911@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Apr 26 19:25:15 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jSl1k-0008w1-UK for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 26 Apr 2020 19:25:13 +0200 Original-Received: from localhost ([::1]:39564 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jSl1j-00037v-UW for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 26 Apr 2020 13:25:11 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:57784) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jSl1b-00035Y-1c for bug-gnu-emacs@gnu.org; Sun, 26 Apr 2020 13:25:03 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.90_1) (envelope-from ) id 1jSl1a-0004fd-DI for bug-gnu-emacs@gnu.org; Sun, 26 Apr 2020 13:25:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:51506) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jSl1Z-0004fY-W0 for bug-gnu-emacs@gnu.org; Sun, 26 Apr 2020 13:25:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jSl1Z-0006Q3-Si for bug-gnu-emacs@gnu.org; Sun, 26 Apr 2020 13:25:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Drew Adams Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 26 Apr 2020 17:25:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 4911 X-GNU-PR-Package: emacs Original-Received: via spool by 4911-submit@debbugs.gnu.org id=B4911.158792186024620 (code B ref 4911); Sun, 26 Apr 2020 17:25:01 +0000 Original-Received: (at 4911) by debbugs.gnu.org; 26 Apr 2020 17:24:20 +0000 Original-Received: from localhost ([127.0.0.1]:34819 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jSl0t-0006P2-Jn for submit@debbugs.gnu.org; Sun, 26 Apr 2020 13:24:19 -0400 Original-Received: from userp2130.oracle.com ([156.151.31.86]:50408) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jSl0r-0006Op-PO for 4911@debbugs.gnu.org; Sun, 26 Apr 2020 13:24:18 -0400 Original-Received: from pps.filterd (userp2130.oracle.com [127.0.0.1]) by userp2130.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 03QHN1IO173276; Sun, 26 Apr 2020 17:24:11 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=mime-version : message-id : date : from : sender : to : cc : subject : references : in-reply-to : content-type : content-transfer-encoding; s=corp-2020-01-29; bh=cy5gEnU9mtjUASEyXQpuCrMFQ8ih7f1Rw5H4cJatfYA=; b=yklTsjtqNkI9T8XeZlp0L6cjW11gwcwEMSBX5tdDIbSerEwS4qTIeJuHl45eN+Etm/6V Gw4fWOckSNR8pq1qXLLAuvaDiTXmTk0r0J8xl/rNPORlXqH9bpZuWNebG0TibdxdDrhg BmBlLn5pFWRRIZZg6+uN+BNPhLDiBLT7SUFp/5BcFGP9ZZk1hXyli6mlHXdlW+9OgHed 9ZjK5xMg34ngNDIHzdl9fg/fWeRIQwplyzDLF5AtHxb8euMHJ2QHVeBNhyMEKzXmX2O+ nMVd6yPXKGUQnxoo+kxtTFNmIow7mLBKar9hWGD+xiKBNuZWTiaXSpBUu4txKmNUA6yl cg== Original-Received: from aserp3030.oracle.com (aserp3030.oracle.com [141.146.126.71]) by userp2130.oracle.com with ESMTP id 30mcmquegp-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sun, 26 Apr 2020 17:24:11 +0000 Original-Received: from pps.filterd (aserp3030.oracle.com [127.0.0.1]) by aserp3030.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 03QHLqNL003102; Sun, 26 Apr 2020 17:22:11 GMT Original-Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by aserp3030.oracle.com with ESMTP id 30mxrnys0a-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sun, 26 Apr 2020 17:22:11 +0000 Original-Received: from abhmp0015.oracle.com (abhmp0015.oracle.com [141.146.116.21]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id 03QHMAIF007042; Sun, 26 Apr 2020 17:22:10 GMT In-Reply-To: <35268628-9ef1-8dd2-ab93-05ca1cae06be@gmail.com> X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 16.0.4993.0 (x86)] X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9603 signatures=668686 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 mlxscore=0 phishscore=0 suspectscore=0 mlxlogscore=999 malwarescore=0 bulkscore=0 spamscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2003020000 definitions=main-2004260158 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9603 signatures=668686 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 phishscore=0 spamscore=0 clxscore=1015 priorityscore=1501 suspectscore=0 impostorscore=0 adultscore=0 malwarescore=0 bulkscore=0 lowpriorityscore=0 mlxlogscore=999 mlxscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2003020000 definitions=main-2004260158 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Received-From: 209.51.188.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:179094 Archived-At: > >> But to some extent it makes sense, since that's how links behave on > >> the web (merging faces), so it's hart to fault users for having the > >> same expectation in Emacs. > > > > Really? A mouseover action over a link in a web browser > > doesn't change the link appearance, by default. >=20 > Most websites do, I think (I just checked Google, the New York Times, > and gnu.org), but you're right that the default style sheet doesn't > include a face change.. I don't think I see that on nytimes.com or google.com. I do see a mouseover "face" change on both, on inline links in text, but what I see is all or nothing. For NYT, for example, a link is shown underlined, and mouseover removes the underline - IOW, two different "faces", and mouseover uses the same face for all of the link text. I don't see examples of link text that has (the equivalent of) multiple faces, so I can't see what happens with mouseover on such links. Do you have an example of a link on some such site, where the link text uses multiple "faces" and mouseover preserves those faces while perhaps adding or removing some "face attributes" across all of them? > > The one case where I might want something like what > > you propose (or maybe exactly like it, depending on > > just what it is), would be when mouseover essentially > > underlines (or overlines or otherwise doesn't > > obscure) the text. In that case, I can see a value > > to continuing to show the foreground colors of the > > underlined text - if that's realizable. >=20 > Yes yes yes! We are in violent agreement here :) I thought so. But probably "more or less", and not violently. ;-) > > > Why is that helpful? > > > > It can perhaps be easier to see the extent of the > > link? Easier to notice the link? Dunno. >=20 > With the change of background, it's actually quite readable. I think it can depend on the background, and how it interacts with the default/frame face and with the faces used in the link text. You may be right that in general most mouseover backgrounds would not be problematic; dunno. > > Anyway, I agree that it's helpful to keep face > > highlighting is some cases - in particular when, > > say, an entire line of code is highlighted. > > The effect of, say, `hl-line-mode' is what I > > prefer in a case like that - and yes, that's > > merging. Similarly, for the region. I think > > it's less likely to be useful for links (i.e., > > for mouseover). But I could be wrong. >=20 > Yup, I feel just the same about hl-line-mode and the region. I find > the effect of foreground colors being reset when the background changes > due to hovering quite distracting, but I agree there's personal taste > involved. The question is really about links (mouseover). > > It's fine to provide a way (some other way - e.g. > > via a variable or another property or whatever) > > to have mouseover merge a face instead of imposing > > it. >=20 > Yes, I think all your suggestions are good approaches. It would be good to try a patch, in some context where there is already lots of use of different faces. One such context is the use of font-lock faces, but in most such uses there isn't much predefined use of links. > Thanks again for your input, And thank you for the suggestion/bug report, and attention to providing the new feature only as an option/alternative. (BTW, why doesn't the bug # appear in the subject line?)