uikeyboard

iPhone/iPad keyboard shortcuts?

流过昼夜 提交于 2019-11-30 20:14:53
There's an action in my program which users need to perform very frequently (potentially hundreds of times per session), and I'd like to add a keyboard shortcut for users with a bluetooth keyboard. Is there any way to do this? Right now, the closest I've come is triggering the action whenever the U+F8FF character is entered ( Shift + Alt + k on an iPad/iPhone/Mac, which prints an apple logo character) in a text view. Of course, this would present an issue if the user actually wanted to input an apple symbol. Are there any better ways to support keyboard shortcuts (hopefully Cmd + something ,

How to hide inputAccessoryView without dismissing keyboard

青春壹個敷衍的年華 提交于 2019-11-30 18:29:11
I am using a toolbar in the inputAccessoryView property of a textView. When the keyboard shows, it displays the toolbar as expected. When the device is rotated I want to remove the toolbar. I tried: myTextView.inputAccessoryView.hidden = !layoutIsPortrait; This does hide the toolbar, but leaves the outline of the taller keyboard behind. The keyboard is apparently still sized to fit the toolbar. It looks bad and interferes with touch events of underlying responders. myTextView.inputAccessoryView = nil; Works only if I resignFirstResponder, then becomeFirstResponder again. This is not acceptable

iOS 8 Xcode how to remove QuickType on UIKeyboard ( auto complete / auto suggest ) [duplicate]

懵懂的女人 提交于 2019-11-30 17:19:34
This question already has an answer here: Disable iOS8 Quicktype Keyboard programmatically on UITextView 5 answers UIKeyboard with QuickType! It is bad to know that there is no sufficient space of screen on iPhone devices, now apple has been taken more room by adding QuickType. How can I remove it for items that do not need quicktype's auto complete, auto suggest? William George You can set the autocorrectionType to NO. Its an existing iOS property so won't break in any previous/current versions of iOS; textField.autocorrectionType = UITextAutocorrectionTypeNo; 来源: https://stackoverflow.com

iOS 8 Xcode how to remove QuickType on UIKeyboard ( auto complete / auto suggest ) [duplicate]

久未见 提交于 2019-11-30 16:33:57
问题 This question already has answers here : Disable iOS8 Quicktype Keyboard programmatically on UITextView (5 answers) Closed 4 years ago . UIKeyboard with QuickType! It is bad to know that there is no sufficient space of screen on iPhone devices, now apple has been taken more room by adding QuickType. How can I remove it for items that do not need quicktype's auto complete, auto suggest? 回答1: You can set the autocorrectionType to NO. Its an existing iOS property so won't break in any previous

How do I replicate the iOS keyboard appearance?

狂风中的少年 提交于 2019-11-30 15:42:51
I have made a custom number pad keypad for my iOS app, but want it to more closely mirror the appearance of the standard keyboard. I am looking for advice on how to make a standard UIButton look and act like the standard keyboard buttons. Specifically, I need to figure out the following for the iPad and would like to do as much as possible in an xib or storyboard. The size of the buttons The color of the keyboard background (or even better, how can I determine this myself?) The background color of the button The font and color of the text in the button How do I add the shadow under the button?

Show UIView with buttons over keyboard, like in Skype,Viber messengers (Swift, iOS)

眉间皱痕 提交于 2019-11-30 15:34:35
问题 I want to create attachments view, that places under input accessory view, over keyboard, like in Skype App or Viber: I already asked such question here, but suggested solution for this question was not so elegant, because when i drag my scroll view to the top, i want to my Attachment UIView move down with keyboard (I use UIScrollViewKeyboardDismissModeInteractive). So i create a function, that find out the view, where keyboard and my custom input accessory view are placed: func

Show UIView with buttons over keyboard, like in Skype,Viber messengers (Swift, iOS)

旧时模样 提交于 2019-11-30 14:16:35
I want to create attachments view, that places under input accessory view, over keyboard, like in Skype App or Viber: I already asked such question here , but suggested solution for this question was not so elegant, because when i drag my scroll view to the top, i want to my Attachment UIView move down with keyboard (I use UIScrollViewKeyboardDismissModeInteractive). So i create a function, that find out the view, where keyboard and my custom input accessory view are placed: func findKeyboardView() -> UIView? { var result: UIView? = nil let windows = UIApplication.sharedApplication().windows

Action of the “Go” button of the ios keyboard

故事扮演 提交于 2019-11-30 11:44:34
问题 How do I bind an action to the Go button of the keyboard in iOS ? 回答1: Objective-C Assuming you're using a UITextField, you could use the <UITextFieldDelegate> method textFieldShouldReturn . - (BOOL)textFieldShouldReturn:(UITextField *)textField { [textField resignFirstResponder]; // Dismiss the keyboard. // Execute any additional code return YES; } Don't forget to assign the class you put this code in as the text field's delegate. self.someTextField.delegate = self; Or if you'd prefer to use

iOS 8 : Keyboard Extension. Issue with adding pop up of keys

♀尐吖头ヾ 提交于 2019-11-30 09:15:33
I am building my Keyboard Extension app and i have added key pop animation on button when user tap on it. It works fine for inside image but for top row image pop up area become hidden as it clip the subview. I tried with ClipToBound property and set as False. But still not working. Anyone have any idea how to fix this? adding subview on superview also not works. Image A is showing correct pop up as it is inside frame of keyboard. Image B is wrong as pop up clip inside frame. I don't think you are allowed to display anything outside of the keyboard view; it will get automatically clipped.

UITextView inputView

旧时模样 提交于 2019-11-30 05:18:23
I'm making a custom input method for the iPad, I want to be able to replace the system keyboard with my input method and enter text via that input method. According to the documentation all I need to do is to set the inputView property with my view and it will be used instead of the system keyboard. I did that and it works, as far as showing the keyboard but how do I actually enter text into the text view? Supposedly the text view needs to adopt the UIKeyInput and I can use the protocol's methods to enter the text but in reality UITextView doesn't adopt this protocol. conformsToProtocol: