NGTabBarController

A custom TabBarController implementation for iPhone and iPad

Showing:

Popularity

Downloads/wk

0

GitHub Stars

265

Maintenance

Last Commit

3yrs ago

Contributors

6

Package

Dependencies

0

License

MIT

Categories

Readme

A custom TabBarController which can be positioned on the bottom, top, left or top. Utilizes iOS 5 Containment API if possible, but works on iOS 4 too. The TabBar is fully customizable with a tintColor or background image as well as the possibility to show/hide the item highlight and the possibility to change the text colors, have image-only tabBar items etc.

Usage

NGColoredViewController vc1 = [[NGColoredViewController alloc] initWithNibName:nil bundle:nil]; NGColoredViewController vc2 = [[NGColoredViewController alloc] initWithNibName:nil bundle:nil]; NGColoredViewController vc3 = [[NGColoredViewController alloc] initWithNibName:nil bundle:nil]; NGColoredViewController vc4 = [[NGColoredViewController alloc] initWithNibName:nil bundle:nil]; NGColoredViewController *vc5 = [[NGColoredViewController alloc] initWithNibName:nil bundle:nil];

vc1.ng_tabBarItem = [NGTabBarItem itemWithTitle:@"Home" image:image1]; vc2.ng_tabBarItem = [NGTabBarItem itemWithTitle:@"Images" image:image2]; vc3.ng_tabBarItem = [NGTabBarItem itemWithTitle:@"Live" image:image3]; vc4.ng_tabBarItem = [NGTabBarItem itemWithTitle:@"Contact" image:image4]; vc5.ng_tabBarItem = [NGTabBarItem itemWithTitle:@"Settings" image:image5];

NSArray *viewController = [NSArray arrayWithObjects:vc1,vc2,vc3,vc4,vc5,nil];

NGTabBarController *tabBarController = [[NGTestTabBarController alloc] initWithDelegate:self];

tabBarController.animation = NGTabBarControllerAnimationMoveAndScale; tabBarController.layoutStrategy = $isPhone() ? NGTabBarLayoutStrategyEvenlyDistributed : NGTabBarLayoutStrategyCentered; tabBarController.itemPadding = 10.f; tabBarController.showsItemHighlight = NO; tabBarController.tintColor = [UIColor redColor]; tabBarController.viewControllers = viewController; self.window.rootViewController = tabBarController;

Just have a look at the provided Demo-Application and the header files to see what's possible.

Credits

NGTabBarController was created by Matthias Tretter (@myell0w).

Images

Right Side Left Side

License

NGTabBarController is available under the MIT license. See the LICENSE file for more info. For usage without attribution contact NOUSguide.

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100