Created
October 5, 2017 14:16
-
-
Save xhacker/2a505210bb93b529a7bcac8998957a4b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NSArray *cascadeList = @[[UIFontDescriptor fontDescriptorWithName:@"Helvetica" size:20.0], | |
[UIFontDescriptor fontDescriptorWithName:@"PingFangTC-Regular" size:20.0]]; | |
CTFontDescriptorRef descriptor = CTFontDescriptorCreateWithAttributes((CFDictionaryRef) @{(id)kCTFontCascadeListAttribute: cascadeList}); | |
UIFont *font = (__bridge_transfer UIFont *) CTFontCreateWithFontDescriptor(descriptor, 20, NULL); | |
CFRelease(descriptor); | |
self.label.font = font; | |
self.label.text = @"Helvetica fallback 到 PingFangTC-Regular 汉体书写信息技术标准相容档案下载使用界面简单支援服务升级资讯专业制作创意空间快速无线上网"; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment