From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jambunathan K Subject: Re: Org-odt fails to export when inline tasks are present Date: Sat, 06 Aug 2011 20:32:53 +0530 Message-ID: <81vcua60rm.fsf@gmail.com> References: Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Return-path: Received: from eggs.gnu.org ([140.186.70.92]:42436) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QpiPJ-0000pJ-6s for emacs-orgmode@gnu.org; Sat, 06 Aug 2011 11:03:22 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QpiPI-0003vH-5R for emacs-orgmode@gnu.org; Sat, 06 Aug 2011 11:03:21 -0400 Received: from mail-pz0-f44.google.com ([209.85.210.44]:61394) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QpiPH-0003uw-Vs for emacs-orgmode@gnu.org; Sat, 06 Aug 2011 11:03:20 -0400 Received: by pzk36 with SMTP id 36so5789135pzk.17 for ; Sat, 06 Aug 2011 08:03:18 -0700 (PDT) In-Reply-To: (suvayu ali's message of "Sat, 6 Aug 2011 13:41:54 +0200") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: suvayu ali Cc: org-mode mailing list --=-=-= Content-Type: text/plain 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") --=-=-= Content-Type: text/x-patch; charset=iso-8859-1 Content-Disposition: inline; filename=0001-Check-org-inlinetask-export-templates-before-exporti.patch Content-Transfer-Encoding: quoted-printable Content-Description: 0001-Check-org-inlinetask-export-templates-before-exporti.patch >From 8bd8dcc2dae59034bfc8e07a4cd43f26941f68a8 Mon Sep 17 00:00:00 2001 From: Jambunathan K Date: Sat, 6 Aug 2011 20:04:35 +0530 Subject: [PATCH] Check org-inlinetask-export-templates before exporting inl= ine 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 =A6 %s" + (format "\n =C2=A6 %s" (mapconcat 'identity (org-split-string content "\n") - "\n =A6 "))))) + "\n =C2=A6 "))))) (docbook " %s%s @@ -333,7 +333,9 @@ Either remove headline and meta data, or do special for= matting." ;; 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))) --=20 1.7.2.3 --=-=-= Content-Type: text/plain -- --=-=-=--