Tag: uitabbarcontroller

使用UITabBarController但状态栏覆盖视图

从这引用: https : //developer.apple.com/library/ios/qa/qa1797/_index.html "Applications that use an opaque UINavigationController or UITabBarController automatically keep their content below the status bar." 我的根视图控制器是一个UITabBarController,但是当加载一个表视图控制器的状态栏覆盖它。 这个文件是不正确的吗? 注意我并没有问如何解决这个问题,关于这个问题已经有很多问题了,我在问是否文档是正确的,如果是这样,他们为什么我的内容不在状态栏之下,尽pipe使用了UITabBarController。

如何隐藏UITabBar中的文本

我正在尝试创build一个只有图像的标签栏,没有标题。 我怎么去做这个? 这是我如何设置图像: FeedViewController.tabBarItem.image=[UIImage imageNamed:@"Describe-Home_Icon_NormalArtboard-1"];

在UITabBarController和UINavigationController中编辑button

我只是将我的UINavigationControllerembedded到UITabBarController中。 我不能再看到我的视图标题或编辑button。 请参阅下面的故事板。 如何使编辑button再次可见? 我的故事板:

为什么我的UITabBar在纵向加载时向下移动20个像素?

我正在UINavigationController加载UITabBarController 。 默认情况下, UITabBar的UITabBarController将它放在视图的底部。 通过使用默认选项,在横向启动应用程序时,该栏将在底部正确显示。 这也使肖像正确显示在底部,(但只有当横向模式启动应用程序)。 如果我以纵向方式启动应用程序,则会在两个横向上向下移动状态栏的高度: 和肖像: 我正在尝试与CNBC应用程序产生类似的效果,并在视图顶部显示UITabBar 。 在回顾了Mihai Damian的问题之后,我试图自定义UITabBar。 我只是简单地添加了几行代码: -(void)loadView{ UIView *contentView = [[UIView alloc] initWithFrame:[[UIScreen mainScreen] applicationFrame]]; contentView.backgroundColor = [UIColor clearColor]; self.view = contentView; [contentView release]; orderingTabBarController = [[UITabBarController alloc] init]; OrderingSpecialsViewController *specialsViewController = [[OrderingSpecialsViewController alloc] initWithNibName:@"OrderingSpecialsViewController" bundle:nil]; OrderingProductViewTabBarController *productViewTabBarController = [[OrderingProductViewTabBarController alloc] init]; OrderingSummaryViewController *summaryViewController = [[OrderingSummaryViewController alloc] init]; […]

在TabBarViewController的Tabs之间传递数据

我有一个基于UITabBarController的应用程序,我想从一个视图传递数据到另一个。 我正在做故事板,我只是做一些testing,然后把它带到主应用程序。 我现在只是用NSString试试这个。 当我使用这个代码使用模态转换时,我能够将数据传递给有问题的VC: NSString *sendingString = @"This string has some content"; UIStoryboard *storyboard = [UIStoryboard storyboardWithName:@"MainStoryboard" bundle:nil]; NextViewController *nVC = (NextViewController *)[storyboard instantiateViewControllerWithIdentifier:@"goToNextVC"]; nVC.receivingString = sendingString; [self presentViewController:nVC animated:YES completion:nil]; 现在,这推动了VC,并按照我的意愿传递,而不是推高VC,我希望它被推到另一个标签栏。 现在我可以用下面的代码来popup所需的TabBar: self.tabBarController.selectedIndex = 1; 我卡住的地方是,如何发送数据到这个ViewController?

iOS – 转到另一个选项卡的某个选项卡的第二个uiviewcontroller

我正在使用Storyboard开发iOS 5应用程序。 我有UITabBarController有3个选项卡。 每个选项卡都有自己的UINavigationController 。 第一个标签的UINavigationController有一个UITableViewController ,它inheritance了另一个UIViewController等。第二个标签的UINavigationController只有一个UIViewController 。 我想要实现的是在第二个选项卡的UIViewController中发生某些操作时,导航到UIViewController (第一个选项卡的UINavigationController的第二个视图)。 我已经尝试使用push segue完成此操作,但导航堆栈与不同选项卡的视图控制器混合(目标视图控制器中的后退button指向另一个选项卡的视图控制器)。 所以我想知道在不同标签的视图控制器之间完成这种转换的“正确方法”是什么。 任何帮助将非常感激。

我有一个标签栏,我试图检测它是否被触摸视图控制器2内

基本上我在视图控制器之一有一个标签栏。 我试图检测这个tabaritem是否触摸视图控制器2内。什么是执行这样的任务的最佳方法是什么? 如果你愿意,我可以发表更多具体的代码。 视图控制器1 TUHomeViewController *homeViewController = [[TUHomeViewController alloc] initWithNibName:nil bundle:nil]; UINavigationController *homeNavigationController = [[UINavigationController alloc] initWithRootViewController:homeViewController]; homeNavigationController.tabBarItem = [[DSTabBarItem alloc] initWithFinishedSelectedImage:[UIImage imageNamed:@"home"] finishedUnselectedImage:[UIImage imageNamed:@"home1"] iconSize:CGSizeMake(76, 59) tag:0]; [tabBarViewControllers addObject:homeNavigationController]; 视图控制器2

标签栏控制器不是所有的UIViewControllers

我刚刚在我的项目中创build了一个标签栏控制器,总共有4个选项卡。 它在4个UIViewControllers之间工作正常。 但是,当我导航到另一个不是4个选项卡之一的UIViewController时,选项卡消失。 我希望在每一页都能看到它。 我怎样才能做到这一点?

制作一个罚款tabBar图标

正如我们所知,tabBar的默认图标大小是30×30。 我有一个细线图标,显示属性不是很好。 它的边缘不锋利。 但是我发现music.app的tabBar图标真的很漂亮。 有什么我应该知道的技巧吗? 提前致谢!

UITabBarController中的“默认”视图

我有一个UITabBarController 5 NavigationControllers,作为标签(类似于下面的图片1)embedded。 所以,问题是:当TabBarController显示时,我想将表视图(或任何其他视图)显示为“默认”视图。 即,显示视图(视图控制器),这是没有embedded到TabBarController中,并使任何选项卡select。 我很抱歉这样的解释,更好的观看下面的图片#2。 我在我的项目中使用最新版本的XCode和Swift。 而对于界面,我正在使用故事板