1
UICollectionView 셀 크기를 UICollectionView의 너비와 높이와 같게하려고합니다. UICollectionViewCell 크기가 UICollectionView 크기와 같습니다.
-(CGSize)collectionView:(UICollectionView *)collectionView layout:(UICollectionViewLayout *)collectionViewLayout sizeForItemAtIndexPath:(NSIndexPath *)indexPath{
CGSize size=collectionView.bounds.size;
return CGSizeMake(414.0, 586.0);
}
내가 size
다음은 높이로 자동 레이아웃 오류 the item height must be less than the height of the UICollectionView minus the section insets top and bottom values, minus the content insets top and bottom values.
를 throw 사용하는 경우
UICollectionView frame = (0 0; 414 650);
contentOffset: {0, 0}; contentSize: {0, 514}
그래서이 높이 문제를 해결할 수 있습니까? 아이폰 OS 9/10에 대한