我正在尝试在StackView的单独列中的ScrollView之间实施相等的高度限制。当我强制约束时,较小的ScrollView会变得等于较大的ScrollView。这会导致某些内容从屏幕上丢失。我尝试过从两个方向创建约束。
为什么会这样?
Unequal heights, left column has more elements.
Add equal height constraint. Change the multiplier from 1.25 to 1.0.
The left scroll view grows and causes some content to be placed off screen.
我想我找到了问题。具有填充类型分布的UIStackView不能具有“空”空间,因为内容会自动增长或缩小以适应定义的边界。