Hiding navigation bar with a segmented control right under the bar - ios

Here's the set up
Navigation Bar
segmented control
Table view
I know in iOS 8 there is the navigationBar.hidesOnSwipe function that works wonders.
Is there a way, perhaps using autolayout, to also hide the segmented control as the navigationBar hides as well without writing a custom function to handle this?
Also, when I make the following setup in a storyboard, swiping the table view does not hide the navigation bar but swiping the segmented control does. But when I turn .hidesOnTap, the navigationBar hides and pulls the segmentedcontrol up
Thanks in advance

Related

UINavigationController with Expandable bar

is there an option to put a custom view in navigation bar? where the view can behave like contacts detail view, where on scrolling the header view gets squeezed or expanded. the back button looks handled natively, which is preferable. I could not see any option in UINavigationController API. am I missing something?
This is probably a custom view that blends in with the navigation bar (looks the same at the point they meet). No special nav bar api's needed. This question talks about how to remove the separator and make it look like the nav bar and underlying view blend together: Separator between navigation bar and view - iOS 7

Implementing Navigation-bar and an Extension view attached to the bottom of nav-bar

What's the right way to implement a hides-on-scroll navigation bar along with an extension view attached to the navigation bar's bottom. And on scroll the navigation bar gets hidden and the extension view sticks to the status bar.
You can use TLYShyNavBar library to implement this feature if you want extension view to stick to status bar. If you just want navigationBar to hide along with extension then use hidesBarsOnSwipe property
navigationController?.hidesBarsOnSwipe = true
refer this thread to read more about this behaviour.

iOS Navigation bar is getting hided when scrolling (is kind of scrolling too), regardless it is outside the scroll view

I'm having issues with the navigation bar, I want to set a view controller where there is a scroll view with its content, but I'm having a weird behavior that when I scroll down the navigation bar hides kind of scrolling with the scroll view but the navigation bar is not inside that.
My Scroll view has a vertical spacing to the top to avoid going upper that I want and hiding the navigation bar but it still happens.
Any help will be appreciated.
Have you tried to set hidesBarsOnSwipe = false for the navigation contrller.
More info from Apple api reference

Segmented control in Navigation bar

I need to put segmented control into navigation bar below the title and other buttons. How do I make this? Everything I found so far says you can't increase the height of navigation bar without hacks. Is it even possible?
https://drive.google.com/file/d/0B2fViGVp6nhhOEdJSU0zeWZiS1U/view?pli=1
Why don't you put both of them separately? On top navigation bar and below that UISegmentControl.
Just make sure background for UISegmentControl should be matched and aligned with UINavigation bar.
Hope that helps.

Attach a Segmented Control to UINavigationBar

In my App, I have a map view and I want to use a segmented control to change the map types (Standard, Hybrid, Satellite). The way I have the app set up, the status bar is hidden and it animates in, moving the navigation bar down a bit. To make sure it doesn't look awkward, I want to make it so the segmented control is attached to the navigation bar so it animates nicely as the status bar comes in. This is basically a picture of what I want to do:
So I noticed that the segmented control is inside a toolbar, so I contain mine in a toolbar as well. I've then tried adding the toolbar to the navigationBar as a subview. (self.navigationController.navigationBar). That works well accept that it can't be tapped because the navigation bar's frame doesn't enclose the extra space, so it can't receive touches. I tried making the frame of the bar bigger, and that worked, but the title and the buttons went away. Obviously there is some way to do this, and I would appreciate any help. Thanks.

Resources