Juan Manuel Macías writes: > If I do M-! (occur org-match-substring-regexp) > > I get: > > 10:(_underline_) > 22:(_underline_ text)
Well, in my case the temporary workaround was to force super/subscripts with braces: #+begin_src emacs-lisp (defun my-org-element-subscript-with-braces-parser () (save-excursion (unless (bolp) (backward-char)) (when (looking-at org-match-substring-with-braces-regexp) (let ((bracketsp (match-beginning 4)) (begin (match-beginning 2)) (contents-begin (or (match-beginning 4) (match-beginning 3))) (contents-end (or (match-end 4) (match-end 3))) (post-blank (progn (goto-char (match-end 0)) (skip-chars-forward " \t"))) (end (point))) (list 'subscript (list :begin begin :end end :use-brackets-p bracketsp :contents-begin contents-begin :contents-end contents-end :post-blank post-blank)))))) (advice-add 'org-element-subscript-parser :override #'my-org-element-subscript-with-braces-parser) #+end_src