add iOS icon font support

This commit is contained in:
王劲鹏
2020-03-13 15:00:42 +08:00
committed by osborn
parent 73c0a5e7ab
commit 49854cc825
6 changed files with 15 additions and 3 deletions

View File

@@ -72,6 +72,10 @@ - (void)blendView:(UILabel *)view forPropName:(NSString *)name propValue:(id)pro
font = [UIFont fontWithDescriptor:fontDescriptor size:0];
}
view.font = font;
} else if ([name isEqualToString:@"font"]) {
NSString *iconfont = prop;
UIFont *font = [UIFont fontWithName:iconfont size:view.font.pointSize];
view.font = font;
} else {
[super blendView:view forPropName:name propValue:prop];
}