[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] [RFC] The "c" Org macro
From: |
Nicolas Goaziou |
Subject: |
Re: [O] [RFC] The "c" Org macro |
Date: |
Mon, 22 May 2017 15:13:07 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux) |
Kaushal Modi <address@hidden> writes:
> I just tried this out and it works:
>
> diff --git a/lisp/org-element.el b/lisp/org-element.el
> index c60a56ead..4f4fc1e2c 100644
> --- a/lisp/org-element.el
> +++ b/lisp/org-element.el
> @@ -181,7 +181,9 @@ specially in `org-element--object-lex'.")
> (?\) ")") (?. "\\.") (_ "[.)]")))
> (alpha (and org-list-allow-alphabetical "\\|[A-Za-z]")))
> (concat "\\(?:[-+*]\\|\\(?:[0-9]+" alpha "\\)" term "\\)"
> - "\\(?:[ \t]\\|$\\)"))
> + "\\(?:[ \t]\\|$\\)")) "\\|"
> + ;; n Macro
> + "\\(?:{{{n\\)" ;Don't allow auto-fill to put n macros at
This is a wrong approach. A macro doesn't separate paragraphs, but
belongs to them. IOW, you get the desired side-effect, but break
underlying syntax.
A better way to solve this would to add a function to
`fill-nobreak-predicate', like we already do for
`org-fill-line-break-nobreak-p' or
`org-fill-paragraph-with-timestamp-nobreak-p'.
I will add it to the "n" macro patch.
Thank you.
Regards,
- Re: [O] [RFC] The "c" Org macro, (continued)
- Message not available
- Re: [O] [RFC] The "c" Org macro, Eric S Fraga, 2017/05/11
- Re: [O] [RFC] The "c" Org macro, Nicolas Goaziou, 2017/05/21
- Re: [O] [RFC] The "c" Org macro, Kaushal Modi, 2017/05/21
- Re: [O] [RFC] The "c" Org macro, Nicolas Goaziou, 2017/05/22
- Re: [O] [RFC] The "c" Org macro, Kaushal Modi, 2017/05/22
- Re: [O] [RFC] The "c" Org macro, Nicolas Goaziou, 2017/05/22
- Re: [O] [RFC] The "c" Org macro, Kaushal Modi, 2017/05/22
- Re: [O] [RFC] The "c" Org macro, Kaushal Modi, 2017/05/22
- Re: [O] [RFC] The "c" Org macro,
Nicolas Goaziou <=
- Re: [O] [RFC] The "c" Org macro, Kaushal Modi, 2017/05/22
- Re: [O] [RFC] The "c" Org macro, Nicolas Goaziou, 2017/05/25
- Re: [O] [RFC] The "c" Org macro, Kaushal Modi, 2017/05/25
- Message not available
- Re: [O] [RFC] The "c" Org macro, Eric S Fraga, 2017/05/22
Re: [O] [RFC] The "c" Org macro, Robert Horn, 2017/05/08