Xcode 5 甚至不熟悉setTitle
to UITabBar
,错误是:
'UITabBar' 没有可见的@interface 声明选择器'setTitle:
寻找UITabBar
: http: //developer.apple.com/library/ios/navigation/没有显示版本的任何变化。这里发生了什么?
编辑:
原始代码是:
- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
if (self) {
// Custom initialization
[[UITabBar appearance] setBackgroundImage:[[UIImage alloc]init]];
[[UITabBar appearance] setSelectionIndicatorImage:[[UIImage alloc]init]];
[[UITabBar appearance] setTitle:NSLocalizedString(@"home", nil)];
}
return self;
}