In my storyboard I have a view on which I have an ImageView
and a Button
. The ImageView
is currently covering my button and I would like to put the button over the ImageView. I found similar topics which were solved by going to "Editor" -> "Arrange" -> "Send to Front", however that was done for UIViews
and this option is passive for ImageView
and Buttons
.
So how can I send my ImageView
to background? Is the best solution for this to add an additional view only for the Button
and then bring it to front?
You can rearrange your views on storyboard:
First view in order will be hidden by next view.
Maybe this options will be also useful for your running application:
myImageView.layer.zPosition = -5;
myImageView.layer.zPosition = 5;
Like in HTML/CSS.
The solution was to move the view components up and down in the "Document Outline" section.
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