android-softkeyboard

Keyboard hiding EditText when android:windowTranslucentStatus=true

时间秒杀一切 提交于 2019-12-29 03:51:10
问题 We're applying the new Android KitKat translucent theme in our apps, and we're getting a weird issue when the keyboard appears. If we don't use the new android:windowTranslucentStatus attribute, all works as usual: The screen is resized, and all remains visible. But when we're using android:windowTranslucentStatus , the screen isn't resized and our EditText becomes hidden by the keyboard. A sample of the issue: The only difference between the screens is in the attribute in the style: First

How can I implement special soft keyboard

做~自己de王妃 提交于 2019-12-29 03:15:06
问题 I want to make special soft keyboard to use it in my android app like the following I worked on the software keyboard sample and I edited the qwerty.xml <?xml version="1.0" encoding="utf-8"?> <!-- /* ** ** Copyright 2008, The Android Open Source Project ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless

Coordinatorlayout adjustresize not working

百般思念 提交于 2019-12-28 12:01:10
问题 MY CODE (and more): I have a Coordinator Layout as follows <android.support.design.widget.CoordinatorLayout android:layout_width="match_parent" android:layout_height="match_parent" android:fitsSystemWindows="true"> <android.support.design.widget.AppBarLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:fitsSystemWindows="true"> <android.support.design.widget.CollapsingToolbarLayout android:id="@+id/collapse_toolbar" android:layout_width="match_parent"

Soft keyboard hides half of EditText

。_饼干妹妹 提交于 2019-12-28 12:00:29
问题 I have a listview and the last list item contains EditText: <RelativeLayout android:id="@+id/contentLayout" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_alignParentLeft="true" android:layout_alignParentRight="true" android:layout_alignParentTop="true" android:layout_marginLeft="10dp" android:layout_marginRight="10dp" android:layout_marginTop="30dp" android:orientation="vertical" > <ImageView android:id="@+id/test" android:layout_width="wrap_content"

How to detect a MotionEvent inside dispatchTouchEvent

时光毁灭记忆、已成空白 提交于 2019-12-25 09:36:59
问题 I have made a FragmentActivity. Some Fragments include an EditText . I would like, when the Soft Input Keyboard is up and a MotionEvent happens - except the Event of clicking inside the EditText - the Soft Input to hide. Until now I wrote this code in my MainActivity: @Override public boolean dispatchTouchEvent(MotionEvent ev) { InputMethodManager im = (InputMethodManager) getApplicationContext() .getSystemService(Context.INPUT_METHOD_SERVICE); im.hideSoftInputFromWindow(getWindow()

Why doesn't the softKeyboard open when I tap an editText inside a ViewPager?

心不动则不痛 提交于 2019-12-25 07:44:40
问题 Like the title says, I've got a viewPager with some editText fields inside. I can select the editText fields perfectly fine (emulator and physical device). I see the cursor, and I see the underline color change, indicating it's selected, but I can't type. Tapping on the editText fields doesn't open the softKeyboard. Is this a known issue with a simple fix, or is code needed to identify what's going wrong here? 回答1: Finally bumped in to an answer that's working for me, which can be found here.

Using keyboard with stateAlwaysVisible, after touch any letter its “select” the button, why?

青春壹個敷衍的年華 提交于 2019-12-25 03:48:26
问题 I have only one button in my layout and the activity has nothing. On Manifest it has the android:windowSoftInputMode="stateAlwaysVisible" for the activity, to always show the keyboard. The problem is that when touch any key on keyboard the only one button is kind selected. Like "highlighted" the entire button in blue. But I don't want this behavior, how can I avoid it? Sorry I can not add images because of my reputation... Below are my codes: Manifest: <activity android:name="

Hide Soft Keyboard from anywhere

半腔热情 提交于 2019-12-25 03:11:46
问题 Hiding the soft keyboard is pain. I use some methods based on having an EditText which gets focus, but in my current app the keyboard keeps popping up at some point where a new fragment is loaded. I have a method in my helper class, but it does not work for me: //Hide keyboard public static void hideSoftKeyboard(Activity activity) { activity.getWindow().setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_STATE_ALWAYS_HIDDEN); } What I would love is a helper method, I could call from

Enter Button on Soft KeyBoard - Android

空扰寡人 提交于 2019-12-25 02:17:22
问题 Im using a a Single Line Edit Text , so when i click on Edit text box, im getting "Go" in place of Enter button. But i want Enter key in place of "Go" key . How can i do this .. Please some one can give solution for this ? 回答1: I am not sure but you can try android:imeOptions="actionDone" , in short you need to try android:imeOptions attribute. 来源: https://stackoverflow.com/questions/6790672/enter-button-on-soft-keyboard-android

Hide or disable WebView softkeyboard Go/Done/Enter button

喜夏-厌秋 提交于 2019-12-25 02:07:14
问题 I've been searching for a working example of this all day and haven't found anything that actually works. I have a simple feedback form online which I've setup with WebView to work on android devices, specifically for Nexus 7 (it will only be used locally at our hotel on these devices). The thing is that the html feedback form has different fieldsets, some with radio buttons others with text fields and text areas. The form is sent via post and I have a jquery validation script called in the