https://bugs.freedesktop.org/show_bug.cgi?id=84494
Priority: medium
Bug ID: 84494
Assignee: [email protected]
Summary: FILEOPEN: Possible failure to follow SVG spec, 800
pixels interpreted as 0.8cm
Severity: normal
Classification: Unclassified
OS: Windows (All)
Reporter: [email protected]
Hardware: Other
Whiteboard: BSA
Status: UNCONFIRMED
Version: 4.3.0.4 release
Component: Drawing
Product: LibreOffice
Created attachment 107091
--> https://bugs.freedesktop.org/attachment.cgi?id=107091&action=edit
contrived draw file expecting pixels as units
Problem description:
images embedded in Draw file not opening at correct scale
I've been working on adding OpenDocument draw compatibility to a program I'm
working on and have been adjusting files so that they open correctly in Draw.
What I've read about SVG says that if no units are specified then pixels (px)
will be assumed
http://www.w3.org/TR/SVG/coords.html#ViewBoxAttribute
my test files are
testing22.odg
testing23.odg
(I will attach testing22.odg after submitting the bug report if allowed, it
appears I can only attach one file at a time)
both are the same except for one line in
content.xml
the testing22.odg specifies pixels "px"
the testing22.odg uses pixels but does specify "px", as follows:
<draw:frame draw:layer="layout" svg:width="800" svg:height="800"
svg:x="0" svg:y="0">
<draw:image xlink:href="data/layer1.png" xlink:type="simple"
xlink:show="embed" xlink:actuate="onLoad" />
</draw:frame>
Current behavior:
testing22.odg does not appear to work at all, the embedded images do not appear
to load
testing23.odg does work, but the embedded image is displayed at 0.8cm
(I've adjusted my code to convert pixels to cm for the purposes of
compatibility. I'm only writing here to make sure Draw is behaving according to
the standards, maybe I've made an incorrect assumption about how minimal I can
get away with my OpenDocument XML being.)
Expected behavior:
If I am interpreting the SVG specification correctly the XML above should have
resulted in the image in being displayed at the correct size and should not
have been converted into 0.8cm and the failure of my contrived file to load
might indicate that Draw is making some incorrect assumptions about units, and
falling back to something other than pixels when the units are not specified.
Operating System: Windows XP
Version: 4.3.0.4 release
--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Libreoffice-bugs mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs