Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there a font picker on iPhone?

Tags:

iphone

as topic, I am strange that why does the SDK not provide API to show the UIFont picker ? like the date Picker......

or maybe some open source code is available now ?

Thanks for your help !

Regards

like image 367
iXcoder Avatar asked Mar 15 '10 07:03

iXcoder


2 Answers

I whipped something up in a few minutes which might be what you want: http://github.com/alexrepty/ARFontChooser

like image 141
Alex Repty Avatar answered Nov 02 '22 17:11

Alex Repty


I am not aware of existing solutions but you can easily retrieve all font names available in system:

for (NSString* familyName in [UIFont familyNames])
     for (NSString* fontName in [UIFont fontNamesForFamilyName:familyName])
         // Store font names or do whatever you want
         // You can create font object using 
         // [UIFont fontWithName:fontName size:fontSize];

And then allow user to pick one of then in your own font picker with the design you want.

like image 6
Vladimir Avatar answered Nov 02 '22 16:11

Vladimir