Dynamic Fonts in CSS

Add-in Express™ Support Service
That's what is more important than anything else

Dynamic Fonts in CSS
Anyway to access local resources? 
Robert Apostolico




Posts: 70
Joined: 2013-09-06
I asked a similar question regarding images in CSS.

The more I am working with ADXIE, the more I feel this type functionality should somehow be exposed, if it is not already.

Here is a snippet from a CSS file that I use and inject in a similar Chrome extension:


@font-face {
	font-family: Museo;
	src: url('chrome-extension://__MSG_@@extension_id__/fonts/MuseoSans_500.otf');
}
@font-face {
	font-family: SegueUI;
	src: url('chrome-extension://__MSG_@@extension_id__/fonts/segoeui.ttf');
}
@font-face {
	font-family: OpenSans;
	src: url('chrome-extension://__MSG_@@extension_id__/fonts/OpenSans-Regular.ttf');
}
@font-face {
	font-family: OpenSansBold;
	src: url('chrome-extension://__MSG_@@extension_id__/fonts/OpenSans-ExtraBold.ttf');
}


Under the Chrome extension, we're able to distribute resources (fonts, images) with the installation, and then programmatically access them while running.

Is there some clean, easy way of doing so with ADXIE?

To me, it seems somewhat silly that an installed extension (program) would have to download fonts or images from a remote url each time it loaded.

Please advise.
BApostolico
Posted 19 May, 2014 10:48:55 Top
Sergey Grischenko


Add-in Express team


Posts: 7187
Joined: 2004-07-05
Hi Robert,

IE extensions don't install any resources (fonts, css, images and so on). But you can add all resources to a .resx file and inject them into any web page programmatically at the runtime.
However, you gave me a good idea. I will consider adding such a feature to Add-in Express for IE. Thank you.
Posted 19 May, 2014 11:30:48 Top