emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Bug: ODT export creates invalid document if literal [8.0-pre (release_8.0-pre-58-g9f1765.dirty @ mixed installation! /Users/bernd.haug/Library/Application Support/Aquamacs Emacs/org/lisp/ and /Users/bernd.haug/Library/Application Support/Aquamacs Emacs/org/info/)]
@ 2013-03-13 15:23 Bernd Haug
  2013-03-13 16:03 ` Bastien
  0 siblings, 1 reply; 2+ messages in thread
From: Bernd Haug @ 2013-03-13 15:23 UTC (permalink / raw)
  To: emacs-orgmode

I am exporting a document to ODT that contains the following text:

blah blah blah =blah <x> blah blah blah...=, blah blah blah
bla bla (bla =bla <x> bla bla bla...= blah). bla blah bla

When opening the document in LibreOffice 3.4, I get the following message:
Read-Error.
Format error discovered in the file in sub-document content.xml at
1837,86(row,col).

I unzipped the ODT file and looked to the named location in content.xml:
blah bla blah blah <text:span text:style-name="OrgCode">blah <x> bla
blah...</text:span>, blah bla blah bla bla
bla bla (bla <text:span text:style-name="OrgCode">blah <x> bla bla
bla...</text:span> blah). blah bla bla

Obviously, the <x> would have to be escaped in the XML output if it
should be presented as intended, but it is interpreted literally as
the == would advise, which causes corruption from the perspective of
LibreOffice.

I would suggest doing the escaping as it seems much more likely that
users want to see such content mono-spaced rather than insert literal
ODT markup.

Quick note on my config: The dirty source directory only contains the
changes from the Makefile-patch I just submitted which allows
installation to locations containing space characters in their path.

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


Emacs  : GNU Emacs 23.3.50.1 (i386-apple-darwin9.8.0, NS apple-appkit-949.54)
 of 2011-10-25 on braeburn.aquamacs.org - Aquamacs Distribution 2.4
Package: Org-mode version 8.0-pre (release_8.0-pre-58-g9f1765.dirty @
mixed installation! /Users/bernd.haug/Library/Application
Support/Aquamacs Emacs/org/lisp/ and
/Users/bernd.haug/Library/Application Support/Aquamacs
Emacs/org/info/)

current state:
==============
(setq
 org-speed-command-hook '(org-speed-command-default-hook
org-babel-speed-command-hook)
 org-blocker-hook '(org-block-todo-from-children-or-siblings-or-parent)
 org-export-latex-tables-centered nil
 org-babel-load-languages '((sh . t) (emacs-lisp . t) (python . t))
 org-metaup-hook '(org-babel-load-in-session-maybe)
 org-after-todo-state-change-hook '(org-clock-out-if-current)
 org-babel-tangle-lang-exts '(("python" . "py") ("emacs-lisp" . "el"))
 org-export-with-drawers nil
 org-support-shift-select t
 org-export-preprocess-hook '(org-export-blocks-preprocess)
 org-tab-first-hook '(org-hide-block-toggle-maybe
org-src-native-tab-command-maybe org-babel-hide-result-toggle-maybe
org-babel-header-arg-expand)
 org-src-mode-hook '(org-src-babel-configure-edit-buffer
org-src-mode-configure-edit-buffer)
 org-confirm-shell-link-function 'yes-or-no-p
 org-agenda-before-write-hook '(org-agenda-add-entry-text)
 org-babel-pre-tangle-hook '(save-buffer)
 org-cycle-hook '(org-cycle-hide-archived-subtrees
 org-cycle-hide-drawers org-cycle-hide-inline-tasks
 org-cycle-show-empty-lines
		  org-optimize-window-after-visibility-change)
 org-export-latex-classes '(("doctooleng"
 "\\documentclass{doctooleng}" ("\\chapter{%s}" . "\\chapter*{%s}")
 ("\\section{%s}" . "\\section*{%s}")
			     ("\\subsection{%s}"
 . "\\subsection*{%s}") ("\\subsubsection{%s}"
 . "\\subsubsection*{%s}"))
			    ("xaidat" "\\documentclass{xaidat}"
 ("\\chapter{%s}" . "\\chapter*{%s}") ("\\section{%s}"
 . "\\section*{%s}")
			     ("\\subsection{%s}"
 . "\\subsection*{%s}") ("\\subsubsection{%s}"
 . "\\subsubsection*{%s}"))
			    ("article"
 "\\documentclass[11pt]{article}" ("\\section{%s}" . "\\section*{%s}")
 ("\\subsection{%s}" . "\\subsection*{%s}")
			     ("\\subsubsection{%s}"
 . "\\subsubsection*{%s}") ("\\paragraph{%s}" . "\\paragraph*{%s}")
 ("\\subparagraph{%s}" . "\\subparagraph*{%s}"))
			    ("report" "\\documentclass[11pt]{report}"
 ("\\part{%s}" . "\\part*{%s}") ("\\chapter{%s}" . "\\chapter*{%s}")
			     ("\\section{%s}" . "\\section*{%s}")
 ("\\subsection{%s}" . "\\subsection*{%s}") ("\\subsubsection{%s}"
 . "\\subsubsection*{%s}"))
			    ("book" "\\documentclass[11pt]{book}"
 ("\\part{%s}" . "\\part*{%s}") ("\\chapter{%s}" . "\\chapter*{%s}")
			     ("\\section{%s}" . "\\section*{%s}")
 ("\\subsection{%s}" . "\\subsection*{%s}") ("\\subsubsection{%s}"
 . "\\subsubsection*{%s}"))
			    ("beamer" "\\documentclass{beamer}" org-beamer-sectioning))
 org-export-with-tags 'not-in-toc
 org-mode-hook '(#[nil "\300\301\302\303\304$\207" [org-add-hook
 change-major-mode-hook org-show-block-all append local] 5]
		 #[nil "\300\301\302\303\304$\207" [org-add-hook
 change-major-mode-hook org-babel-show-result-all append local] 5]
 org-babel-result-hide-spec
		 org-babel-hide-all-hashes)
 org-ctrl-c-ctrl-c-hook '(org-babel-hash-at-point
org-babel-execute-safely-maybe)
 org-confirm-elisp-link-function 'yes-or-no-p
 org-export-backends '(ascii html icalendar latex md odt)
 org-clock-out-hook '(org-clock-remove-empty-clock-drawer)
 org-enforce-todo-dependencies t
 org-occur-hook '(org-first-headline-recenter)
 org-from-is-user-regexp "\\<Bernd J\\. Haug\\>"
 org-latex-format-headline-function 'org-latex-format-headline-default-function
 org-metadown-hook '(org-babel-pop-to-session-maybe)
 )
--text follows this line--

-- 
Senior Software Engineer

Xaidat GmbH
Wickenburggasse 5
8010 Graz
Austria / Europe

web: http://www.xaidat.com/
phone:  +43-676-845023-706
email:   bernd.haug@xaidat.com

FN 384295s, LG ZRS Graz
UID-Nr. ATU67414611

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Bug: ODT export creates invalid document if literal [8.0-pre (release_8.0-pre-58-g9f1765.dirty @ mixed installation! /Users/bernd.haug/Library/Application Support/Aquamacs Emacs/org/lisp/ and /Users/bernd.haug/Library/Application Support/Aquamacs Emacs/org/info/)]
  2013-03-13 15:23 Bug: ODT export creates invalid document if literal [8.0-pre (release_8.0-pre-58-g9f1765.dirty @ mixed installation! /Users/bernd.haug/Library/Application Support/Aquamacs Emacs/org/lisp/ and /Users/bernd.haug/Library/Application Support/Aquamacs Emacs/org/info/)] Bernd Haug
@ 2013-03-13 16:03 ` Bastien
  0 siblings, 0 replies; 2+ messages in thread
From: Bastien @ 2013-03-13 16:03 UTC (permalink / raw)
  To: Bernd Haug; +Cc: emacs-orgmode

Hi Bernd,

Bernd Haug <bernd.haug@xaidat.com> writes:

> I am exporting a document to ODT that contains the following text:
>
> blah blah blah =blah <x> blah blah blah...=, blah blah blah
> bla bla (bla =bla <x> bla bla bla...= blah). bla blah bla
>
> When opening the document in LibreOffice 3.4, I get the following message:
> Read-Error.
> Format error discovered in the file in sub-document content.xml at
> 1837,86(row,col).

Thanks for reporting this (and for looking into the .odt file!)

It is now fixed in master.

-- 
 Bastien

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2013-03-13 16:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-03-13 15:23 Bug: ODT export creates invalid document if literal [8.0-pre (release_8.0-pre-58-g9f1765.dirty @ mixed installation! /Users/bernd.haug/Library/Application Support/Aquamacs Emacs/org/lisp/ and /Users/bernd.haug/Library/Application Support/Aquamacs Emacs/org/info/)] Bernd Haug
2013-03-13 16:03 ` Bastien

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).