Minitour / AZTabBarController

A custom tab bar controller for iOS written in Swift 4.2
MIT License
348 stars 65 forks source link

How do we create a bigger center Item button #30

Closed Abhishekg219 closed 5 years ago

Abhishekg219 commented 6 years ago

Is there a way we can create a bigger button at any index.

Minitour commented 6 years ago

@Abhishekg219 Out of the box this functionality does not exist but in theory you can achieve that effect. You can check out issue #11, although it's meant for an outdated version of the framework and may not work with the latest.

What I recommend you do is hide the original button (without removing it) by simply changing it's alpha value, and then add an additional button with the size you desire to the superview. Apply some auto layout constraints to position the button and you are good to go.

Abhishekg219 commented 6 years ago

@Minitour Hey, I have checked that issue. I am looking for something like this https://i.stack.imgur.com/D0q46.png

dimabiserov commented 6 years ago

it will be great! and how i can change button size?

Minitour commented 6 years ago

Sorry for now following up with this issue, Like I explained in previous issues, This is not something that can be done out of the box. What you would need to do is make the button hidden, and then perhaps add a sub-view to the tab-bar that will act as your center button.

This can be done, and has already been done by me in the past year like I mentioned. In the next releases I will add a much more simple, easier to use API that would allow you to customize your buttons.