Swift drawRect on UICollectionView subview with layout constraints draws in unexpected location
I am trying to draw onto a subview (subclass of UIView) that I have added to a UICollectionViewCell’s contentView. I did this by implementing a drawRect function to draw a very simple cross in the center of the subview.