How to config a UIScrollView?
Larrycal opened this issue · 1 comments
Larrycal commented
I have a UIScrollView which contains some subviews, I'm puzzled when I want to use these views to determine the scrollview's contentSize and frame size.
For example, when subviews' width is more than screen's width, I want to change the scrollView's width to screen's width and the contentSize.width to the subview's total width.
But now, I use below method to achieve this.
tagScrollView.pin.below(of: likeButton).marginTop(10) .left(StatusTableViewCellHorizentalSpacing) .right() .height(of: tagScrollViewContentView) .maxWidth(Constants.screenWidth - StatusTableViewCellHorizentalSpacing) tagScrollView.contentSize = tagScrollViewContentView.size
lucdion commented
Closing this old issue