You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
App crash when TabView has more than 5 items and different font-style #1426
If/when I add more than 5 items to my TabView component the app crashes. This is for sure a bug. According to iOS dev library, if you add more than 5 items to the Tab controller, it will automatically add a "More" button in the last position, so when you tap it, it will show the other items in a list. Very neat.
Does this also apply in {N}? It should. Otherwise we have to create a "More" Item specifically, add listView innside, populate the list with data for each menu item. Program the tap for each listViewItem, that will also cause a page-navigation away from the view with the original TabView component, etc... Too much work and hassle compared to the native way.
The More Navigation Controller
The tab bar has limited space for displaying your custom items. If you add six or more custom view controllers to a tab bar controller, the tab bar controller displays only the first four items plus the standard More item on the tab bar. Tapping the More item brings up a standard interface for selecting the remaining items.
I created a new main-view with your example in it. Just copied your code and pasted it. Ran the app, and the same exception came. I removed the last tab-item, ran the app, no exception.
This does not seem to work.
EDIT: One thing I notice now, is that I am running iOS 8.4 on simulator. But it should work on 8 as well...
If we set a different font-familiy or font-size on a main container or the TabView itself, AND you have more than 5 TabItems the app crashes with the above error.
On a side note, I have also noticed that if you have an ActionBar in you app with the TabView, and you select the "More" tab, the new "more view" adds an additional ActionBar below the one you originaly added.
changed the title [-]App crash when TabView has more than 5 items (iOS)[/-][+]App crash when TabView has more than 5 items and different font-style[/+]on Jan 30, 2016
Activity
enchev commentedon Jan 25, 2016
I've just tested this and here is what I've got with 6 items:
manijak commentedon Jan 25, 2016
Lucky you, this is what I get:
enchev commentedon Jan 26, 2016
Can you post how exactly these tabs are created?
manijak commentedon Jan 26, 2016
I don't have the code in front of me, but they are created via XML, the same way you did. Just that mine have icons as well.
I can post some code later today.
manijak commentedon Jan 26, 2016
I created a new main-view with your example in it. Just copied your code and pasted it. Ran the app, and the same exception came. I removed the last tab-item, ran the app, no exception.
This does not seem to work.
EDIT: One thing I notice now, is that I am running iOS 8.4 on simulator. But it should work on 8 as well...
manijak commentedon Jan 26, 2016
Nope, didn't work on 9.2 either...
enchev commentedon Jan 27, 2016
What is your {N} version?
manijak commentedon Jan 27, 2016
1.5.2
manijak commentedon Jan 29, 2016
Found the issue @enchev
Please test the following in your example.
Add one (or both) of these in you .css file and run the app.
If we set a different font-familiy or font-size on a main container or the TabView itself, AND you have more than 5 TabItems the app crashes with the above error.
On a side note, I have also noticed that if you have an ActionBar in you app with the TabView, and you select the "More" tab, the new "more view" adds an additional ActionBar below the one you originaly added.
Please fix this :(
[-]App crash when TabView has more than 5 items (iOS)[/-][+]App crash when TabView has more than 5 items and different font-style[/+]manijak commentedon Feb 1, 2016
Genius @enchev :) 👍 Thank you!
Should I create a separate issue on the part where "More" view adds additional ActionBar if you already have one on the main Page?
lock commentedon Aug 30, 2019
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.