Hello, Rasmus <ras...@gmx.us> writes:
> Attached is a simple patch that works by silently drops the caption in > a sneaky way. I didn't experience any problems when testing it, but > you might have more insights as to whether this approach have latent > issues. Thank you. Altering the parse tree seems a bit drastic to me, though. See below. > I think we had the discussion with leaving out packages earlier, when > discussing things like wrap-float etc. As I recall, the consensus was > to include the necessary packages. Thus, I think solution (iii) would > require adding caption to the default package alist. Caption is a > package that's very good, so I wouldn't mind it. But, I'm still not > convinced that non-floating caption for equation is the correct > behavior. We don't need to add "caption" to the default packages set. We can specify that this feature is available only if that package is required. > - (let* ((caption (org-latex--caption/label-string table info)) > + (let* (;; Silently drop captions as they are not supported in > + ;; math-mode. > + (caption (org-latex--caption/label-string > + (org-element-put-property table :caption nil) info)) We could replace (caption (org-latex--caption/label-string ...)) with (label (let ((label (org-element-property :name table))) (and label (format "\\label{%s}\n" (org-export-solidify-link-text label))))) and change "caption" into "label" later in the function. WDYT? Regards, -- Nicolas Goaziou