Which font formats does iOS support?

2020-08-09 06:22发布

I'd like to know which font formats iOS supports. I already know that iOS supports the TTF format. Does it support any others—for example, PFM or PMB?

标签: ios fonts
3条回答
可以哭但决不认输i
2楼-- · 2020-08-09 06:59

As of iOS 10, both WOFF and WOFF2 formats are supported. Though there's no info about it

查看更多
神经病院院长
3楼-- · 2020-08-09 07:03

The official documentation on this is spotty to say the least. In the article Adding a Custom Font to Your App, Apple states that can use True Type Font (.ttf) and Open Type Font (.otf) files.

In related Apple documentation for setting up a configuration profile on iOS, Apple states that you can use

[a] font file in TrueType (.ttf) or OpenType (.otf) format. Collection formats (.ttc or .otc) are not supported.

Again only True Type Fonts and Open Type Fonts are official supported. Although this document is not directly related to app development. It is further evidence for official support for fonts only extending to .ttf and .otf.

I couldn't find any official documentation for WOFF or WOFF2 support outside of Safari.

查看更多
The star\"
4楼-- · 2020-08-09 07:08

As of iOS 7, both TTF and OTF font formats are supported. You can distribute these fonts in your apps, or through configuration profiles (to make them available system wide).

查看更多
登录 后发表回答