This is probably a dumb question, but I can't seem to figure it out. In IB, if I have two UIViews, that are subviews of the main UIViewController.view that I basically show and hide depending on the user's input, is there a way to hide one of the views while working in IB. All the text/buttons are on top of each other so I can't really tell what's going on. Is there a way to just make that view and all its children hidden while I work on the other view? Thanks.
Overview. Stack views let you leverage the power of Auto Layout, creating user interfaces that can dynamically adapt to the device's orientation, screen size, and any changes in the available space. The stack view manages the layout of all the views in its arrangedSubviews property.
I'd suggest temporarily dragging one of the views outside of the UIViewController.view while you do everything in IB, and then dragging it back after you're done.
In case someone comes back to this question: in the newest XCode, you can open Assistant Editor with Preview and see what's happening in the Preview while working on the xib (e.g. when you hide a view).
EDIT: doesn't seem to work in XCode 8 any more.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With