0

I wrote a small program to evaluate expressions using the set. But on the small screen is the following

With keyboard and without keyboard

How to fix the Layout Issue?

solved the problem by adding in AndroidManifest.xml line
android:windowSoftInputMode="stateHidden|adjustPan"
thx for helping

2 Answers2

0

You can use the android:windowSoftInputMode attribute of your <activity /> element in AndroidManifest.xml to control what Android does to your application window when the keyboard is opened.

Barend
  • 17,296
  • 2
  • 61
  • 80
0

hide your keyboard:

<activity android:name="com.your.package.ActivityName"
          android:windowSoftInputMode="stateHidden|adjustResize"  />

when your app start keyboard is hide. when you touch on edittext then it open.

you can also hide it using:

InputMethodManager imm = (InputMethodManager)getSystemService(
      Context.INPUT_METHOD_SERVICE);
imm.hideSoftInputFromWindow(myEditText.getWindowToken(), 0);

check this link for layouts check all answer.

Community
  • 1
  • 1
Dhaval Parmar
  • 18,812
  • 8
  • 82
  • 177