0

I have created a login page. If I insert some text in edit text (username, password) etc then a softkeyboard is visible. but it comes on my password field view. So upper half of password field is visible while lower half is not because of that softkeyboard. I want when the softkeyboard is visible the password field to move up a little, so that the entire edittext will be visible.

Thanks

DonGru
  • 13,532
  • 8
  • 45
  • 55
Sunil Kumar Sahoo
  • 53,011
  • 55
  • 178
  • 243

3 Answers3

2

add this line in your menifest.xml file

<activity android:name=".your_activity" android:windowSoftInputMode="adjustResize"></activity>
Niranj Patel
  • 32,980
  • 10
  • 97
  • 133
0

Your layout should shift up automatically when it has focus and the softkeyboard is displaying. I have a login form and I've done nothing special to get this behaviour.

C0deAttack
  • 24,419
  • 18
  • 73
  • 81
0

One way you can solve this is by having a ScrollView as the root of your layout.

Joru
  • 4,406
  • 1
  • 19
  • 13