I programmed a customKeyboard. What I need to do is to override native softkeybaord, system wide. Is it possible to do so? If yes, how can it achieve this and if no, then what are the alternatives to accomplish this task.
It's called an "Input Method Editor"
There are plenty of apps such as swiftkey and swype which are custom keyboards which work this way.
Basically, Android let's the user choose who will manager their input (both keyboard and touch).
After installing your keyboard (apk), the user has to enable it manually in Settings -> Language & Input -> Default Keybaord. As pointed out by #hatcyl, there are plenty of other apps out there taking the same approach.
Related
I'm working on an Android app that needs to take input in Arabic whenever the User taps on an EditText view. So how do I change the keyboard language programatically or ask the User to do so?
I conducted extensive research and found out that it can be done via:
a) creating a custom Arabic keyboard,
b) using the IME manager to prompt the user to change input method by calling showInputMethodPicker(),
c) using the IME manager to change input method by calling setInputMethod.
of these, (c) is only workable for System apps, and (a) requires a lot of time (which I currently don't have), and (b) requires the user to manually enable it.
Is there absolutely ANY simple and workable way to accomplish this? Any external API that I could use or anything at all?
https://www.codeproject.com/Questions/996415/ceate-custom-arabic-keyboard-for-android
Above link can help you.For getting above required feature you need to make custom keyboard Arabic then open that keyboard when you type in edit text.
I would like to listen for a text-highlight event in the system not only in my app (i.e at least in chrome).
Is this possible folks and if yes can you please provide a sample implementation?
I found the answer here: How to develop an Android tool to be used for any text in any app
Is that possible?
Generally speaking, no, for security reasons.
In this specific case, you could create your own input method editor
(a.k.a., soft keyboard), which the user could elect to use, and you
could find out when the user selects text in an EditText. But writing
a good input method editor is not simple, and it will have no effect
on, say, text highlighted in a Web browser.
Can I use "The Clipboard Framework" to listen for text selection?
No.
I am trying to control the behavior off a an IME keyboard.
For instance the keyboard I downloaded uses combinations of characters(
say if you press "ß" + "π" it suggests "∑"
I am making this example up.
I would like to turn off this feature.
Usually asian keyboards uses this feature.
I dont know the tech term for this. I looked at spannable but not very helpful.
Thanks
The Keyboard example that comes with the sdk shows how to do this, plus the keyboard that comes installed on the phone is open source.
Here is a link
If you have any specific questions after looking these over I am sure you will be able to find answers here! Good luck!
If the keyboard doesn't have the option to turn it off, then it probably cannot be done. I don't think there is such a option in Android that applies to all keyboards.
I want to add the functinality of Home,Back,Searcha and Menu Hard keys via some soft keys which can be accessed anytime the device is up.
I know their are few applications available which already do this, but i wanted to know the way this can be implemented.
Any help would be appreciated.
As stated elsewhere, the SDK is not enough to emulate hardware buttons: you need to be able to modify or at least call system sources, so you should be compiling Android from sources.
That said you can emulate the software button by calling "injectKeyEvent" in IWindowManager like done in these examples:
http://java-admin.iteye.com/blog/813208 (chinese)
http://tinyurl.com/5spjxja (android-x86 patch)
I'd like to show my own IME in the Select input method chooser dialog like the Japanese IME and the Chinese IME. How can I do that?
I am new to Android. I have tested Greek IME and other IME. Although .apk is successfully uploaded. But can't show in it and how to choose own IME from this place.
What do I need to do in my code?
You probably need to activate the installed keyboards before you can select them in the Input Method menu. For this you need to open Settings -> Language & Keyboard and in this menu check the keyboards you would like to use. This probably should get your GreekIME running.
Now for coding your own soft keyboard, there is an example which is delivered with the Android SDK. You can find it in <Andoid SDK Base>/samples/SoftKeyboard. The process is a bit poorly documented, but when you get the example up and running you can start to tweak the example a bit and you should get the hang of it.
Nice writeup about
Onscreen Input Methods from developer.android.com
In part ...
What is an input method?
The Android IMF is designed to support a variety of IMEs, including soft keyboard, hand-writing recognizers, and hard keyboard translators. Our focus, however, will be on soft keyboards, since this is the kind of input method that is currently part of the platform.