Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

SVG text scale - width and height

Tags:

text

scale

svg

i would like to scale a text in svg. If i use the font size width and height are scaled. Is there any way for just scaling width or height? - All examples i found using the scale tag witch didn't work or for the text i think.

Thanks for your help, Hendrik

like image 654
Hendrik Avatar asked Nov 04 '11 16:11

Hendrik


1 Answers

You can use the scale(x,y) transform command to scale an element. A scale of 1 is normal size, 0.5 is half normal size, and 2 is double normal size.

For example, add transform="scale(1, 2)" to your tag to scale it normally horizontally and twice the size vertically.

like image 112
Polynomial Avatar answered Jan 05 '23 07:01

Polynomial