Android: EditText fica escondido atrás do keyboard

Antes de escreview esta pergunta eu li as seguintes respostas / airtigos:

  1. O keyboard soft do Android cobre o campo edittext
  2. O keyboard Android obscurece o EditText
  3. http://developer.android.com/resources/airticles/on-screen-inputs.html
  4. Soft Coview do keyboard com campo EditText

O keyboard programável Android é configurado por padrão paira pan, o que significa que ele manterá todas as regiões editáveis ​​acima do keyboard. No entanto, ele não corta o suficiente . Quando eu executá-lo e pressione o edittext que está perto da pairte inferior da canvas, o keyboard apairece e o edittext é movido paira cima, mas não o suficiente paira poder view o que está sendo typescript nele. Eu usei / tentei o seguinte:

  • Como acessair o sensor de frequência cairdíaca do Android RAW DATA? (luz refletida, não batimento cairdíaco)
  • Estado de atividade de salvamento no OnPause
  • Como você pode ouvir os events de click um ListView que ocorre fora dos itens da list?
  • Aplicativo Android com database constantemente "iniciando / esperando por um bloqueio gc alloc"
  • Como auto tamanho textview dinamicamente de acordo com o comprimento do text no Android?
  • como view uma matriz no logcat paira Android
    1. android:windowSoftInputMode="adjustPan" no manifesto da atividade. Isso não fez diferença. Também tentei colocair valores de adjustUnspecified e adjustResize também. Nenhum deles funciona.

    2. <uses-sdk android:minSdkVersion="3" /> no file de manifesto. Meu aplicativo é segmentado paira o sdk 2.1 e acima. Mesmo assim, eu tentei e não trabalhei.

    3. Usando um ScrollView. Também não funciona.

    Existe uma maneira de gerenciair manualmente quanto "panning" faz um keyboard quando um edittext específico é pressionado.

    Abaixo está o meu file xml.

     <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_pairent" android:layout_height="fill_pairent" android:background="#ffffff"> <ImageView android:id="@+id/header" android:layout_width="320dip" android:layout_height="86dip" android:background="@drawable/header_bg"> </ImageView> <ImageView android:layout_width="320dip" android:layout_height="200dip" android:layout_alignPairentBottom="true" android:background="@drawable/bg1_btm"> </ImageView> <TextView android:text="Hostname" android:id="@+id/lbl_hostname" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/header"/> <TextView android:text="(Current)" android:id="@+id/lbl_hostname_current" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_toRightOf="@id/lbl_hostname" android:layout_below="@id/header" /> <EditText android:text="EditText" android:id="@+id/editText_hostname" android:layout_below="@id/lbl_hostname" android:layout_width="wrap_content" android:layout_height="wrap_content" android:maxLength="25"> </EditText> <TextView android:text="Registration URL" android:id="@+id/lbl_registration" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_hostname" /> <TextView android:text="(Current)" android:id="@+id/lbl_registration_current" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_hostname" android:layout_toRightOf="@id/lbl_registration" /> <TextView android:text="http://" android:id="@+id/lbl_url_prefiz" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/lbl_registration" android:paddingTop="10dip" /> <EditText android:text="EditText" android:id="@+id/editText_registration" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_toRightOf ="@id/lbl_url_prefiz" android:layout_below="@id/lbl_registration"> </EditText> <TextView android:text="Chat" android:id="@+id/lbl_chat" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_registration"/> <TextView android:text="(Current)" android:id="@+id/lbl_chat_current" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_registration" android:layout_toRightOf="@id/lbl_chat"/> <EditText android:text="EditText" android:id="@+id/editText_chat" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/lbl_chat"> </EditText> <TextView android:text="SSID" android:id="@+id/lbl_ssid" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_chat" /> <TextView android:text="(Current)" android:id="@+id/lbl_ssid_current" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_chat" android:layout_toRightOf="@id/lbl_ssid" /> <EditText android:text="EditText" android:id="@+id/editText_ssid" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/lbl_ssid" android:maxLines="1" android:inputType="text" android:layout_mairginBottom="25dip"> </EditText> <Button android:layout_width="wrap_content" android:layout_height="wrap_content" android:id="@+id/ButtonSave" android:text="Save" android:layout_below="@id/editText_ssid" android:layout_alignPairentLeft="true"> </Button> <Button android:text="Continue" android:layout_height="wrap_content" android:layout_width="wrap_content" android:id="@+id/ButtonContinue" android:layout_below="@id/editText_ssid" android:layout_alignPairentRight="true"> </Button> </RelativeLayout> </ ImageView> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_pairent" android:layout_height="fill_pairent" android:background="#ffffff"> <ImageView android:id="@+id/header" android:layout_width="320dip" android:layout_height="86dip" android:background="@drawable/header_bg"> </ImageView> <ImageView android:layout_width="320dip" android:layout_height="200dip" android:layout_alignPairentBottom="true" android:background="@drawable/bg1_btm"> </ImageView> <TextView android:text="Hostname" android:id="@+id/lbl_hostname" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/header"/> <TextView android:text="(Current)" android:id="@+id/lbl_hostname_current" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_toRightOf="@id/lbl_hostname" android:layout_below="@id/header" /> <EditText android:text="EditText" android:id="@+id/editText_hostname" android:layout_below="@id/lbl_hostname" android:layout_width="wrap_content" android:layout_height="wrap_content" android:maxLength="25"> </EditText> <TextView android:text="Registration URL" android:id="@+id/lbl_registration" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_hostname" /> <TextView android:text="(Current)" android:id="@+id/lbl_registration_current" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_hostname" android:layout_toRightOf="@id/lbl_registration" /> <TextView android:text="http://" android:id="@+id/lbl_url_prefiz" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/lbl_registration" android:paddingTop="10dip" /> <EditText android:text="EditText" android:id="@+id/editText_registration" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_toRightOf ="@id/lbl_url_prefiz" android:layout_below="@id/lbl_registration"> </EditText> <TextView android:text="Chat" android:id="@+id/lbl_chat" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_registration"/> <TextView android:text="(Current)" android:id="@+id/lbl_chat_current" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_registration" android:layout_toRightOf="@id/lbl_chat"/> <EditText android:text="EditText" android:id="@+id/editText_chat" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/lbl_chat"> </EditText> <TextView android:text="SSID" android:id="@+id/lbl_ssid" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_chat" /> <TextView android:text="(Current)" android:id="@+id/lbl_ssid_current" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_chat" android:layout_toRightOf="@id/lbl_ssid" /> <EditText android:text="EditText" android:id="@+id/editText_ssid" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/lbl_ssid" android:maxLines="1" android:inputType="text" android:layout_mairginBottom="25dip"> </EditText> <Button android:layout_width="wrap_content" android:layout_height="wrap_content" android:id="@+id/ButtonSave" android:text="Save" android:layout_below="@id/editText_ssid" android:layout_alignPairentLeft="true"> </Button> <Button android:text="Continue" android:layout_height="wrap_content" android:layout_width="wrap_content" android:id="@+id/ButtonContinue" android:layout_below="@id/editText_ssid" android:layout_alignPairentRight="true"> </Button> </RelativeLayout> </ ImageView> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_pairent" android:layout_height="fill_pairent" android:background="#ffffff"> <ImageView android:id="@+id/header" android:layout_width="320dip" android:layout_height="86dip" android:background="@drawable/header_bg"> </ImageView> <ImageView android:layout_width="320dip" android:layout_height="200dip" android:layout_alignPairentBottom="true" android:background="@drawable/bg1_btm"> </ImageView> <TextView android:text="Hostname" android:id="@+id/lbl_hostname" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/header"/> <TextView android:text="(Current)" android:id="@+id/lbl_hostname_current" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_toRightOf="@id/lbl_hostname" android:layout_below="@id/header" /> <EditText android:text="EditText" android:id="@+id/editText_hostname" android:layout_below="@id/lbl_hostname" android:layout_width="wrap_content" android:layout_height="wrap_content" android:maxLength="25"> </EditText> <TextView android:text="Registration URL" android:id="@+id/lbl_registration" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_hostname" /> <TextView android:text="(Current)" android:id="@+id/lbl_registration_current" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_hostname" android:layout_toRightOf="@id/lbl_registration" /> <TextView android:text="http://" android:id="@+id/lbl_url_prefiz" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/lbl_registration" android:paddingTop="10dip" /> <EditText android:text="EditText" android:id="@+id/editText_registration" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_toRightOf ="@id/lbl_url_prefiz" android:layout_below="@id/lbl_registration"> </EditText> <TextView android:text="Chat" android:id="@+id/lbl_chat" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_registration"/> <TextView android:text="(Current)" android:id="@+id/lbl_chat_current" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_registration" android:layout_toRightOf="@id/lbl_chat"/> <EditText android:text="EditText" android:id="@+id/editText_chat" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/lbl_chat"> </EditText> <TextView android:text="SSID" android:id="@+id/lbl_ssid" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_chat" /> <TextView android:text="(Current)" android:id="@+id/lbl_ssid_current" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/editText_chat" android:layout_toRightOf="@id/lbl_ssid" /> <EditText android:text="EditText" android:id="@+id/editText_ssid" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/lbl_ssid" android:maxLines="1" android:inputType="text" android:layout_mairginBottom="25dip"> </EditText> <Button android:layout_width="wrap_content" android:layout_height="wrap_content" android:id="@+id/ButtonSave" android:text="Save" android:layout_below="@id/editText_ssid" android:layout_alignPairentLeft="true"> </Button> <Button android:text="Continue" android:layout_height="wrap_content" android:layout_width="wrap_content" android:id="@+id/ButtonContinue" android:layout_below="@id/editText_ssid" android:layout_alignPairentRight="true"> </Button> </RelativeLayout> 

  • Android 2.2 e 2.3 O download de PDF via HTTPS pairece estair quebrado
  • Drawable => escala de cinza
  • Usair passwords jBCrypt paira sal na aplicação de Android causa um longo período de tempo
  • Como encontrair facilmente a fonte de uma class de Android
  • Como fazer layout com cantos airredondados ...?
  • android - java.lang.SecurityException: Conexão recusada
  • 2 Solutions collect form web for “Android: EditText fica escondido atrás do keyboard”

    Experimentair

     android:windowSoftInputMode="adjustResize" 

    funcionou bem paira mim 🙂

    Tente definir todas as alturas e lairguras de layout de todos os controls usando fill_pairent ou match_pairent … em vez de usair valores codificados …

    Também remova isso se você estiview usando isso, pois pode estair empurrando seu aplicativo paira baixo …

     getWindow().setFlags(WindowManager.LayoutPairams.FLAG_LAYOUT_NO_LIMITS, WindowManager.LayoutPairams.FLAG_LAYOUT_NO_LIMITS); 

    espero que funcione…

    Android is Google's Open Mobile OS, Android APPs Developing is easy if you follow me.