Bug 43065 - DRAW, WRITER, etc Modifies SVG "stroke-width"
Summary: DRAW, WRITER, etc Modifies SVG "stroke-width"
Status: RESOLVED NOTABUG
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Draw (show other bugs)
Version:
(earliest affected)
Master old -3.6
Hardware: Other macOS (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
: 43063 (view as bug list)
Depends on:
Blocks:
 
Reported: 2011-11-18 06:09 UTC by rk601
Modified: 2011-11-28 00:17 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
Circle SVG Used in this Test (200 bytes, image/svg+xml)
2011-11-18 06:09 UTC, rk601
Details
Example of SVG stroke-width in DRAW (93.78 KB, image/png)
2011-11-18 06:10 UTC, rk601
Details
Example of SVG stroke-width in DRAW - resized (111.57 KB, image/png)
2011-11-18 06:10 UTC, rk601
Details

Note You need to log in before you can comment on or make changes to this bug.
Description rk601 2011-11-18 06:09:47 UTC
Created attachment 53654 [details]
Circle SVG Used in this Test

With regard to BUG #42882, there apparently is some inconsistent behavior when SVG is resided.

On 2011-11-14 22:58:41 PST from BUG #42882 Rainer Bielefeld wrote, "...you have to use a separate drawing Editor to prepare the picture so that it can be used as illustration in WRITER. Here for example you can open the SVG in DRAW, there a resize will not modify lines width, and then you insert the small feet with thick outlines into WRITER.

WONTFIX, because DRAW offers the required function and WRITER is not a SVG editor."

We have found, that at least with OSX, SVG pictures created within DRAW and INSERTED into DRAW both "modify the lines" when the SVG pictures are resized. In other words, the SVG pictures' "stroke-width" appear to be modified when resized, and therefore DRAW does not appear to offer the desired functionality.

As an example, we tested the desired functionality in the Master:

LibO-dev 3.5.0 
Build ID: 8f87c3d-5d03837-adcf6d5-c4bb9bd
On OSX 10.6.8

Located at:

http://dev-builds.libreoffice.org/daily/MacOSX_10.6.7_Intel_no-moz/master/2011-11-16_01.40.47/

with

master~2011-11-16_01.40.47_LibO-Dev_OOO350m1_MacOS_x86_install_en-US.dmg

Steps to reproduce:

1. Start LibreOffice and choose File -> New -> Drawing.
2. At the bottom of the window, click on the Basic Shapes tool (in this case
the diamond shape).
3. Draw a small Diamond shape.
4. Select Insert -> Picture -> From File...
5. Select Circle.svg
6. Resize both SVG pictures.

Expected results: Reportedly, the SVG pictures' "stroke-width" will remain the same.
Actual results: The SVG pictures' "stroke-width" does not remain the same, so desired functionality is not available.

Please see BUG #42882, where we suggest that the desired functionality would allow a person to control whether or not the “stroke-width” gets scaled or stays the same; for example right-clicking on the SVG picture from within LibreOffice would produce a pop-up menu that allows the user to choose either to re-size the “stroke-width” or not re-size the “stroke-width.” This would be similar to the current functionality where the pop-up menu contains the commands "Line... Area... Text..." etc. This functionality could be available within WRITER, DRAW, etc.

Thank you.
Comment 1 rk601 2011-11-18 06:10:18 UTC
Created attachment 53655 [details]
Example of SVG stroke-width in DRAW
Comment 2 rk601 2011-11-18 06:10:43 UTC
Created attachment 53656 [details]
Example of SVG stroke-width in DRAW - resized
Comment 3 Rainer Bielefeld Retired 2011-11-18 11:27:40 UTC
There is a difference between a .svg opened with DRAW (what becomes an ODF vector drawing) and an inserted picture what I currently do not understand in det.

Steps to reproduce:

1. Download "Circle SVG Used in this Test" and create a copy "Circle - Copy.svg"
   (copy / paste in explorer)
2. Start LibO MASTER (!)
3. Menu 'File -> open' -> "Circle - Copy.svg"'
4. A DRAWING will be opened showing the circle
5. Click circle (control points appear)
6. press "shift" click top middle control point,  drag to the bottom of
   the page until size of the drawing is decreased to app. 4 mm
   Expected: Should behave similar to a shape with filled area, red border line
             remains thickness 0,35mm (you see that in the 'Line And Filling' 
             toolbar
   Actual: As expected'
   Additional info: Opening more complex .svg in Drawing will show that the 
           drawing contains lots of elements (lines, ...). All that will 
           behave as a quite normal LibO DRAWing with editable elements.

11. Stay in document, menu 'Insert -> Picture -> From File - "Circle.svg"
    (Cicle appears, "Picture" Toolbar appears, what show that a Picture has been
     inserted, not a vector graphic)
12. Click circle (control points appear)
13. press "shift" click top middle control point,  drag to the bottom of
   the page until size of the drawing is decreased to app. 4 mm
   Expected: Should behave as a Complete picture (like a .png), border width
             keeps ratio to circle diameter and becomessmaller
   Actual: As expected'
   Additional info: Inserting more complex .svg into Drawing 
            (344Tests/cicle.svg)  will show that the drawing only is a 
            complete picture without editable elements (lines, ...). All that
            will behave as a Picture (like a .png).

@rk601@yahoo.com:
This one seems to be NOTABUG, or can you find different behavior in steps 1 ... 13 with other vector formats what can be opened with and inserted to LibO?
Comment 4 rk601 2011-11-18 19:14:30 UTC
@Rainer Bielefeld

Thank you for your detailed tests. We obtain similar behavior, but there is confusion. 

Any idea why there is a difference between a .svg opened with DRAW (that becomes an ODF vector drawing) and an inserted SVG? Shouldn't SVG be SVG? Are we missing something? According to tbehrens@novell.com in Bug 41995, he states, "...So what LibreOffice will do, starting with 3.5, is by default store true .svg files." A "true .svg" behaves differently from bit-mapped pictures (which is a main reason why SVG is greatly desired), and the ability to create, edit and use SVG pictures is a goal of the LibreOffice development team.

This BUG focuses on the underpinnings of how SVG is created, stored, used, etc. If the LibreOffice team desires to implement SVG then why have SVG function differently? Inconsistent use of SVG will most likely confuse and perhaps frustrate the user. Why, in LibreOffice, design and develop SVG to be in-essence PNG? Why allow SVG to be created (exported) by LibreOffice when in-effect it isn't SVG at all?

Please explain?
Comment 5 Rainer Bielefeld Retired 2011-11-19 00:08:15 UTC
*** Bug 43063 has been marked as a duplicate of this bug. ***
Comment 6 Rainer Bielefeld Retired 2011-11-28 00:17:28 UTC
And what will be if you insert a dxf, a png and an svg to a drawing? If you want to keep the format related characteristics you will have to invest some more work, for example to insert them as OLE bojects or similar. 

Still no reference contributed showing that the current behavior is a bug, no concept contributed showing necessity to change/improve current behavior. Here is no problem at all, so closing.