jupyter-org-insert-src-block: Don't move past an inlinetask

This commit is contained in:
Nathaniel Nicandro 2019-07-10 19:24:06 -05:00
parent 642b0ef592
commit e084842242

View file

@ -183,7 +183,9 @@ language based on the src-block's near `point'."
(unless (looking-at-p "^[\t ]*$") (unless (looking-at-p "^[\t ]*$")
;; Move past the current element first ;; Move past the current element first
(let ((elem (org-element-at-point)) parent) (let ((elem (org-element-at-point)) parent)
(while (setq parent (org-element-property :parent elem)) (while (and (setq parent (org-element-property :parent elem))
(not (memq (org-element-type parent)
'(inlinetask))))
(setq elem parent)) (setq elem parent))
(when elem (when elem
(goto-char (org-element-property (goto-char (org-element-property