我想改变这个视图的颜色。我希望标签栏更多按钮视图颜色与应用颜色相同,而不是白色。怎么可能。
问问题
557 次
1 回答
1
为此,您必须自定义moreNavigationController
。一种解决方案是将您的子类化UITabBarController
并在方法上添加以下内容- (void)viewDidLoad
。
- (void)viewDidLoad
{
[super viewDidLoad];
// Do any additional setup after loading the view.
UINavigationController *moreController = self.moreNavigationController;
//if u want to custamize navigationBar u can customize
//moreController.navigationBar
if ([moreController.topViewController.view isKindOfClass:[UITableView class]]) {
//Custamize your tableview here
UITableView *tableView = (UITableView *)moreController.topViewController.view;
//Change the color of tableView
[tableView setBackgroundColor:[UIColor redColor]];
moreController.topViewController.view = tableView;
}
}
我希望这可以帮助你
要自定义,tabBarItem
您可以关注其他答案。
于 2012-11-07T09:18:00.677 回答