Search code examples
cssfont-family

css - machine specific font-family


I'm writing a sample web-app for myself to be run on my computer. I'd like to use a font that exists on my machine "Helvetica Neue UltraLight". However I can't get the browser to use the font. It can use the "Helvetica Neue" but not the Ultralight flavour.

Thanks


Solution

  • You have to determine the name of the specific typeface in your computer and use it. Alternatively, you can use @font-face with the specific font file name, provided that you use a font format recognized by the browser being used.

    If the name of the typeface cannot be easily guessed, you may need to take the long route of analyzing the font using e.g. DTL OTMaster Light. By CSS specifications, the name to be used is the PostScript name or the full name of the font. These can be found in the names table at entries corresponding to nameID values 6 and 4.

    Or you can take a different route and use a font listing tool like http://hasseg.org/stuff/fontList/example.html or http://www.fileformat.info/info/unicode/font/fontlist.htm