Bug 90432 - FILESAVE: svg export using selection does not work correctly, FIX suggestion included
Summary: FILESAVE: svg export using selection does not work correctly, FIX suggestion ...
Status: RESOLVED DUPLICATE of bug 88117
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Draw (show other bugs)
Version:
(earliest affected)
4.3.5.2 release
Hardware: x86 (IA32) Windows (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-04-03 11:18 UTC by devseppala
Modified: 2015-05-07 14:22 UTC (History)
0 users

See Also:
Crash report or crash signature:


Attachments
Draw document containing simple object to be exported to using selection. (10.61 KB, application/vnd.oasis.opendocument.graphics)
2015-04-03 11:18 UTC, devseppala
Details
Original SVG-file exported from Draw using selection (8.76 KB, image/svg+xml)
2015-04-03 11:21 UTC, devseppala
Details
Corrected SVG-file, where xy-attributes of clipPath have been changed (8.76 KB, image/svg+xml)
2015-04-03 11:23 UTC, devseppala
Details
Corrected SVG-file, where clipPath has been removed (8.54 KB, image/svg+xml)
2015-04-03 11:24 UTC, devseppala
Details
Writer document illustrating the problem and the FIX suggestions (30.59 KB, application/vnd.oasis.opendocument.text)
2015-04-03 11:26 UTC, devseppala
Details

Note You need to log in before you can comment on or make changes to this bug.
Description devseppala 2015-04-03 11:18:32 UTC
Created attachment 114575 [details]
Draw document containing simple object to be exported to using selection.

Exporting selected content from Draw to SVG-format does not work correctly because clipPath xy-coordinates are allways set to zero, instead of viewBox coordinates of the svg-element.

This results in the picture showing up only partially or not at all, when trying to insert the picture to Writer document. The same thing happens if one tries to view the svg-file in other programs as Firefox or Internet Explorer.

Solution is to set the clipPath-->rect elements x="0" y="0" attributes to the viewBox-attributes origo.

In addition I would consider removing "clip-path"-attribute from the root svg-element.  It is redundant, because element:
<g id="id1" class="Slide" clip-path="url(#presentation_clip_path)">  , contains it also.
I think it might not be good to reference it in multiple places, although I am not SVG expert.

Other option is to remove the clipPath element and all references to it. 

Attached Draw, Writer and svg-files illustrating the problem. See especially the writer document.
Comment 1 devseppala 2015-04-03 11:21:21 UTC
Created attachment 114576 [details]
Original SVG-file exported from Draw using selection
Comment 2 devseppala 2015-04-03 11:23:27 UTC
Created attachment 114577 [details]
Corrected SVG-file, where xy-attributes of clipPath have been changed
Comment 3 devseppala 2015-04-03 11:24:22 UTC
Created attachment 114578 [details]
Corrected SVG-file, where clipPath has been removed
Comment 4 devseppala 2015-04-03 11:26:33 UTC
Created attachment 114579 [details]
Writer document illustrating the problem and the FIX suggestions
Comment 5 devseppala 2015-04-03 11:44:11 UTC

*** This bug has been marked as a duplicate of bug 88117 ***