The problem encountered by ScrollView in Mas. After ios10.0

Source: Internet
Author: User

After ios10.0 Xcode8 after the use of masonry encountered some problems summarized as follows

1. Sub-controls with Mas layout cannot print frame

Online information is said to be masonry bug is currently not fixed. Also because of this problem, the ScrollView automatically sets the Scrollview.contentsize property to {0,0}, which is set to its own size to scroll.

2. When you layout a child control in a ScrollView with Mas, you find that ScrollView cannot scroll

Debugging found that if ScrollView's child controls were used with properties such as Mas.left or mas.right, it would cause scrollview not to scroll up or down. Other attributes, such as mas.center, are not problematic.

So if you want to use the MAS layout.  Do not use Mas.left.right.mas_equalto (0); Switch to Mas.width.mas_equalto (self.view.frame.size.width);

If ScrollView to scroll horizontally. Try to avoid attributes such as Top.bottom. Also remember to set your own scrollview.contentsize.

I hope the MAS can fix this problem as soon as possible.

The problem encountered by ScrollView in Mas. After ios10.0

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.