iphone - 如何做到 tabBar.title != navBar.title ?

标签 iphone

我有标签栏和导航栏。在导航栏中我有表格 View 。问题是,当我在 IB 中将标题设置为选项卡栏,然后在 TableView 中设置标题时,选项卡栏标题将更改为 TableView 中的标题,并且我在导航栏和选项卡栏中具有相同的标题,但是我想在那里有不同的标题。

如何将标签栏标题设置为与普通栏中不同?

最佳答案

试试这个:

self.navigationController.navigationBar.topItem.title = @"Your Title";

此链接也有类似但不同的解决方案: self.title sets navigationController and tabBarItem's title? Why?

关于iphone - 如何做到 tabBar.title != navBar.title ?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3307591/

相关文章:

iphone - 在 iOS 中创建 JsonString

iphone - 控制音频的声音

ios - UIImageView 未在应用程序中显示

iphone - 如何使用 Iphone 应用程序获取设备 token 以及有关设备的其他信息?

ios - UINavigationController 上的 UIPageViewController 自更改方向后不会重新布局其 subview Controller

iphone - UIKit 框架实现文件位于哪里?

ios - 当关闭启动位置服务通知错误的 View 时

iphone - 标签栏 Controller 下的导航 Controller 中的数组索引搞砸了

iphone - iOS 5 中的 View Controller

ios - UITextfield 中的图像的点数有多大