'American Typewriter', 'Andale Mono', 'Arial', 'Arial Black', 'Arial Narrow', 'Arial Rounded MT Bold', 'Arial Unicode MS', 'Avenir', 'Avenir Next', 'Avenir Next Condensed', 'Baskerville', 'Big Caslon', 'Bodoni 72', 'Bodoni 72 Oldstyle', 'Bodoni 72 Smallcaps', 'Bradley Hand', 'Brush Script MT', 'Chalkboard', 'Chalkboard SE', 'Chalkduster', 'Charter', 'Cochin', 'Comic Sans MS', 'Copperplate', 'Courier', 'Courier New', 'Didot', 'DIN Alternate', 'DIN Condensed', 'Futura', 'Geneva', 'Georgia', 'Gill Sans', 'Helvetica', 'Helvetica Neue', 'Herculanum', 'Hoefler Text', 'Impact', 'Lucida Grande', 'Luminari', 'Marker Felt', 'Menlo', 'Microsoft Sans Serif', 'Monaco', 'Noteworthy', 'Optima', 'Palatino', 'Papyrus', 'Phosphate', 'Rockwell', 'Savoye LET', 'SignPainter', 'Skia', 'Snell Roundhand', 'Tahoma', 'Times', 'Times New Roman', 'Trattatello', 'Trebuchet MS', 'Verdana', 'Zapfino', 'Arial', 'Arial Black', 'Bahnschrift', 'Calibri', 'Cambria', 'Cambria Math', 'Candara', 'Comic Sans MS', 'Consolas', 'Constantia', 'Corbel', 'Courier New', 'Ebrima', 'Franklin Gothic Medium', 'Gabriola', 'Gadugi', 'Georgia', 'HoloLens MDL2 Assets', 'Impact', 'Ink Free', 'Javanese Text', 'Leelawadee UI', 'Lucida Console', 'Lucida Sans Unicode', 'Malgun Gothic', 'Marlett', 'Microsoft Himalaya', 'Microsoft JhengHei', 'Microsoft New Tai Lue', 'Microsoft PhagsPa', 'Microsoft Sans Serif', 'Microsoft Tai Le', 'Microsoft YaHei', 'Microsoft Yi Baiti', 'MingLiU-ExtB', 'Mongolian Baiti', 'MS Gothic', 'MV Boli', 'Myanmar Text', 'Nirmala UI', 'Palatino Linotype', 'Segoe MDL2 Assets', 'Segoe Print', 'Segoe Script', 'Segoe UI', 'Segoe UI Historic', 'Segoe UI Emoji', 'Segoe UI Symbol', 'SimSun', 'Sitka', 'Sylfaen', 'Symbol', 'Tahoma', 'Times New Roman', 'Trebuchet MS', 'Verdana', 'Webdings', 'Wingdings', 'Yu Gothic', MacOS/iOS Font List 'American Typewriter',
This code works on the simple principle that each character appearsÄifferently in different fonts. Var matched = (s.offsetWidth != defaultWidth] || s.offsetHeight != defaultHeight]) This is one of the more casual and spirited fonts in the mix, evoking memories of girls names in high school yearbooks, which could be ideal if youre looking to add a personal or hand-written feel to your design. S.style.fontFamily = font + ',' + baseFonts // name of the font along with the base font for fallback. get the default width for the three base fontsÄefaultWidth] = s.offsetWidth //width for the default fontÄefaultHeight] = s.offsetHeight //height for the defualt font create a SPAN in the document to get the width of the text we use to test Var h = document.getElementsByTagName("body") we test using 72px font size, we may use any size. And we use a LLi so that the same matching fonts can get separated we use m or w because these two characters take up the maximum width. and if it doesn't match all 3 then that font is not available. a font will be compared against all the three default fonts. * Replaced sans with serif in the list of baseFonts * then that font is 100% not available in the system * Comparing font against all the 3 generic font families ie, * to parent element if the font is missing. * as in FF3.0 font of child element didn't fallback * Changed comparision font to default from sans-default-default, * particular font in a browser using JavaScript and CSS. * JavaScript code to detect available availability of a