Skip to content

Instantly share code, notes, and snippets.

@wouterds
Created April 30, 2013 12:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wouterds/5488474 to your computer and use it in GitHub Desktop.
Save wouterds/5488474 to your computer and use it in GitHub Desktop.
Enumerate loaded fonts in Objective-C
- (void)enumerateFonts {
NSLog(@"[AppDelegate.enumerateFonts] Start enumerating fonts");
for(NSString *fontFamilyStrings in [UIFont familyNames]) {
NSLog(@"[AppDelegate.enumerateFonts] Font family: %@", fontFamilyStrings);
for(NSString *fontStrings in [UIFont fontNamesForFamilyName:fontFamilyStrings]) {
NSLog(@"[AppDelegate.enumerateFonts] Font: %@", fontStrings);
}
}
NSLog(@"[AppDelegate.enumerateFonts] End enumerating fonts");
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment