I currently have the UIKeyboardWillHideNotification setup with my keyboard. When i tap the keyboard's emoji button, the notification is called, drastically messing up my UI (for i have a tool bar with a text field "attached" to it). I assume this is suppose to happen, but is there a way to detect if the keyboard is simply switching the type of keyboard? I would like that notification to be called only when the keyboard actually closes. Thank you!
duplicate question
Notice that after iOS7, Apple suggest use textInputMode.primaryLanguage, but the emoji keyboard will return nil when you access the primaryLanguage. Seem like it's a bug.
Related
It is possible to trigger the emoji keyboard programmatically?
I am trying to open the emoji keyboard when the user clicks a button, it is possible?
Emoji is also considered a language keyboard, As of now Apple does not provide any public API to programmatically switch to another input method.
However there may be a workaround, This question might help:
Change the iOS keyboard layout to emoji?
My app was running fine on ios 8.4, but now after trying it on ios 9 beta, once the app is opened, the cursor on the UITextfield doesn't show up.
The keyboard doesn't come up. Shouldn't it come automatically?
The app works perfectly fine till ios8.4. Can some one help me out?
After one tap gesture on the UITextField, cursor doesn't show up at all.
Also, I tried checking the tintColor property as well as suggested by some users, but it is default blue.
Is there some specific change made in the way keyboard works on ios9?
A Situation - When I click on Login button, Alert message is displayed and then on pressing ok, the keyboard appears with a cursor but I can type only 1 character and suddenly the cursor and keyboard disappears. Then again, click on login, get the error message, cursor is available, type 1 character and cursor and keyboard disappears again.
Why is cursor on visible when tapped on a UITextField. This according to me must be a simple automatic thing. I have used resignFirstResponder and becomeFirstResponder too.
Anything to do with the Views here? For example, super view or something?
Thanks in advance!
Shrikant Kekane
The situation you have described is not happening when I tried the same.
The steps I followed:
Drag and drop one UITextField in Storyboard.
Give it required constraints.
Build & Run.
Keyboard and cursor both work perfectly in iOS9 simulator.
I'm making a custom keyboard and I want to transition directly to emoji keyboard that is provided by Apple when nextKeyboard button is pressed.
#IBAction func nextKeyboardPressed(sender: AnyObject) {
advanceToNextInputMode()
}
This code takes me to the stock keyboard.
And I want this keyboard to open when nextKeyboard is pressed
Is it possible? Is there a way to access stack of installed keyboards?
No, you can't. It has been quite limited that the custom keyboard extension to access the external data for some reasons (Especially for security). There is no way to know active keyboards nor change to particuller keyboard.
You can't, in the section Providing a Way to Switch to Another Keyboard of this document, Apple says:
To ask the system to switch to another keyboard, call the
advanceToNextInputMode method of the UIInputViewController class. The
system picks the appropriate “next” keyboard; there is no API to
obtain a list of enabled keyboards or for picking a particular
keyboard to switch to.
However, you could modify your Keyboard to contain an Emoji section as well.
From the device settings a user can set keyboard to dock type or split type.
For the convenience of our app can we set the iPad keyboard to dock type/ split type via code? Because sometimes a split type keyboard/undocked keyboard will be best suited for our ui. I searched a lot for any clue, but I didn't got a solution for this.
No, you do not have control over the keyboard. Your iPad app should work OK with split keyboard, docked keyboard, and hardware keyboard. Your best bet is to listen to UIKeyboardWillChangeFrameNotification and change your UI to avoid being hidden under the keyboard frame.
As of iOS 5, the keyboard can now be a variable height based on the input language. Specifically the Chinese language now includes an autocomplete section above the keyboard, very similar to what you see in Android. That autocomplete section increases the measured height of the keyboard.
Is there an even to which one may subscribe and/or receive notifications about when the keyboard changes dimensions as a result of the user clicking the "world" key? Note that this is different from getting the notification about the keyboard coming up (keyboardWillShow). In this case, they keyboard is already up, it's dimensions are simply changing as a result of user interaction.
Thanks!
When the input method changed, although the keyboard is already there, iOS will still send notification UIKeyboardDidShowNotification, so, register this notification, and get the location and frame change through the userInfo within notification with key UIKeyboardFrameEndUserInfoKey, then you can relayout your elements depend on the keyboard size.
more detail information, read this blog post:
(English) How to handle the keyboard frame change when input Chinese in iOS 5
(Chinese) 如何处理iOS 5中文输入法下keyboard的frame尺寸变化