Check if certain character is supported by UIFont

2019-07-17 20:54发布

问题:

I know how to get the array of all fonts in iOS. Now I need to check if certain font support Cyrillic characters (Ukrainian alphabet).

回答1:

I think you can check font for Cyrillic characters using this function:

CTFontGetGlyphsForCharacters

If it returns False the font is improper.