Storyboard - ViewController 到选项卡栏控制器

发布于 2024-12-25 08:25:35 字数 381 浏览 3 评论 0原文

我有视图控制器,它是主界面,包含选项等...

我想从第一个视图控制器转换>选项卡控制器

现在在选项卡控制器上我想添加更多选项卡,因为默认情况下 xcode 只创建两个。

q)如何在故事板中添加更多选项卡

我在选项卡控制器中嵌入了第一个视图控制器,但它使xcode崩溃了

q)如何避免崩溃并使流程看起来更好

任何建议,想法将受到欢迎:来自android活动和意图我'我不确定这里最好的解决方案是什么,所以欢迎所有意见。

更新:我想我想问但没有明确说明的是

我有视图控制器,我希望它首先加载,然后单击三个按钮之一转到选项卡控制器,这就是当我执行 Editor > 时 xcode 崩溃的地方。嵌入导航控制器内。

I have view controller which is the main interface contains options etc...

i want to transition from 1st view controller > tab controller

now once at tab controller i want to add more tabs as by default xcode only creates two.

q) how you add more tabs in storyboarding

I embeded the 1st view controller in tab controller but it crashed xcode

q) how to avoid crashing and making the flow seems better

any suggestions, ideas will be welcomed: coming from android activities and intents i'm not sure what is best solution here so welcome all input.

UPDATE: i guess what i was trying to ask and didnt made it clear is

i have view controller i want this to load first and upon clicking one of the three buttons go to tab controller which is where xcode crashes when i do Editor > embed within nav controller.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

青春如此纠结 2025-01-01 08:25:35

如何在故事板中添加更多选项卡?

只需将另一个视图控制器添加到故事板即可。然后,按住 Control 键将连接从选项卡控制器拖动到新的视图控制器,然后从出现的弹出菜单中选择“关系 - viewControllers”。

如何避免崩溃并改善流程?

我偶尔会看到故事板编辑器使 Xcode 崩溃。如果您有时间,请向 Apple 报告错误。很可能他们已经知道了这个问题,但是再报告一个 bug 也没什么坏处,而且可能会提高 bug 的优先级。除此之外,重新启动 Xcode 并继续您正在做的事情——通常第二次就可以正常工作。

从用户的角度改善程序的流程是一个设计问题;一种方法是首先尝试您认为最有效的方法,然后进行彻底测试以找出困难点。根据需要进行修复和重复,并确保其他人也尝试一下。

How do you add more tabs in storyboarding?

Just add another view controller to the storyboard. Then, control-drag a connection from the tab controller to the new view controller, and choose "Relationship - viewControllers" from the popup menu that appears.

How do you avoid crashing and improve the flow?

I've seen the storyboard editor crash Xcode every once in a while. If you have time, report a bug to Apple. Chances are that they already know about the problem, but another bug report never hurts, and it may increase the priority of the bug. Other than that, relaunch Xcode and continue what you were doing -- it usually works fine the second time around.

Improving the flow of the program from the user's point of view is a design problem; one approach is to try whatever you think will work best first, and then test thoroughly to identify the rough spots. Fix and repeat as necessary, and be sure to have other people try it too.

寻梦旅人 2025-01-01 08:25:35

我想你可能会比遵循故事板教程做得更糟糕。我发现 Ray Wenderlich 的相当不错。事实上,我什至购买了他的书以获得全部内容。

请参阅http://www.raywenderlich.com/5138/ ios-5-part-1 中的开始故事板

I guess you could do worse than follow along a Storyboard tutorial. I found Ray Wenderlich's rather good. In fact I even purchased his book to get the whole thing.

See http://www.raywenderlich.com/5138/beginning-storyboards-in-ios-5-part-1

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文