Hello Suvayu

> Hi Jambunathan,
>
> Exporting to org-odt fails if my org file has inline tasks and
> org-inlinetask is already loaded. To reproduce the bug with the attached
> org file you can do the following:

Looks like I need to create an entry in

C-h v org-inlinetask-export-templates.

Till such time as that happens, the attached patch would strip inline
tasks from odt export. i.e., the exporter will behave as though
org-inlinetask-export is set to nil for the purpose of odt export.

NOTE TO THE MAINTAINERS: git diff is forcibly creating the first hunk in
the attached diff even though I haven't made any modifications as
suggested by it. (I think it is getting confused by the presence of the
"special non-ascii A") 

>From 8bd8dcc2dae59034bfc8e07a4cd43f26941f68a8 Mon Sep 17 00:00:00 2001
From: Jambunathan K <kjambunat...@gmail.com>
Date: Sat, 6 Aug 2011 20:04:35 +0530
Subject: [PATCH] Check org-inlinetask-export-templates before exporting inline tasks

* lisp/org-inlinetask.el (org-inlinetask-export-handler): Don't export
inline tasks if the current backend has provided no entries in
org-inlinetask-export-templates.
---
 lisp/org-inlinetask.el |    8 +++++---
 1 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/lisp/org-inlinetask.el b/lisp/org-inlinetask.el
index 7a52d6b..a990bd3 100644
--- a/lisp/org-inlinetask.el
+++ b/lisp/org-inlinetask.el
@@ -119,9 +119,9 @@ When nil, they will not be exported."
 	   '((unless (eq todo "") (format "%s%s " todo priority))
 	     heading
 	     (unless (eq content "")
-	       (format "\n         ¦ %s"
+	       (format "\n         ¦ %s"
 		       (mapconcat 'identity (org-split-string content "\n")
-				  "\n         ¦ ")))))
+				  "\n         ¦ ")))))
     (docbook "<variablelist>
 <varlistentry>
 <term>%s%s</term>
@@ -333,7 +333,9 @@ Either remove headline and meta data, or do special formatting."
       ;; Remove the task.
       (goto-char beg)
       (delete-region beg end)
-      (when org-inlinetask-export
+      (when (and org-inlinetask-export
+		 (assq org-export-current-backend
+		       org-inlinetask-export-templates))
 	;; Format CONTENT, if appropriate.
 	(setq content
 	      (if (not (and content (string-match "\\S-" content)))
-- 
1.7.2.3

-- 

Reply via email to