newsdev / ai2html

A script for Adobe Illustrator that converts your Illustrator artwork into an html page.

Home Page:http://ai2html.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

font problem

szeemi opened this issue · comments

I can not make Roboto Condensed fonts to work. What could cause my problem?
{"aifont":"RobotoCondensed-Bold","family":"roboto-condensed,sans-serif","weight":"700","style":"normal"},
{"aifont":"RobotoCondensed-Light","family":"roboto-condensed,sans-serif","weight":"300","style":"normal"},
{"aifont":"RobotoCondensed-Regular","family":"roboto-condensed,sans-serif","weight":"400","style":"normal"},

thx

I can think of a few things that could cause this problem.

One possibility is that ai2html applied the font style correctly, but a web font named "roboto-condensed" is not present on your HTML page. To investigate this, you could view the page in a browser and use Chrome's DevTools or equivalent to inspect one of the text objects that uses Roboto to see if the "roboto-condensed,sans-serif" font family was applied to the text. Or, you could open the html file in a text editor and look at the CSS classes that were generated for the text in question to see if "roboto-condensed" was applied. If the correct CSS was generated, then the problem is probably with a missing web font.

Another possibility is that ai2html was unable to load your custom font rules. If this is the case, then ai2html's popup messages should include a message such as: "Missing a rule for converting font: RobotoCondensed-Regular". Let me know if you're getting this message and we can figure out how to get your font rules loaded.

If the problem is something other than these two options, let me know and we can keep troubleshooting.

I'll try to find a way to document this kind of gotcha... maybe an FAQ or troubleshooting guide on the ai2html.org site.