VIGNESH
VIGNESH

Reputation: 2033

Keyboard popup for editText should not push the UI and draw on top

After searching many related threads , i am posting this question .

My problem is that when i click on the editText box the Keyboard popup pushes the UI and the keyboard draws at the bottom rather i want the keyboard to draw over my UI and according to Android - Adjust screen when keyboard pops up?

I tried android:windowSoftInputMode="adjustPan" in my manifest file but that didnt solve my problem . Again i get the same issue .

Is there any other solution , any related answers are welcomed . Thanks in advance .

Upvotes: 0

Views: 1170

Answers (4)

Dom
Dom

Reputation: 1457

I had this problem as well, and even though

android:windowSoftInputMode="adjustPan"

should work, try putting the following code instead, in the onCreate() method of your activity:

getWindow().setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_ADJUST_PAN);

Upvotes: 1

Heigo
Heigo

Reputation: 946

In your AndroidManifest.xml, add the following line under the activity with the keyboard:

android:windowSoftInputMode="adjustNothing"

Duplicate: Keyboard Showed messed up elements' position

Upvotes: 1

amalBit
amalBit

Reputation: 12181

Insted of ..

 android:windowSoftInputMode="adjustPan"

Try this..

android:windowSoftInputMode="adjustResize"

Upvotes: 0

mstrengis
mstrengis

Reputation: 839

i think android:windowSoftInputMode="adjustResize" is what you are looking for

Upvotes: 0

Related Questions