I am writing a mobile HTML5 web application to run on both Apple and Android. On the Android device I am testing on, I am having the following issue:
I have an input web control text box located in the lower 50% of the screen. When the focus goes to the text box, the soft keyboard is displayed and obscures/covers up/hides the input web control for which the user is supposed to be typing into. Only when the user types in at least one character does the input web control become visible and no longer hidden underneath the keyboard.
What I want is for the field being entered NOT to be obscured by the keyboard. When the soft keyboard is displayed, I want the input web control to remain visible.
This is on a Samsung tablet running Android version 3.2.
Please tell me how to accomplish this.
The simplest way to solve this android (and now ios7 too) nasty is to use the inputs focus and blur events. if you don't have a footer tag change to a class.
In jQuery:
$("input").focus(function(){
$('footer').hide();
});
$("input").blur(function(){
$('footer').show();
});
Related
I am creating an App for Dual Screen by using Presentation API for showing a separate view for Customer, in which there is an input field (EditText), which asks the customer to input depending on type of fields. Now, the issue is that the softkeyboard only appears on the main screen & not the secondary screen, due to which only the person facing main screen will be able to input values in EditText. But I want to open softkeyboard on both sides, not both at the same time and atleast they should be able to open it one at a time.
If I try to forcibly open the keyboard it still opens on the other side (main screen) only.
If you were using Android 10:
From:
https://developer.android.com/guide/topics/ui/foldables#software_keyboard
Software keyboard
A keyboard can be shown on a secondary screen if the display is configured to support system decorations. The input method editor will automatically show up if a text field requests input on that display.
While leads to:
Android Open Source Project - Input Method Editor Support
https://source.android.com/devices/tech/display/multi_display/ime-support
and that page has a lot of detail on the various implementation & security issues on having a multiple display IME.
As you mentioned a custom device running Android 7.1 unless the manufacturer has modified for system decorations:
From that AOSP page on IME support:
In Android 9 (and lower), the IME was only available on the default screen...
So from stock AOSP you can't have the native IME appear outside of the default display.
I can only suggest reaching out to the manufacturer to see if they have a custom SDK for that feature, else you will have to create your own IME-like view, assuming you can get touch events from the secondary display.
I have a mobile website and it has some HTML input elements in it, like this:
<input type="number"/>
I have made the site viewable by an Android application.
Is it possible to get the keyboard with symbols instead of the default one with letters when this HTML input element is focused?
It works with IOs using type="number" but on android it shows just a number pad.
The only input you can control reliably is your own. If you want to ensure that there is a keyboard with the right symbols you can:
Specify no inputType (the default keyboard usually has all supported characters)
Create an in-website keyboard.
I dealt with the same problem in the past. We finally settled on the first solution in combination with custom input validation. But none of them are actually good.
I am helping to style a Banking mobile app, and the company is using PhoneGap to build across all platforms. I am using a Nexus 4 (android) to test the app, and have noticed that when input fields are tapped, the screen does not scroll up with the soft keyboard - many input fields get lost behind the keyboard.
I can NOT have the addressbar at the top of the screen show, so the one fix I found that said to change the xml file fullscreen preference won't work.
How can this be fixed? I have not been able to test on other devices yet.
The plugin suggested in the comments worked.
I have an EditText in my Android app, with a normal keyboard attached to it, e.g. there are no custom filters, or other restrictions set on it. I would like to find out if the user uses the QWERTY keyboard, or she switched to another type, for example to the one where the numbers are displayed, and other special characters. Is this possible?
Thanks.
I am developing an Android application. What I find most annoying during testing is, that the emulator always pops up that on-screen telephone keyboard whenever I click into a text input field. Since I input my data with the keyboard anyway I find that most annoying. Can one switch that on-screen keyboard appearance off? Or can one change that so that it at least presents a mini-qwerty keyboard as my actual device does, not that old-fashioned T9 keyboard?
Michael
You can disable the virtual keyboard in Settings->Language.
If you change orientation of the emulator it won't popup (KEYPAD_7, Ctrl-F11).
If you use cursor keys instead of clicking the fields, probably won't popup either.
Whatever you do, keep in mind that in actual devices it usually pops up anyway.