On 18/09/2022 19:27, Juan Manuel Macías wrote:

* Section
  :PROPERTIES:
  :presec:  \begingroup\foo
  :postsec: \endgroup
  :END:

Juan Manuel, can it be implemented using a derived backend that calls the original variant of headline transcoder (`org-latex-headline') and adds pre/post code to the returned value? I have not tried to implement this idea, so perhaps I just have missed something obvious. Actually I wonder if the purpose of your patch is solely convenience or you faced a limitation with no reasonable workaround.

My only real objection is that the new keywords works for LaTeX only, but their names are rather generic. Moreover, Org's term is "headline", not "section". I would consider something like
- :headline_pre_latex: \begingroup\foo
- :headline_pre: :latex \begingroup\foo

By the way, are affiliated keywords a part of the following headline?

* Section One

#+attr_latex: :headline_pre \begingroup\foo
* Section Two


Reply via email to