类方法创建label

    xiaoxiao2022-06-29  35

    + (UILabel *)creatLabelWithFrame:(CGRect )frame

                               title:(NSString *)title

                          titleColor:(UIColor *)titleColor

                                font:(NSInteger )font {

        

        UILabel *label = [[UILabel alloc] initWithFrame:frame];

        label.text = title;

        label.font = [UIFont systemFontOfSize:font];

        label.textColor = titleColor;

        

        return label;

    }

    转载请注明原文地址: https://ju.6miu.com/read-1125219.html

    最新回复(0)