gsdios / SDAutoLayout

One line of code to implement automatic layout. 一行代码搞定自动布局!支持Cell和Tableview高度自适应,Label和ScrollView内容自适应,致力于做最简单易用的AutoLayout库。The most easy way for autoLayout. Based on runtime.
MIT License
5.9k stars 1.28k forks source link

xib创建的label,使用代码布局时出现-[UILabel sd_layout]: unrecognized selector sent to instance 0x11345070 #106

Open boothlee opened 8 years ago

boothlee commented 8 years ago

请问xib创建视图,在使用SD-AutoLayout创建约束时,出现这个问题,xib视图需要添加约束吗? _bookingAddressLabel.sd_layout .topSpaceToView(self.heightButton,30) .leftEqualToView(self.addressTextView) .rightEqualToView(self.addressTextView) .autoHeightRatio(0);