Is there a way that I can add new imageView
over all other views and send that view to back of my viewController
directly from storyboard
? I don't want to create ImageView
in code and use sendSubviewToBack
method for that.
Click the Editor menu, then select Arrange > Send to Back. Show activity on this post. In XCode 8 you go to the menu bar on the top of the screen then click Edit > Arrange > Send to Back. This also Works for moving an item behind a single item or in front of an item.
Select the subview and drag over the view entry in the Objects Explorer of storyboard. Once you leave the mouse hold, the parent view will have a triangle indicating your subview has become its child and the subview will have a bigger indent than your view.
In Xcode 9.2, simply go to your Storyboard and go to the bottom, Click View As and choose a device you like.
In Interface Builder check the left sidebar and you will see the view hierarchy as shown below.
Just add your view as normal, then drag it up the view hierarchy to the top of the list in 'View' and it will be at the bottom of the stack.
In the example below There is a container view in the root view controller view then Image View and then all the labels are 'on top' of that bottom image view.
Select the view in the Interface Builder, and then do Editor -> Arrange -> Send to Back
You can also rearrange the views in the view list in the left panel of the IB window. The views that are on top of that list will also appear on top in the app.
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