I have a problem in Swift where I put a UIImageView on my view in Main.storyboard. I want to use this UIImageView as a background image and therefore I want it on the bottom of the "stack of components". Unfortunately this UIImageView seems to be on the top of everything and not showing my UIPickerView and UIButtons. If i resize the UIImageView you can see what i mean by looking at the picture I attached.
Does anyone know how to solve this problem and set the UIImageView on the bottom, and all my other components above it?
Answer: Thanks everyone, I fixed it by changing the backgroundview of the collectionview to the backgroundview. Here is the code:
var imageViewObject :UIImageView!
imageViewObject = UIImageView(frame: CGRectMake(0, 0, viewSize.width, viewSize.height))
imageViewObject.image = UIImage(named:"intro.jpg")
collectionView = UICollectionView(frame: self.view.frame, collectionViewLayout: layout)
collectionView!.dataSource = self
collectionView!.delegate = self
collectionView!.registerClass(NameCell.self, forCellWithReuseIdentifier: "Cell")
collectionView!.backgroundView = imageViewObject
backgroundView.addSubview(collectionView!)