ICViewPager
ICViewPager copied to clipboard
How to change the color of the selected tab?
I need to set a highlight color for the selected tab,but i cannot find any way to implement this requirement.
@ufosky
A temporary solution is to add some lines in the - (void)setActiveTabIndex:(NSUInteger)activeTabIndex
method.
like this:
// Set to-be-inactive tab unselected
activeTabView = [self tabViewAtIndex:self.activeTabIndex];
activeTabView.selected = NO;
labelSubview = activeTabView.subviews[0];
labelSubview.textColor = [UIColor blackColor];
// Set to-be-active tab selected
activeTabView = [self tabViewAtIndex:activeTabIndex];
activeTabView.selected = YES;
labelSubview = activeTabView.subviews[0];
labelSubview.textColor = [UIColor whiteColor];
Hope this could help you if you are still working on that project.
Any Update on Highlight the Tab's Text ?