ios7 - Is it possible to use iOS 7's modified Helvetica in apps? -


for ios 7, apple made special modified version of helvetica thin/light has rounded periods , colons:

enter image description here

compare using helvetica-neue thin or helvetica-neue light in xcode:

enter image description here

is possible develop apps special modified version rounded colons , periods?

edit: turns out these round colons , periods not custom designed apple, "character alternates" , can see them in favorite font glyph viewer.

here's how it. reading documentation, it's unclear.

first, have characteristics of font, give constants use in uifontdescriptorfeaturesettingsattribute. got mine this post.

this gives feature type identifier keys, , options values, feature selector identifier keys.

nsarray *timerdisplaysettings = @[                                       @{ uifontfeaturetypeidentifierkey: @(6),                                         uifontfeatureselectoridentifierkey: @(1)                                      },                                       @{ uifontfeaturetypeidentifierkey: @(17),                                         uifontfeatureselectoridentifierkey: @(1)                                         }]; 

then create font descriptor adding descriptor - way can specify font name , family via uifont:

uifont *font = [uifont fontwithname:@"helveticaneue-ultralight" size:32];  uifontdescriptor *originaldescriptor = [font fontdescriptor]; uifontdescriptor *timerdescriptor =[originaldescriptor fontdescriptorbyaddingattributes: @{ uifontdescriptorfeaturesettingsattribute: timerdisplaysettings }]; 

then, close loop , create font descriptor. (the size "0.0" means aren't scaling original size of 32.

uifont *timerfont = [uifont fontwithdescriptor: timerdescriptor size:0.0]; 

Comments

Popular posts from this blog

python - Subclassed QStyledItemDelegate ignores Stylesheet -

java - HttpClient 3.1 Connection pooling vs HttpClient 4.3.2 -

SQL: Divide the sum of values in one table with the count of rows in another -