I have a custom view @IBDesignable.
I want to have a minimum height.
If I add a view to the code I override
override init(frame: CGRect) { let height = frame.height > minHeight ? minHeight : frame.height let minFrame = CGRectMake(frame.origin.x, frame.origin.y, frame.width, height) super.init(frame: minFrame) }
set the minimum height.
when adding to storyboard
required init?(coder aDecoder: NSCoder) { super.init(coder: aDecoder) }
.
So where can I set the minimum height?
thanks
source share