比如 UIButton
UILabel
他们中间是18px 怎样在设置UILabel时根据UIButton设置距离 求解答
比如 UIButton
UILabel
他们中间是18px 怎样在设置UILabel时根据UIButton设置距离 求解答
label.center = CGPoint(100,100);
button.origin = CGPoint(100,label.frame.origin.x+label.frame.size.height+18)
或者你用我博客提到的那种方式可以更简单一些
http://www.jianshu.com/p/0a1a9b13b104