emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [PATCH v3 2/3] ox-texinfo: Optionally use @itemx for certain descrip


From: Jonas Bernoulli
Subject: Re: [PATCH v3 2/3] ox-texinfo: Optionally use @itemx for certain description list items
Date: Sun, 23 Jan 2022 21:43:48 +0100

Nicolas Goaziou <mail@nicolasgoaziou.fr> writes:

>> -     (items (and tag
>> -                 (let ((tag (org-export-data tag info)))
>> +     (items (org-element-property :itemx item))
>> +     (items (cond (items
>> +                   (mapcar (lambda (tag) (org-export-data tag info))
>> +                           (nconc items (list tag))))
>> +                  ((not tag) nil)
>> +                  (t
>> +                   (setq tag (org-export-data tag info))
>
> OK, but I think this is a bit convoluted. I wonder if we need
> `org-texinfo--combine-items' at all. I.e., `org-texinfo-item' could
> decide to prefix current tag with @itemx if 1) the item is empty 2) the
> list has a non-nil :compact attribute 3) there's another item following
> it. IOW, we do not need to rely on an :itemx property.

Yes, `org-texinfo--combine-items' wasn't necessary and its better
without it.  But just like when crossing the street we now have to look
in both directions.  ;)

I have kept the :compact and :sep code-paths apart because mixing them
would result in something that resembles the code you called convoluted
and because I think it would not make sense to mix the two styles in the
same list anyway.

     Jonas



reply via email to

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