From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Alan Third Newsgroups: gmane.emacs.bugs Subject: bug#67794: 30.0.50; mouse-face is not respected on SVG images Date: Mon, 18 Dec 2023 11:42:21 +0000 Message-ID: References: <83a5qers00.fsf@gnu.org> <87zfye11z3.fsf@ledu-giraud.fr> <838r5yroyp.fsf@gnu.org> <87v8920xlb.fsf@ledu-giraud.fr> <835y12rle4.fsf@gnu.org> <87bkatgnj6.fsf@ledu-giraud.fr> <83plz9qgsb.fsf@gnu.org> <877clh868o.fsf@ledu-giraud.fr> <83jzphqeto.fsf@gnu.org> <87frzzai4h.fsf@ledu-giraud.fr> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="35462"; mail-complaints-to="usenet@ciao.gmane.io" Cc: gerd.moellmann@gmail.com, 67794@debbugs.gnu.org, Eli Zaretskii To: Manuel Giraud Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Dec 18 12:43:19 2023 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 1rFC1m-00092A-OY for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 18 Dec 2023 12:43:18 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rFC1Z-0006oY-U0; Mon, 18 Dec 2023 06:43:05 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rFC1U-0006k4-PV for bug-gnu-emacs@gnu.org; Mon, 18 Dec 2023 06:43:01 -0500 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rFC1U-0005YJ-Fp for bug-gnu-emacs@gnu.org; Mon, 18 Dec 2023 06:43:00 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rFC1V-00016f-Li for bug-gnu-emacs@gnu.org; Mon, 18 Dec 2023 06:43:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Alan Third Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 18 Dec 2023 11:43:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 67794 X-GNU-PR-Package: emacs Original-Received: via spool by 67794-submit@debbugs.gnu.org id=B67794.17028997524186 (code B ref 67794); Mon, 18 Dec 2023 11:43:01 +0000 Original-Received: (at 67794) by debbugs.gnu.org; 18 Dec 2023 11:42:32 +0000 Original-Received: from localhost ([127.0.0.1]:59533 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rFC11-00015S-Nh for submit@debbugs.gnu.org; Mon, 18 Dec 2023 06:42:32 -0500 Original-Received: from dane.soverin.net ([185.233.34.150]:54325) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rFC10-000155-AW for 67794@debbugs.gnu.org; Mon, 18 Dec 2023 06:42:31 -0500 Original-Received: from smtp.soverin.net (c04smtp-lb01.int.sover.in [10.10.4.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by dane.soverin.net (Postfix) with ESMTPS id 4Styby4Znyz6l; Mon, 18 Dec 2023 11:42:22 +0000 (UTC) Original-Received: from smtp.soverin.net (smtp.soverin.net [10.10.4.100]) by soverin.net (Postfix) with ESMTPSA id 4Styby1wC2zF0; Mon, 18 Dec 2023 11:42:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=idiocy.org; s=soverin; t=1702899742; bh=W2teqJ6CQ3gapfOLtt0goAZ6Z2C3hnrpwpNcj5p/Bpk=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=ppdPnmjbNbM4BkwOQ74fD6s+zhEcPs3juhtKSJsL+q4hrrmxI6lzvT5sfrSB3col8 UmCL3erTSq2xT63EIpajG7Z4f5tguTttoTLEPPXwP1KIw7C/wdLrY1JCxROiPHkz43 OoyiaFCfNkBEckL9cTHoJzDYPWh3AUJzoH1ES1WrJDmSKfcpZnAOyc9GhRgiGz7xDU Z1TuoU3M6ZaLawnqg2GG+GOWeRYDdsy0cQEj/WLJ78aqdgv0Q4v/CNvFsRj1Bjyl9E 0SSp/mvPjwusVWFs/y5nzAszQ2k63T1uIq8jofysCg17zYPxsHofiOw5vNdhF+goiP n4NF7lZ2wDTFw== Original-Received: from alan by faroe.holly.idiocy.org with local (Exim 4.96) (envelope-from ) id 1rFC0r-000G0a-2N; Mon, 18 Dec 2023 11:42:21 +0000 Mail-Followup-To: Alan Third , Manuel Giraud , Eli Zaretskii , gerd.moellmann@gmail.com, 67794@debbugs.gnu.org Content-Disposition: inline In-Reply-To: <87frzzai4h.fsf@ledu-giraud.fr> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:276458 Archived-At: On Mon, Dec 18, 2023 at 12:02:22PM +0100, Manuel Giraud via Bug reports for GNU Emacs, the Swiss army knife of text editors wrote: > + /* Alter the spec a bit to have a different hash for the > + image cache. */ > + ptrdiff_t id; > + Lisp_Object spec = Fcopy_sequence (s->img->spec); > + spec = nconc2 (spec, list2 (intern (":highlight"), Qt)); > + id = lookup_image (f, spec, hlinfo->mouse_face_face_id); > + s->img = IMAGE_FROM_ID (f, id); You shouldn't have to change the image spec as the image cache differentiates by colour too. So if the mouse face has the same colours as the default face it will use the same image, but if they're different it will create a new image. If that's not happening then there must be a bug somewhere. > It does something on the an image glyph when it is hover but the image > is completely messed up. I have stepped this code down to > svg_load_image but I do not understand what went wrong. Any ideas? The code looks OK to me. In what way is the image messed up? I'm not sure how to test mouse face on my machine, is there a built-in theme that uses it? -- Alan Third