hackiftekhar/IQKeyboardManager

Showing black space between UIKeyboard and View due to Sliding up Keyboard above View position.

hackiftekhar opened this issue · 15 comments

Showing black space between UIKeyboard and View due to Sliding up Keyboard above View position.

Added preventShowingBottomBlankSpace bool to not show bottom blank space between UIkeyboard and View. preventShowingBottomBlankSpace default to YES.

Seems it doesn't work on iOS 9.3. Whatever I set the property to false or true, it wont work.

Could you please share an screenshot of issue you are getting?

@hackiftekhar , thanks for response quickly , please check the attached. You can see the black bar at the bottom.
The code used:IQKeyboardManager.sharedManager().preventShowingBottomBlankSpace = true

simulator screen shot apr 15 2016 10 33 13 am

Hmm, looks like you set keyboardDistanceFromTextField to something about 100-200, but still this shouldn't happen.

No, I didn't touch keyboardDistanceFromTextField property.

I used a ScrollView there to make it scrollable to select fields.

Are you sure your scrollView is calculating correct contentSize?

Actually I didn't touch contentSize, I do auto layout config all on Storyboard. It displays fine when keyboard isn't showing. Weird!!!

Then could you please share a demo project?

Same issue here. iOS 9.3 before this version its working correctly.
preventShowingBottomBlankSpace = false or true same behavior.

screen shot 2016-06-27 at 8 57 16 pm

simulator screen shot jun 27 2016 8 56 51 pm

@forsan @dongmai Could you please share a demo project so that I can debug it?

Same issue still exists.
(I changed the backgroud color from black to white with
UIApplication.shared.keyWindow?.backgroundColor = UIColor.white)

ezgif com-video-to-gif

    IQKeyboardManager.sharedManager().canAdjustAdditionalSafeAreaInsets = true

Adding this to appdelegate resolved my problem.

Adding
viewdidappear
textField.becomeFirstResponder()

and

https://stackoverflow.com/questions/4374436/how-to-detect-when-keyboard-is-shown-and-hidden/27087733#27087733
and

@objc func keyboardWillAppear() {
    //Do something here
    
    self.payTextView.frame.origin.y += self.view.safeAreaInsets.bottom
}

@objc func keyboardWillDisappear() {
    //Do something here
    self.payTextView.frame.origin.y -= self.view.safeAreaInsets.bottom

}

fixed my issue.