I am using UICollectionView to display multiple sections of data. These sections have a fixed number of elements. I want all objects displayed in a continuous grid.
Now I am doing this in horizontal orientation: 
But vertically this leaves a big gap: 
I want to solve this gap between sections, because it is ugly, and it does not belong there. I would be happy to use a custom FlowLayout, but I cannot find a tutorial that points me in the right direction (I found several, but none of them specifically address this problem.)
Can someone help me solve this problem or at least point me in the right direction?
PS: I implemented partitions because I load data on the fly. Using 1 partition at the moment is not an option for me.
UPDATE Upon request, I add the values used for the current FlowLayout stream. I use the standard horizontal flow layout on a full-screen (minus UINavigationBar) UICollectionView with 21 elements per section.
- Scrolling Direction: Horizontal
- Cell Size: 248, 196
- Header Size: No
- Minimum cell spacing: 10
- Minimum line spacing: 10
- Partition Inserts: 20, 20, 10, 10
source share