Ios5 如何定制iAbbar IOS 5.0?
我必须自定义tabbar项目中的图像,以便在我的图标中插入图像,我该怎么做? 我从我的朋友那里听说我应该创建一个新的xib,并使用它来定制一个新的tabbar项。 这是真的吗Ios5 如何定制iAbbar IOS 5.0?,ios5,uitabbaritem,Ios5,Uitabbaritem,我必须自定义tabbar项目中的图像,以便在我的图标中插入图像,我该怎么做? 我从我的朋友那里听说我应该创建一个新的xib,并使用它来定制一个新的tabbar项。 这是真的吗 非常感谢 只需将下面的方法放入 appdelegate.m 文件 这可能对你有帮助 查看这些自定义选项卡项的示例在此处勾选答案可能是您的解决方案 - (void)customizeAppearance { // Costomise UITabBar // Note you can also specify “f
非常感谢 只需将下面的方法放入 appdelegate.m 文件 这可能对你有帮助
查看这些自定义选项卡项的示例在此处勾选答案可能是您的解决方案
- (void)customizeAppearance
{
// Costomise UITabBar
// Note you can also specify “finished” and “unfinished” images if you wish to modify the manner in which the selected & unselected images appear.
UIImage *tabBackground = [[UIImage imageNamed:@"tab_bg"]resizableImageWithCapInsets:UIEdgeInsetsMake(0, 0, 0, 0)];
[[UITabBar appearance] setBackgroundImage:tabBackground];
[[UITabBar appearance] setSelectionIndicatorImage:[UIImage imageNamed:@"tab_select_indicator"]];
}