Search code examples
iosobjective-cuicollectionviewlayoutuicollectionreusableview

Is it possible to change some specified section headerView height in uicollectionview?


In my app, this is a collectionView in my main view controller, the items are many kinds of images, one kind is a section.

I want to add a label to per section header, so users can input or edit their throughs about some kind of images. Because of this, I must adjust the height of label when lines of text changes.

So, how can I change the height of some specified section header?


Solution

  • I use [layout invalidateLayout] to update all headerViews and it works!