[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] Allow LaTeX reference command (\ref) to be customised
From: |
Nicolas Goaziou |
Subject: |
Re: [PATCH] Allow LaTeX reference command (\ref) to be customised |
Date: |
Wed, 09 Jun 2021 13:52:04 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) |
Hello,
Timothy <tecosaur@gmail.com> writes:
> I'm wondering if you've had a chance to take a look yet? (just making
> sure this hasn't slipped by, given your recent replies in other
> threads).
I agree there is no good reason to hard-code "\ref", but, off the top of
my head, there may be a couple of things to consider:
1. There is still a dangling \ref in `org-latex-footnote-defined-format';
2. This change is already somewhat trivial using a link filter:
(defun my-ref-link-filter (s &rest _)
(replace-regexp-in-string (rx string-start "\\ref") "\\foo" s nil t))
(add-to-list 'org-export-filter-link-functions #'my-ref-link-filter)
3. \hyperref is still hard-coded in `org-latex-link'; your patch could
look like a partial solution.
Those are not strong objections, so if you think none of them is worth
considering, then I'm fine with your patch.
Regards,
--
Nicolas Goaziou