Issue 118780 - copy title and desc from svg file to graphic object property when inserting a svg graphic
Summary: copy title and desc from svg file to graphic object property when inserting a...
Alias: None
Product: Draw
Classification: Application
Component: open-import (show other issues)
Version: 3.4.0 Beta (OOo)
Hardware: PC Windows XP
: P5 (lowest) Normal (vote)
Target Milestone: 4.0.0
Assignee: Armin Le Grand
QA Contact:
Depends on:
Reported: 2012-01-12 20:17 UTC by Regina Henschel
Modified: 2013-07-12 16:11 UTC (History)
2 users (show)

See Also:
Latest Confirmation in: ---
Developer Difficulty: ---


Note You need to log in before you can comment on or make changes to this issue.
Description Regina Henschel 2012-01-12 20:17:29 UTC
A svg-document can contain title elements and description elements. A graphic object in AOO also has a title and a description. For accessibility the value from the title and from desc sub-element of the outermost svg element should be copied to the corresponding properties of the graphic object.

A svg document can have title and description on each of its child graphics. But in AOO exists only one of them. Therefore the outermost should be used.

If the user decides to change the title or description text in AOO, then it should not be changed back from the svg source. Therefore this request is only for the situation, when the svg graphic is inserted the first time.

Please notice
Comment 1 Armin Le Grand 2012-02-09 17:25:03 UTC
ALG: Not as easy as it seems. Each entry in SVG may have a title and desc, but in AOO it is embedded to a single SdrObject (GraphicObject). Thus, it is not clear which tiltle/desc to take if there are several ones.
It is also not clear how to remember them. It would be possible to create a new title/desc primitive and add that information to the sequence of primitives, so it would be later available when breaking the object (and a pure break from primitives will be available).
Comment 2 Armin Le Grand 2012-03-26 16:30:46 UTC
ALG: Taking over.
Comment 3 Armin Le Grand 2012-05-14 17:22:30 UTC
ALG: Added code to scan for ObjectInfoPrimitive2D when graphic is changed/set at SdrGraphicObject; Title and Desc is taken from the outmost such info at primitives from SVG import, Name is set to filename of the inserted SVG. Need to check for SW graphic object and if/what is possible there...
Comment 4 Armin Le Grand 2012-05-15 11:15:14 UTC
ALG: Moved ObjectInfoPrimitive2D extractor to drawinglayer, changed name to be the filename only, added code to SW to set Title and Desc. No set of Name in SW currently, there is a SW-provided default name and it has to be unique. Had to do some changes to SW to get the detection running since inside the SwGrfNode constructors the SwFlyFrmFmt can not yet be found, thus had to change constructing instances. Also isolated GraphicObject access at SwGrfNode to const, thus all accesses to change Graphic there are saved and will trigger SVG name detection (onGraphicChanged()).

ALG: Done so far. Usage of Name,Desc in SdrObject dismantle will have to wait until SdrObjects will be constructed from primitives directly, the info is not available in metafiles.
Comment 5 Oliver-Rainer Wittmann 2012-06-13 12:33:17 UTC
getting rid of value "enhancement" for field "severity".
For enhancement the field "issue type" shall be used.