Questions tagged [uitabbaritem]

The UITabBarItem class implements an item on a tab bar, instances of the UITabBar class. Tab bar items are used to configure the tab bar.

Tab bar items gives the ability to switch between different subtasks, views, or modes. A tab bar operates strictly in radio mode, where one item is selected at a time—tapping a tab bar item toggles the view above the tab bar. There is a way to specify a badge value on the tab bar item for adding additional visual information—for example, the Phone application uses a badge on the item to show the number of new messages. This class also provides a number of system defaults for creating items.

991 questions
3
votes
1 answer

Changing UITabbar when the app theme is being changed?

I want to support 2 themes for an app. Light and Dark one. So, I have a UIButton that allows the user to tap on it and switch between light and dark theme. The UITabBar has it's own class and I've set it to change accordingly to the current theme…
Dani
  • 3,427
  • 3
  • 28
  • 54
3
votes
1 answer

Can't Remove Tab Bar After Deleting Tab Bar Item in Storyboard (Swift 4)

This should be ridiculously simple, but I just can't seem to find the answer. Assume you start off with a brand new View Controller, and then drag in a Tab Bar Item from the object library (putting it on the bottom of the controller). Then you…
Adam S.
  • 173
  • 3
  • 15
3
votes
1 answer

How do I respond to a touch *down* event in the UITabbar

I'd like to begin animating a UITabBarItem when the user touches down on the tab. However, UITabBarDelegate only provides a didSelect method. What's the best way of detecting a UIControlEvents.touchDown event in this context?
rob
  • 4,069
  • 3
  • 34
  • 41
3
votes
1 answer

Configuring a UITabBar with more than 16 items

My UITabBarController contains more than 16 view controllers. When I go in the "More" tab, I can see all the UITabBarItems. If I click the "Edit" button, I can see the 16 first icons, but there is not enough room to display more, so starting from…
MonsieurDart
  • 6,005
  • 2
  • 43
  • 45
3
votes
1 answer

NSImage Overlay/Mask Gradient like iOS

I'm looking to replicate with Cocoa/Core Graphics the process which seems to occur on iOS when setting an image for a UITabBarItem. When the tab bar item is selected, the image is overlayed with a gradient. For example, becomes... I'm unsure…
JoeR
  • 1,901
  • 3
  • 25
  • 39
3
votes
3 answers

TabBar image size in landscape mode

I am working on application which supports both Portrait and Landscape mode. I am using default TabBarController in Storyboard. NOTE: I am adding custom offset on images In Portrait mode the image size of tabbarItems are looking well nice. But…
3
votes
1 answer

UINavigtion controller back button do not show properly

Native back buttons are buggy on iOS 11 as shown in the picture. Is there a solution for this?
Shahbaz Akram
  • 1,598
  • 3
  • 28
  • 45
3
votes
3 answers

show another storyboard as the content of 1st tab of TabBarController

I have a tab bar controller in storyboard like below: I have anther storyboard which I would like to use as the content of 1st tab. Let's call it Content.storyboard What I want to achieve is: I would like the content of the 1st tab of Tab Bar…
Leem.fin
  • 40,781
  • 83
  • 202
  • 354
3
votes
1 answer

iOS Swift Tabbar Controller Add Item (new tab) programmatically

My App have Tab bar Controller, Which have 4 Tab bar items. I need to add one more tab bar item as 5th, is it possible to add new item as programmatically.
Kavin Kumar Arumugam
  • 1,792
  • 3
  • 28
  • 47
3
votes
1 answer

Add UITabBar in ViewController Swift 3(NOT TO IMPLEMENT UITabBarController)

I successfully added a UITabBar to my UIViewController. But, I'm unable to switch view controllers when tabs are tabbed. I used the following approaches : public func tabBar(_ tabBar: UITabBar, didSelect item: UITabBarItem) { switch item.tag…
Akaanksha
  • 161
  • 1
  • 14
3
votes
2 answers

How to disable UITabBarItem without greying the item

Is it possible to disable a UITabBarItem without greying out the image and text? I'm disabling an item but when the item becomes disabled it's image and text are also dimmed. Is there any way to keep the default selected appearance while also having…
Mbusi Hlatshwayo
  • 554
  • 1
  • 10
  • 23
3
votes
1 answer

Load views with tab bar item!

is that possible to bring the view with the help of tab bar item. let me explain you the question clearly.I created view based application. Added two vies let us say first and second. the first view contains a button that takes us to the second…
AKM
  • 31
  • 3
3
votes
1 answer

tabBar default and custom image aligned

I have a problem with the Apple Tab Bar. I created a tab bar with defaults and customs images. so here ( this is the storyboard) looks quite good but when I run the simulator this happens: customs images are not aligned centered and I can't find…
3
votes
2 answers

Single tab bar item present different view controllers depending on a condition?

I am making an app that has a couple of different tabs using a tab bar controller. I add items to a bag in the first tab, and update the cart in the next viewcontroller. If the user goes to the second tab (the cart) without adding anything I want…
jnwagstaff
  • 226
  • 1
  • 12
3
votes
1 answer

How to hide / disable tab bar item in swift

I have a five tab, tab bar controller in my app, and I want to only show the 5th item if a manager is logged into the app (instead of employee). I currently have this code which disables the 5th item but I can still see it (its just grayed out and…
Ronnie L
  • 123
  • 1
  • 3
  • 9