Last active
August 9, 2016 14:34
-
-
Save adriantofan/8c0cfc8872df54446476 to your computer and use it in GitHub Desktop.
show custom fonts family names
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(NSString *fontfamilyname in [UIFont familyNames]) | |
{ | |
if (![fontfamilyname containsString:@"elvetica"]) { | |
continue; | |
} | |
NSLog(@"family:'%@'",fontfamilyname); | |
for(NSString *fontName in [UIFont fontNamesForFamilyName:fontfamilyname]) | |
{ | |
NSLog(@"\tfont:'%@'",fontName); | |
} | |
NSLog(@"-------------"); | |
} |
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: String in UIFont.familyNames() | |
{ | |
print("\(family)") | |
for names: String in UIFont.fontNamesForFamilyName(family) | |
{ | |
print("== \(names)") | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment