UILabel

UILabel

  • 常用属性
    • 标签的文本
      @property (nonatomic,copy) NSString *text;
    • 文本字体
      @property (nonatomic,strong) UIFont *font;
    • 字体颜色
      @property (nonatomic,strong) UIColor *textColor;
    • 阴影颜色
      @property (nonatomic,strong) UIColor *shadowColor;
    • 阴影偏移
      @property (nonatomic,assign) CGSize shadowOffset;
    • 文本对齐方式
      @property (nonatomic,assign) NSTextAlignment textAlignment;
    • 文本折行模式(文本超出标签范围)
      @property (nonatomic,assign) NSLineBreakMode lineBreakMode;
    • 文本行数(0值表示多行)
      @property (nonatomic,assign) NSInteger numberOfLines;
    • 富文本
      @property (nonatomic,copy) NSAttributedString *attributedString;
 
原文地址:https://www.cnblogs.com/buakaw/p/5072421.html