Ios tab Bar 使用方法
http://blog.sina.com.cn/s/blog_63578f140100w56m.html
UITabBar* tabBar = [[UITabBar?alloc]?initWithFrame:CGRectMake(40,0.0,240,30)];
????[mainView addSubview:tabBar];
????[tabBar?release];
????
????UITabBarItem?*tabBarItem1 = [[UITabBarItem?alloc]?initWithTitle:@"排隊人數"?image:nil?tag:0];
????UITabBarItem?*?tabBarItem2?= [[UITabBarItem?alloc]?initWithTitle:@"人均"?image:nil?tag:1];
????UITabBarItem?*?tabBarItem3?= [[UITabBarItem?alloc]?initWithTitle:@"距離"?image:nil?tag:2];
????UITabBarItem?*?tabBarItem4?= [[UITabBarItem?alloc]?initWithTitle:@"好評"?image:nil?tag:3];
????NSArray?*tabBarItemArray = [[NSArray?alloc]?initWithObjects:?tabBarItem1,?tabBarItem2,?tabBarItem3,?tabBarItem4,nil];
????[tabBar?setItems:?tabBarItemArray];
????[tabBarItemArray?release];
?
????好像tabBar.backgroundColor?= [UIColor?blueColor];設置背景不起作用
????alpha可以起作用
轉載于:https://www.cnblogs.com/wcLT/p/4046527.html
總結
以上是生活随笔為你收集整理的Ios tab Bar 使用方法的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: CRC校验(转)
- 下一篇: 关闭uboot MMU 会导致andro