This is what I have implemented:
See the black space on the right, it could still hold two extra items.
But for some reason, starting from the 7th item, the rendering starts at the next line.
My layout configuration only changes two parameters:
class CarouselFlowLayout: UICollectionViewFlowLayout {
override init() {
super.init()
minimumLineSpacing = 40
minimumInteritemSpacing = 20
}
required init?(coder aDecoder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
override func prepare() {
super.prepare()
}
}
Any idea, which parameters should I configure in order to force the collectionView to fill each "row" before returning to the next line?