Can you detect if Cleartype is enabled on PC via javascript?
-
29-09-2019 - |
Question
Some @font-face fonts don't play nice with non-cleartype settings (gets really choppy on the edges)
Is there a way to detect this via javascript so that I can do a modernizr-style class addition to the body if cleartype is off so I can use this in my CSS
Solution
In IE 6+ you can check the screen.fontSmoothingEnabled
property. Otherwise you need to use an html 5 canvas to check for this.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow