Embedding mac font into flex application - apache-flex

I have one font(VinylRegular). This font has extensions (like .ttf, .otf) of PostScript Type 1 outline font. How do I embed such fonts into a Flex application?

There are several ways to embed fonts, all of them are explained here: http://livedocs.adobe.com/flex/3/html/help.html?content=fonts_04.html

Related

How to enable font variant like "Italic Display"

I've got a font rendered on webkit (specifically in the text editor "Nano") and I'd like to display an OTF font that has a variant called "Garamond Premier Pro Italic Display". I believe it's a "suitcase" font.
Here's what the font looks like in Font Book:
Things I've tried:
font-variant-alternates: character-variant("ItDisp");
and
font-variant-alternates: character-variant("Garamond Premier Pro Italic Display");
No dice.
Any thoughts here? Or is this just not possible?
Unfortunatly this is not possible on the web at the time of writing.
The only real options available to use are as follows:
italic
normal
oblique
You can read up on the font-style attribute and the different things you can do with it here: https://developer.mozilla.org/en-US/docs/Web/CSS/font-style
There are /MANY/ fonts on desktop platforms that simply will not work on the web, as the web use different file formats. It is recommended to use fonts that are specifically designed for use on the web.
Also a note that font-variant-alternates is only supported in Firefox 34+ and Safari, and as such should not be used in production.

importing a font into css file to work with IE [duplicate]

I'm trying to determine the status of support for the TTF font format on Internet Explorer. (I don't have any Windows machines on hand to try it with.) The table at caniuse states that IE from version 9 onwards supports TTF but "only working when [fonts are] set to be installable". What does that mean? That page links to a blog post on MSDN, which describes updated font support on IE9. It isn't very clear or explicit; I think the "raw fonts" being referred to mean ttf and otf. It says "supported font formats include ... raw fonts with embedding permissions set to installable"
So, in summary:
Does IE support ttf fonts at all?
If ttf support exists, does it differ among IE9, IE10, and IE11?
What does "embedding permissions set to installable" mean in reference to ttf fonts?
So as I mentioned in my question above, Internet Explorer has some ttf support starting with version 9, but "only working when [fonts are] set to be installable".
Some background:
...TrueType fonts have embedding "bits" which allow the creator of the
font to decide the level of embedding that will be permitted. There
are four different embedding bits: (1) no embedding, (2) embedding for
view and print only, (3) embedding for view, print and editing, and
(4) installable embedding.. Many small type design houses have set
their embedding bits so that embedding of any kind is not permitted. ...
Source (also contains a lot of other information on this) and here's Another source with similar info
In another question, dealing with the embedding bits was discussed. It was revealed there that the Font Squirrel webfont generator automatically deals with these embedding bits by default on most fonts. Since I had ran my font through font squirrel I was good to go. I tweaked my CSS to prefer TTF over WOFF for testing and obtained the following results using webpagetest:
IE8 Did not work with TTF. It fell back to EOT
IE9 Worked with TTF
IE10 Worked with TTF
Note that I did not test fonts without the embedding bits set to installable, no I cannot say anything about that. But the general conclusion is that TTF fonts work in IE 9 onwards when the embedding bits are set to installable
Just google internet explorer ttf support or alike which would give you lots of information like eg http://www.fontspring.com/blog/fixing-ie9-font-face-problems
IE support for TTF is unclear: some sites claim support (like caniuse) other deny that (like http://webfonts.info/node/379)
In a ttf file there is information on what a user is allowed to do with the font. For TTF fonts to be allowed to be used in websites the font's embedding bits must be set to installable. The 'embedding bits' refer to fsType information in the OS/2 table, and 'installable' means that all fsType bits are off. So even if a browser supports TTF the font's foundry could deny usage of particular fonts.

How can I Use a Font Suitcase with the #font-face CSS statement?

I would like to use the Eurostyle font in my Rails application. We got it a while ago and installed in on our Mac computers. The font shows up in all our applications.
This will be my first time using the #font-face CSS statement in my stylesheet. I could not find any examples using a font suitcase. I have found a few solutions on how to split the font. So far the one I found has not worked. The link below suggested using DFontSplitter but when I did I got an error which is listed below. I have no idea what this is.
Want to embed a font but cannot convert from Font Suitcase or PostScript Type 1 files
The error message is: ‘Can't find an appropriate resource fork in /Users/xxxxxxx/Desktop/Exported Fonts/Eurostile/Eurostile
The only other solution I saw was very complicated and was for Mac OS 9.
Has anyone successfully used a font suitcase with the #font-face statement? If not how do I convert this to ttf or some other font format that works on popular browsers?
Short answer: you can't. #font-face is for loading individual font files, not suitcases/fontbooks/opentype collections/etc.
Long answer: there is no long answer, the short answer is all there is to it.
Convert the individual fonts you need to an opentype format, or ideally an opentype format that's been wrapped by a WOFF (WOFF v1 has massive support, WOFF v2 not yet, it's too new), and point to those with your (possibly multiple due to multiple font styles and weights) #font-face rules.
I was able to find a solution to convert my font suitcase to TTF using the solution from this link below.
http://macthoughts.net/20131112-373
After converting my suitcase file I copied the TTF files into my Rails application. I changed the src value in my stylesheet to point to the font files in my application. Now people who do not have the font installed will see the font I want in my Rails application.
I was able to get ttf files from font suitcase files this way:
I opened the Font Book app on my mac (osx 10.13.2), and located the font (make sure it's installed). Select the font and click file - export fonts and select a location.
The result in my case was a ttc file. I could convert this file easily with an online converter like this one.

what is a webfont and can i rely on them

i want to add pretty fonts to my Bootstrap site. i'm a programmer, not a designer.
I googled around and ended up at Google Webfonts website. Google's own font browser does not work (all the fonts default to a serif or something) for any of my browsers (OSX Chrome, OSX Safari, Win7 Chrome, Win7 IE9), all the fonts show up the same.
why doesn't google's webfont broswer work for me? http://www.google.com/webfonts
how can i trust them to work for everyone else
what is the bulletproof way to use custom
fonts?
to i have to buy them and host them myself? is this a bad idea?
Web fonts are fonts that have been licensed specifically for web-use. Besides Google Webfonts, there are other font sites that offer free (and legal) fonts for use on the web like Font Squirrel (free), and Typekit (mostly a paid service). Font Squirrel has a lot of fonts with #face kits that can help end the "browser blues", and make it easy to host the fonts on your own server (my preference).
There's a good article on A List Apart that will help you a bunch - have a read
BTW - it's a violation of your font license to take a font from your computer and run it through a true-type converter (for use on the web)...unless you've purchased/established licensing for web-use via the font provider/manufacturer/creator, etc.
But i used them a couple of times so thought of sharing with you guys. I am just answering for How to use them?
For ex:
When you use a particular web font Archivo then you need to include its style sheet as follows
<link href='http://fonts.googleapis.com/css?family=Archivo+Narrow' rel='stylesheet' type='text/css'>
In other way you need to install the fonts API so that you dont need to make a online request every single time.
They should be supported by most of the modern browsers.
Can't guess the reason for the first question.
Google web-fonts will work with every browser and I'm sure it is working. There are some issues.
** Fonts will be not smooth or fonts will be jugged in some browsers such as IE. Also fonts are not clear some times (Some fonts). You have to use CSS shadows ..etc to fix this.
You can use your own web-fonts. Download font and convert it to .ttf, .svg, .eot and .woff and call them in CSS with #font-face
You don't have to buy them if you are using like above example. But you will have to buy the font if it is commercial.
** You can use cufon.js too.

Difference between embedded and system fonts in flex

I need to use multiple fonts in my Flex 4 application, so I compile them into swf and load at runtime. I have single .ttf file for each font. When I dont load font's swf file at runtime, flex uses copy of this font installed on my system, and it works fine - I can switch between regular, bold and italic faces of the font correctly.
However, when I load fonts from swfs, setting their style to bold or italic makes no effect. I tried different ways of compiling swfs (css using mxmlc compiler, fontswf utility, .as files with [embed] tags), but nothing worked. When compiling using css it sometimes throw errors that font face is not supported, and it seems that some fonts are available only in bold-italic style only or bold style only.
I use cff fonts, load them using etcs.ru.utils.FontLoader utility. Fonts are loaded correctly, I check this with Font.enumerate fonts.
So is there any way to embed these .ttf files with all styles available?
Here is example how to embed the same font with different font faces.
What about the difference between system and embed fonts, system fonts can differ on different computers of different OS and finally can be absent on a user computer. But embed fonts will display the same way in any configuration.

Resources