alphapapa / alphapapa/dogears.el
Create and keep separate another dogears-list that holds only positions where a textual change ocurred
- Langage dominant
- Emacs Lisp
- Étoiles
- 224
- Forks
- 11
- Métriques de merge des PR
- Aucune PR mergée en 30 j
Description
Intellij IDEA has this feature and I use it a lot. See
https://www.jetbrains.com/help/idea/navigating-through-the-source-code.html#recent_locations and n.b. the "Show changed only checkbox".
I think `after-change-functions` could be used for this very simply. If performance is a concern, n.b. that it seems that `gumshoe` uses the much scarier `post-command-hook` (see https://github.com/Overdr0ne/gumshoe/blob/223d19ffbd6296864a775d18025150ccbcbc7800/gumshoe-core.el#L447C5-L448C88) but nonetheless seems to be working well.
If performance is lacking, perhaps something like the following can be done:
```
(add-hook
'after-change-functions
(lambda (&rest _)
;; taken from the `(while-no-input (redisplay) CODE)` suggestion in `post-command-hook`'s documentation
(while-no-input
(redisplay)
;; `run-with-timer` is only necessary if `dogears-remember-change` can't gracefully handle being interrupted midway by the `while-no-input`
(run-with-timer
0
nil
;; new command
(dogears-remember-change)))))
```
Guide de contribution
Aucun guide de contribution indexé pour ce dépôt
Évaluation
Cette issue n'a pas encore été évaluée.