iOS添加自定义自体 [UIFont fontWithName: size:](英文有效)

Posted 我来看烟花

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了iOS添加自定义自体 [UIFont fontWithName: size:](英文有效)相关的知识,希望对你有一定的参考价值。

[UIFont fontWithName:(NSString *)fontName size:(CGFloat)fontSize];

//便利字体名称

for (NSString *str in [UIFont familyNames])

        dlog(@"UIFont_name: %@",str);

2015-05-25 16:36:46.591 pengsi[10717:2381284] UIFont_name: Marion

2015-05-25 16:36:46.591 pengsi[10717:2381284] UIFont_name: Copperplate

2015-05-25 16:36:46.591 pengsi[10717:2381284] UIFont_name: Heiti SC

2015-05-25 16:36:46.591 pengsi[10717:2381284] UIFont_name: Iowan Old Style

2015-05-25 16:36:46.591 pengsi[10717:2381284] UIFont_name: Courier New

2015-05-25 16:36:46.591 pengsi[10717:2381284] UIFont_name: Apple SD Gothic Neo

2015-05-25 16:36:46.591 pengsi[10717:2381284] UIFont_name: Heiti TC

2015-05-25 16:36:46.591 pengsi[10717:2381284] UIFont_name: Gill Sans

2015-05-25 16:36:46.591 pengsi[10717:2381284] UIFont_name: Marker Felt

2015-05-25 16:36:46.591 pengsi[10717:2381284] UIFont_name: Thonburi

2015-05-25 16:36:46.591 pengsi[10717:2381284] UIFont_name: Avenir Next Condensed

2015-05-25 16:36:46.591 pengsi[10717:2381284] UIFont_name: Tamil Sangam MN

2015-05-25 16:36:46.591 pengsi[10717:2381284] UIFont_name: Helvetica Neue

2015-05-25 16:36:46.591 pengsi[10717:2381284] UIFont_name: Gurmukhi MN

2015-05-25 16:36:46.591 pengsi[10717:2381284] UIFont_name: Times New Roman

2015-05-25 16:36:46.591 pengsi[10717:2381284] UIFont_name: Georgia

2015-05-25 16:36:46.596 pengsi[10717:2381284] UIFont_name: Apple Color Emoji

2015-05-25 16:36:46.596 pengsi[10717:2381284] UIFont_name: Arial Rounded MT Bold

2015-05-25 16:36:46.596 pengsi[10717:2381284] UIFont_name: Kailasa

2015-05-25 16:36:46.596 pengsi[10717:2381284] UIFont_name: Kohinoor Devanagari

2015-05-25 16:36:46.596 pengsi[10717:2381284] UIFont_name: Sinhala Sangam MN

2015-05-25 16:36:46.596 pengsi[10717:2381284] UIFont_name: Chalkboard SE

2015-05-25 16:36:46.596 pengsi[10717:2381284] UIFont_name: Superclarendon

2015-05-25 16:36:46.596 pengsi[10717:2381284] UIFont_name: Gujarati Sangam MN

2015-05-25 16:36:46.596 pengsi[10717:2381284] UIFont_name: Damascus

2015-05-25 16:36:46.596 pengsi[10717:2381284] UIFont_name: Noteworthy

2015-05-25 16:36:46.596 pengsi[10717:2381284] UIFont_name: Geeza Pro

2015-05-25 16:36:46.596 pengsi[10717:2381284] UIFont_name: Avenir

2015-05-25 16:36:46.596 pengsi[10717:2381284] UIFont_name: Academy Engraved LET

2015-05-25 16:36:46.596 pengsi[10717:2381284] UIFont_name: Mishafi

2015-05-25 16:36:46.596 pengsi[10717:2381284] UIFont_name: Futura

2015-05-25 16:36:46.597 pengsi[10717:2381284] UIFont_name: Farah

2015-05-25 16:36:46.597 pengsi[10717:2381284] UIFont_name: Kannada Sangam MN

2015-05-25 16:36:46.597 pengsi[10717:2381284] UIFont_name: Arial Hebrew

2015-05-25 16:36:46.597 pengsi[10717:2381284] UIFont_name: Arial

2015-05-25 16:36:46.597 pengsi[10717:2381284] UIFont_name: Party LET

2015-05-25 16:36:46.597 pengsi[10717:2381284] UIFont_name: Chalkduster

2015-05-25 16:36:46.597 pengsi[10717:2381284] UIFont_name: Hiragino Kaku Gothic ProN

2015-05-25 16:36:46.597 pengsi[10717:2381284] UIFont_name: Hoefler Text

2015-05-25 16:36:46.597 pengsi[10717:2381284] UIFont_name: Optima

2015-05-25 16:36:46.597 pengsi[10717:2381284] UIFont_name: Palatino

2015-05-25 16:36:46.597 pengsi[10717:2381284] UIFont_name: Malayalam Sangam MN

2015-05-25 16:36:46.597 pengsi[10717:2381284] UIFont_name: Lao Sangam MN

2015-05-25 16:36:46.597 pengsi[10717:2381284] UIFont_name: Al Nile

2015-05-25 16:36:46.597 pengsi[10717:2381284] UIFont_name: Bradley Hand

2015-05-25 16:36:46.597 pengsi[10717:2381284] UIFont_name: Hiragino Mincho ProN

2015-05-25 16:36:46.597 pengsi[10717:2381284] UIFont_name: Trebuchet MS

2015-05-25 16:36:46.597 pengsi[10717:2381284] UIFont_name: Helvetica

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: Courier

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: Cochin

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: Devanagari Sangam MN

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: Oriya Sangam MN

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: Snell Roundhand

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: Zapf Dingbats

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: Bodoni 72

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: Verdana

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: American Typewriter

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: Avenir Next

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: Baskerville

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: Khmer Sangam MN

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: Didot

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: Savoye LET

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: Bodoni Ornaments

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: Symbol

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: Menlo

2015-05-25 16:36:46.598 pengsi[10717:2381284] UIFont_name: Bodoni 72 Smallcaps

2015-05-25 16:36:46.599 pengsi[10717:2381284] UIFont_name: DIN Alternate

2015-05-25 16:36:46.599 pengsi[10717:2381284] UIFont_name: Papyrus

2015-05-25 16:36:46.599 pengsi[10717:2381284] UIFont_name: Euphemia UCAS

2015-05-25 16:36:46.599 pengsi[10717:2381284] UIFont_name: Telugu Sangam MN

2015-05-25 16:36:46.599 pengsi[10717:2381284] UIFont_name: Bangla Sangam MN

2015-05-25 16:36:46.599 pengsi[10717:2381284] UIFont_name: Zapfino

2015-05-25 16:36:46.599 pengsi[10717:2381284] UIFont_name: Bodoni 72 Oldstyle

2015-05-25 16:36:46.599 pengsi[10717:2381284] UIFont_name: DIN Condensed

以上是关于iOS添加自定义自体 [UIFont fontWithName: size:](英文有效)的主要内容,如果未能解决你的问题,请参考以下文章

ios7以上自定义导航栏标题的字体大小及颜色的方法

自定义视图很慢

iOS 根据字符串数目,自定义Label等控件的高度

iOS 根据字符串数目,自定义Label等控件的高度

如何在iOS7中使用具有动态文本大小的自定义字体

自定义UITableViewCell高度