[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] Bug: Bad ODT files when including multiple images [7.9.3f (relea
From: |
Christian Moe |
Subject: |
Re: [O] Bug: Bad ODT files when including multiple images [7.9.3f (release_7.9.3f-17-g7524ef @ /usr/share/emacs/24.3/lisp/org/)] |
Date: |
Tue, 03 Dec 2013 14:53:04 +0100 |
User-agent: |
mu4e 0.9.9.5-dev6; emacs 24.3.1 |
Hi,
This problem was also reported by Tyler Smith a couple of weeks back. I
confirmed it and did a little checking. Unfortunately I also sort of
promised a patch, which I never got around to.
Instead, let me report what I've found about the syntax:
It seems LibreOffice 4.1 now requires that draw:frame elements wrapping
images be uniquely named with the draw:name attribute if there's more
than one of them.
Multiple uncaptioned images fail because Org currently wraps them in
frames without these attributes.
e.g. a simple document containing
[[file:test1.jpg]]
[[file:test2.jpg]]
results in unnamed image frames, e.g. for the first image of the
example:
<draw:frame draw:style-name="OrgDisplayImage"
svg:width="12.70cm" svg:height="12.70cm" text:anchor-type="paragraph">
<draw:image xlink:href="Images/0001.jpg" xlink:type="simple"
xlink:show="embed" xlink:actuate="onLoad"/>
</draw:frame>
This now results in a read error in LibreOffice 4.1. LibreOffice uses
draw:name="graphics1", "graphics2" etc. for the draw:frame element when
a picture is inserted, but I think any unique value will do.
The problem does not occur if you add captions to the images. Then the
draw:frame gets a draw:name attribute containing the caption text.
e.g.
#+caption: A picture
[[file:test1.jpg]]
#+caption: Another picture
[[file:test2.jpg]]
exports without a problem, because it results in draw:frame elements
like (for the first picture of the example):
<draw:frame draw:style-name="OrgCaptionedImage" (...)
draw:name="A picture" text:anchor-type="paragraph">
^^^^^^^^^^^^^^^^^^^^^
However, this only works as long as each caption is unique. If you have
more than one image with identical #+captions, even if they have different
#+names, you get the read error.
So we may need a fix for the corner case of identical captions as well.
I haven't checked what other elements may be affected by similar new
requirements besides images.
Yours,
Christian
- [O] Bug: Bad ODT files when including multiple images [7.9.3f (release_7.9.3f-17-g7524ef @ /usr/share/emacs/24.3/lisp/org/)], Enrico Scholz, 2013/12/02
- Re: [O] Bug: Bad ODT files when including multiple images [7.9.3f (release_7.9.3f-17-g7524ef @ /usr/share/emacs/24.3/lisp/org/)], Jambunathan K, 2013/12/02
- Re: [O] Bug: Bad ODT files when including multiple images [7.9.3f (release_7.9.3f-17-g7524ef @ /usr/share/emacs/24.3/lisp/org/)], Enrico Scholz, 2013/12/02
- Re: [O] Bug: Bad ODT files when including multiple images [7.9.3f (release_7.9.3f-17-g7524ef @ /usr/share/emacs/24.3/lisp/org/)], Enrico Scholz, 2013/12/03
- Re: [O] Bug: Bad ODT files when including multiple images [7.9.3f (release_7.9.3f-17-g7524ef @ /usr/share/emacs/24.3/lisp/org/)], Jambunathan K, 2013/12/04
- Re: [O] Bug: Bad ODT files when including multiple images [7.9.3f (release_7.9.3f-17-g7524ef @ /usr/share/emacs/24.3/lisp/org/)], Tim, 2013/12/17
- Re: [O] Bug: Bad ODT files when including multiple images [7.9.3f (release_7.9.3f-17-g7524ef @ /usr/share/emacs/24.3/lisp/org/)], Jambunathan K, 2013/12/17
- Re: [O] Bug: Bad ODT files when including multiple images [7.9.3f (release_7.9.3f-17-g7524ef @ /usr/share/emacs/24.3/lisp/org/)], Tim, 2013/12/17