newsdev / ai2html

A script for Adobe Illustrator that converts your Illustrator artwork into an html page.
http://ai2html.org
Other
897 stars 145 forks source link

Text outline as text-shadow? #93

Open cedricsam opened 6 years ago

cedricsam commented 6 years ago

I was wondering if there had been discussion before about text outlining? In other words, do we have a mechanism to convert stroke colors on text in Illustrator to some equivalent form in HTML/CSS?

I know that text-outline was removed from CSS3, and the WebKit-specific -webkit-text-stroke is non-standard. Would the seemingly good way to accomplish this with a text-shadow of 1px on every side? (i.e. with text-shadow: 1px -1px 0 #fff, 1px 1px 0 #fff, -1px 1px 0 #fff, -1px -1px 0 #fff;)

jsonkao commented 5 years ago

I think it should be added to the documentation's Custom CSS section that text-shadow is a solution for text outlining (albeit for only a 1px stroke).