Yury Bulka <yurk...@gmail.com> writes:

> One more thing, related to unicode inside the href of the link:
>
> [[https://commons.wikimedia.org/wiki/File:%D0%91%D1%83%D0%B7%D0%BE%D0%BA.ogg][https://commons.wikimedia.org/wiki/File:Бузок.ogg]]
>
> Turns into:
> \href{https://commons.wikimedia.org/wiki/File:Бузок.ogg}{\url{https://commons.wikimedia.org/wiki/File:Бузок.ogg}}
>
> I.e. for some reason the href gets url-decoded. Such links don't work
> in evince.

Indeed, links are url-decoded when parsed (see line 3139 in
org-element.el). I think the reasoning behind it is that url should then
be encoded again to make sure every url is correctly encoded.

One possibility is to use (org-link-escape (org-link-unescape
raw-link)), that is every parsed link will be url-encoded. Another one
is to leave links as-is, but back-end developers will have to deal with
that. I lean towards the former.

Funnily, this only applied to bracket links (i.e., [[link][desc]]),
plain links are not url-decoded (or encoded) at all. This isn't
consistent and also needs to be fixed.

Any opinion?


Regards,

-- 
Nicolas Goaziou

Reply via email to