Animate navigation bar with view during push transition in iOS 7 - ios

I'm using the iOS 7 transition API in for some custom transitions. I've got a great transition going, but have problems with the navbar. I want the navigation bar to act as part of the view, so there is a clear line/shadow going the entire vertical length of the screen. (Such as the Reeder app, from this screenshot)
In my view however, the line on the left side of the top view does not extend all the way to the top of the navigation bar.
Just a sample app, so the view stack is generic, and using just a standard UINavigationController.

Related

Swift - how to mimic iOS's Files app expandable navigation bar

I'm working on iOS application in Swift and I'm showing a table views in Navigation Controller with a Navigation bar.
I'd like to implemented the same "Toolbar experience" as the Files app does. (see attached image) in order to present additional options/buttons without cluttering the screen (for UX purposes mostly).
I could not find anything related, expect for workaround with toolbar on top, but it does not work as part of the navigation bar, meaning that after navigation that toolbar is no following the navigation bar but instead stays on the previous controller.
The ideal behavior is:
to expand when scrolling down (requires table view to be scrolled to top) and to collapse when scrolling down.
to keep the toolbar attached to the navigation bar on navigation (push & pop)
In the screenshot, the toolbar is showing additional options (under the search bar). I'd very much like to do the same.

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

iPhone X - Hidden status bar pushes Navigation Bar upwards

I'm testing iPhone X behavior using the Xcode simulator. For some odd reason, if I'm hiding the Status Bar the Navigation Bar pushed upwards causing the title to completely disappear and cutting the left and right buttons. This is happening only on the iPhone X.
Illustration:
How can I hide the status bar and keep the Navigation Bar at a visible position?
UPDATE:
Sample project for your convince:
https://drive.google.com/file/d/0B5qJARV-Oc9ra1hvZkpXZm9lRUE/view?usp=sharing
One solution is to embed the navigation controller inside a container view controller which is properly constrained to the safe area.
Just create another view controller and drag a "Container View" from the Object Library. This view has top, bottom, leading, and trailing constraints to the safe area, all with constants equal to 0. If you control-drag from the container view to the navigation controller, you'll get an option to set an "embed segue" which will embed the selected view controller as a child view controller.
I set the status bar to be hidden on the new view controller I created, and it works fine.
This feels like something that UINavigationBar should handle automatically, but this workaround seems like it should work pretty well.
Another note: if you change the color of the navigation bar, you'll also need to create another view above the container view, and change its color to match the color of the navigation bar.
I, for a small app, changed from using a Push to a Modal segue and adding in my own navigation bar. I used Push because it looks good, and already had a Modal for another part, which I wanted to animate differently for style reasons.
For smaller apps this may be the quickest and easiest solution, but my next update I need to use the navigation controller. For that I think I'll switch on the status bar, which is no big deal for me and allows it to work.
I think you need to use "safeAreaLayoutGuide" new update in iOS 11
Apple has provided us with the necessary APIs to get around the unsafe regions of this iphone x. We do this by using the new safeAreaLayoutGuide anchors in our code
safeAreaLayoutGuide

Xcode 6 Navigation Bar Constraints Issue

I am currently working on a basic app that has many single view view controllers. I am trying to add a navigation bar to one of my view controllers, when using the "Suggested Constraints", I can see nothing. When the only restraint on the Navigation bar is a center horizontal, it shows up but I think it is too long for the screen. When I tried to add a button on the left side of the Navigation bar, it would not show up in my app because the navigation bar does not have the correct width. I know I have the wrong constraint setup, please help.

push up and swap Navigation Bar in iOS

I've seen this being achieved a few months ago in an app (wish I could remember which).
My main screen is a scrollable view (UITableView) that has the default navigation bar on top, and another added navigation bar at the bottom.
When I scroll down (swipe finger up), the bottom navbar will eventually reach the top. What I'm trying to achieve is to make the top navbar be pushed up by the bottom navbar as I'm scrolling and swap it. All in a smooth transition, which will of course work in the opposite direction (be reversible).
Can anyone give me directions on how to go about doing this?
I have thought about creating an animation, but not sure if its actually possible to push up and out of the screen the "default" navigation bar of the view controller.
Thanks.
I think what you are looking at is headers for sections in an UITableView.
See Apple's documentation on UITableView`: Documentation
Specifically, see the headerViewForSectionmethod.

Resources