Reloading Text on Path Renders Incorrectly

Bug #1256798 reported by Jon Grossart
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Inkscape
Confirmed
Low
Unassigned

Bug Description

Ran into a "text on path" bug where when reloading the file, the SVG isn't rendered the same as when it was saved.

1. create a path
2. create a text object (FlowedText) with centered alignment
3. put text on path (which convertes it to a standard Text object)
4. see correct alignment
5. save file and close inkscape
6. reload file
7. see incorrect alignment/missing text
8. selected text and set alignment to anything other then center and then center again (Inkscape already thinks it's centered so you can't click on that again)
9. see correct alignment
10. save and close inkscape
11. reload file
12. see correct alignment

I did a quick diff on the SVG of the project I was working on (not the test files), and it seemed that there were some elements to the text object that got added on the conversion from FlowedText to Text that get removed when you re-align the text object.

This happened on 0.48.4. I tried loading the intermediate file with a daily inkscape build, and it still had the same problem, so this definitely has to do with the way inkscape is reading/writing the data vs. how it is originally displaying the data.

Tags: aligning text
Revision history for this message
Jon Grossart (jon-grossart) wrote :
Revision history for this message
Jon Grossart (jon-grossart) wrote :
Revision history for this message
Jon Grossart (jon-grossart) wrote :
Revision history for this message
Jon Grossart (jon-grossart) wrote :
Revision history for this message
Jon Grossart (jon-grossart) wrote :
Revision history for this message
Jon Grossart (jon-grossart) wrote :
Revision history for this message
Jon Grossart (jon-grossart) wrote :
Revision history for this message
Jon Grossart (jon-grossart) wrote :

This may be similat to bug #170995.

description: updated
jazzynico (jazzynico)
tags: added: aligning text
Revision history for this message
su_v (suv-lp) wrote :

AFAIU duplicate of (or at least same underlying issue as tracked in)
- Bug #799736 “Text put on path ignores 'Align Center' on <tspan> after reload”
  <https://bugs.launchpad.net/inkscape/+bug/799736>

'Flowed text' cannot be put on path as is ('flowed text' is not part of SVG 1.1) - Inkscape converts it to regular text first, and during this conversion, the directive to center the text (style="text-anchor:middle;text-align:center") is initially applied to the inner <tspan> element, which consequently triggers the same problem after putting that text on path as tracked in bug #799736.

tags: removed: aligning
Changed in inkscape:
importance: Undecided → Low
status: New → Confirmed
tags: added: aligning
Revision history for this message
jazzynico (jazzynico) wrote :

Confirmed on Crunchbang Waldorf, Inkscape trunk revision 12833.

Note that Curved Test.2.reload.svg renders correctly with Iceweasel 20 (Firefox) and only slightly shifted with Batik/Squiggle 1.7.

Changed in inkscape:
importance: Low → Undecided
Revision history for this message
Jon Grossart (jon-grossart) wrote :

I think it might be different thatn 799736 (although similar).

If you compare the svg files between 2 and 3, the only real difference is that in the .2, there is a double <tspan> added to the elemnts.

In the .3, the double tspan is corrected, and

 x="192.75386"
       y="0"

is added to the top <text> element. So, it would seem that the problem is that when the first FlowedText is converted into text, it's not appending some coordinates that it needs to in order to read back correctly.

jazzynico (jazzynico)
Changed in inkscape:
importance: Undecided → Low
Revision history for this message
Jon Grossart (jon-grossart) wrote :

still present in 0.91.0

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.