Great to hear :-) After all, D3 is often used to generate SVG :-). Also the D3 syntax / API design is inspired by jQuery, so if you know jQuery then D3 is also easier to understand.
Can I find the exact height and width occupied by SVG text? What are the parameters on which the height and width depends? Only on font-size and letter spacing? What is the exact relation or formula to retrieve these from SVG text?
No, you cannot find the exact height and width occupied by an SVG text, unfortunately (at least not that I know of). It is possible with an HTML 5 Canvas to measure the width of a text before drawing it - see here: tutorials.jenkov.com/html5-canvas/text.html#measuring-text-width
@@JakobJenkov I wanted to create a SVG through my code using the data extracted from image processing, since image processing has only height and width and coordinates with it, I had to use any relation for creating that SVG. Any help in that case?
Because you can use SVG text inside SVG diagrams. You can bend SVG text, and add effects to it which are not possible with HTML text (at least not at the time I made this video).
Man this is super helpful. I am learning D3, but decided to go through all your vids for SVG and now D3 is making much more sense.
Great to hear :-) After all, D3 is often used to generate SVG :-). Also the D3 syntax / API design is inspired by jQuery, so if you know jQuery then D3 is also easier to understand.
Can I find the exact height and width occupied by SVG text? What are the parameters on which the height and width depends? Only on font-size and letter spacing? What is the exact relation or formula to retrieve these from SVG text?
No, you cannot find the exact height and width occupied by an SVG text, unfortunately (at least not that I know of). It is possible with an HTML 5 Canvas to measure the width of a text before drawing it - see here:
tutorials.jenkov.com/html5-canvas/text.html#measuring-text-width
@@JakobJenkov I wanted to create a SVG through my code using the data extracted from image processing, since image processing has only height and width and coordinates with it, I had to use any relation for creating that SVG. Any help in that case?
how i can use google fonts in my logo width SVG?
That's a good question! I don't know, actually. Maybe you can change the font in SVG 2.0
very clear explanation, at a good time in my design stage, thank you
You are welcome ! :-)
thanks for the tutorial (y). I have a question please, why would you use SVG text over HTML text? thanks
Because you can use SVG text inside SVG diagrams. You can bend SVG text, and add effects to it which are not possible with HTML text (at least not at the time I made this video).
@@JakobJenkov I see, thanks.
@@JakobJenkov thanks, very interesting indeed.
I could not add Add < sign
How to add comparison signs in a text element? Thanks
Fantastic svg videos. Thank you very much!
excellent tutorial. Thanks a lot.
Thank you! ... and you are welcome ! :-)
Great stuff
Thanks!
Hi do you know how to apply antialiasing property to text svg? The text rendering attribute doesn't seem to change anything :(
No, I don't know that, unfortunately