swift - Xcode expects UILabel in stack view to have greater height than it is -
i trying place 2 identically sized sets of uilabel directly above uitextfield on uiview. figured excellent use of stack views.
however, reason, xcode seems expect uilabel taller should , results in warnings layout.
with uilabel selected, can see outline. can see same sized outline on other uilabel too, , when selecting stack view elements shows larger area. when clicking on uitextfield, outline shown begin outline uilabel ends. using 'resolve auto layout issues' 'update frames' make stack view expand outwards match size of outline, instantly jumps original size.
am misusing or have misconfigured stack views? or there other issue going on?
i using xcode 7.3 build 7d111g.
this because label filling stackview.
don't give height constraint stackview. add following 2 constraints top stackview
- top space
- center horizontally in container
stackview height content.
check updated gif :
all warning finished.
hope can help.



Comments
Post a Comment