From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#74725: 31.0.50; image-scaling-factor is ignored by create-image Date: Sun, 08 Dec 2024 08:03:47 +0200 Message-ID: <86frmyhfss.fsf@gnu.org> References: <2304cad6-884f-4528-a85e-ab9c06b80016@orange.fr> <868qsrim4a.fsf@gnu.org> <2793f551-8715-4679-8f52-b4673dd6802d@orange.fr> <86y10rh26m.fsf@gnu.org> <87plm3ghzw.fsf@yahoo.com> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="35603"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 74725@debbugs.gnu.org, da_vid@orange.fr, alan@idiocy.org To: Po Lu Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Dec 08 07:04:32 2024 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 1tKAP9-00096i-PD for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 08 Dec 2024 07:04:32 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tKAOs-0008AG-3T; Sun, 08 Dec 2024 01:04:14 -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 1tKAOi-00088E-Rt for bug-gnu-emacs@gnu.org; Sun, 08 Dec 2024 01:04:06 -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 1tKAOg-0000QA-U2 for bug-gnu-emacs@gnu.org; Sun, 08 Dec 2024 01:04:04 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=References:In-Reply-To:From:Date:To:Subject; bh=7o2qxFm3IrIgolUpSjp4cmL1phTI14vP4QgbJ4B5p0s=; b=NQP+GV66Lp/PV6rk0dk3dBef3vkMiND8fDWIFFRkJfpA0049/Iew1QQ7eguQtbZKG9PUi1mfxNHtOffq2fXfAmS1pJvhdPHIUN9JMX/ySq3nfOAhNqYhSku/kD3mTnkQd3Lx/nznC+g2utoADuJ5rU1VZyap44lgTgfTq6CnmhI5SHR0LjXpv4b8LwWyPq44aqg0AHQU2rYXu1GSqD0dAWH0/t7BnBtB48VnerCY7njsySNIRCCFSR+ExeT12SC0hc31P3wcPmCMc06STrIEwMBfWmY6AZR3KKEvFcMomINeUxniT956i4cjLdCr6vuaerBukAZfFYPOtcrYNwdeug==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tKAOg-0004Sv-Co for bug-gnu-emacs@gnu.org; Sun, 08 Dec 2024 01:04:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 08 Dec 2024 06:04:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 74725 X-GNU-PR-Package: emacs Original-Received: via spool by 74725-submit@debbugs.gnu.org id=B74725.173363783817154 (code B ref 74725); Sun, 08 Dec 2024 06:04:02 +0000 Original-Received: (at 74725) by debbugs.gnu.org; 8 Dec 2024 06:03:58 +0000 Original-Received: from localhost ([127.0.0.1]:49369 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tKAOc-0004Sb-7q for submit@debbugs.gnu.org; Sun, 08 Dec 2024 01:03:58 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:52840) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tKAOZ-0004SO-MC for 74725@debbugs.gnu.org; Sun, 08 Dec 2024 01:03:56 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tKAOS-0000O9-LS; Sun, 08 Dec 2024 01:03:48 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=7o2qxFm3IrIgolUpSjp4cmL1phTI14vP4QgbJ4B5p0s=; b=BPmZFZVD/Xmb f+l+SstmsI2vQ4bLLLnLtz78TdGT9nzZp5khKXlGDe+0IboDHmlgdSyfU5VIAWqFd8B/rREGIAD6h oHI1DK6JUB7KHlfJRF0geKCysdmIEi4G/kOoarrEAyzX1ORo3cWPfdAlctd4XwYCTrB9/L/8qwQCX jU9ccg4f14uPT7TP1c1y7U84Sl2qcm7Nt13gfWzo9AyYL2DFTOQWfeJf6xSXWgINLc5X+m9O5qpY2 GbBkgdautk8keJUNoZvlra/UgMbVX+Fc3sSqEprdu0626cQa/C/zbDorL0a4Zh01N8GZIM4ogFcvC IcKOYKrK286jeS1n8Rqx8A==; In-Reply-To: <87plm3ghzw.fsf@yahoo.com> (message from Po Lu on Sun, 08 Dec 2024 08:01:39 +0800) 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:296611 Archived-At: > From: Po Lu > Cc: David Ponce , alan@idiocy.org, 74725@debbugs.gnu.org > Date: Sun, 08 Dec 2024 08:01:39 +0800 > > Eli Zaretskii writes: > > >> author Po Lu 2024-06-03 16:34:51 +0800 > >> committer Po Lu 2024-06-03 16:36:29 +0800 > >> commit 56376585134d627f96c71b7b063ec51548d3ad3f (patch) > >> > >> Which replaced > >> > >> - (list :scale > >> - (image-compute-scaling-factor > >> - image-scaling-factor))) > >> > >> By this > >> > >> + (list :scale 'default)) > >> > >> In create-image. > >> > >> With the side effect that the image spec don't change when the scaling > >> factor changes, so the same cached image in always used. > > > > Po Lu, what were the reasons for that particular part of the commit? > > The scale applied by image-scaling-factor is liable to differ by > display How so? Please elaborate. > and computing the default scale in Lisp would result in images > being displayed with an incorrect scale in the presence of multiple > displays. How does the above changeset solve this problem, then? > Image caches must be flushed when image-scaling-factor is modified, > unless it is set to `auto' and a display's scale changes, because > image.c has no means of detecting variable modifications and so only the > latter event can be automatically detected. Please describe the issue in more detail, as I don't think I follow what you are saying here. If we need to detect changes in variables, we can use the add-variable-watcher technique, similar to what we do in frame.el with variables that need to force redisplay (but maybe I don't understand the problem you are describing). In any case, I don't think changes in image-scaling-factor are supposed to be immediately reflected on display, if that's what you have in mind. This is not the documented effect of this variable.