Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

himuleo/WaterfallCollectionView

Open more actions menu
 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
21 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

WaterfallCollectionView

WaterfallCollectionView is custom layout for UICollectionView, based on Pinterest style. It supports (sticky or not) header supplementary view and decoration view.

...and now It's in development phase. :)

Sample usage

Setup FRGWaterfallCollectionViewLayout as UICollectionView layout in you view controller.

/*...*/
FRGWaterfallCollectionViewLayout *cvLayout = [[FRGWaterfallCollectionViewLayout alloc] init];
    cvLayout.delegate = self;
    
    cvLayout.itemWidth = 140.0f;
    cvLayout.topInset = 10.0f;
    cvLayout.bottomInset = 10.0f;
    cvLayout.stickyHeader = YES;
    
    [self.cv setCollectionViewLayout:cvLayout];		//cv is UICollectionView property
/*...*/

If you want to show section header you should implement delegate method

- (CGFloat) collectionView:(UICollectionView *)collectionView
                    layout:(FRGWaterfallCollectionViewLayout *)collectionViewLayout
heightForHeaderAtIndexPath:(NSIndexPath *)indexPath;

Screenshots

Sections

Decoration view

Horizontal orientation

Sticky header

About

Waterfall-style implementation of UICollectionView layout

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Morty Proxy This is a proxified and sanitized view of the page, visit original site.