SVG text scale - width and height
16,170
Solution 1
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.
Solution 2
SVG transform on text attribute works excellent!
<text transform="scale(1, 2)" fill="orange"
font-family="Arial" font-size="70">
This snippet, for example, will increase your text by 2x at Y-axis.
![Admin](/assets/logo_square_200-5d0d61d6853298bd2a4fe063103715b4daf2819fc21225efa21dfb93e61952ea.png)
Author by
Admin
Updated on June 06, 2022Comments
-
Admin about 2 years
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
-
Bjorn almost 12 yearsThis question was not about inkscape.