android - Bloated background picture when using keyboard -
i have question regarding background pictures , android keyboard.
my interface looks following in 2 pictures below. search function listview beneath it. problem is, whenever type in search-bar (edittext) keyboard appears , changes background picture. looks awful , bloated. how tell android not change background picture when using keyboard (just make keyboard slide on background picture without changing it) ?
how background should like: http://tinypic.com/view.php?pic=2nsxowx&s=6
keyboard changes background mess: http://tinypic.com/view.php?pic=23huck0&s=6
this xml file:
<tablelayout xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/layout_search_task" android:layout_width="fill_parent" android:layout_height="fill_parent" android:background="@drawable/searchable" android:gravity="center|top" android:orientation="vertical" android:stretchcolumns="1" android:weightsum="1.0" > <tablerow > <edittext android:id="@+id/searchtext" android:layout_width="0dp" android:layout_height="wrap_content" android:layout_weight="0.8" android:hint="@string/searchtaskhint" /> <button android:id="@+id/searchbutton" android:layout_width="0dip" android:layout_height="fill_parent" android:layout_gravity="center" android:layout_weight="0.2" android:text="@string/search" /> </tablerow> <tablerow> <textview android:layout_width="wrap_content" android:layout_height="5dp"> </textview> </tablerow> <tablerow android:paddingleft="40dp"> <textview android:id="@+id/search_task_column_names" android:layout_width="0dip" android:layout_height="wrap_content" android:textstyle="bold" android:layout_weight="0.33" > </textview> <textview android:id="@+id/search_task_column_names1" android:layout_width="0dip" android:layout_height="wrap_content" android:textstyle="bold" android:layout_weight="0.33"> </textview> <textview android:id="@+id/search_task_column_names2" android:layout_width="0dip" android:layout_height="wrap_content" android:textstyle="bold" android:layout_weight="0.33" > </textview> </tablerow> <tablerow android:paddingleft="25dp" android:paddingright="30dp" > <listview android:id="@+id/search_task_list" android:layout_width="fill_parent" android:layout_height="wrap_content" android:gravity="center" /> </tablerow> </tablelayout>
the default behavior when soft keyboard launched os resize view fit within new screen bounds. since have background image result gets pinched seeing.
see documentation here on android:windowsoftinputmode behavior want "adjustpan"
Comments
Post a Comment