Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

解决10.3 系统label不能自适应 #295

Closed
zhongab opened this issue Apr 12, 2017 · 5 comments
Closed

解决10.3 系统label不能自适应 #295

zhongab opened this issue Apr 12, 2017 · 5 comments

Comments

@zhongab
Copy link

zhongab commented Apr 12, 2017

8308ddbf-e56b-4bdc-b64b-cf3bd58e9a3f

@faimin
Copy link

faimin commented Apr 12, 2017

添加这个约束的目的只是用来计算高度的,高度计算完毕之后需要把添加的约束移除,就像作者的做法一样。

@zhongab
Copy link
Author

zhongab commented Apr 12, 2017

@faimin 你是怎么做的呢,我发现还是有问题

@faimin
Copy link

faimin commented Apr 12, 2017

@zhongab 我还是老老实实的给 多行label 设置preferredMaxLayoutWidth属性值,官方文档就这么要求的

@shanglina
Copy link

对于有2个或以上的多行label时 , 设置这个preferredMaxLayoutWidth 加上[cell.contentView mas_makeConstraints:^(MASConstraintMaker *make) {
make.left.mas_equalTo(0).priorityLow();
make.right.mas_equalTo(0).priorityLow();
}]; 可以解决

@weekwood
Copy link
Member

Same as #291.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants