I have a document that looks like the following.

 

If I export the whole file, I get the whole file. (I’m exporting to LaTeX using C-c C-e d.)

 

If I move to the line “** Level 2 A” and export that subtree using C-c C-e 1 d, the inline tasks are omitted.

 

Is this a bug or have I just misconfigured this somehow?

 

It seems to be caused by the fact that those inline tasks are treated as “lines before the first headline” and that org-export-latex-first-lines calls org-export-preprocess-string with a more-or-less hardcoded opt-plist that doesn’t include :tasks.

 

Is there a reason not to modify this section of org-export-latex-first-lines:

         (org-export-latex-content

          (org-export-preprocess-string

           (buffer-substring pt end)

           :for-backend 'latex

           :emph-multiline t

           :add-text nil

           :comments nil

           :skip-before-1st-heading nil

           :LaTeX-fragments nil

           :tasks (plist-get opt-plist :tasks)                    ;; <-- this is the line I want to add

           :timestamps (plist-get opt-plist :timestamps)

           :footnotes (plist-get opt-plist :footnotes)))

 

----------------------------------------------------------------------

* Level 1 A

** Level 2 A

test

*************** TODO Test 1

*************** END

*************** TODO Test 2

*************** END

*************** TODO Test 3

*************** END

test2

and more

 

** Level 2 B

----------------------------------------------------------------------