3 ms·
> In the tag layout, it would be about as easy to just write line-wrapping code by hand, than to use a UICollectionView. Possibly but the code you would be wri
by pat2man 13y ago
> In the tag layout, it would be about as easy to just write line-wrapping code by hand, than to use a UICollectionView.
Possibly but the code you would be writing for UICollectionView would be mostly boiler plate. All the layout would be handled for you. Updating a few parameters would be quite easy and you could do it via IB or via code. Once you wrote this once it would also be quite portable.
- jcampbell1 13y ago> All the layout would be handled for you. No it won't. The tags are variable width, you have to implement something like sizeForItemAtIndexPath. You also must monitor the height of scrollable content region, so you have to monkey patch the collectionViewContent size (or KVO a non-public property), so you can resize the collection view and have the outer controller layout the subviews. Collection Views don't really make sense when the collection view shouldn't scroll.