Skip to content

Instantly share code, notes, and snippets.

@pkh
Created January 4, 2013 16:57
Show Gist options
  • Save pkh/4454105 to your computer and use it in GitHub Desktop.
Save pkh/4454105 to your computer and use it in GitHub Desktop.
List all fonts available to an iOS app
NSArray *familyNames = [UIFont familyNames];
for ( NSString *familyName in familyNames ) {
printf( "Family: %s \n", [familyName UTF8String] );
NSArray *fontNames = [UIFont fontNamesForFamilyName:familyName];
for ( NSString *fontName in fontNames ) {
printf( "\tFont: %s \n", [fontName UTF8String] );
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment