Bug 98118 - INSERT: SVG outer elements shouldn't be rendered completely
Summary: INSERT: SVG outer elements shouldn't be rendered completely
Status: RESOLVED NOTABUG
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: graphics stack (show other bugs)
Version:
(earliest affected)
5.2.0.0.alpha0+
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: bisected, filter:svg, regression
Depends on:
Blocks:
 
Reported: 2016-02-23 16:16 UTC by Xisco Faulí
Modified: 2016-03-01 14:37 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
masking-path-03-b (6.61 KB, image/svg+xml)
2016-02-23 16:16 UTC, Xisco Faulí
Details
Screenshot Seamonkey 2.39 with high window (35.31 KB, image/png)
2016-02-23 18:22 UTC, Regina Henschel
Details
Screenshot Seamonkey with wide window (42.14 KB, image/png)
2016-02-23 18:27 UTC, Regina Henschel
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Xisco Faulí 2016-02-23 16:16:09 UTC
Created attachment 122916 [details]
masking-path-03-b

Regression from a2d8a9873deb5b39198c346cf637a9a8cb9e5105

Reproduced with 

Version: 5.2.0.0.alpha0+
Build ID: 003d0ccf902d2449320dd24119564565a384f365
CPU Threads: 4; OS Version: Windows 6.1; UI Render: default; 
TinderBox: Win-x86@39, Branch:master, Time: 2016-02-23_00:56:18
Locale: es-ES (es_ES)
Comment 1 Regina Henschel 2016-02-23 18:10:47 UTC
Why do you think it is a regression? With the setting width="100%" and height="100%" there exist no obvious method for calculating the viewport. Browsers use the inner area of their window, when opening a svg file as standalone graphic. For Draw or Impress such does not exist. Do you not like the decision, to use the size of the svg content as viewport? The user can use the cropping tool to reduce the image to the size he wants; which is not possible in browsers. What do you want to use as viewport instead?

Reading "The negotiation process uses any information provided by the containing document and the SVG content itself to choose the viewport location and size." in the first section of "7.2 The initial viewport" [https://www.w3.org/TR/SVG/coords.html#ViewportSpace] I think, it is a valid method to use the content size to determine a viewport in this case.

When you define a proper viewport by making at least one of width and height absolute, then the content is clipped to the viewport.
Comment 2 Regina Henschel 2016-02-23 18:22:18 UTC
Created attachment 122928 [details]
Screenshot Seamonkey 2.39 with high window
Comment 3 Regina Henschel 2016-02-23 18:27:20 UTC
Created attachment 122929 [details]
Screenshot Seamonkey with wide window

The 100% value in width and height has the effect, that always one of width and height are the same as the space in the window and determine the size of the image. The other direction shows as much content as possible in the window. The cropping does not happen at the black rectangle, but at the window edge, because the window is the viewport in browsers.
Comment 4 Xisco Faulí 2016-03-01 14:37:11 UTC
Hi Regina,
No, I'm ok with the changes you did with regards to the height and width being equal to the viewbox. I just wanted you to take a look at it in case this was a corner case introduced by your changes, but if you say it's ok as it's right now, it's ok for me too. Thus, I'm closing this.

best