You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@openoffice.apache.org by bu...@apache.org on 2014/05/08 12:04:03 UTC
[Issue 124852] New: Bad SVG import with particular files
https://issues.apache.org/ooo/show_bug.cgi?id=124852
Issue ID: 124852
Issue Type: DEFECT
Summary: Bad SVG import with particular files
Product: Draw
Version: 4.1.0
Hardware: All
URL: http://openclipart.org/collection/collection-detail/ko
ppi/4207
OS: All
Status: CONFIRMED
Severity: normal
Priority: P3
Component: open-import
Assignee: issues@openoffice.apache.org
Reporter: arielch@apache.org
Created attachment 83356
--> https://issues.apache.org/ooo/attachment.cgi?id=83356&action=edit
Draw document with two SVG flags
Download any flag from this collection:
http://openclipart.org/collection/collection-detail/koppi/4207
For example:
http://openclipart.org/download/people/koppi/tf.svg
http://openclipart.org/download/people/koppi/ar.svg
and open them in Draw.
They just don't look like the export in the OpenClipart site, or when they are
opened in Firefox or Inkscape.
--
You are receiving this mail because:
You are the assignee for the issue.
You are watching all issue changes.
4.1.1_release_blocker granted: [Issue 124852] Bad SVG import with
particular files
Posted by bu...@apache.org.
jsc@apache.org has granted Armin Le Grand <Ar...@me.com>'s request for
4.1.1_release_blocker:
Issue 124852: Bad SVG import with particular files
https://issues.apache.org/ooo/show_bug.cgi?id=124852
------- Additional Comments from jsc@apache.org
grant showstopper flag
[Issue 124852] Bad SVG import with particular files
Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=124852
Armin Le Grand <Ar...@me.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|4.2.0 |4.1.1
--- Comment #9 from Armin Le Grand <Ar...@me.com> ---
Added to AOO411, done
--
You are receiving this mail because:
You are watching all issue changes.
[Issue 124852] Bad SVG import with particular files
Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=124852
Ariel Constenla-Haile <ar...@apache.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |Armin.Le.Grand@me.com
--
You are receiving this mail because:
You are the assignee for the issue.
You are watching all issue changes.
[Issue 124852] Bad SVG import with particular files
Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=124852
--- Comment #6 from SVN Robot <sv...@dev.null.org> ---
"alg" committed SVN revision 1607682 into trunk:
i124852 Corrected mask and clip polygons for userSpaceOnUse
--
You are receiving this mail because:
You are watching all issue changes.
[Issue 124852] Bad SVG import with particular files
Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=124852
Armin Le Grand <Ar...@me.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|CONFIRMED |RESOLVED
Resolution|--- |FIXED
Target Milestone|--- |4.2.0
Flags| |4.1.1_release_blocker?
--- Comment #7 from Armin Le Grand <Ar...@me.com> ---
Committed, done. Also a safe fix, I see no reason against adding it to AOO411.
Setting flag...
--
You are receiving this mail because:
You are watching all issue changes.
[Issue 124852] Bad SVG import with particular files
Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=124852
Rekha S <re...@gmail.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |rekhask@gmail.com
--- Comment #12 from Rekha S <re...@gmail.com> ---
Verified fixed on AOO 4.1.1 m2 revision : 1608452
on Windows 8 as well.
I'm able to see the downloaded flags correctly in Draw.
--
You are receiving this mail because:
You are watching all issue changes.
[Issue 124852] Bad SVG import with particular files
Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=124852
--- Comment #5 from Armin Le Grand <Ar...@me.com> ---
Experimented a lot with OpenClipart, looks good. Preparing commit...
--
You are receiving this mail because:
You are watching all issue changes.
[Issue 124852] Bad SVG import with particular files
Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=124852
--- Comment #2 from Regina Henschel <rb...@t-online.de> ---
@Armin: In http://www.w3.org/TR/SVG/coords.html#TransformAttribute the
following example is given:
-- quote start --
In the element
<rect x="10" y="10" width="20" height="20" transform="scale(2)"/>
the x, y, width and height values are processed after the current coordinate
system has been scaled uniformly by a factor of 2 by the ‘transform’ attribute.
Attributes x, y, width and height (and any other attributes or properties) are
treated as values in the new user coordinate system, not the previous user
coordinate system. Thus, the above ‘rect’ element is functionally equivalent
to:
<g transform="scale(2)">
<rect x="10" y="10" width="20" height="20"/>
</g>
-- quote end --
Besides the above "and any other attributes or properties", I do not find any
explicit statement about clipPath together with transform. But when I apply the
way of the example above to the attached file, then
<g id="01" transform="translate(128,128)" clip-path="url(#clipPathFlag)">
<rect id="mask"
ry="57"
height="512" width="512" y="0" x="0"
fill="#00f"/>
</g>
should be functionally equivalent to the surrogate
<g id="01" transform="translate(128,128)">
<g id="myclip" clip-path="url(#clipPathFlag)">
<rect id="mask"
ry="57"
height="512" width="512" y="0" x="0"
fill="#00f"/>
</g>
</g>
If I change the structure in the attached file to this surrogate, the image is
shown as expected.
The browsers IE, Chrome, Seamonkey, and the applications Inkscape and Batik
show the image the same way as my surrogate. Only my rather old (from 2003)
CorelDraw 12 shows it, not equal, but similar to the current AOO rendering. To
be compatible with modern browsers and applications, I would go with their
rendering, even if there might be a comment in any older SVG spec, that
indicates it different.
--
You are receiving this mail because:
You are watching all issue changes.
[Issue 124852] Bad SVG import with particular files
Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=124852
--- Comment #10 from SVN Robot <sv...@dev.null.org> ---
"alg" committed SVN revision 1607810 into branches/AOO410:
i124852 Corrected mask and clip polygons for userSpaceOnUse
--
You are receiving this mail because:
You are watching all issue changes.
[Issue 124852] Bad SVG import with particular files
Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=124852
jsc@apache.org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jsc@apache.org
Flags|4.1.1_release_blocker? |4.1.1_release_blocker+
--- Comment #8 from jsc@apache.org ---
grant showstopper flag
--
You are receiving this mail because:
You are watching all issue changes.
[Issue 124852] Bad SVG import with particular files
Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=124852
--- Comment #3 from Armin Le Grand <Ar...@me.com> ---
Hi Regina, thanks for investigating.
I found the same quote in the SVG specs, thanks for the proof that there is
nothing else mentioned. I am still sure that I changed that by purpose in the
past, sigh.
I did the same replacements you did in the example file and came to the same
conclusions :-) I agree that the main argument is the compatibility with what
othesr do, thus I agree that the semantic should be changed corresponding to
the quote above.
--
You are receiving this mail because:
You are watching all issue changes.
[Issue 124852] Bad SVG import with particular files
Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=124852
Kay <ks...@apache.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |VERIFIED
CC| |kschenk@apache.org
--- Comment #11 from Kay <ks...@apache.org> ---
Verified fixed with -- AOO411m2(Build:9771) - Rev. 1608452
2014-07-07 15:22 - Linux i686
--
You are receiving this mail because:
You are watching all issue changes.
[Issue 124852] Bad SVG import with particular files
Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=124852
Armin Le Grand <Ar...@me.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |rb.henschel@t-online.de
Assignee|issues@openoffice.apache.or |Armin.Le.Grand@me.com
|g |
--- Comment #1 from Armin Le Grand <Ar...@me.com> ---
Took a look. Problem is that groups with transforms and referenced ClipPaths
are used. In this case (tf.svg):
<g transform="translate(128,128)" clip-path="url(#clipPathFlag)">
<rect .../>
</g>
The ClipPath and transform is applied to the group context, but the ClipPath is
*not* transformed in the group definition. This is by purpose (I checked
SvgStyleAttributes::add_postProcess where I remember to have changed that for
another fix, see svgstyleattributes.cxx:1116, see comment there). If I apply
these, the import is correct (except the missing filtering stuff).
I remember to have seen somewhere in SVG spec that this is as it should be
(which would mean that the files are wrong). Adding Regina to CC.
@Regina: In the example above, does transform need to be applied to the
referenced clip-path or not? AFAIK the SVG spec says not to apply it, but then
the example files would be wrong.
--
You are receiving this mail because:
You are the assignee for the issue.
You are watching all issue changes.
[Issue 124852] Bad SVG import with particular files
Posted by bu...@apache.org.
https://issues.apache.org/ooo/show_bug.cgi?id=124852
--- Comment #4 from Armin Le Grand <Ar...@me.com> ---
I experimented and found the trick: It depends on the MaskContentUnits. When
objectBoundingBox scale according to ObjectBounds, when userSpaceOnUse use the
transformation if available. With that modification the test files look good.
Also all my collected test files from many other tasks regarding SVG look good,
some even seem to be improved.
Doing some more tests...
--
You are receiving this mail because:
You are watching all issue changes.
4.1.1_release_blocker requested: [Issue 124852] Bad SVG import with
particular files
Posted by bu...@apache.org.
Armin Le Grand <Ar...@me.com> has asked for 4.1.1_release_blocker:
Issue 124852: Bad SVG import with particular files
https://issues.apache.org/ooo/show_bug.cgi?id=124852
------- Additional Comments from Armin Le Grand <Ar...@me.com>
Committed, done. Also a safe fix, I see no reason against adding it to AOO411.
Setting flag...