all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Suggestion to add hook to be run when org-indent completes a buffer's initialization
@ 2023-12-30  5:24 dark.key8799
  2023-12-31 14:42 ` Ihor Radchenko
  0 siblings, 1 reply; 6+ messages in thread
From: dark.key8799 @ 2023-12-30  5:24 UTC (permalink / raw)
  To: emacs-orgmode

The org-modern-indent package relies on org-indent having finished preparing a buffer to add its own customizations. Currently it relies on a timer mechanism to watch org-indent-agentized-buffers and execute once a buffer has been prepped by org-indent.

That leads to some downstream issues in particular use-cases (https://github.com/jdtsmith/org-modern-indent/issues/11)

Although there are some workarounds for the particular issue above, a cleaner solution would be org-indent calling some hook at the end of the preparation. As per link above, jdtsmith proposes to add such call in org-indent-initialize-buffer:

         ;; Job is complete: un-agentize buffer.
	 (unless interruptp
	   (setq org-indent-agentized-buffers
		 (delq buffer org-indent-agentized-buffers))
           (run-hook-with-args 'org-indent-buffer-init-finished buffer)) ;; <-- added

-- 
Alexandre Avanian


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2024-01-03 15:36 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-12-30  5:24 Suggestion to add hook to be run when org-indent completes a buffer's initialization dark.key8799
2023-12-31 14:42 ` Ihor Radchenko
2024-01-02 10:56   ` [PATCH] " dark.key8799
2024-01-02 11:15     ` Ihor Radchenko
2024-01-02 15:53       ` dark.key8799
2024-01-03 15:38         ` Ihor Radchenko

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.