Swift UILabel方法总结
let label = UILabel();
label.frame = CGRect(x:100,y:100,width:160,height:30);
label.text = "我是SwiftLabel";
label.backgroundColor = UIColor.orange;
label.textColor = UIColor.blue;
label.font = UIFont.systemFont(ofSize: 22);
label.textAlignment = NSTextAlignment.center
label.isUserInteractionEnabled = true;
self.view?.addSubview(label);
详细代码查看:https://github.com/xiaolitou-ping/Swift-All