Bug 446174

Summary: OOo Draw not loading OOo1 sxd files correctly
Product: [Fedora] Fedora Reporter: Paul F. Johnson <paul>
Component: openoffice.orgAssignee: Caolan McNamara <caolanm>
Status: CLOSED NOTABUG QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: medium    
Version: rawhideCC: jnavrati
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2008-05-13 13:02:08 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
File incorrectly rendered
none
How the diagram should be rendered none

Description Paul F. Johnson 2008-05-13 08:04:50 UTC
Description of problem:
If I load an sxd file into OOo Draw, parts of the file are either not correctly
placed or converted to paths.

Version-Release number of selected component (if applicable):
2.4.0.12-8

How reproducible:
Always

Steps to Reproduce:
1. Import the drawing attached to this BZ report
2.
3.
  
Actual results:
The letter C is not able to be moved (though can be rotated) and the lines are
out of place

Expected results:
See screenshot attached.

Additional info:

Comment 1 Paul F. Johnson 2008-05-13 08:04:51 UTC
Created attachment 305210 [details]
File incorrectly rendered

Comment 2 Paul F. Johnson 2008-05-13 08:06:01 UTC
Created attachment 305211 [details]
How the diagram should be rendered

OOo Draw does not have snap to grid switched on when importing, so it's not
related to that.

Comment 3 Caolan McNamara 2008-05-13 08:39:57 UTC
Which version is the screenshot from ? It looks the same in my F-8 2.3.0 as it
does in my F-9 2.4.0, i.e. the C is offset to the left in both

Comment 4 Paul F. Johnson 2008-05-13 08:54:11 UTC
Screenshot is from chemtool which exports as sxd

Comment 5 Caolan McNamara 2008-05-13 09:28:03 UTC
Hmm, looking inside the format (just unzip and look at content.xml) the circle
is "draw:ellipse" and has an X of 1.4224cm and a width of 1.9812cm, this matches
what's shown in size and positioning in the UI. So the
center point is at an X of 2.413.

So if we want the "C" to be positioned neatly on the centre point then we need
to position the C box so that it has half of its box to the left, and half to
the right. The values in the file are x1 2.1844cm and x2 2.29023cm which match
what's shown in the UI, and are way off to the left of the centre point.

So as far as I can see OOo is positioning the text faithfully according to the
file, If the C is to be centered then the x1 point should be = 
center point - width/2

i.e. 

<draw:line draw:layer="layout" draw:z-index="10" draw:style-name="Fig2SxdText11"
svg:x1="2.36cm" svg:y1="2.18798cm" svg:x2="2.47cm" svg:y2="2.18798cm">

not

<draw:line draw:layer="layout" draw:z-index="10" draw:style-name="Fig2SxdText11"
svg:x1="2.1844cm" svg:y1="2.18798cm" svg:x2="2.29023cm" svg:y2="2.18798cm">



Comment 6 Paul F. Johnson 2008-05-13 13:02:08 UTC
I've emailed the author over this (mainly as I'm trying to get fig2sxd into
rawhide!). As this isn't an OOo bug, I'll close it.

Thanks :-)