TestsTested | ✗ |
LangLanguage | Obj-CObjective C |
License | MIT |
ReleasedLast Release | Dec 2014 |
Maintained by Unclaimed.
A refined scrolling tab bar for iPhone.
To get started using CCFScrollingTabBar, download the source and checkout the sample project. Here's what we did in the example:
CCFScrollableTabView
viewDidLoad
method, set the delegate
and dataSource
properties on the scrollable tab view to ourselves.#pragma mark - CCFScrollableTabViewDataSource
- (UIColor *)textColorInScrollableTabView:(CCFScrollableTabView *)tabView {
return [UIColor whiteColor];
}
- (UIColor *)darkColorInScrollableTabView:(CCFScrollableTabView *)tabView {
return [UIColor colorWithRed:0.0706f green:0.1529f blue:0.4235f alpha:1.0f];
}
- (UIColor *)lightColorInScrollableTabView:(CCFScrollableTabView *)tabView {
return [UIColor colorWithRed:0.258f green:0.639f blue:0.890f alpha:1.0f];
}
- (NSArray *)titlesInScrollableTabView:(CCFScrollableTabView *)tabView {
return [NSArray arrayWithObjects:@"Afrikaans",@"Basque",@"Catalan",@"Croatian",@"Danish",@"English",@"French",@"German",@"Hungarian", nil];
}
#pragma mark - CCFScrollableTabViewDelegate
- (void)scrollableTabView:(CCFScrollableTabView *)tabView didSelectItemAtIndex:(NSInteger)index;
{
NSLog(@"%s - SELECTED = %d",__FUNCTION__,index);
NSString *language = Languages[index];
self.textLabel.text = LanguageTexts[language];
}
And that's it!