IPhone - keyboard key

I would like to make an additional button in the lower corner of the iPhone keyboard, as in the photo below. Can this be done?

enter image description here

+4
source share
2 answers

the only way to configure these buttons is to rebuild the keyboard itself.

http://www.raywenderlich.com/1063/ipad-for-iphone-developers-101-custom-input-view-tutorial

Ray always has some good tutorials on iphone dev. being able to customize your entry screen is only half the battle. Then you will need to create a custom view. You will probably want to emulate an existing keyboard, obviously with your custom button.

as an additional note. to remove the keyboard, you need to execute the resignFirstResponder command using the first responder.

When you go this far, here is the code I use to do just that

@implementation UIView (FindAndResignFirstResponder) - (BOOL)findAndResignFirstResponder { UIView *responder = [self findFirstResponder]; if (responder) { [responder resignFirstResponder]; return YES; } return NO; } - (UIView*)findFirstResponder { if (self.isFirstResponder) { return self; } for (UIView *subView in self.subviews) { UIView *responder = [subView findFirstResponder]; if (responder != nil) return responder; } return nil; } @end 

call, if you have control over all the inputs, you can call findAndResignFirstResponder in this view.

Or, as you can see, findAndResignFirstResponder calls resignFirstResponder on the "found" firstResponder. therefore, if you have a first responder, you can simply resign.

0
source

No, it is not. The keyboard belongs to the system. You can change the type of keyboard (regular, numeric, twitter, etc.), but you cannot configure it. This is a question that is worth +1

0
source

Source: https://habr.com/ru/post/1438443/


All Articles