auctex
[Top][All Lists]
Advanced

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

Re: tex-fold.el: allow macro folding specifications to "abort"


From: Ikumi Keita
Subject: Re: tex-fold.el: allow macro folding specifications to "abort"
Date: Wed, 30 Aug 2023 16:20:07 +0900

Hi Paul,

>>>>> Paul Nelson <ultrono@gmail.com> writes:
> I'd like to suggest a modification to tex-fold.el: when the macro
> specification is a function, allow it to return the elisp symbol
> ~abort~ (rather than a string) to signal that macro folding should be
> aborted. This would to allow the user to decide programmatically not
> to fold certain macros. It requires a "one-line" change to
> ~TeX-fold-hide-item~ (see patch below) with no effect on existing
> usage.

Thanks for your suggestion. It seems good to me. I'd push the attached
commit unless someone else objects.

(I presume this change doesn't need copyright assignment form because
most of it is indent adaptation and the substantial change is just
addition of
----------------------------------------------------------------------
    (if (eq computed 'abort)
        (progn (delete-overlay ov)
               t ; so that `TeX-fold-dwim' "gives up"
               )
----------------------------------------------------------------------
. But this may be a border case. Is there anyone who think it needs
copyright assignment?)

Regards,
Ikumi Keita
#StandWithUkraine #StopWarInUkraine

Attachment: 0001-Allow-programmatical-folding.patch
Description: patch


reply via email to

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