From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: =?UTF-8?Q?Cl=C3=A9ment?= Pit-Claudel Newsgroups: gmane.emacs.bugs Subject: bug#4911: mouse-face property should merge face attributes, not replace Date: Fri, 10 Apr 2020 12:26:12 -0400 Message-ID: References: <4AFC026C.4060701@googlemail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="130790"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.4.1 To: 4911@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Apr 10 18:27:12 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 1jMwUq-000XvO-Be for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 10 Apr 2020 18:27:12 +0200 Original-Received: from localhost ([::1]:36702 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jMwUp-0005ln-9o for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 10 Apr 2020 12:27:11 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:36747) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jMwUh-0005kb-M1 for bug-gnu-emacs@gnu.org; Fri, 10 Apr 2020 12:27:04 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jMwUg-000625-KW for bug-gnu-emacs@gnu.org; Fri, 10 Apr 2020 12:27:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:44391) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jMwUg-00061v-H7 for bug-gnu-emacs@gnu.org; Fri, 10 Apr 2020 12:27:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jMwUg-0004vH-E5 for bug-gnu-emacs@gnu.org; Fri, 10 Apr 2020 12:27:02 -0400 X-Loop: help-debbugs@gnu.org In-Reply-To: <4AFC026C.4060701@googlemail.com> Resent-From: =?UTF-8?Q?Cl=C3=A9ment?= Pit-Claudel Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 10 Apr 2020 16:27:02 +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.158653598118873 (code B ref 4911); Fri, 10 Apr 2020 16:27:02 +0000 Original-Received: (at 4911) by debbugs.gnu.org; 10 Apr 2020 16:26:21 +0000 Original-Received: from localhost ([127.0.0.1]:55937 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jMwU0-0004uL-VC for submit@debbugs.gnu.org; Fri, 10 Apr 2020 12:26:21 -0400 Original-Received: from mail-qt1-f173.google.com ([209.85.160.173]:42999) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jMwTz-0004u5-AI for 4911@debbugs.gnu.org; Fri, 10 Apr 2020 12:26:19 -0400 Original-Received: by mail-qt1-f173.google.com with SMTP id b10so1825276qtt.9 for <4911@debbugs.gnu.org>; Fri, 10 Apr 2020 09:26:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=to:from:subject:message-id:date:user-agent:mime-version :content-language:content-transfer-encoding; bh=ietsFT48ltmh/EgLduOrc4NL0oDeGwHJwlciNo0CAF8=; b=IeyKdRDwp06fb9fv8fLnemnqXevvWYE7bZLK0g1Y0uZCAePGnfa1okKJTzP6c0dUB6 aRqdtJ2XWM0iYl4A+jwVB6OPzvr4WPJlpRSjorVgJe4hYeFw7YFiTMn0q9EsevEQR+SQ eZmmOvnd0ng2MYx+gTtbNWZPw6ezDF2HPv3tk4rOYRV+S4AtcxHSwUY93ZfyOZ9CiJx3 Hx/KRYCUWMxp3D9TSN6B1zmNrYr95w+TwV22arJ+kmqiVnAQiJtahqDH2ulB1xx+CfwK snrPBMI9+F2fOiXSxu5P1wkXZfrI3mg0z67Y6a/gWXjIByS6ZTN2uHvOTMwxQDcIFfrc ixEg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:to:from:subject:message-id:date:user-agent :mime-version:content-language:content-transfer-encoding; bh=ietsFT48ltmh/EgLduOrc4NL0oDeGwHJwlciNo0CAF8=; b=hy3hkWcYOrEPEbG1xzq5CGz49SaYgj2PKQ/n051fcdEtYEJEEzvnDGXTYOXovMrEfi D1CdZ8QmWL2mshOK/PGFy1VSdN0WA7tsKrSUfoYw8yZQo44VAsHHeLI9cN3zs/8YqHAK PCS3vbX/qia9o77pRdANxvkUce/+1OV2kjZ6pvs8d294C6hNeROINUvdgkVLhAsQ874r CTV4wpMiKvbnXvpSnVzw+yZPKvtKf6sUSuKFAFLQAltZFJ9aSeRCizi9982s0w70WsAa +BI5C6cBjyrsxBiH7a8mJTduaG4GctGpICqY6SOUku6q7knjU7CBpdE9nybl6O6oEmzn Ulwg== X-Gm-Message-State: AGi0PuaNd6BJcZkaj9s1V2otdVEPUla+B8qFx8NCafRKeoi8BIg7lrbu n2l034HSNO85XiCcpp0uSJR6V/SM X-Google-Smtp-Source: APiQypI1Y/ej6ogsMUGNTx8SgfISmMU88b5om0PY7aRN9inJMNsunjTExbcl0KZ1TnbBxYkAcdZ08A== X-Received: by 2002:ac8:7397:: with SMTP id t23mr2500qtp.196.1586535973529; Fri, 10 Apr 2020 09:26:13 -0700 (PDT) Original-Received: from ?IPv6:2601:184:4180:66e7:c45e:9b1f:d618:e435? ([2601:184:4180:66e7:c45e:9b1f:d618:e435]) by smtp.googlemail.com with ESMTPSA id x65sm1902041qkd.78.2020.04.10.09.26.12 for <4911@debbugs.gnu.org> (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 10 Apr 2020 09:26:13 -0700 (PDT) Content-Language: en-GB X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] 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:178195 Archived-At: Lars Ingebrigtsen gnus.org> writes: > Eli Zaretskii gnu.org> writes: > >> I see no reason to change that now. The use case described in the bug >> report could be handled by using some non-color attribute for the >> mouse-face, for example. > > Seems like everybody agrees, so I'm closing this bug report. I'd like to disagree :) This is a problem I've run into in various packages and as a user, and the workaround doesn't work when there are multiple different faces applied to the text of a link. As a concrete example, consider compilation-mode, which uses different colors for the file name, the line number, the column number, and the error message. Currently, when hovering over a compilation-mode line highlights it, but also causes it to lose all of its other highlighting. Setting different mouse-face properties to match the different faces would cause the mouse-face highlighting to be only applied to part of the line. Of course, one way to go is to handle mouse-in and mouse-out events in Lisp, creating and removing overlays as needed. But that's explicitly recommended against in the ELisp manual, and it's a lot of work for not much gain. It would be great to have an option for this; maybe as an extra text property, like 'mouse-face-merge? Or maybe as a user option? Of course, if the default changed to merging, recovering the current behavior would be easy even without an extra property (it would just be a matter of making the mouse-face inherit from 'default), I think. But even without changing the default it would be nice to introduce a way to achieve that behavior. Clément.