Automatic inline image toggling as the cursor enters and exits them, similar to org-fragtog.
Org mode supports inline image previews. These are annoying to edit, since you either have to blindly press delete on the image and hope that destroys the inline image preview, or toggle the entire file. org-imgtog
provides the functionality to toggle just the one you’re editing when your cursor goes on it.
org-imgtog.mp4
(use-package org-imgtog
:straight (org-imgtog :type git :host github :repo "gaoDean/org-imgtog")
:hook org-mode)
(add-to-list 'load-path "/path/to/plugin/")
(require 'org-imgtog)
(add-hook 'org-mode-hook 'org-imgtog-mode)
This is only for users who do not turn on caching. To turn on caching, just set the variable url-automatic-caching
to true. If not, it would be benificial to add the following as the image would be fetched every time it is hidden.
(setq org-imgtog-preview-delay 0.5) ;; wait 0.5 seconds before toggling
(setq org-imgtog-preview-delay-only-remote t) ;; only delay for remote images