all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "Clément Pit--Claudel" <clement.pit@gmail.com>
To: emacs-devel@gnu.org
Subject: Re: Use cases for post-redisplay hooks
Date: Mon, 11 Jul 2016 00:17:11 +0200	[thread overview]
Message-ID: <5782C967.8020905@gmail.com> (raw)
In-Reply-To: <577A9156.9070007@gmail.com>


[-- Attachment #1.1: Type: text/plain, Size: 2067 bytes --]

On 2016-07-04 12:39, Clément Pit--Claudel wrote:
> Hi emacs-devel,
> 
> As a prelude to implementing the actual functionality, I'd like to get a clearer picture of what use cases exist for post-redisplay hooks.

Summarizing the current discussion:

(1) Is still valid, though Richard did suggest that we could have Emacs take the screenshots itself. It would indeed be a useful feature to have, though it is partly orthogonal, and seems non-trivial to implement. Richard also suggested special casing this feature and implementing only that instead of a post-display-hook.

(2) Does not sound like it would benefit significantly from such a hook (but I may have missed something).

(3) Does not resolve to something concrete.

Clément.

> Here are the ones that I'm currently aware of; can you think of other ones?
> 
> 1. (my own) Generating emacs screenshots. You can see a demo at http://web.mit.edu/cpitcla/www/emacs-screencast-annot.gif (let me know what you think!). Other hooks do not work because:
>   - pre-redisplay-functions are called too early
>   - pre- and post-command-hook do not run often enough (in the screencast above, see the butterfly animation, for example)
>   - window-related hooks do not run often enough either
>   - redisplay-end-trigger-functions are tricky to use, and deprecated
> 
> 2. (Keith David Bershatsky + Michael Heerdegen @ https://lists.gnu.org/archive/html/bug-gnu-emacs/2016-01/msg01013.html) Updating overlays after scrolling.  The bug thread is pretty long and subtle, but this issue has also been discussed on emacs.stackexchanged IIRC.
> 
> 3. (Stefan? @ https://lists.gnu.org/archive/html/emacs-devel/2009-02/msg00785.html) Running code every time "something visible" happens (e.g. due to process filters)
> 
> For number 1, and potentially number 3, a hook that run after redisplay completes entirely would work. For number 2, things are less clear. Michael, Keith, and Eli, do you have ideas of when in the display cycle such a hook should run?
> 
> Thanks!
> Clément.
> 
> 



[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

  parent reply	other threads:[~2016-07-10 22:17 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-04 16:39 Use cases for post-redisplay hooks Clément Pit--Claudel
2016-07-04 17:02 ` Eli Zaretskii
2016-07-04 17:15   ` Clément Pit--Claudel
2016-07-04 21:45 ` Stefan Monnier
2016-07-10 22:17 ` Clément Pit--Claudel [this message]
2016-07-11  3:34   ` Stefan Monnier
  -- strict thread matches above, loose matches on Subject: below --
2016-07-04 21:42 Keith David Bershatsky
2016-07-04 22:06 ` Stefan Monnier
2016-07-05  2:35 ` Eli Zaretskii
2016-07-04 22:50 Keith David Bershatsky
2016-07-05  8:12 ` Stefan Monnier
2016-07-07 16:08 ` Clément Pit--Claudel
2016-07-05 17:45 Keith David Bershatsky
2016-07-07 17:53 Keith David Bershatsky
2016-07-07 19:44 ` Clément Pit--Claudel
2016-07-07 20:19 Keith David Bershatsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5782C967.8020905@gmail.com \
    --to=clement.pit@gmail.com \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.