tikz add tag
5 years ago user 3.14159

I am wondering if one can get the outlines of glyphs somehow into TikZ without too much hassle.

In asymptote and to some extent in PSTricks this is possible, see e.g. https://tex.stackexchange.com/a/21593. (IMHO in PSTricks this is sort of a cheat, but I do not want to discuss this here.)

In TikZ it seems to be possible only with tremendous effort, see e.g. https://tex.stackexchange.com/a/21594. However, this information is almost a decade old. So I am hoping that there are now more user-friendly methods available, ideally as easy to use as in asymptote.

Why am I interested in this? One reason is that there is the perspective library, another reason is that there are generic nonlinear transformations. It would be really gorgeous if one could apply them to glyphs in TikZ.

To be clear, what I am not interested in is something that can also be achieved with path fading. I really want to have an explicit path that can be transformed in an any way a path can be transformed, without limitations. And, of course, the more user-friendly, the better.

What have I tried? Not much that I can present here. So no MWE, sorry. I could copy one from the links above, but do not see what this will add. (This is not because I am too lazy to forge an MWE, but I really do not see its purpose here.)

Top Answer
4 years ago Anonymous 2084

The present answer builds upon two good answers from Stack Exchange:

Maybe Tikz can add a library for this.

Boring output is

Screenshot

4 years
Jairo A. del Rio — Wednesday, 17th Mar 2021 06:11

If you consider a bit of cheating, you could use LuaLaTeX to pass data from MetaPost to TeX/TikZ. However, outlining for TTF/OTF fonts is AFAIK only supported in ConTeXt. For pdf(La)TeX see this: https://tex.stackexchange.com/questions/580204/outlines-for-a-tex-label-in-metapost

a year
samcarter — Wednesday, 1st Jan 2020 15:07
samcarter — Wednesday, 1st Jan 2020 15:06

Certainly not 2020ies style, rather a workaround: I’m using the “Object to Path” function from inkscape and svg2tikz:

3 days
Skillmon — Sunday, 29th Dec 2019 12:33

I guess the best approach would be using LuaTeX and/or Metafont/-fun. I have no idea how this should be done in pdfTeX. But I never tried anything like this nor was I interested in it in the past 😃

Enter question or answer id or url (and optionally further answer ids/urls from the same question) from

Separate each id/url with a space. No need to list your own answers; they will be imported automatically.