Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

It is possible to separate roman and italic variable font file? #526

Open
ottta opened this issue Nov 1, 2023 · 3 comments
Open

It is possible to separate roman and italic variable font file? #526

ottta opened this issue Nov 1, 2023 · 3 comments

Comments

@ottta
Copy link

ottta commented Nov 1, 2023

Is your feature request related to a problem? Please describe.
This issue's about variable font on web, my experience using variable fonts in web development especially in front-end area really makes the job easier, because I only need to load one or maybe two files for several styles includes italic to avoid waterfall data fetching. Slanted "slnt" axis doesn't work on default html text formatting tags such a <i /> and <em /> even though by default these tags have font-style: italic; on any browser.

Describe the solution you'd like
As a GF Guide recommendation to separate roman and slanted (to be italic)

Describe what you've tried so far
I never touch the masters font file, but for temporary solution for web development is manually adding:

i, 
em {
    font-variation-settings: "slnt" -15;
}

or in the modern environment like TailwindCSS

.italic {
    font-variation-settings: "slnt" -15;
}

However it breaks the native html text formatting tags and TailwindCSS experience for entire web pages

@arrowtype
Copy link
Owner

Hey, thanks for asking! Yeah, I should split the variable font for web, and add that to the release. It is annoying browser support is so bad, but it is what it is.

For now, you can split it on your own in two ways:

  1. Use the app Slice for a GUI
  2. Use the FontTools Instancer in the terminal (or via Python).

@ottta
Copy link
Author

ottta commented Nov 1, 2023

Glad to hear if you willing to separate roman and italic, and I will let this issue open until the upcoming release, is it ok right?

@arrowtype
Copy link
Owner

Hey, sorry I missed replying to this earlier! Yeah, let’s leave this open until the next release (hoping to do a small one soon).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants