SVG text does not scale properly




10 years ago
10 years ago


(Reporter: Hughman, Unassigned)


Firefox Tracking Flags

(Not tracked)



(1 attachment)



10 years ago
User-Agent:       Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv: Gecko/2008072820 Firefox/3.0.1
Build Identifier: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv: Gecko/2008072820 Firefox/3.0.1

This seems to be a problem on both the X and Y axis scaling.
It is especially noticeable on single lines on text when resizing the window with a viewbox and similar scaling methods.

The main of the problems are that Y scaling affects the X scale when its not supposed to and the X scaling is not consistent.

As some say "a picture is worth 1000 words" and in this case I have made an SVG test case that I will attach. It looks wrong in Firefox 3.0.1 but correct in Inkscape 0.46.

Reproducible: Always

Steps to Reproduce:
1. Add a long line of text (larger than window) in a viewbox SVG with a bg rect to outline it (more noticeable this way).
2. Resize window to different sizes.
3. Notice the last char of the line isnt always the same. Longer the visible line the bigger the change.
(This is mainly the X axis problem I think)
Actual Results:  
The last character of the line that is inside the box is always different.

Expected Results:  
For it to be correctly scaling the last character in the box should always be the same and in the same location of that character.

Comment 1

10 years ago
Created attachment 337652 [details]
The test case I promised

This highlights the main problems that I can find with the scaling of the text in the best way I could think of.

You want geometricPrecision. The default is auto and you are seeing its speed/legibility and geometric precision tradeoffs.
Last Resolved: 10 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.