On 2023-12-11 19:16 GMT, Ihor Radchenko wrote: > >> +*** Capture template expansion now supports ID links >> + >> +The capture template expansion element `%K' creates links using >> +`org-store-link', which respects the values of >> +`org-id-link-to-use-id'. > > Here, we simply use Org markup. So, =%K=, ~org-store-link~, and > ~org-id-link-to-use-id~. > See doc/Documentation_Standards.org for details.
I'll update for the new patch version. > >> + (save-excursion > > `save-excursion' should be unnecessary here. `org-with-point-at' already > takes care about restoring window configuration and point. > Correct, I'll remove it. The patch is now much simpler :) >> + (org-with-point-at org-clock-marker >> + (substring-no-properties (org-store-link >> current-prefix-arg nil)))) >> "")) > > Using `current-prefix-arg' is incorrect here. > `org-capture-fill-template' is called from `org-capture' that assigns a > completely different meaning to the prefix argument (see the > docstring). > Okay, I'll pass `nil' instead. I'm not sure any other value makes sense. > Also, why `substring-no-properties'? I figured the link should not come with the face properties inherited from `org-store-link'. If that's incorrect, I'll drop it. It seems to work either way. -- -Kenny