emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] trying to automatically refresh inline images after org-babel-ex


From: Grant Rettke
Subject: Re: [O] trying to automatically refresh inline images after org-babel-execute:ditaa
Date: Tue, 11 Oct 2016 12:42:16 -0500

On Tue, Oct 11, 2016 at 12:01 PM, Stig Brautaset <address@hidden> wrote:
> Hello!
>
> I'm trying to automatically update inline ditaa images, by adding this
> advice:
>
> ,----
> |   (advice-add 'org-babel-execute:ditaa
> |               :after
> |               (lambda (a &rest b)
> |                 (message "my sage advice")
> |                 (org-redisplay-inline-images)))
> `----
>
> When hitting =C-c C-c= in a =#+begin_src ditaa= block I *do* get my sage
> advice printed to *Messages*, but inline images just blinks out of
> existence. Is the image overlay removed at a higher level?
>
> Any advice (hah!) welcome.

(defun help/org-babel-after-execute-hook ()
  "HELP settings for the `org-babel-after-execute-hook'.

This does not interfere with exports.

Attribution: URL
`https://lists.gnu.org/archive/html/emacs-orgmode/2015-01/msg00534.html'"
  (interactive)
  (org-redisplay-inline-images))

(add-hook 'org-babel-after-execute-hook #'help/org-babel-after-execute-hook)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]