In my app the user can move the navigation bar and find a uibutton underneath. The button fails to register taps when located underneath where the navigation bar would be. The button works fine when placed away from the navigation bar. How can I make sure the button recognizes taps when visible?
Uinavigationbar will not recognize touches in navigation region if navigation bar is set to opaque. I solved by temporarily setting bar to translucent while hidden
Related
I have a search bar set as the title view in my navigation bar. In the initial view the search bar is evenly spaced in the middle with buttons on both sides. In this view the back button pushes the search bar so that it is uneven. I've tried getting rid of the text of the back button, but it still didn't work to spread the search bar out. Squished search bar image
I recently needed to solve the same issue. I ended up creating a UIBarButtonItem with the back button image asset, and setting that as the navigationItem.leftBarButtonItem. This button press then calls navigationController?.popViewController(animated: true) to pop the viewController off the stack
I am adding a right bar button in navigation bar but when i click out side of navigation bar as shown in picture below it get pressed i don't know why it is behaving like this. I have added this button from storyboard.
I can click 5-10 points underneath the navigationbar and it registers a button click. This barbutton item is not a custom bar button. I used the new debug views debugger and the frame of the barbutton item is not stretching down underneath the navigation bar. this is not a custom navigation bar.
I have a UINavigationController with a UISearchBar right under the UINavigationBar. When I click in the search bar, the text and buttons on the UINavigationBar disappears, but the blank white bar still stays. I think this is because it is a navigation controller and so the navigation bar can disappear. In addition, when I start typing, the search bar disappears, but I can still type. My question: is there a way to either make the entire navigation bar disappear when I start searching or make the text on the navigation bar stay while searching, and how do I ensure the search bar does not disappear? Thanks.
self.searchController.hidesNavigationBarDuringPresentation = NO;
Figured it out. In the storyboard, I had to click on the little icon on the bottom, third from the left, then "resolve auto layout issues." Autolayout must be off for this to work
I want my top nav bar to be hidden, with a menu icon in the top left hand corner (same position as on the nav bar). When the button is activated the top nav bar appears and the menu icon appears in the same position on the nav bar. So the top nav bar show hides like the tap screen function, but rather than tapping anywhere on the screen its on a specific button. Is this possible? (i'm a designer not a developer btw)