GNOME Bugzilla – Bug 607564
custom shape svg:text elements positioned wrong when opening a saved .dia file
Last modified: 2011-12-06 09:34:39 UTC
Created attachment 151847 [details] Screenshots showing positioning of svg:text elements before and after When opening a saved .dia file, custom shapes with <svg:text> elements appear with the text positioned incorrectly. This positioning issue extends to printing and exporting the file. Adding a new instance of the custom shape to the diagram causes all existing instances of the custom shape to reposition the text correctly. The text is only positioned incorrectly if there are multiple instances of the shape. Steps to reproduce: 1) create a new diagram and add several instances of a custom shape containing a svg:text element. The results are more pronounced if the shapes are scattered randomly across the diagram. 2) save the diagram in the native .dia file format and close Dia 3) reopen Dia and reopen your savied diagram. The svg:text elements should now appear positioned incorrectly. 4) add a new instance of the custom shape and refresh the diagram, all of the old instances should refresh with their text positioned correctly. Refreshing before adding the new instance of the custom shape will have no effect.
Attaching the shape and the diagram would probably make look into this in more detail.
The first custom shape with text, you put on diagram, has the text on the wrong position. If you put a second instance, the text is on the right position. If you refersh then the diagram, also the first instance has then the text at the right position.
custom_distance_from(), custom_draw() and custom_update_data() are modifying the conceptionally const display_list, i.e. the Text object contained (shared between all object instances), but update_data was not restoring the previous state. http://git.gnome.org/browse/dia/commit/?id=fb449723e36a92a43fc3a15e565a6ff4556d4ee9
Cherry-picked to dia-0-97 branch
Created attachment 202823 [details] test shape This shape can be used to reproduce the issue but the issue is not limited to just this shape.
I'm still seeing this issue in ver 0.97.1 on Mac OSX 10.6.8.
(In reply to comment #6) > I'm still seeing this issue in ver 0.97.1 on Mac OSX 10.6.8. to be expected, target milestone is 0.97.2 - not yet released
My apologies, I misunderstood. Thanks.