Skip to content →

MHTabBarController

Source: https://github.com/dougdiego/MHTabBarController

I forked MHTabBarController, which is a custom tab bar controller for iOS 5.  I forked it to accomplish two things.

  1. I wanted to use Quartz to draw my arrow instead of using images.
  2. I wanted my arrows to go down in addition to up.

To change the direction of the arrow, just set the pageIndicatorDirection variable like:

MHTabBarController *tabBarController = [[MHTabBarController alloc] init];
tabBarController.pageIndicatorDirection = PageIndicatorDirectionDown;

You can also easily modify the colors in MHTabBarController.m here:

// TAB Colors
#define SELECTED_TAB_COLOR UIColorFromRGB(0xCF785B)
#define SELECTED_TAB_TITLE_COLOR UIColorFromRGBWithAlpha(0xFFFFFF,0.5f)
#define DESELECTED_TAB_COLOR UIColorFromRGB(0xF5EECD)
#define DESELECTED_TAB_TITLE_COLOR UIColorFromRGB(0xAF553A)

ScreenshotDownScreenshotUp

Published in Apple iOS