How to avoid IQKeyboard from scrolling up the navigation bar too?

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP



How to avoid IQKeyboard from scrolling up the navigation bar too?



I am using IQKeyboard (https://github.com/hackiftekhar/IQKeyboardManager) to avoid keyboard hiding the textfields while writing on them.
However they also scroll up the navigation bar which I don't intend to do. How do I avoid this?



I'm using the following snippet for using the same in AppDelegate-


IQKeyboardManager.sharedManager().enable = true
IQKeyboardManager.sharedManager().enableAutoToolbar = false
IQKeyboardManager.sharedManager().shouldShowToolbarPlaceholder = false
IQKeyboardManager.sharedManager().previousNextDisplayMode = IQPreviousNextDisplayMode.alwaysHide
IQKeyboardManager.sharedManager().keyboardDistanceFromTextField = 20





by just adding your textfields in scrollview ..
– vaibhav
1 min ago




1 Answer
1



Simplest way to avoid NavigationBar to move up is put all your content inside UIScrollView


NavigationBar


UIScrollView



Check this from aurthor of IQKeyboardManager Check this


IQKeyboardManager






By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Popular posts from this blog

Firebase Auth - with Email and Password - Check user already registered

Dynamically update html content plain JS

How to determine optimal route across keyboard