emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [PATCH v4.0] Re: [PATCH] add a function to only refresh inline image


From: Ihor Radchenko
Subject: Re: [PATCH v4.0] Re: [PATCH] add a function to only refresh inline images under current headline instead of global buffer
Date: Thu, 22 Aug 2024 13:19:30 +0000

Karthik Chikmagalur <karthikchikmagalur@gmail.com> writes:

>> Maybe even hook into link parameters.
>
> Yes, the idea is to add an org-link-parameter named ":preview" so each
> link type can register how it should be previewed.  When omitted, we
> fall back to a default (only for file links) that's the current
> image preview behavior.
>
> More fine-grained behavior may be desired in the future -- for example,
> web url links to YouTube should be previewed differently from web url
> links to arXiv, but for now this will be the responsibility of the
> single :preview function in org-link-parameters.

This is not a problem.
It is possible (and also Elispy) to use advices:

(add-function :before-until (org-link-get-parameter "id" :follow) #'my-function)

We may want to document this fact better though.

> Would you like this to be part of org.el or should I spin out an
> org-image-preview.el feature+library?

Spin out will be easier when for my rebase :)

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>



reply via email to

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