Created
August 7, 2019 07:22
-
-
Save devmjun/51a2fbb258f60927ce00cf8ed137448b to your computer and use it in GitHub Desktop.
print All Font list
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for family in UIFont.familyNames { | |
let sName: String = family as String | |
print("family: \(sName)") | |
for name in UIFont.fontNames(forFamilyName: sName) { | |
print("name: \(name as String)") | |
let customFont = UIFont(name: name, size: 11) | |
print("font is nil?: \(customFont)") | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment