I am having an comment edit text in my application. The edit text is aligned at the bottom of the screen. when edit text is focused i want to move edit text alone with soft keyboard without changing other views in layout similar to comment edit box in facebook. I tried adjustpan in manifest but it moves all views up with soft keyboard. adjustresize in manifest hides some view.please provide suggestions.
Asked
Active
Viewed 5,378 times
4
-
I am also facing same problem. Any luck ? Can you please share with me ? – Gangadhar Nimballi Nov 11 '14 at 11:34
3 Answers
1
Try like this inside your Android manifest file..
<activity name="YourActivity"
android:windowSoftInputMode="stateVisible|adjustResize">
</activity>
or
<activity name="YourActivity"
android:windowSoftInputMode="stateVisible|adjustPan">
</activity>
Please also read this for ref/Clarity

CRUSADER
- 5,486
- 3
- 28
- 64
-
1i tried with resize it hides some of the view, i want only to move the edit text with keyboard without changing the position of other view.but resize and adjustpan affects all the view – user1526671 Jun 18 '13 at 05:14
-
same problem. need space between edittext and soft keyboard to display errors? – filthy_wizard Apr 08 '16 at 10:53
1
Add
android:windowSoftInputMode="adjustPan"
in your AndroidManifest file (in activity property)

Joe Li
- 21
- 3
0
dialog.getWindow().
setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_STATE_ALWAYS_VISIBLE);
Its also working with out manifest file entry

Uma
- 422
- 4
- 5