Hi,
I asked a question about putting UICollectionView within UITableViewCell on
Apple Developer Forums (https://forums.developer.apple.com/thread/98176), but
it doesn’t get many replies. I’m not sure if it’s ok to repost the question
here. I apologize if it’s not.
Here is the question:
Hi, I'
Where I work we have spent a fair amount of trying unsuccessfully to get
self-sizing collection view cells to work as described by Apple documentation
with UICollectionViews that have any sort of complexity. I would suggest trying
to implement the sizeForItemAtIndexPath delegate method to see if
I would suggest rethinking the table view enclosure and just use a collection
view with headers and footers by way of the supplemental views.
--
Gary L. Wade
http://www.garywade.com/
> On Mar 9, 2018, at 8:00 AM, Glen Huang wrote:
>
> Hi,
>
> I asked a question about putting UICollectionView w
@Cosmo
My collection items contain label, so I don’t know the exact sizes before hand.
@Gary
In my case I actually also need to display section headers and section index
titles, so using just a collection view probably won’t be easy I guess.
—
From the suggestions it seems it might be somethi
But you presumably know the width (i.e. the CollectionView width minus any
insets), and you can calculate the height based on that with NSString or
NSAttributedString boundingRect functions. Assuming you have a subclass for
your CollectionViewCell, you can add a method to return your cell height