From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 08 06:17:21 2022 Received: (at submit) by debbugs.gnu.org; 8 Dec 2022 11:17:21 +0000 Received: from localhost ([127.0.0.1]:56135 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3Eu0-0002oK-JD for submit@debbugs.gnu.org; Thu, 08 Dec 2022 06:17:20 -0500 Received: from lists.gnu.org ([209.51.188.17]:46568) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3Etv-0002oC-4o for submit@debbugs.gnu.org; Thu, 08 Dec 2022 06:17:18 -0500 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 1p3Etu-0007ld-KC for bug-gnu-emacs@gnu.org; Thu, 08 Dec 2022 06:17:14 -0500 Received: from mout02.posteo.de ([185.67.36.66]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p3Ets-0005XH-Kl for bug-gnu-emacs@gnu.org; Thu, 08 Dec 2022 06:17:14 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id 9B20B240107 for ; Thu, 8 Dec 2022 12:17:09 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1670498229; bh=zYKKRoKZgtD33I2yUCGZTdAkkYmBrjKJsDc2dUgvFUI=; h=From:To:Subject:Date:From; b=CtNvXRFVmm4xWrsp4nGZvuI0ojiaClHmCJHtZ5gqvWj/2SU6bOYg/nNoWoGJQri+h Q3TH4e2ruFGb5GXSU4vOIjaViGJbYMKe8R2bA7W+FlUgZKxomVWKWN1uMQihNIz9UX cI2mICtlV2YB4qc4pzTgagkdMT+QX1tHtXSFojwm+KlYVGnM1I6qeEArgH81tgaB0V TWarWBHkgRncJSMlcObbRu6vTf8E8pm8ycoNh8hlWdU/6oeK6LsTAQl1JiBcTWB9Pc WVk33Di9d4GWDLT0bb3W3u3kWowFu4H9oiSlNuThzwDSirQSbwwFFiHt44Ww9dxygR +UpHklX3D5+tw== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4NSWnt5pM3z6tsZ for ; Thu, 8 Dec 2022 12:17:04 +0100 (CET) From: Ihor Radchenko To: bug-gnu-emacs@gnu.org Subject: 30.0.50; Image overlay is not updated until the cursor moves to the overlay Date: Thu, 08 Dec 2022 11:17:01 +0000 Message-ID: <87zgby87rm.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=185.67.36.66; envelope-from=yantar92@posteo.net; helo=mout02.posteo.de X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) Hi, Consider the following 1. emacs -Q 2. M-: (require 'ob-shell) 3. Open the following org file #+begin_src sh :results graphics file :file /tmp/colour.png convert -size 300x300 xc:#002b36 /tmp/colour.png #+end_src 4. Move point to the source block and C-c C-c yes 5. C-c C-x C-v 6. Observe the 300x300 image appearing 7. Edit the source code to 500x300 8. C-c C-c yes 9. Image disappears 10. C-c C-x C-v 11. Observe what appears to be the old 300x300 image 12. Move the cursor to the image 13. Observe the correct 500x300 appearing while the cursor is on it!! If I step through the code inserting the image overlays, the wrong (not updated) overlay appears in `org-display-inline-images': (let ((ov (make-overlay (org-element-property :begin link) (progn (goto-char (org-element-property :end link)) (skip-chars-backward " \t") (point))))) (overlay-put ov 'display image) ;; <- the updated image is correctly displayed (overlay-put ov 'face 'default) ;; <- un-updated image is displayed until we move cursor to the overlay (overlay-put ov 'org-image-overlay t) In GNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.35, cairo version 1.17.6) of 2022-12-07 built on localhost Repository revision: f0e118d3f676afe39df29663399d4bbe8f53f208 Repository branch: master Windowing system distributor 'The X.Org Foundation', version 11.0.12101004 System Description: Gentoo Linux -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 08 06:38:07 2022 Received: (at 59902) by debbugs.gnu.org; 8 Dec 2022 11:38:07 +0000 Received: from localhost ([127.0.0.1]:56242 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3FE6-0003HE-Lw for submit@debbugs.gnu.org; Thu, 08 Dec 2022 06:38:07 -0500 Received: from eggs.gnu.org ([209.51.188.92]:36660) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3FE1-0003Gg-8L for 59902@debbugs.gnu.org; Thu, 08 Dec 2022 06:38:06 -0500 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 1p3FDm-0005zX-GZ; Thu, 08 Dec 2022 06:37:55 -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=XgSalqOnx0PBUb50xIPxwhBFA7PTkpjo9Y+JKmefnVI=; b=CiSJhf6eOMRX qJgtBfVlJ8iEkJ6CMTsEljLkWcAyflU9Umw3wheMGzFEuo5QqZ1LedlXcKk6jPkg7tTOLstUjwStd OzKbi6bflZu06z+B8lpH1PmvI2ncll8sg7ImW7GWWVo+b3s1zr8ujZ3jG19DZoGpTbRmSq04ErT/F 9mH7zhuZhBuw6BdjgXbkEpMvTwQj0FXcWr6xfxW9GDxTwg/oMozP5i/GI5/8fGgzB2UpINlMrBh64 T5ALD0SqQvKFADrXCMVM1OeeweWsl3XxnWVX02qDDehAT3UMi4TnkwCgeZLAixU6IKa0DvHkR36v5 PQCvexd0vvumUE6JHTtHwQ==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p3FDg-0002D0-Ie; Thu, 08 Dec 2022 06:37:42 -0500 Date: Thu, 08 Dec 2022 13:37:30 +0200 Message-Id: <83h6y62kjp.fsf@gnu.org> From: Eli Zaretskii To: Ihor Radchenko In-Reply-To: <87zgby87rm.fsf@localhost> (message from Ihor Radchenko on Thu, 08 Dec 2022 11:17:01 +0000) Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay References: <87zgby87rm.fsf@localhost> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Ihor Radchenko > Date: Thu, 08 Dec 2022 11:17:01 +0000 > > 1. emacs -Q > 2. M-: (require 'ob-shell) > 3. Open the following org file > #+begin_src sh :results graphics file :file /tmp/colour.png > convert -size 300x300 xc:#002b36 /tmp/colour.png > #+end_src > 4. Move point to the source block and C-c C-c yes > 5. C-c C-x C-v > 6. Observe the 300x300 image appearing > 7. Edit the source code to 500x300 > 8. C-c C-c yes > 9. Image disappears > 10. C-c C-x C-v > 11. Observe what appears to be the old 300x300 image > 12. Move the cursor to the image > 13. Observe the correct 500x300 appearing while the cursor is on it!! Is the "convert" part in step 3 necessary to reproduce this? If so, it's a huge turn-off for me, because I don't have, and won't have, ImageMagick installed, or anything similar to it. So someone else will have to investigate this in that case, sorry. > If I step through the code inserting the image overlays, the wrong (not > updated) overlay appears in `org-display-inline-images': Where is this code through which you are stepping? > (let ((ov (make-overlay > (org-element-property :begin link) > (progn > (goto-char > (org-element-property :end link)) > (skip-chars-backward " \t") > (point))))) > (overlay-put ov 'display image) ;; <- the updated image is correctly displayed > (overlay-put ov 'face 'default) ;; <- un-updated image is displayed until we move cursor to the overlay And if you switch the order of the above two lines? Anyway, it is not reliable to try to deduce what happens when stepping through the code if the problem is relied to cursor motion or redisplay, because Edebug changes all of that in radical ways. Finally, a stab in the dark: the fact that the problem disappears when you move the cursor might mean that a call to 'redisplay' (or some other trigger for redisplay to know stuff has changed) is missing somewhere. From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 08 06:53:01 2022 Received: (at 59902) by debbugs.gnu.org; 8 Dec 2022 11:53:01 +0000 Received: from localhost ([127.0.0.1]:56322 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3FSX-0005wG-43 for submit@debbugs.gnu.org; Thu, 08 Dec 2022 06:53:01 -0500 Received: from mout01.posteo.de ([185.67.36.65]:44763) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3FSU-0005wA-QP for 59902@debbugs.gnu.org; Thu, 08 Dec 2022 06:52:59 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id 446EC240027 for <59902@debbugs.gnu.org>; Thu, 8 Dec 2022 12:52:53 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1670500373; bh=cBZpSRyJHAQDcravG3OOMA/0QKpQxUaDtkh3fpOb3z8=; h=From:To:Cc:Subject:Date:From; b=lFgKzUGTN2IPTDKjFOTmWRIoppCKgBgNuJk0bh7g7YyrWe77low1e3+3+QhsUqkvF CoKAs3sNZVyhic/8Zkj9li4e/nGhPHbLAJ4OGqwvcg16KUrozoxfr9lnIvCk6yphh1 jiustYtyQFs0E3SvIu349y/+/oEgTFKvzho+MV3u935b08EA/xRkTZANBy7a3D+arR sVoRSmLfMBvFzC8hHV30uctannQuCEFykaTn0oh6d6RdRLSc1S5Lbyfnrir5Fj7tb9 Of+qcNFOFI/7mSrb2TShE0W56VdrFyyC7MY2Gir1Qw1DYR5/qcdsByWkxy8EwidWJp T739kAbBIEG0A== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4NSXb833vvz6tnw; Thu, 8 Dec 2022 12:52:52 +0100 (CET) From: Ihor Radchenko To: Eli Zaretskii Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay In-Reply-To: <83h6y62kjp.fsf@gnu.org> References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> Date: Thu, 08 Dec 2022 11:52:49 +0000 Message-ID: <87ilim863y.fsf@localhost> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) --=-=-= Content-Type: text/plain Eli Zaretskii writes: >> 3. Open the following org file >> #+begin_src sh :results graphics file :file /tmp/colour.png >> convert -size 300x300 xc:#002b36 /tmp/colour.png >> #+end_src > ... > Is the "convert" part in step 3 necessary to reproduce this? If so, > it's a huge turn-off for me, because I don't have, and won't have, > ImageMagick installed, or anything similar to it. So someone else > will have to investigate this in that case, sorry. It is not. Anything generating an image of known size will do. The original report is in https://list.orgmode.org/87wn7287n2.fsf@localhost/T/#mda89a57883b92c8b48ad6c4aec9e111c131efe92 You can try the following: #+begin_src sh :results graphics file :file /tmp/colour.png true #+end_src and then change to #+begin_src sh :results graphics file :file /tmp/colour2.png true #+end_src The images are attached. >> If I step through the code inserting the image overlays, the wrong (not >> updated) overlay appears in `org-display-inline-images': > > Where is this code through which you are stepping? `org-display-inline-images' >> (let ((ov (make-overlay >> (org-element-property :begin link) >> (progn >> (goto-char >> (org-element-property :end link)) >> (skip-chars-backward " \t") >> (point))))) >> (overlay-put ov 'display image) ;; <- the updated image is correctly displayed >> (overlay-put ov 'face 'default) ;; <- un-updated image is displayed until we move cursor to the overlay > > And if you switch the order of the above two lines? Ain't helping. > Anyway, it is not reliable to try to deduce what happens when stepping > through the code if the problem is relied to cursor motion or > redisplay, because Edebug changes all of that in radical ways. I use debug-on-entry. Probably not much different though. > Finally, a stab in the dark: the fact that the problem disappears when > you move the cursor might mean that a call to 'redisplay' (or some > other trigger for redisplay to know stuff has changed) is missing > somewhere. Nope. When I move the cursor away, the erroneous image is displayed again. --=-=-= Content-Type: image/png Content-Disposition: attachment; filename=colour.png Content-Transfer-Encoding: base64 iVBORw0KGgoAAAANSUhEUgAAASwAAAEsAQMAAABDsxw2AAAABGdBTUEAALGPC/xhBQAAACBjSFJN AAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAABlBMVEUAKzb////GiCa1AAAA AWJLR0QB/wIt3gAAAAd0SU1FB+YMCAszOau2lQgAAAAiSURBVGje7cExAQAAAMKg9U9tCj+gAAAA AAAAAAAAAAB4GS20AAH/6QlrAAAAJXRFWHRkYXRlOmNyZWF0ZQAyMDIyLTEyLTA4VDExOjUxOjU3 KzAwOjAwE0fC7wAAACV0RVh0ZGF0ZTptb2RpZnkAMjAyMi0xMi0wOFQxMTo1MTo1NyswMDowMGIa elMAAAAodEVYdGRhdGU6dGltZXN0YW1wADIwMjItMTItMDhUMTE6NTE6NTcrMDA6MDA1D1uMAAAA AElFTkSuQmCC --=-=-= Content-Type: image/png Content-Disposition: attachment; filename=colour2.png Content-Transfer-Encoding: base64 iVBORw0KGgoAAAANSUhEUgAAAfQAAAEsAQMAAAAPddOLAAAABGdBTUEAALGPC/xhBQAAACBjSFJN AAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAABlBMVEUAKzb////GiCa1AAAA AWJLR0QB/wIt3gAAAAd0SU1FB+YMCAsvAWXDcMsAAAApSURBVHja7cExAQAAAMKg9U9tCy+gAAAA AAAAAAAAAAAAAAAAAAAA4GdLAAAB9wDA9AAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAyMi0xMi0wOFQx MTo0NzowMSswMDowMPTnVjYAAAAldEVYdGRhdGU6bW9kaWZ5ADIwMjItMTItMDhUMTE6NDc6MDEr MDA6MDCFuu6KAAAAKHRFWHRkYXRlOnRpbWVzdGFtcAAyMDIyLTEyLTA4VDExOjQ3OjAxKzAwOjAw 0q/PVQAAAABJRU5ErkJggg== --=-=-= Content-Type: text/plain -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 08 09:03:20 2022 Received: (at 59902) by debbugs.gnu.org; 8 Dec 2022 14:03:20 +0000 Received: from localhost ([127.0.0.1]:56963 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3HUe-0003KK-BJ for submit@debbugs.gnu.org; Thu, 08 Dec 2022 09:03:20 -0500 Received: from eggs.gnu.org ([209.51.188.92]:52150) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3HUc-0003KE-JY for 59902@debbugs.gnu.org; Thu, 08 Dec 2022 09:03:19 -0500 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 1p3HUX-0002dO-2j; Thu, 08 Dec 2022 09:03:13 -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=AZdzlCjEL4StGKKhkknzbqreYiKvauobeyTY2qZI0Gg=; b=G48r0q7nFrRQ 0PENyvSRpFIeNDDOv0dVj9qSLhSAf3tFT9N41s5p0vh6ecyAfWRg/qK5azS/aaHeX4RpdVfa5xTj4 u47CGtljQ4cAqFtK/6NmIVhv6otdB0vb6i5XMdr/gQQdcvQyzxpCvjPAhfgGGOgUOw7BITpj/Xamd 5Q6fmNIgCOfdKwnpoHhOvfmzPL5IYpiB+H20jiqPGJMUScrY2AK/O6DZmYYNFbZpLRVkR2CeTwNh3 trHxEghsDS13Fc3bGy7ZlSUVU6e6k6NxcrWeSZ27EDNAx/Sk7hVKHzeSoYQdhDjSI95iu8SNvYjhE ZVvbmPtPaJ/wlWLW+XXLkg==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p3HUW-0000y2-IF; Thu, 08 Dec 2022 09:03:12 -0500 Date: Thu, 08 Dec 2022 16:03:02 +0200 Message-Id: <83edta2dt5.fsf@gnu.org> From: Eli Zaretskii To: Ihor Radchenko In-Reply-To: <87ilim863y.fsf@localhost> (message from Ihor Radchenko on Thu, 08 Dec 2022 11:52:49 +0000) Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Ihor Radchenko > Cc: 59902@debbugs.gnu.org > Date: Thu, 08 Dec 2022 11:52:49 +0000 > > > Finally, a stab in the dark: the fact that the problem disappears when > > you move the cursor might mean that a call to 'redisplay' (or some > > other trigger for redisplay to know stuff has changed) is missing > > somewhere. > > Nope. When I move the cursor away, the erroneous image is displayed again. ?? Really? And the fact that you report this for Emacs 30, does it mean that previous versions don't behave like that and this is a recent regression? From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 08 09:10:24 2022 Received: (at 59902) by debbugs.gnu.org; 8 Dec 2022 14:10:24 +0000 Received: from localhost ([127.0.0.1]:57007 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3HbU-0003OW-HO for submit@debbugs.gnu.org; Thu, 08 Dec 2022 09:10:24 -0500 Received: from mout01.posteo.de ([185.67.36.65]:42037) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3HbS-0003OH-DA for 59902@debbugs.gnu.org; Thu, 08 Dec 2022 09:10:23 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id 5AAA624002A for <59902@debbugs.gnu.org>; Thu, 8 Dec 2022 15:10:16 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1670508616; bh=9hvE9NoTf5PX1eoXvHZdUQtAu4O9+AuXhHzs4sr9MXU=; h=From:To:Cc:Subject:Date:From; b=Pf5ZX88+1n3fgzQsOtzRH35KhfQKj+8npuRQbrhFY3OfAnN1cRnFhcjY+h2Z+vWf7 LixNBBMQSB4Il90RE1+PVupcIyCWKQC8+kOPgh5mA1Rbs/W91Zde9paQrrcuCES6F2 /Ee29dAbycjZhgLjx/YcuqaiGTmibYYr1fYu5voNm2/rYAo7YgrWdvSXUSLurcTy6Y xMM0HlIn5hRC/pLPRe7HnQJU5TuUhenkyGM/9xCqW0/qX1iqQfxxxlIEICz+l40xcr C54gyXzezZj13N/WB9v1qEFDl/EkGIOUGnv0NPY02qqRPnysOBNtMLPtoNGmRTffMx wPWdNuYp+iTgg== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4NSbdg5Lkhz9rxQ; Thu, 8 Dec 2022 15:10:14 +0100 (CET) From: Ihor Radchenko To: Eli Zaretskii Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay In-Reply-To: <83edta2dt5.fsf@gnu.org> References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83edta2dt5.fsf@gnu.org> Date: Thu, 08 Dec 2022 14:10:07 +0000 Message-ID: <87pmcu6l6o.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Eli Zaretskii writes: >> Nope. When I move the cursor away, the erroneous image is displayed again. > > ?? Really? Yup. I hope that it is reproducible on your side as well. > And the fact that you report this for Emacs 30, does it mean that > previous versions don't behave like that and this is a recent > regression? I was also able to reproduce using Emacs 28 + Org 9.6. -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 08 13:52:02 2022 Received: (at 59902) by debbugs.gnu.org; 8 Dec 2022 18:52:02 +0000 Received: from localhost ([127.0.0.1]:58421 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3M02-0002Js-6D for submit@debbugs.gnu.org; Thu, 08 Dec 2022 13:52:02 -0500 Received: from eggs.gnu.org ([209.51.188.92]:50174) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3M00-0002Je-95 for 59902@debbugs.gnu.org; Thu, 08 Dec 2022 13:52:00 -0500 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 1p3Lzu-0000S2-V4; Thu, 08 Dec 2022 13:51:54 -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=UnJeVUNMQK0y4dgot64kN2H9Lka9WugUEHfzsLjgTss=; b=rILfQicQIbFE veAPxirpeOR9JJVlDL+0VUQInrOvkhHLNriF3URZkKRVl1flTvJGvwBpxD1rA945u5jB99mB1UJy4 OOrmtF8dhJ8YuVEUCKo3+rolPQRg1N2rYhgnACC9qsHOyFJoGJjIJdfTdMaslKxZTsy1UN59ST5aX HIt+STD4kyj7htTGvRhAXRSuA9laA9mSenbv9Tu0EL6flVL7mHIkj9QAa/8l1W+TebSTsAR7pDMEc HgFX5GdukmQMkh7czf1yUlhr9u1ixvmO0GjTnRNR0L9ALt+k7W31MDadadWxCJSgUDU6u1z+RaQfO 3SHHKbSQgaHh8YW7q1Vjmw==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p3Lzu-0006p9-2L; Thu, 08 Dec 2022 13:51:54 -0500 Date: Thu, 08 Dec 2022 20:51:45 +0200 Message-Id: <83lenh20fy.fsf@gnu.org> From: Eli Zaretskii To: Ihor Radchenko In-Reply-To: <87ilim863y.fsf@localhost> (message from Ihor Radchenko on Thu, 08 Dec 2022 11:52:49 +0000) Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Ihor Radchenko > Cc: 59902@debbugs.gnu.org > Date: Thu, 08 Dec 2022 11:52:49 +0000 > > You can try the following: > > #+begin_src sh :results graphics file :file /tmp/colour.png > true > #+end_src Can you help me modify the recipe so that I won't need a 'sh' executable that is a Posix shell? I'm not familiar with the Org source blocks feature very well, so I don't know how to tweak this to use some other program. Since we are not really interested in what the program does here, it could be anything, I think. Does that have to be a program that Emacs runs? Or is that an important part of the problem? From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 08 14:18:40 2022 Received: (at 59902) by debbugs.gnu.org; 8 Dec 2022 19:18:40 +0000 Received: from localhost ([127.0.0.1]:58553 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3MPo-0002ac-AM for submit@debbugs.gnu.org; Thu, 08 Dec 2022 14:18:40 -0500 Received: from pb-smtp2.pobox.com ([64.147.108.71]:58110) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3MPd-0002aW-Gb for 59902@debbugs.gnu.org; Thu, 08 Dec 2022 14:18:39 -0500 Received: from pb-smtp2.pobox.com (unknown [127.0.0.1]) by pb-smtp2.pobox.com (Postfix) with ESMTP id 4A0F614C577; Thu, 8 Dec 2022 14:18:28 -0500 (EST) (envelope-from wtd@pobox.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed; d=pobox.com; h=date:from :to:cc:subject:message-id:mime-version:content-type; s=sasl; bh= tRa448kKrROP8kxGE5FPq3v7Em74SiElTehfCSeUjnc=; b=sj19WTQatQtx6ead u56+WM/UMQAc0A3nLXYGKJD6F9U5pEvvW6+N5yKJc5fHWHvjBgl9hAcCDEMkPlef KawCIgwXrqWm5PwczBxnZdvnMNKSHkLVFsaaPV53HyvqU1NNScdMm4kUHl+JEd/c +UBua1dijozleWDS6EfdA2sthBA= Received: from pb-smtp2.nyi.icgroup.com (unknown [127.0.0.1]) by pb-smtp2.pobox.com (Postfix) with ESMTP id 4259614C576; Thu, 8 Dec 2022 14:18:28 -0500 (EST) (envelope-from wtd@pobox.com) Received: from shell3.miskatonic.org (unknown [199.103.62.6]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by pb-smtp2.pobox.com (Postfix) with ESMTPSA id B29AC14C575; Thu, 8 Dec 2022 14:18:27 -0500 (EST) (envelope-from wtd@pobox.com) Received: by shell3.miskatonic.org (Postfix, from userid 1000) id 154551208A5; Thu, 8 Dec 2022 14:18:27 -0500 (EST) Received: from localhost (localhost [127.0.0.1]) by shell3.miskatonic.org (Postfix) with ESMTP id 0EEBA12061B; Thu, 8 Dec 2022 14:18:27 -0500 (EST) Date: Thu, 8 Dec 2022 14:18:27 -0500 (EST) From: William Denton X-X-Sender: wtd@shell3.miskatonic.org To: 59902@debbugs.gnu.org Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay Message-ID: User-Agent: Alpine 2.22 (DEB 394 2020-01-19) MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset=US-ASCII X-Pobox-Relay-ID: 17F50820-772D-11ED-9671-307A8E0A682E-56320186!pb-smtp2.pobox.com X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 59902 Cc: Eli Zaretskii , Ihor Radchenko X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) About not needing a sh executable: I don't know if this helps, but if you have R installed this will show the problem: #+begin_src R :results graphics file :file /tmp/plot.png plot(1) #+end_src C-c C-c to execute, and a small chart will be generated. Change "plot(1)" to "plot(2)" and re-execute. The file on disk will change, but not the image in the buffer. Move the pointer down to after the colon in #+RESULTS:, move it right once more to the next line, and the image will change. You can toggle back and forth by moving the pointer left and right. Bill -- William Denton https://www.miskatonic.org/ Librarian, artist and licensed private investigator. Toronto, Canada From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 08 14:28:02 2022 Received: (at 59902) by debbugs.gnu.org; 8 Dec 2022 19:28:02 +0000 Received: from localhost ([127.0.0.1]:58665 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3MYr-0002jw-LU for submit@debbugs.gnu.org; Thu, 08 Dec 2022 14:28:01 -0500 Received: from mout01.posteo.de ([185.67.36.65]:48583) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3MYp-0002jq-Ti for 59902@debbugs.gnu.org; Thu, 08 Dec 2022 14:28:00 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id 8D6CF240027 for <59902@debbugs.gnu.org>; Thu, 8 Dec 2022 20:27:53 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1670527673; bh=AJtTYnBJ+Vj7BL9aU03NBEJYe14W+yax7XYTPhSHL5w=; h=From:To:Cc:Subject:Date:From; b=UKDxXu4PcXD9t1ryW/du5+87gpYKfShXkLavus1yGmYyUzbAbHJkhIEkQY+fQ7yzJ lIZymU3PsCT7MntQbpodohq175VHoyIDWnBKTL2304dy+U2gNJP2UWZ4n6PULNfyLT NZ4PLX/yDP+idFkSpMCGfgCxjiXfxcRfP44urzvp0AtODllGPLYYSrt+x5Ls0pfccF f79lBaAJQtLT4edbu8ersTfVH9V54DQRbZw0gMlXB3Y6PxaEJ+5YM3QgNh7boB3MOf 0IWIPM5SYlCCIuBoAaT8uiWU9XBZSvMg1FtP1F5rffNa7SGqoGzSwuPDffP4FFthG+ 5SmKkccVIpDnw== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4NSkh86f77z6tm9; Thu, 8 Dec 2022 20:27:50 +0100 (CET) From: Ihor Radchenko To: Eli Zaretskii Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay In-Reply-To: <83lenh20fy.fsf@gnu.org> References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> Date: Thu, 08 Dec 2022 19:27:39 +0000 Message-ID: <87a63x7l1w.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Eli Zaretskii writes: > Can you help me modify the recipe so that I won't need a 'sh' > executable that is a Posix shell? Ok. Try the following: 1. Save colour.png to /tmp/colour.png (300x300) 2. emacs -Q 3. Open an org file with the following contents [[file:/tmp/colour.png]] 4. C-c C-x C-v 5. Observe 300x300 image displayed 6. Overwrite /tmp/colour.png with colour2.png (500x300) 7. C-c C-x C-v 8. Image disappear 9. C-c C-x C-v 10. _Old_ image appears 11. Move point to the image. Observe image being updated to the correct 500x300 size -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 08 15:24:19 2022 Received: (at 59902) by debbugs.gnu.org; 8 Dec 2022 20:24:19 +0000 Received: from localhost ([127.0.0.1]:58917 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3NRL-0003JN-C5 for submit@debbugs.gnu.org; Thu, 08 Dec 2022 15:24:19 -0500 Received: from eggs.gnu.org ([209.51.188.92]:52178) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3NRJ-0003JH-TC for 59902@debbugs.gnu.org; Thu, 08 Dec 2022 15:24:18 -0500 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 1p3NRE-0002cC-Fv; Thu, 08 Dec 2022 15:24:12 -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=Ki4hkcsy2f3oCO+BqMEebwgh6xfmkWpOanbYabUYupU=; b=oyxWDzX+wuCo TbHTOsGbGXjYZOM27SskG4qPgSxBlnNBzN0w743z+BIO9fjmg813ik29fgaeJ8wQpHvayX99i512e 6AlcjM3KZVKsnLOTyDIcEizW5LSEQbpaEanJSij7eJJg38JmsiGdFHBUqVDpqDVvGqDzi1N+SIRZa UZWrvECfCXf1MFJWEKDFUU3q51jtm5mgfJ3QdFBD+ob4YUU/2K64h6OXiGLeurRMAtUZgglEgs5x8 PLdqJf7dwun/kID55q8BNW0+4PgQIJFMqqX9vQS2t/9NUyU8Em4J/iukBtMKcGjawA6nVDUtHruHI T2Vbom/UbLkXiEBHao4MjA==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p3NRD-0007Oa-UH; Thu, 08 Dec 2022 15:24:12 -0500 Date: Thu, 08 Dec 2022 22:24:01 +0200 Message-Id: <83h6y51w66.fsf@gnu.org> From: Eli Zaretskii To: Ihor Radchenko In-Reply-To: <87a63x7l1w.fsf@localhost> (message from Ihor Radchenko on Thu, 08 Dec 2022 19:27:39 +0000) Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Ihor Radchenko > Cc: 59902@debbugs.gnu.org > Date: Thu, 08 Dec 2022 19:27:39 +0000 > > Eli Zaretskii writes: > > > Can you help me modify the recipe so that I won't need a 'sh' > > executable that is a Posix shell? > > Ok. Try the following: > > 1. Save colour.png to /tmp/colour.png (300x300) > 2. emacs -Q > 3. Open an org file with the following contents > > > > [[file:/tmp/colour.png]] > > 4. C-c C-x C-v > 5. Observe 300x300 image displayed > 6. Overwrite /tmp/colour.png with colour2.png (500x300) > 7. C-c C-x C-v > 8. Image disappear > 9. C-c C-x C-v > 10. _Old_ image appears > 11. Move point to the image. Observe image being updated to the correct > 500x300 size Thanks. I think when the image is replaced, you need to call clear-image-cache. From debbugs-submit-bounces@debbugs.gnu.org Sat Dec 10 04:57:43 2022 Received: (at 59902) by debbugs.gnu.org; 10 Dec 2022 09:57:43 +0000 Received: from localhost ([127.0.0.1]:41821 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3wc2-0003Eh-Nm for submit@debbugs.gnu.org; Sat, 10 Dec 2022 04:57:43 -0500 Received: from mout01.posteo.de ([185.67.36.65]:42457) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3wc0-0003EZ-O5 for 59902@debbugs.gnu.org; Sat, 10 Dec 2022 04:57:41 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id DCD59240027 for <59902@debbugs.gnu.org>; Sat, 10 Dec 2022 10:57:33 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1670666254; bh=msAIc5JdFqkTDbXmnxGsiEnzDv2lbqQOKqgbO1rHV1o=; h=From:To:Cc:Subject:Date:From; b=pbzeI2U+y5joPY3tRmm6moXXRQLRZfNyH3obwE4dTwF2GtKfWSd2uuXp89d/MJDE+ hDm92sfL3KmL+fT2fuus2dlOhN5c9KXHBb/LvgxGXi7iqFwD2ywFXcVRBKxNfOjNI5 bB65DSuEXFMHgDTufKL4qBj0awxfiJcUVT2GD9PHkzRTUytnCwhERZGspB68OISr94 XwXbCZfX+IWLWjVYafr94kUSg6CSGPjXTY8peMftNZ5ADJca2jMCkvFOpV2rbzQ3wk Fn8NCPq/jRsDOAlMoIJgZDzL8AumfxFY2nr5AiG7UDu3Bp4fNvq25b8VWn5pDJYTB8 z05aWHzbhwusA== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4NTjx92ykdz6tnF; Sat, 10 Dec 2022 10:57:33 +0100 (CET) From: Ihor Radchenko To: Eli Zaretskii Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay In-Reply-To: <83h6y51w66.fsf@gnu.org> References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> Date: Sat, 10 Dec 2022 09:57:33 +0000 Message-ID: <87wn6zr376.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Eli Zaretskii writes: > Thanks. I think when the image is replaced, you need to call > clear-image-cache. Sure, I can. Or even `image-flush'. However, it is not obvious at all that it should be necessary to clear image cache. The current Emacs' behaviour is unexpected and very confusing here. Ideally, Emacs should be able to judge by itself whether to update cached image in memory. -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at From debbugs-submit-bounces@debbugs.gnu.org Sat Dec 10 06:03:32 2022 Received: (at 59902) by debbugs.gnu.org; 10 Dec 2022 11:03:32 +0000 Received: from localhost ([127.0.0.1]:42131 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3xdk-000060-3W for submit@debbugs.gnu.org; Sat, 10 Dec 2022 06:03:32 -0500 Received: from eggs.gnu.org ([209.51.188.92]:35332) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3xdi-00005t-Pz for 59902@debbugs.gnu.org; Sat, 10 Dec 2022 06:03:31 -0500 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 1p3xdd-0003eh-J5; Sat, 10 Dec 2022 06:03:25 -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=uk5MZdopAIu3N97d8h+cCKvqKMs+AMs5I2yS9ykQAuo=; b=M4Y270p3z/RI EhXSqWyR55PW+lEaayQCBFFbKzd74MkyB9TqW6AZWf1qSkiQQoj4BsAx6zyWwcvmEPHsgUxpAXG2e M2x471FJ4lRSh1U5PFjiP1g03JhAXd7H3UGDrXOnWA7eV50Nj5ktXKbkKt5m7m7A/8oAHoVccqXpw iLurzVp2Scv7Th4hj6Le+BjjHk8uKNt6AgIcvcK9490m0BheA1PZETOthWmNxMHrQtuCeZxEprAav bVfr/rX2wsO5qxmBPoJDak75+CSUrgKIxwr3y7vmJuieIoN3g9soBS7iWk4NAGQ5OV3vVhrraXHxR BImHHG6Lvc0OGRiuA8a/hg==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p3xdc-0000JU-Ti; Sat, 10 Dec 2022 06:03:25 -0500 Date: Sat, 10 Dec 2022 13:03:21 +0200 Message-Id: <83bkoby0zq.fsf@gnu.org> From: Eli Zaretskii To: Ihor Radchenko In-Reply-To: <87wn6zr376.fsf@localhost> (message from Ihor Radchenko on Sat, 10 Dec 2022 09:57:33 +0000) Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Ihor Radchenko > Cc: 59902@debbugs.gnu.org > Date: Sat, 10 Dec 2022 09:57:33 +0000 > > Eli Zaretskii writes: > > > Thanks. I think when the image is replaced, you need to call > > clear-image-cache. > > Sure, I can. Or even `image-flush'. > However, it is not obvious at all that it should be necessary to clear > image cache. > > The current Emacs' behaviour is unexpected and very confusing here. > Ideally, Emacs should be able to judge by itself whether to update > cached image in memory. You want Emacs to hit the disk and process the file on each redisplay cycle? From debbugs-submit-bounces@debbugs.gnu.org Sat Dec 10 06:10:37 2022 Received: (at 59902) by debbugs.gnu.org; 10 Dec 2022 11:10:37 +0000 Received: from localhost ([127.0.0.1]:42165 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3xkV-0000BG-8D for submit@debbugs.gnu.org; Sat, 10 Dec 2022 06:10:37 -0500 Received: from mout01.posteo.de ([185.67.36.65]:41353) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3xkS-0000B3-Us for 59902@debbugs.gnu.org; Sat, 10 Dec 2022 06:10:29 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id 431D1240026 for <59902@debbugs.gnu.org>; Sat, 10 Dec 2022 12:10:21 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1670670623; bh=e5uxHtTDKzCux7YDtuqNES9G86HwdIQi+tMMgZOywHc=; h=From:To:Cc:Subject:Date:From; b=BjA2g/aCXEFtAg8ncrTnIOPBiwtMAweo8UvpjKpm1WisjIAagWrrEZ2bFmvjU+zBD gpZYG94ZjMjRvR7rHB3WF36vbUE1aOiRLJgHacS/5lS8NVQ1Q+Do+g6sqtJTg64LgJ m4Riyjrb04yEuvK7CgG7YPpX10e77SrambaUuGxxuRfoLhejIebvSl85MzGX55kbAV 6czqOImrFueM5Kzyy3crMt7ExbQgO5A2HZ+YaSMC0eWcc31YO45yVd+NeRr6tfkqGK PsV05viTnvuY29vlIWpo9FmYhQbnUJZ2Cf2m1r47VzRGpbcVFAhWpWQgswxDfMQn0R k7sw5xSHaPSLA== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4NTlY83XPZz6tnx; Sat, 10 Dec 2022 12:10:19 +0100 (CET) From: Ihor Radchenko To: Eli Zaretskii Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay In-Reply-To: <83bkoby0zq.fsf@gnu.org> References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> <83bkoby0zq.fsf@gnu.org> Date: Sat, 10 Dec 2022 11:10:19 +0000 Message-ID: <87ilijfrac.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Eli Zaretskii writes: >> The current Emacs' behaviour is unexpected and very confusing here. >> Ideally, Emacs should be able to judge by itself whether to update >> cached image in memory. > > You want Emacs to hit the disk and process the file on each redisplay > cycle? No. It can be less frequent. Maybe just when a new image view is created (like in overlay). Or maybe on timer - make images in the image cache expire after some time. -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at From debbugs-submit-bounces@debbugs.gnu.org Sat Dec 10 09:18:56 2022 Received: (at 59902) by debbugs.gnu.org; 10 Dec 2022 14:18:56 +0000 Received: from localhost ([127.0.0.1]:43005 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p40gq-0007ZW-Ff for submit@debbugs.gnu.org; Sat, 10 Dec 2022 09:18:56 -0500 Received: from eggs.gnu.org ([209.51.188.92]:48768) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p40gn-0007ZO-Am for 59902@debbugs.gnu.org; Sat, 10 Dec 2022 09:18:55 -0500 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 1p40gh-0002Gk-LT; Sat, 10 Dec 2022 09:18:47 -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=fBnbvfHfxpx9HbcG3Z97Vnfbei/1Y0IjyQfXHH6SObg=; b=NAUBlBqVu2re 9vknwZN6r0N3benpaCebZ/y6QU1VOJsy0GlEYujP2vueUEv4+fV+7O7s6SfGQdKaqQgVO/ObqsTq8 BjZ4G3MR9A1qgYAx4nxP/FLb24E9ApwJIA1oHMRCHXGCIhXClO5X3jn+SGmuIwpwD1ie0DXXL7twS pIUO1cAJlRBt2JVzrIM6/lKOa94ed8AWELXL7CSlFKajvw6pCIoCVZg5sRvWHx/IFHuZ/BkVGlopH TcQrcgDztHoqX4TDLVV3/Le8eIkzb3z3nOcYOD8vV09/ReNzoC6m4fRjioFEWIS4Gk5k0aez5oBMG OWVePOWoP3vFIEhFzyY+Tw==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p40gh-0008Am-7D; Sat, 10 Dec 2022 09:18:47 -0500 Date: Sat, 10 Dec 2022 16:18:44 +0200 Message-Id: <83o7sbwddn.fsf@gnu.org> From: Eli Zaretskii To: Ihor Radchenko In-Reply-To: <87ilijfrac.fsf@localhost> (message from Ihor Radchenko on Sat, 10 Dec 2022 11:10:19 +0000) Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> <83bkoby0zq.fsf@gnu.org> <87ilijfrac.fsf@localhost> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Ihor Radchenko > Cc: 59902@debbugs.gnu.org > Date: Sat, 10 Dec 2022 11:10:19 +0000 > > Eli Zaretskii writes: > > >> The current Emacs' behaviour is unexpected and very confusing here. > >> Ideally, Emacs should be able to judge by itself whether to update > >> cached image in memory. > > > > You want Emacs to hit the disk and process the file on each redisplay > > cycle? > > No. It can be less frequent. Maybe just when a new image view is created > (like in overlay). Or maybe on timer - make images in the image cache > expire after some time. The image-handling code doesn't necessarily know where the image came from. The idea of clearing images from time to time was discussed, but AFAIR we didn't find a good way that fits all the needs for doing so. I think this is best left to the application level. In particular, in this case, the application _knows_ when it will replace the image file. From debbugs-submit-bounces@debbugs.gnu.org Sun Dec 11 04:19:33 2022 Received: (at 59902) by debbugs.gnu.org; 11 Dec 2022 09:19:34 +0000 Received: from localhost ([127.0.0.1]:46218 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p4IUd-0007Z6-0Z for submit@debbugs.gnu.org; Sun, 11 Dec 2022 04:19:33 -0500 Received: from mout02.posteo.de ([185.67.36.66]:54519) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p4IUX-0007Yy-Af for 59902@debbugs.gnu.org; Sun, 11 Dec 2022 04:19:29 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id 4A11B240105 for <59902@debbugs.gnu.org>; Sun, 11 Dec 2022 10:19:18 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1670750359; bh=DiYTEg2eELpvm1pSgei2y5gAOpJHpFMn6M3KsbaASG0=; h=From:To:Cc:Subject:Date:From; b=T+KmxaQ3Hl8kBVtcLlkYOIHDk/xaEwIXRcOjQgK6xFu+Gd6eHrUtbjoIJZf8Hfwpj vVNrC+T2e4i00AUgtmL7/hZuyC/kMYGNBytpALgzW4WDgpf6mRxmPLHpbaTMK38XTy 51orjZnj54cDsR8RdZlPjE3d4Y4BMIPWfeuvANJupFemz2t8eO0d5zokdw6maY6ujb BJK5ecFnVwhz4D7X80fHxY1aMzXt7WWRcARC89wQm7kcCFF6KxRxtFC0DNWrF+AgqI WmVAK4BDGJYWjC+xgb724Iw1MO5Stt2ezozHTN7omV0nELklVrUqBnh9PtoU6/htup XxXRzj4p07njw== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4NVK2Y48qgz9rxK; Sun, 11 Dec 2022 10:19:17 +0100 (CET) From: Ihor Radchenko To: Eli Zaretskii Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay In-Reply-To: <83o7sbwddn.fsf@gnu.org> References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> <83bkoby0zq.fsf@gnu.org> <87ilijfrac.fsf@localhost> <83o7sbwddn.fsf@gnu.org> Date: Sun, 11 Dec 2022 09:19:16 +0000 Message-ID: <87zgbul2ln.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Eli Zaretskii writes: >> > You want Emacs to hit the disk and process the file on each redisplay >> > cycle? >> >> No. It can be less frequent. Maybe just when a new image view is created >> (like in overlay). Or maybe on timer - make images in the image cache >> expire after some time. > > The image-handling code doesn't necessarily know where the image came > from. > > The idea of clearing images from time to time was discussed, but AFAIR > we didn't find a good way that fits all the needs for doing so. Are you referring to https://debbugs.gnu.org/cgi/bugreport.cgi?bug=33275 ? I do not see anyone proposing cache expiry time there. Expiry is not really related to this particular bug report, but might be a good idea to help large memory consumption that is reported from time to time (I reported once for pdfs and I have seen people report memory issues with images). > I think this is best left to the application level. In particular, in > this case, the application _knows_ when it will replace the image > file. No. Not really. Source block execution does not pass any information about updating/not updating images to Org image display code. Even if it did, the same issue could appear when the image file changes on disk outside Emacs. I was still able to make some improvements in Org's image code thanks to your replies. https://git.savannah.gnu.org/cgit/emacs/org-mode.git/commit/?id=a12d15df9 Yet, do note that flickering two different image versions when moving point is unexpected even considering the information you provided. -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at From debbugs-submit-bounces@debbugs.gnu.org Sun Dec 11 05:23:44 2022 Received: (at 59902) by debbugs.gnu.org; 11 Dec 2022 10:23:44 +0000 Received: from localhost ([127.0.0.1]:46290 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p4JUl-0008Oy-Pt for submit@debbugs.gnu.org; Sun, 11 Dec 2022 05:23:44 -0500 Received: from eggs.gnu.org ([209.51.188.92]:60758) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p4JUj-0008Op-Ni for 59902@debbugs.gnu.org; Sun, 11 Dec 2022 05:23:42 -0500 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 1p4JUe-00014V-DN; Sun, 11 Dec 2022 05:23:36 -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=z716+JYUZLV0Bm+p2oV/jUnHyFCTqu8s+2/kyAxyvHs=; b=a+i3x62F1TQv AQGegXQYEpN1APhP2ev0SFcJAEYUO5W/Roi4NGqR0Lc6FoqvvOrLn/E7WnvI/LUMgoXnsByZLKup3 U0Zz81fmRXzFhe/BawRt9XZyG1JZqnaE8VOGfUSUpDmmcqvdemHFLL3E3athMXgVrcsSZp/E/trjy 3B8z4JjJMBPxubnWniEHWovD3lnP/PZ8hNvY1dCzkt/FFniMHryQuBiQL/cgcW0kfqZxOlLGemM7j PCKADt8uaQ3EUmTFS+kvRB1YcW1SWmQlCFWZqH3hxQ20hoP4koYQhEhAZEEza6oIIXX2SVZVk+Kp2 z/PcI8luxAo21SpIJ7xaMw==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p4JUd-0004bb-Py; Sun, 11 Dec 2022 05:23:36 -0500 Date: Sun, 11 Dec 2022 12:23:34 +0200 Message-Id: <83bkoautll.fsf@gnu.org> From: Eli Zaretskii To: Ihor Radchenko In-Reply-To: <87zgbul2ln.fsf@localhost> (message from Ihor Radchenko on Sun, 11 Dec 2022 09:19:16 +0000) Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> <83bkoby0zq.fsf@gnu.org> <87ilijfrac.fsf@localhost> <83o7sbwddn.fsf@gnu.org> <87zgbul2ln.fsf@localhost> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Ihor Radchenko > Cc: 59902@debbugs.gnu.org > Date: Sun, 11 Dec 2022 09:19:16 +0000 > > Eli Zaretskii writes: > > > The idea of clearing images from time to time was discussed, but AFAIR > > we didn't find a good way that fits all the needs for doing so. > > Are you referring to https://debbugs.gnu.org/cgi/bugreport.cgi?bug=33275 > ? That's one of them, yes. There were others. > I do not see anyone proposing cache expiry time there. Expiry is not > really related to this particular bug report, but might be a good idea > to help large memory consumption that is reported from time to time (I > reported once for pdfs and I have seen people report memory issues with > images). > > > I think this is best left to the application level. In particular, in > > this case, the application _knows_ when it will replace the image > > file. > > No. Not really. Source block execution does not pass any information > about updating/not updating images to Org image display code. Even if it > did, the same issue could appear when the image file changes on disk > outside Emacs. Then I don't think I understand what you expect Emacs to do in these cases. We have no idea when the image file is replaced, and cannot have such an idea without examining the file at high enough frequency. Doing this "from time to time" is going to miss some changes, or take note of them too late. What else is possible? > I was still able to make some improvements in Org's image code thanks to > your replies. > https://git.savannah.gnu.org/cgit/emacs/org-mode.git/commit/?id=a12d15df9 > > Yet, do note that flickering two different image versions when moving > point is unexpected even considering the information you provided. Flickering is expected when you do something that affects a large portion of the Emacs display. For example, the same will happen if you change a large overlay at high enough frequency. There's no way around that except not doing that. Why was this implementation chosen for whatever feature that produces images? Emacs doesn't react instantly to changes in disk files that it visits, and here you expect it to do so. Isn't it possible to implement this in some other way, like have the program produce its image data in a temporary Emacs buffer, then use that buffer's contents for creating an image? Then I believe the updated image will have a different hash value, and there will be no cache-related collisions. From debbugs-submit-bounces@debbugs.gnu.org Mon Dec 12 03:35:53 2022 Received: (at 59902) by debbugs.gnu.org; 12 Dec 2022 08:35:53 +0000 Received: from localhost ([127.0.0.1]:51398 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p4eHx-0004jt-2q for submit@debbugs.gnu.org; Mon, 12 Dec 2022 03:35:53 -0500 Received: from mout02.posteo.de ([185.67.36.66]:39831) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p4eHu-0004jj-Lw for 59902@debbugs.gnu.org; Mon, 12 Dec 2022 03:35:51 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id B99B8240103 for <59902@debbugs.gnu.org>; Mon, 12 Dec 2022 09:35:44 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1670834144; bh=/lebylAd5ZVxITEF1Cm8cthmvHEAcOop1aA/yCRMLok=; h=From:To:Cc:Subject:Date:From; b=c6mpl+AqW2eX5xofiLnyaG/vDCmNzqJRajLyaZ+W32aK+8jjYxqw9HRCzLo3bG3O3 LN0zLyvjgzais3R+GX5xYqc9Pgi7OT8QmrG82Jyg0MI79DjoTPqpJQ03a8SdHYqKUV nt3Mw6zJYr2AQst/NP4uOJGq82ndXB6mfIyFfsva4U4A2GJPv5UH0JPRtn0AAA8jMc 8mLshbBFJq/Mc/XRK5Iy5AS4il5qb1zFmh7097xQtIuSz1nd1uCn33znNv4jT1bat5 0DXeRQxr3ARGGXBt8BMDNGceH842ed5FQtb2NgSvi8X8dn0BnUXQMxj3kDJXQHvBp1 t2+USp5TEolnQ== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4NVw1r023Qz9rxL; Mon, 12 Dec 2022 09:35:43 +0100 (CET) From: Ihor Radchenko To: Eli Zaretskii Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay In-Reply-To: <83bkoautll.fsf@gnu.org> References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> <83bkoby0zq.fsf@gnu.org> <87ilijfrac.fsf@localhost> <83o7sbwddn.fsf@gnu.org> <87zgbul2ln.fsf@localhost> <83bkoautll.fsf@gnu.org> Date: Mon, 12 Dec 2022 08:35:43 +0000 Message-ID: <87pmcpc940.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Eli Zaretskii writes: >> No. Not really. Source block execution does not pass any information >> about updating/not updating images to Org image display code. Even if it >> did, the same issue could appear when the image file changes on disk >> outside Emacs. > > Then I don't think I understand what you expect Emacs to do in these > cases. We have no idea when the image file is replaced, and cannot > have such an idea without examining the file at high enough frequency. > Doing this "from time to time" is going to miss some changes, or take > note of them too late. What else is possible? For example, `create-image' could accept optional argument to update the cached image if the file modification time is newer than it was when the image was cached. >> Yet, do note that flickering two different image versions when moving >> point is unexpected even considering the information you provided. > > Flickering is expected when you do something that affects a large > portion of the Emacs display. For example, the same will happen if > you change a large overlay at high enough frequency. There's no way > around that except not doing that. Sorry, I used inaccurate word here. What I am referring to here is image overlay displayed old and new image when you move the cursor to the overlay and back repeatedly. > Why was this implementation chosen for whatever feature that produces > images? Emacs doesn't react instantly to changes in disk files that > it visits, and here you expect it to do so. Isn't it possible to > implement this in some other way, like have the program produce its > image data in a temporary Emacs buffer, then use that buffer's > contents for creating an image? Then I believe the updated image will > have a different hash value, and there will be no cache-related > collisions. It could be possible, but looks like unnecessary complication. Also, creating buffers often creates overheads associated with user hooks. I am not sure if something like (let ((revert-without-query '("."))) (with-current-buffer (find-file-noselect file) ;; Do not crown the buffer list. (unless (string-prefix-p " " (buffer-name)) (setf (buffer-name) (concat " " (buffer-name)))) (buffer-string))) is not going to cause significant slowdowns. -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at From debbugs-submit-bounces@debbugs.gnu.org Mon Dec 12 08:15:50 2022 Received: (at 59902) by debbugs.gnu.org; 12 Dec 2022 13:15:50 +0000 Received: from localhost ([127.0.0.1]:52908 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p4ier-0006iP-HN for submit@debbugs.gnu.org; Mon, 12 Dec 2022 08:15:49 -0500 Received: from eggs.gnu.org ([209.51.188.92]:58690) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p4iep-0006iD-DL for 59902@debbugs.gnu.org; Mon, 12 Dec 2022 08:15:48 -0500 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 1p4iek-0006B2-1g; Mon, 12 Dec 2022 08:15:42 -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=KuJZEW/BXUIKSIygsrSYSo+sQEgIkJMv/N8Fk709DRs=; b=qUpmHI3/drwE p5ZyTGzZc8A5uyt+145zNrgSi4IPM4fifR2VK9HH8+m9UoN9pIsRjEAERTOh8PFv2CWpxQY/ACKnE fdTdOySHJg/TMToCImyojxE0Uwt2SMT9bFwBHVyR9nimtgucoPPmdLgJxNKOZmgQa2jfzqvm9V1kB 7mKG2X9+DeKJIoGNBbY6l/nQQY5V4rKxoY1F871816Ys730yWg5UQ/N5eKGS95Wf99m68we5KRGwH QEikTBInLxls8PvBmMFQ34rdN9jevTCZAzeK6eT5S6+pdU1CE/AVt5o34cgqS+vbcYxkfSvF8KZOx VYzinjTmAgjQT4+jLzLXFA==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p4iej-0001pN-FM; Mon, 12 Dec 2022 08:15:41 -0500 Date: Mon, 12 Dec 2022 15:15:43 +0200 Message-Id: <83h6y0sqyo.fsf@gnu.org> From: Eli Zaretskii To: Ihor Radchenko In-Reply-To: <87pmcpc940.fsf@localhost> (message from Ihor Radchenko on Mon, 12 Dec 2022 08:35:43 +0000) Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> <83bkoby0zq.fsf@gnu.org> <87ilijfrac.fsf@localhost> <83o7sbwddn.fsf@gnu.org> <87zgbul2ln.fsf@localhost> <83bkoautll.fsf@gnu.org> <87pmcpc940.fsf@localhost> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Ihor Radchenko > Cc: 59902@debbugs.gnu.org > Date: Mon, 12 Dec 2022 08:35:43 +0000 > > Eli Zaretskii writes: > > > Then I don't think I understand what you expect Emacs to do in these > > cases. We have no idea when the image file is replaced, and cannot > > have such an idea without examining the file at high enough frequency. > > Doing this "from time to time" is going to miss some changes, or take > > note of them too late. What else is possible? > > For example, `create-image' could accept optional argument to update the > cached image if the file modification time is newer than it was when the > image was cached. Patches welcome. We currently hash only the spec itself, and don't pay attention to the file's meta-data. (I also think that if we go this way, file modification time alone could be insufficient for 100% reliability, what with today's fast filesystems.) > >> Yet, do note that flickering two different image versions when moving > >> point is unexpected even considering the information you provided. > > > > Flickering is expected when you do something that affects a large > > portion of the Emacs display. For example, the same will happen if > > you change a large overlay at high enough frequency. There's no way > > around that except not doing that. > > Sorry, I used inaccurate word here. > What I am referring to here is image overlay displayed old and new image > when you move the cursor to the overlay and back repeatedly. Yes, I understood. My response is still the same. > > Why was this implementation chosen for whatever feature that produces > > images? Emacs doesn't react instantly to changes in disk files that > > it visits, and here you expect it to do so. Isn't it possible to > > implement this in some other way, like have the program produce its > > image data in a temporary Emacs buffer, then use that buffer's > > contents for creating an image? Then I believe the updated image will > > have a different hash value, and there will be no cache-related > > collisions. > > It could be possible, but looks like unnecessary complication. > Also, creating buffers often creates overheads associated with user > hooks. > > I am not sure if something like > > (let ((revert-without-query '("."))) > (with-current-buffer (find-file-noselect file) > ;; Do not crown the buffer list. > (unless (string-prefix-p " " (buffer-name)) > (setf (buffer-name) (concat " " (buffer-name)))) > (buffer-string))) > > is not going to cause significant slowdowns. Sorry, you lost me here: how is the above snippet relevant to what I proposed as an alternative implementation? From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 15 05:24:27 2022 Received: (at 59902) by debbugs.gnu.org; 15 Dec 2022 10:24:27 +0000 Received: from localhost ([127.0.0.1]:42731 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5lPf-0001Kl-5I for submit@debbugs.gnu.org; Thu, 15 Dec 2022 05:24:27 -0500 Received: from mout01.posteo.de ([185.67.36.65]:33751) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5lPd-0001Kb-Lx for 59902@debbugs.gnu.org; Thu, 15 Dec 2022 05:24:26 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id DD33B24002A for <59902@debbugs.gnu.org>; Thu, 15 Dec 2022 11:24:18 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1671099859; bh=2afedN99coSvYkYYNK7XsHsWVUv1L00656NI2nVY67U=; h=From:To:Cc:Subject:Date:From; b=Hhq+uMo5tds0K3bjjFD55wRJPpjdX51drIil46ATGf1yQCnONHL9wiRUj10p4qED2 eK46+2vUzxyXRrlpy9vYbrTe/PzOIlthN4wVrDt5v4nK1bXIbtEosmHumEOrYri8pt xG5c5+kY3uEAHykyIxuYgVl3hRKeLxZcWyZCQfAiUZASYevVjZ9Pee2kvC+hZ4a37O DrQR7vhPV4N/+y///f1LQtf3cMX6WSgVdDmeNcR4Zvi1oq+zzdrVSWBVzX/H0pIlDo 3Ow2otNrICD/yiCr7hVPg0z54t1ZgVjOIIvK3pe4L3S8qVxc3uTKyK/hjvmzKgXSqC OsPmgAnzDXFsQ== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4NXpHj6CSbz9rxG; Thu, 15 Dec 2022 11:24:17 +0100 (CET) From: Ihor Radchenko To: Eli Zaretskii Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay In-Reply-To: <83h6y0sqyo.fsf@gnu.org> References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> <83bkoby0zq.fsf@gnu.org> <87ilijfrac.fsf@localhost> <83o7sbwddn.fsf@gnu.org> <87zgbul2ln.fsf@localhost> <83bkoautll.fsf@gnu.org> <87pmcpc940.fsf@localhost> <83h6y0sqyo.fsf@gnu.org> Date: Thu, 15 Dec 2022 10:24:16 +0000 Message-ID: <87cz8lufqn.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Eli Zaretskii writes: >> > Why was this implementation chosen for whatever feature that produces >> > images? Emacs doesn't react instantly to changes in disk files that >> > it visits, and here you expect it to do so. Isn't it possible to >> > implement this in some other way, like have the program produce its >> > image data in a temporary Emacs buffer, then use that buffer's >> > contents for creating an image? Then I believe the updated image will >> > have a different hash value, and there will be no cache-related >> > collisions. >> >> It could be possible, but looks like unnecessary complication. >> Also, creating buffers often creates overheads associated with user >> hooks. >> >> I am not sure if something like >> >> (let ((revert-without-query '("."))) >> (with-current-buffer (find-file-noselect file) >> ;; Do not crown the buffer list. >> (unless (string-prefix-p " " (buffer-name)) >> (setf (buffer-name) (concat " " (buffer-name)))) >> (buffer-string))) >> >> is not going to cause significant slowdowns. > > Sorry, you lost me here: how is the above snippet relevant to what I > proposed as an alternative implementation? The above snippet creates a buffer with image FILE, reverts it if necessary (`find-file-noselect' should do it), and returns the image data that is guaranteed to be up-to-date with the actual file. -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 15 05:49:17 2022 Received: (at 59902) by debbugs.gnu.org; 15 Dec 2022 10:49:17 +0000 Received: from localhost ([127.0.0.1]:42780 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5lnh-0001g4-2z for submit@debbugs.gnu.org; Thu, 15 Dec 2022 05:49:17 -0500 Received: from eggs.gnu.org ([209.51.188.92]:55778) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5lnf-0001fy-35 for 59902@debbugs.gnu.org; Thu, 15 Dec 2022 05:49:15 -0500 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 1p5lnZ-0005Xz-8s; Thu, 15 Dec 2022 05:49:09 -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=rImAWmWVEODRirkNb+IdSTvOUVa3DBwXtJNHNEWjIRM=; b=nI4CZgsh6DKE dEEwil0CTquYubj4iBp4UTqovpaK6d+OhnYddpxGXpkg86Sa5vWT1lCTObXpLcNEud52Z5syezX4V tAGVvp1WE7OviBExClkzG9YH8V77u33Y8/5k0O4I6RGJhMpSBvkM2qqfhv6WVnm7DDApzOz84KBhP SyB4OhcgXxJ9IfG2j/Nl2s/7Uu+bdqKs4l/4d7wtmneMdGPqMnu0tWafQphtIRIbuq2BVjo5gP8A/ 5vO+hyCyypudAD0gT6X5V6Mgw7wS5qY2Qe0dbNXsEjJr+5s7j7rkkcJZwDD2FcGYr0X1D5ZftBsm3 VoprEYYf26i1Bhxf31GEPw==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p5lnY-0007vZ-NG; Thu, 15 Dec 2022 05:49:09 -0500 Date: Thu, 15 Dec 2022 12:49:08 +0200 Message-Id: <83edt1kkm3.fsf@gnu.org> From: Eli Zaretskii To: Ihor Radchenko In-Reply-To: <87cz8lufqn.fsf@localhost> (message from Ihor Radchenko on Thu, 15 Dec 2022 10:24:16 +0000) Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> <83bkoby0zq.fsf@gnu.org> <87ilijfrac.fsf@localhost> <83o7sbwddn.fsf@gnu.org> <87zgbul2ln.fsf@localhost> <83bkoautll.fsf@gnu.org> <87pmcpc940.fsf@localhost> <83h6y0sqyo.fsf@gnu.org> <87cz8lufqn.fsf@localhost> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Ihor Radchenko > Cc: 59902@debbugs.gnu.org > Date: Thu, 15 Dec 2022 10:24:16 +0000 > > Eli Zaretskii writes: > > >> I am not sure if something like > >> > >> (let ((revert-without-query '("."))) > >> (with-current-buffer (find-file-noselect file) > >> ;; Do not crown the buffer list. > >> (unless (string-prefix-p " " (buffer-name)) > >> (setf (buffer-name) (concat " " (buffer-name)))) > >> (buffer-string))) > >> > >> is not going to cause significant slowdowns. > > > > Sorry, you lost me here: how is the above snippet relevant to what I > > proposed as an alternative implementation? > > The above snippet creates a buffer with image FILE, reverts it if > necessary (`find-file-noselect' should do it), and returns the image > data that is guaranteed to be up-to-date with the actual file. Then why do you think it will cause slowdowns? Especially if you call find-file-noselect with its 3rd argument non-nil, as I think you should anyway? From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 15 05:53:33 2022 Received: (at 59902) by debbugs.gnu.org; 15 Dec 2022 10:53:33 +0000 Received: from localhost ([127.0.0.1]:42796 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5lrp-0001jj-Hl for submit@debbugs.gnu.org; Thu, 15 Dec 2022 05:53:33 -0500 Received: from mout01.posteo.de ([185.67.36.65]:53591) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5lrn-0001jd-Ct for 59902@debbugs.gnu.org; Thu, 15 Dec 2022 05:53:31 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id 74C73240026 for <59902@debbugs.gnu.org>; Thu, 15 Dec 2022 11:53:25 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1671101605; bh=qAd7LLB2WNsRMkvxeUp9oHI9AYup/30WfvCdGg3qNy0=; h=From:To:Cc:Subject:Date:From; b=IFBjVZcBpWoMdocMmS8K0djXqOVfsA7bRKTPu/9UdS3zAettWBdeOTDxC8w+zXLkg bIGVEF9h1oWasuu58FnK5EsJhmLKsBAGBwTTK8nwblH/sEyOzHIl+fmykRVTyQxLR7 LCKxVtqhevX0f49PSfgBZyVW3kRPdx9CbxG7d4rZTc1Ju6irvF7xPBapnl54u62iX4 HiOq6AjImNi+qyfaaQbg9QPCcLnYr5yvvG4S7M+8k5Kop7v4wgH7kWJb3l9Xd5FGLl 0XmW/wRJ33mQhFBHxKbG/5K9AbgJJeHLcOb0URxlharHcG/1eHCv+7PhQDmeM9xRWr LCRESBusZRWEg== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4NXpxJ4Vrrz6tmJ; Thu, 15 Dec 2022 11:53:21 +0100 (CET) From: Ihor Radchenko To: Eli Zaretskii Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay In-Reply-To: <83edt1kkm3.fsf@gnu.org> References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> <83bkoby0zq.fsf@gnu.org> <87ilijfrac.fsf@localhost> <83o7sbwddn.fsf@gnu.org> <87zgbul2ln.fsf@localhost> <83bkoautll.fsf@gnu.org> <87pmcpc940.fsf@localhost> <83h6y0sqyo.fsf@gnu.org> <87cz8lufqn.fsf@localhost> <83edt1kkm3.fsf@gnu.org> Date: Thu, 15 Dec 2022 10:53:19 +0000 Message-ID: <871qp1uee8.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Eli Zaretskii writes: >> The above snippet creates a buffer with image FILE, reverts it if >> necessary (`find-file-noselect' should do it), and returns the image >> data that is guaranteed to be up-to-date with the actual file. > > Then why do you think it will cause slowdowns? Especially if you > call find-file-noselect with its 3rd argument non-nil, as I think you > should anyway? Hooks will be executed first time an image is opened. This may cause slowdowns when there is a huge number of inline images in the buffer, first time they are displayed. -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 15 05:58:43 2022 Received: (at 59902) by debbugs.gnu.org; 15 Dec 2022 10:58:43 +0000 Received: from localhost ([127.0.0.1]:42808 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5lwo-0001nX-Jr for submit@debbugs.gnu.org; Thu, 15 Dec 2022 05:58:42 -0500 Received: from eggs.gnu.org ([209.51.188.92]:35494) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5lwm-0001nR-3w for 59902@debbugs.gnu.org; Thu, 15 Dec 2022 05:58:41 -0500 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 1p5lwg-0001eN-QO; Thu, 15 Dec 2022 05:58:34 -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=1og2w78ak2K1TxAyiXocEf56H2/oY01GMtgpLkPTjJE=; b=aKICy7NwOHTY UVytpHdL8ZynAvg5c4f58nd5M5teIOR7sAU7wAwQ9leC5e1ylWeqyglt1LkeeE3dp7dCqF+ZNglJ5 lJML+Ld+xem+2OTqvTwAkT+QSazusDkyQ2WGKj4BDhvXX8S7DtJeeSdbmsY3dVXYddJ9EuYHIwHRE T3i7acF3/ngmaZhi01a/kkeZS0JXNFBHf2wOLSj8fq2ZMcxDsQISLDlF+FSALYdiSNIQpr5DteI7d +AhkeNl2QbpZQOM6DqOzgJjWmJ39vVbzbKwhsHgT7408H5AYeoGJYSG7H+/j9SiwrTz16tEuKmbsc UifY+4VGh26seCPvfOmD0w==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p5lwg-0003QA-64; Thu, 15 Dec 2022 05:58:34 -0500 Date: Thu, 15 Dec 2022 12:58:34 +0200 Message-Id: <83bko5kk6d.fsf@gnu.org> From: Eli Zaretskii To: Ihor Radchenko In-Reply-To: <871qp1uee8.fsf@localhost> (message from Ihor Radchenko on Thu, 15 Dec 2022 10:53:19 +0000) Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> <83bkoby0zq.fsf@gnu.org> <87ilijfrac.fsf@localhost> <83o7sbwddn.fsf@gnu.org> <87zgbul2ln.fsf@localhost> <83bkoautll.fsf@gnu.org> <87pmcpc940.fsf@localhost> <83h6y0sqyo.fsf@gnu.org> <87cz8lufqn.fsf@localhost> <83edt1kkm3.fsf@gnu.org> <871qp1uee8.fsf@localhost> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Ihor Radchenko > Cc: 59902@debbugs.gnu.org > Date: Thu, 15 Dec 2022 10:53:19 +0000 > > Eli Zaretskii writes: > > >> The above snippet creates a buffer with image FILE, reverts it if > >> necessary (`find-file-noselect' should do it), and returns the image > >> data that is guaranteed to be up-to-date with the actual file. > > > > Then why do you think it will cause slowdowns? Especially if you > > call find-file-noselect with its 3rd argument non-nil, as I think you > > should anyway? > > Hooks will be executed first time an image is opened. This may cause > slowdowns when there is a huge number of inline images in the buffer, > first time they are displayed. Which hooks are we talking about here? From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 15 06:06:06 2022 Received: (at 59902) by debbugs.gnu.org; 15 Dec 2022 11:06:06 +0000 Received: from localhost ([127.0.0.1]:42812 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5m3x-0001tR-Ln for submit@debbugs.gnu.org; Thu, 15 Dec 2022 06:06:05 -0500 Received: from mout01.posteo.de ([185.67.36.65]:39229) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5m3v-0001t4-Ry for 59902@debbugs.gnu.org; Thu, 15 Dec 2022 06:06:04 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id F070C240026 for <59902@debbugs.gnu.org>; Thu, 15 Dec 2022 12:05:57 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1671102358; bh=ekf/NKZuY91+GKQlyP4EBJmT1ZstRUMUTVBiQP0o9eE=; h=From:To:Cc:Subject:Date:From; b=NEDb+d6G6MoKjg0LZjqZUWrhYjdQ5P34WZBnf2MWMf1DCatZo/8xlOWK0VlYRhOVu 5GMot/3gnH6MV6QLbUdsx0AOFM2EnpbY444MI3TkFn4Gs2rhk/gAjB/yz2ThCpm3v4 XFxULuAAYtSdB6nTDviNV/aPJ4hEYWR0LKTU5zKS+0QRxvPlfSfwIzx1jmegFio8w5 cV7DQwyy9MXInd3mkX8Pg+VIBb8BLO/W+pP2FgeByhKRxl9niPxQVYtmY9ShSuJTbz 3j/v5fyTh4WV0zfGflcQGjkgRkFwbRgqT+B7Ao8S5bl1KuPgBUahaAMCruDmK1c8/6 ltiTTdvjSFX8g== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4NXqCn1V7bz9rxR; Thu, 15 Dec 2022 12:05:57 +0100 (CET) From: Ihor Radchenko To: Eli Zaretskii Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay In-Reply-To: <83bko5kk6d.fsf@gnu.org> References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> <83bkoby0zq.fsf@gnu.org> <87ilijfrac.fsf@localhost> <83o7sbwddn.fsf@gnu.org> <87zgbul2ln.fsf@localhost> <83bkoautll.fsf@gnu.org> <87pmcpc940.fsf@localhost> <83h6y0sqyo.fsf@gnu.org> <87cz8lufqn.fsf@localhost> <83edt1kkm3.fsf@gnu.org> <871qp1uee8.fsf@localhost> <83bko5kk6d.fsf@gnu.org> Date: Thu, 15 Dec 2022 11:05:56 +0000 Message-ID: <87y1r9sz8r.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Eli Zaretskii writes: >> Hooks will be executed first time an image is opened. This may cause >> slowdowns when there is a huge number of inline images in the buffer, >> first time they are displayed. > > Which hooks are we talking about here? find-file-hook, change-major-mode-after-body-hook, and after-change-major-mode-hook. In my setup, these hooks call 29 functions total. It may be more in heavily customized distributions like Doom. -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 15 06:16:28 2022 Received: (at 59902) by debbugs.gnu.org; 15 Dec 2022 11:16:28 +0000 Received: from localhost ([127.0.0.1]:42826 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5mE0-0001zy-Dm for submit@debbugs.gnu.org; Thu, 15 Dec 2022 06:16:28 -0500 Received: from eggs.gnu.org ([209.51.188.92]:55922) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5mDx-0001zp-2a for 59902@debbugs.gnu.org; Thu, 15 Dec 2022 06:16:26 -0500 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 1p5mDr-0008QT-4O; Thu, 15 Dec 2022 06:16:19 -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=6QMTcu8pO0yGVpW0qwOsoWmTgGeFj+YpDbDss3B+jP8=; b=IymGktwLcVdZ 7thjyVT9am28wvutT7eLQagJ12C02noe0a4QUik4d8OOKOU943fTajtBbFRZkp6LmpfUcKJRQHEmK o+cVHQy8R5fvZVkChfSOwt7E2/b3XIT6rwyVXNQG+1zMG6TVUjV7XidxwL6JcJBAYh/cpFKtqUEly 5RhJyuKB36OymNqYX45QA2ZZLxOja5EHP4l3r0O7+6CrQEbZsPG08SXaNE1vii0GnfzIYdEpK7R33 /0IRHpgRk5srnCUecaqMslHlkboZBKLgRi7RVrqj0aZ/J2SS/9jinuibLflH0FaBdDUvgvuEDP9go /Gml2nIFk9A/qkj1WrsJqw==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p5mDq-0006rz-LP; Thu, 15 Dec 2022 06:16:18 -0500 Date: Thu, 15 Dec 2022 13:16:16 +0200 Message-Id: <83a63olxxb.fsf@gnu.org> From: Eli Zaretskii To: Ihor Radchenko In-Reply-To: <87y1r9sz8r.fsf@localhost> (message from Ihor Radchenko on Thu, 15 Dec 2022 11:05:56 +0000) Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> <83bkoby0zq.fsf@gnu.org> <87ilijfrac.fsf@localhost> <83o7sbwddn.fsf@gnu.org> <87zgbul2ln.fsf@localhost> <83bkoautll.fsf@gnu.org> <87pmcpc940.fsf@localhost> <83h6y0sqyo.fsf@gnu.org> <87cz8lufqn.fsf@localhost> <83edt1kkm3.fsf@gnu.org> <871qp1uee8.fsf@localhost> <83bko5kk6d.fsf@gnu.org> <87y1r9sz8r.fsf@localhost> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Ihor Radchenko > Cc: 59902@debbugs.gnu.org > Date: Thu, 15 Dec 2022 11:05:56 +0000 > > Eli Zaretskii writes: > > >> Hooks will be executed first time an image is opened. This may cause > >> slowdowns when there is a huge number of inline images in the buffer, > >> first time they are displayed. > > > > Which hooks are we talking about here? > > find-file-hook, change-major-mode-after-body-hook, > and after-change-major-mode-hook. You can let-bind them to nil around that snippet, mo? From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 15 06:21:17 2022 Received: (at 59902) by debbugs.gnu.org; 15 Dec 2022 11:21:17 +0000 Received: from localhost ([127.0.0.1]:42831 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5mIf-00023T-2W for submit@debbugs.gnu.org; Thu, 15 Dec 2022 06:21:17 -0500 Received: from mout01.posteo.de ([185.67.36.65]:46227) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5mId-00023K-06 for 59902@debbugs.gnu.org; Thu, 15 Dec 2022 06:21:16 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id 28F6F240029 for <59902@debbugs.gnu.org>; Thu, 15 Dec 2022 12:21:08 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1671103269; bh=QGkMmDBXapRNb6DnvBLdBFJXhGdM4Hhs3BqwETqzczE=; h=From:To:Cc:Subject:Date:From; b=ro0u0PQw6+/1YMLu/sHIdQlX9w6GDgFx+swl30tG6/dc5wbYdTEtwwfxEh+vyyeh4 r3RiDPSLuXnWPGnBN3ACjZJ43vand9UcriAm2nSUwrLFs+Gtj3Mw21Wk/aIvoefC1X 3hkcN8dUrwzIUINBRFQa7xlhvBzZNCcqY4ummtnE1NO3c2wMBWBEjMUiD7U8QU9GC+ BqPMSmWb34WaFKPyvthGXJIsu/7lHTav5bR5jXRcV4YYeEvuFZ9gvVaivWvTuh9tcU Fi1b+6S0ng5XpSdh3gfxfFhczCb4mYUy7GX4T6+U0a5gVDY5HSLVgZZz92KxUYble9 Ay7lV14asi5JA== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4NXqYJ0s42z6tmB; Thu, 15 Dec 2022 12:21:07 +0100 (CET) From: Ihor Radchenko To: Eli Zaretskii Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay In-Reply-To: <83a63olxxb.fsf@gnu.org> References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> <83bkoby0zq.fsf@gnu.org> <87ilijfrac.fsf@localhost> <83o7sbwddn.fsf@gnu.org> <87zgbul2ln.fsf@localhost> <83bkoautll.fsf@gnu.org> <87pmcpc940.fsf@localhost> <83h6y0sqyo.fsf@gnu.org> <87cz8lufqn.fsf@localhost> <83edt1kkm3.fsf@gnu.org> <871qp1uee8.fsf@localhost> <83bko5kk6d.fsf@gnu.org> <87y1r9sz8r.fsf@localhost> <83a63olxxb.fsf@gnu.org> Date: Thu, 15 Dec 2022 11:20:49 +0000 Message-ID: <87tu1wud4e.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Eli Zaretskii writes: >> find-file-hook, change-major-mode-after-body-hook, >> and after-change-major-mode-hook. > > You can let-bind them to nil around that snippet, mo? I only know these hooks from reading the code. How can I make sure that let-binding will reliably work in future Emacs versions? -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 15 08:16:51 2022 Received: (at 59902) by debbugs.gnu.org; 15 Dec 2022 13:16:51 +0000 Received: from localhost ([127.0.0.1]:42982 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5o6V-0005xZ-BR for submit@debbugs.gnu.org; Thu, 15 Dec 2022 08:16:51 -0500 Received: from eggs.gnu.org ([209.51.188.92]:48636) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5o6S-0005xP-5J for 59902@debbugs.gnu.org; Thu, 15 Dec 2022 08:16:49 -0500 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 1p5o6M-00005F-Nc; Thu, 15 Dec 2022 08:16:42 -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=Rc3X3sp0TR5eHcdhcxi/2gcbTclvEb6dOYq31XFsA5I=; b=Z/OxzkTF7VTk x8lmacsi5wZbE8fVfDJoQTYn5FjUljbcqr51uTo+bYlVPnweYHtonabmKe9JmMm2l7O7+kQsRmMva ERFFW+7Ac/mYgV9zcjVcqcIFC/V8RIBlbc2X1CzCAMGQXcXGnegl78wprJkmV5h08+t6QwofoSWnV 5QyF7r3F74k/HMEpIk52FNfMApg4q7+RPUCA05/3P2pMaMMW8kB7/xDjCwKmOEyvAyBEEqQNhq2b2 fiNphZyFh6iwCKEQDnkji9fHjj3ujXUZsv6jFy8o+Py70l4R+1z5NU2vMT2mo0QPPNWJWzZBGq7TY SuLSQsbSRgWckg9DPuBRzQ==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p5o6L-0005y4-W7; Thu, 15 Dec 2022 08:16:42 -0500 Date: Thu, 15 Dec 2022 15:16:41 +0200 Message-Id: <838rj8lscm.fsf@gnu.org> From: Eli Zaretskii To: Ihor Radchenko In-Reply-To: <87tu1wud4e.fsf@localhost> (message from Ihor Radchenko on Thu, 15 Dec 2022 11:20:49 +0000) Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay References: <87zgby87rm.fsf@localhost> <83h6y62kjp.fsf@gnu.org> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> <83bkoby0zq.fsf@gnu.org> <87ilijfrac.fsf@localhost> <83o7sbwddn.fsf@gnu.org> <87zgbul2ln.fsf@localhost> <83bkoautll.fsf@gnu.org> <87pmcpc940.fsf@localhost> <83h6y0sqyo.fsf@gnu.org> <87cz8lufqn.fsf@localhost> <83edt1kkm3.fsf@gnu.org> <871qp1uee8.fsf@localhost> <83bko5kk6d.fsf@gnu.org> <87y1r9sz8r.fsf@localhost> <83a63olxxb.fsf@gnu.org> <87tu1wud4e.fsf@localhost> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Ihor Radchenko > Cc: 59902@debbugs.gnu.org > Date: Thu, 15 Dec 2022 11:20:49 +0000 > > Eli Zaretskii writes: > > >> find-file-hook, change-major-mode-after-body-hook, > >> and after-change-major-mode-hook. > > > > You can let-bind them to nil around that snippet, mo? > > I only know these hooks from reading the code. > How can I make sure that let-binding will reliably work in future Emacs > versions? I don't think I understand the question. Do you mean we could possibly remove these hooks in future versions? If not, what do you mean by "reliably"? From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 15 08:24:14 2022 Received: (at 59902) by debbugs.gnu.org; 15 Dec 2022 13:24:14 +0000 Received: from localhost ([127.0.0.1]:42997 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5oDd-000639-SJ for submit@debbugs.gnu.org; Thu, 15 Dec 2022 08:24:14 -0500 Received: from mout01.posteo.de ([185.67.36.65]:36711) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5oDa-000633-Pp for 59902@debbugs.gnu.org; Thu, 15 Dec 2022 08:24:12 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id 4939A240027 for <59902@debbugs.gnu.org>; Thu, 15 Dec 2022 14:24:05 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1671110645; bh=zwIG+NrV3QLY0/MVQQp8oZ/oyTF3+1krVkqj7D++m/k=; h=From:To:Cc:Subject:Date:From; b=WIW1iQUoZm8MeqJS1UgImvWCp715cjy8KhEVm1HHseDr+T6eVuHBAIH16qM87LWUK ydrx+7msDtcXYdT0meV+uLpKembNmOQYnr+qvbSYBVNXV5WIPy3vtUwXxHS5y82e0P TlM1Iutto69K2M3OOGlCfYguj08vrSB7Qg4UPPsYSQApO3OdNtgDumsu/R3jZ1OT9i 9ko/1Y08pEuHsVO0D2gfI/byduCG9ZtW6AJQ3XLFMgDXvqlPkK1spIbmHpqmaSUPeW o1Jo3QV9msECBDXjFL+xuhzXNBUTWE58k29GziLF20NaUpupwvYblPYFUaY3KSCgHP HiBxP2qymUkBQ== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4NXtH82bHYz6tmQ; Thu, 15 Dec 2022 14:24:04 +0100 (CET) From: Ihor Radchenko To: Eli Zaretskii Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay In-Reply-To: <838rj8lscm.fsf@gnu.org> References: <87zgby87rm.fsf@localhost> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> <83bkoby0zq.fsf@gnu.org> <87ilijfrac.fsf@localhost> <83o7sbwddn.fsf@gnu.org> <87zgbul2ln.fsf@localhost> <83bkoautll.fsf@gnu.org> <87pmcpc940.fsf@localhost> <83h6y0sqyo.fsf@gnu.org> <87cz8lufqn.fsf@localhost> <83edt1kkm3.fsf@gnu.org> <871qp1uee8.fsf@localhost> <83bko5kk6d.fsf@gnu.org> <87y1r9sz8r.fsf@localhost> <83a63olxxb.fsf@gnu.org> <87tu1wud4e.fsf@localhost> <838rj8lscm.fsf@gnu.org> Date: Thu, 15 Dec 2022 13:23:58 +0000 Message-ID: <87fsdgu7f5.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Eli Zaretskii writes: >> > You can let-bind them to nil around that snippet, mo? >> >> I only know these hooks from reading the code. >> How can I make sure that let-binding will reliably work in future Emacs >> versions? > > I don't think I understand the question. Do you mean we could > possibly remove these hooks in future versions? If not, what do you > mean by "reliably"? I am mostly afraid about adding new similar hooks in future. I am not even sure if my list of executed hooks is complete. Practically, I'd prefer Emacs to provide a macro or extra argument that binds all the necessary hooks when opening a file buffer. Maybe, something similar to `delay-mode-hooks'. -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 15 09:26:05 2022 Received: (at 59902) by debbugs.gnu.org; 15 Dec 2022 14:26:05 +0000 Received: from localhost ([127.0.0.1]:43067 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5pBV-0006kY-61 for submit@debbugs.gnu.org; Thu, 15 Dec 2022 09:26:05 -0500 Received: from eggs.gnu.org ([209.51.188.92]:56020) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5pBT-0006kJ-3y for 59902@debbugs.gnu.org; Thu, 15 Dec 2022 09:26:03 -0500 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 1p5pBN-0006p1-NL; Thu, 15 Dec 2022 09:25:57 -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=ER7W2MkPmZL99VP71UeBvDbtR6XtxwfoHLujEBChGzs=; b=hef4JyJI9ZH2 uYhKi5L+F7Ht7rksZ7iZDDvY930ZTGt0owMKGoyxXCsKnCsD/pekIvmoMUZv+1Fgp4e/hssLjHuQz K7w8WSxDzMxBnYo7kDkspDKFoUBSzalZk8m7XaIH3q7Eym7glTyAj/4vFBLZXVBb1ePLB9n9orlMD Y87vbBlEPPaR+qOGOd2DxJqHNqcjLuiERMJ3c4H/ZZ58ZhXNphJpqVHckhyw9fnzSxDbrPrF1eeo4 wF1xXhLKQG6jaoKf62QszX+BUkLseto0i1nHobfV3leCoRRGjB5Slti49r3O5GC5TJ7djrw+XST2V ytqupMC0fLYM/sYymZegpw==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p5pBM-0005iT-E4; Thu, 15 Dec 2022 09:25:57 -0500 Date: Thu, 15 Dec 2022 16:25:56 +0200 Message-Id: <834jtwlp57.fsf@gnu.org> From: Eli Zaretskii To: Ihor Radchenko In-Reply-To: <87fsdgu7f5.fsf@localhost> (message from Ihor Radchenko on Thu, 15 Dec 2022 13:23:58 +0000) Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay References: <87zgby87rm.fsf@localhost> <87ilim863y.fsf@localhost> <83lenh20fy.fsf@gnu.org> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> <83bkoby0zq.fsf@gnu.org> <87ilijfrac.fsf@localhost> <83o7sbwddn.fsf@gnu.org> <87zgbul2ln.fsf@localhost> <83bkoautll.fsf@gnu.org> <87pmcpc940.fsf@localhost> <83h6y0sqyo.fsf@gnu.org> <87cz8lufqn.fsf@localhost> <83edt1kkm3.fsf@gnu.org> <871qp1uee8.fsf@localhost> <83bko5kk6d.fsf@gnu.org> <87y1r9sz8r.fsf@localhost> <83a63olxxb.fsf@gnu.org> <87tu1wud4e.fsf@localhost> <838rj8lscm.fsf@gnu.org> <87fsdgu7f5.fsf@localhost> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Ihor Radchenko > Cc: 59902@debbugs.gnu.org > Date: Thu, 15 Dec 2022 13:23:58 +0000 > > Eli Zaretskii writes: > > >> > You can let-bind them to nil around that snippet, mo? > >> > >> I only know these hooks from reading the code. > >> How can I make sure that let-binding will reliably work in future Emacs > >> versions? > > > > I don't think I understand the question. Do you mean we could > > possibly remove these hooks in future versions? If not, what do you > > mean by "reliably"? > > I am mostly afraid about adding new similar hooks in future. I am not > even sure if my list of executed hooks is complete. If and when we'll add new hooks and they prove to be an issue in this context (i.e. will slow down display of images), they should be added to those disabled. > Practically, I'd prefer Emacs to provide a macro or extra argument that > binds all the necessary hooks when opening a file buffer. Maybe, > something similar to `delay-mode-hooks'. I don't think this is possible in practice, since only the application can know which hooks are or aren't needed. From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 15 09:31:23 2022 Received: (at 59902) by debbugs.gnu.org; 15 Dec 2022 14:31:23 +0000 Received: from localhost ([127.0.0.1]:43076 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5pGc-0006oJ-Dw for submit@debbugs.gnu.org; Thu, 15 Dec 2022 09:31:23 -0500 Received: from mout01.posteo.de ([185.67.36.65]:35373) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5pGZ-0006o9-Ce for 59902@debbugs.gnu.org; Thu, 15 Dec 2022 09:31:20 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id 7F0A724002B for <59902@debbugs.gnu.org>; Thu, 15 Dec 2022 15:31:13 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1671114673; bh=5vzt9JFlCwfQuSbP8BgM1GeZfDHmpH/e0OlQ1Pl3Vkg=; h=From:To:Cc:Subject:Date:From; b=O6tNZ3PDwrbe5YshxOocFFTTljMmN2SiqNb7krklrBo0TZS5ahSidUdZBhLJofLJv Kbuu0Z2us1J21B1C2YYaMYvrNyfliuEdsAntN4a6HKuNp4vgofXHEhF7yb1OQf7fbN yLj1RLu6G9ezxNFaOyeOW9M5hmfmyZE+0tjsLDmRqHQE1mgvZgfsvbE0ip+LyjYHS0 HSmBRV7R5PQSt+8Ad19+ab2O3SxtEActlf0ULe28ZqAblbT8ho1bbqZxfPLcrRmSw+ +ISWZTtzIsanXyvL83xC6I+G0YzTnTGBRu+xkSgoZkiBV0acLIYxM0JpigTveQoneN LkDnkVmCOLrXg== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4NXvmc4NTDz6tmc; Thu, 15 Dec 2022 15:31:09 +0100 (CET) From: Ihor Radchenko To: Eli Zaretskii Subject: Re: bug#59902: 30.0.50; Image overlay is not updated until the cursor moves to the overlay In-Reply-To: <834jtwlp57.fsf@gnu.org> References: <87zgby87rm.fsf@localhost> <87a63x7l1w.fsf@localhost> <83h6y51w66.fsf@gnu.org> <87wn6zr376.fsf@localhost> <83bkoby0zq.fsf@gnu.org> <87ilijfrac.fsf@localhost> <83o7sbwddn.fsf@gnu.org> <87zgbul2ln.fsf@localhost> <83bkoautll.fsf@gnu.org> <87pmcpc940.fsf@localhost> <83h6y0sqyo.fsf@gnu.org> <87cz8lufqn.fsf@localhost> <83edt1kkm3.fsf@gnu.org> <871qp1uee8.fsf@localhost> <83bko5kk6d.fsf@gnu.org> <87y1r9sz8r.fsf@localhost> <83a63olxxb.fsf@gnu.org> <87tu1wud4e.fsf@localhost> <838rj8lscm.fsf@gnu.org> <87fsdgu7f5.fsf@localhost> <834jtwlp57.fsf@gnu.org> Date: Thu, 15 Dec 2022 14:31:05 +0000 Message-ID: <87bko4u4ba.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 59902 Cc: 59902@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Eli Zaretskii writes: >> Practically, I'd prefer Emacs to provide a macro or extra argument that >> binds all the necessary hooks when opening a file buffer. Maybe, >> something similar to `delay-mode-hooks'. > > I don't think this is possible in practice, since only the application > can know which hooks are or aren't needed. I'd say that only the application can know which hooks _are_ needed. For example, a common issue with Org + large number of small files is running hooks. We do know that org-mode-hook may be needed for correctness, while all other hooks are likely not needed for non-interactive use (parsing the file contents). So, it is not about disabling some hooks but rather about enabling some known-in-advance hooks. -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at