6

I've been playing around with the new https://fonts.google.com/specimen/Roboto+Flex?query=roboto#standard-styles font from Google, and found myself a style I really like (screenshot below). I would like to use it in places that don't yet support variable fonts (not on the web).

Is there a way to export/convert a variable font to a static one while keeping the customization? I've looked around a lot but haven't found any tools for it. Ideally I'd like an online or open-source tool I can use on Linux, but I'm open to other suggestions, too.

enter image description here

3
  • Hi. Welcome to GDSE. When you say "to use it in places that don't yet support variable fonts" what places do you mean? For what purpose specifically? Do you need it to be actual text, or could you convert to vector outlines and use those? Commented May 14, 2022 at 0:28
  • I'd like to use it as my default font on my computer (Ubuntu). For that I think it has to be an actual font, but I have to admin I know very little about font file formats, so I don't know for sure whether an outline would work. Another place I'd like to use it is in presentations (Google Slides, pdfs). Commented May 14, 2022 at 2:59
  • 1
    You could certainly use variable fonts in Inkscape which is open source and works on Linux, convert to outlines, export as SVG to use in another program, or export as PDF. But for your OS you'd need an actual font. You could use FontForge,which is open source and works on Linux, but I'm no expert at using font editing software. I found a discussion here on a forum which might help. So it would seem to be possible. Commented May 14, 2022 at 10:45

1 Answer 1

7

The Python package fontTools works great for this. You need the mutator.

For example,

fonttools varLib.mutator VARIABLE-TTF wght=490 wdth=90 

where VARIABLE-TTF is the path to the variable ttf from Google.

2
  • Fantastic, @jake-n, works flawlessly. Thanks a lot! Commented Oct 4, 2022 at 0:57
  • This may not set the correct metadata in the resulting TTF though – e.g. I had to change the family name, etc. in FontForge afterwards. Commented Sep 19, 2024 at 9:57

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.