I have a stack view containing some text fields in a storyboard. I embeded the stack view in a scroll view to get it to move out of the way of the keyboard when required. All of that works fine.
I pinned the sides and bottom of the scroll view to the sides and bottom of the main view. But there are some labels at the top of the main view, so the top of the scroll view is pinned to the bottom of the lowermost label. So the distance between scroll view top and the main view top is significantly greater than the distance between scroll view bottom and the main view bottom.
When I constrain my stack view to be vertically centred within the scroll view, it looks off-centre. What I'd like to do is have the stack view vertically centered with respect to the main view, rather than the scroll view. How would I use constraints to do this?