Presenting just a subset of emojis on the keyboard on iOS apps - ios

I am making an app where I use the "People" emojis as avatar faces and the "Food and drink" emojis for, well, food and drink icons. I would like to use the regular keyboard for presenting the emojis for user input, but I would like to present only these two categories of emojis (and even so, each category would be presented in a different context).
I am working with iOS 8, Xcode 6.3 and Swift.
Can I configure the regular keyboard so that it only shows a subset of emojis which I define?
If not, can I create a new custom keyboard preserving everything from the original Apple keyboard but limiting the subset of characters? Any pointers on how to do this?
Thanks.

You can not configure the regular keyboard so that it only shows a subset of emojis. But yes can make your own custom keyboard.
You can find some really good posts about how to make the custom keyboards:
http://verisage.us/en/blog/2014/07/17/ios-8-custom-keyboard-swift-tutorial/
http://code.tutsplus.com/tutorials/ios-8-creating-a-custom-keyboard-in-swift--cms-22344
Also I found this FaceBoardPlus sample: http://code4app.net/ios/FaceBoardPlus/52a9ba56cb7e841e178b69d0 which is exactly what you are looking for but written in objective c.
EDIT: From iOS developer library:
After a user chooses a custom keyboard, it becomes the keyboard for
every app the user opens. For this reason, a keyboard you create must,
at minimum, provide certain base features. Most important, your
keyboard must allow the user to switch to another keyboard.
To provide a fully custom keyboard for just your app or to supplement
the system keyboard with custom keys in just your app, the iOS SDK
provides other, better options. Read about custom input views and
input accessory views in Custom Views for Data Input in Text
Programming Guide for iOS.

Related

iOS - How to make custom keyboard extension work with physical keyboard

I have had this question for a long time and I tried to search it in iOS 10 APIs but I couldn't find any, if anyone knows the corresponding APIs, please help here.
So I have an iOS custom keyboard for Mandarin and it requires selecting word after some inputs.
Google's custom keyboard GBoard now supports Simplified Chinese and it works with iPad Pro Smart Keyboard and it will display a list of candidate words right below the cursor as shown in this video.
GBoard Simplified Chinese Input
But I couldn't find the corresponding API to make this happen for my own custom keyboard extension.
So 2 questions here:
Is it doable now to make a custom keyboard extension work for external physical bluetooth keyboard, and how? Not iPad Pro Smart Keyboard but generally using Apple bluetooth keyboard with say an iPad Air.
If #1 it not doable now, how can I make my custom keyboard work like GBoard so that when the user types some english chars, the candidate list will appear right below the cursor and then use arrow keys to navigate and enter to input.
Much appreciated.

What is the process to include a Custom Keyboard in my iOS app

First of all I'm not looking for code or how to do it, just the process.
I don't fully understand how Custom Keyboards work in iOS8-up and I would like to include a simple custom numeric keyboard in my app. In the past I have created static keyboards with multiple UIButtons which are visible all the time, this time however I want a custom 9 digit keyboard with the same behavior as one of the default keyboards in iOS, in other words, the keyboard will show when a UITextField is tapped and hide when the resignFirstResponder method is called. I want this to be the default and ONLY keyboard used in my app.
What are my alternatives to adopt the behavior described above?
Do I need to create a Custom Keyboard extension?
Can someone describe the process to include a custom keyboard that acts as the default keybaord WITHIN your app?
Again I'm not looking for how to do it just the process.
Thanks

Multiple keyboard layouts in an iOS keyboard extension

I'm currently working on a keyboard extension for iOS, and am now wondering how to integrate multiple layouts support into the system settings.
In the system settings, the default en_US keyboard has an additional menu (indicated by a arrow to the right), where you can choose from multiple keyboard layouts, as you can see in the screenshot from the iOS simulator below (iOS 9.1 13B137)
Can this be achieved with a custom keyboard extension, too? I can't find any documentation on it. (Which may mean that it either isn't possible using public APIs or I am too stupid to use Google.) I've searched quite a lot online, but most of what I find is about setting the keyboard locale in the Info.plist file or instructions on how to enable the system keyboard in different languages (which are registered as different keyboards), which I would like to avoid.
I can see an alternative, if this doesn't work, which would be to basically create multiple keyboard extensions in one wrapping app, which include the same code base, but define other layouts. However, this would look rather ugly, clutter up the code, and people will have to enable each layout individually, which, from my point of view, isn't the most user-friendly approach. As stated above, iOS ships with different keyboards for different languages, but I'm trying to provide multiple keyboard layouts for the same language, so this is not what I want.
This doesn't appear to be directly supported. Like you said, other third-party keyboards are stepping around this issue by providing alternate keyboard layouts as a function within the keyboard itself.
For example, Swype allows QWERTY/AZERTY/QWERTZ layout changes by long-pressing on the spacebar.

How to lock keyboard to Simplified Chinese Handwriting?

I want to lock my keyboard to just simplified chinese handwriting. How do I do this?
The problem is that I am trying to create a Chinese quiz app in Xcode 6 using swift and I want the quiz-takers to write in the character to match the English word using a chinese handwriting keyboard. I do not know how to program this and other questions asked like this do not seem to yield a useful result for me.
You can't lock the keyboard unless you present your own custom keyboard. Once again, you have to take into account those with physical keyboards as well (who can bypass your custom keyboard).
A good recommendation is to use a custom handwriting recogniser that links to a label (to prevent keyboard intervention).

Custom Image iPhone Keyboard

Before this question is dismissed, let me start by saying I've read the dozens of questions that sound similar. I haven't found anyone that has asked for this specific use case, though, so I'm going to give it a shot.
I would like to create custom images to use (similar to emojis) in a custom keyboard that can be accessed with the globe icon. I understand that I can create a custom keyboard inside my own app, but it will only work within that app. I also understand how the emoji keyboard works.
Is it possible to create a situation where if two people are using the app, though, that the keyboard could be used to input the custom images (emojis) and be viewed only by a receiving user that ALSO has the app - even if the keyboard is being used outside of the custom image keyboard app.
So, basically, there would be a set of images stored within the app and the custom keyboard would reference those images to display whenever the keystroke has been entered and then the receiving phone can locate those images stored within the app to display them (but this could all be done within the native SMS messaging app, not solely in the new custom image keyboard app).
I've researched this a good deal, but can't find a straight answer. Any help or direction would be greatly appreciated!
You could create your own Keyboard that creates somehow special Strings that imply an image. For example could a smiley be encoded like ".CoolSmiley". When you now want to display that text, you should search for patterns you want to recognise. That's how emoji is working. When you type in (y) it will get replaced by a thumb up image because it's recognising the string as a known pattern for a thumb up. This will of course just work inside your app.

Resources