How can I rearrange UITabBarController items using the Storyboard?

后端 未结 9 1516
暗喜
暗喜 2020-12-29 19:40

Hi I have a UITabBarController in XCode 4.5 as the root controller with many tabs I need to change the order to.

The only thing that works for me is remove the relat

相关标签:
9条回答
  • 2020-12-29 19:42

    I solved this by right-clicking on the storyboard -> open as source code, and then rearranged the "segue" xml-blocks in the order I wanted them to be.

    0 讨论(0)
  • 2020-12-29 19:42

    Some of the suggestions above worked for me sometimes, but not always. Even rebooting the Mac did not help.
    The only way I found that works always is deleting all segues from the tab bar controller to its child view controllers, and reconnecting them in the right order.

    0 讨论(0)
  • 2020-12-29 19:46

    xcode 4.5, drag and drop failed. as suggested by another, close xcode and restart xcode. after this drag and drop of tabBarItems worked perfectly to rearrange order.

    0 讨论(0)
  • 2020-12-29 19:51

    Using Xcode 5 and above you should just drag and drop them:

    enter image description here

    0 讨论(0)
  • 2020-12-29 19:54

    When working with Xamarin iOS Designer, I open the .storyboard file in a text editor and locate the <tabBarController ...> node. Then I rearrange the order of the segues in the <connections> section:

    <connections>
        <segue destination="274" kind="relationship" relationship="viewControllers" id="286"/>
        <segue id="943" destination="910" kind="relationship" relationship="viewControllers"/>
        <segue destination="147" kind="relationship" relationship="viewControllers" id="159"/>
    </connections>
    
    0 讨论(0)
  • 2020-12-29 19:59

    In the storyboard highlight the tab bar controller.

    Make sure you are zoomed in enough and that a blue box is around the tab bar controller.

    Then click on the tabs and drag them around to where you want them

    0 讨论(0)
提交回复
热议问题