This is main activity screen of my application.But I do not provide same view in different screen size and density.Please help me.How can I solve this problem.I want to use this xml layout with android API 10 and higher.I tried most of techniques solve this problem but I did not.
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/firstLayout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="center"
android:animateLayoutChanges="true"
android:background="@drawable/home"
>
<RelativeLayout
android:id="@+id/topheader"
android:layout_width="match_parent"
android:layout_height="142dip"
android:layout_alignParentLeft="true"
android:layout_alignParentTop="true" >
</RelativeLayout>
<RelativeLayout
android:id="@+id/RelativeLayout1"
android:layout_width="wrap_content"
android:layout_height="320dip"
android:layout_alignParentBottom="true"
android:layout_alignParentLeft="true" >
<include
android:id="@+id/include2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/include3"
android:layout_alignParentLeft="true"
android:layout_marginBottom="20dip"
layout="@layout/anaekran_seconddock" />
<include
android:id="@+id/include1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/include2"
android:layout_alignParentLeft="true"
android:layout_marginBottom="20dip"
layout="@layout/anaekran_firstdock" />
<include
android:id="@+id/include3"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentLeft="true"
android:layout_marginBottom="30dip"
layout="@layout/anaekran_thirddock" />
</RelativeLayout>
<RelativeLayout
android:id="@+id/relativeLayout2"
android:layout_width="match_parent"
android:layout_height="142dip"
android:layout_alignParentLeft="true"
android:layout_below="@+id/topheader"
android:background="@color/gray" >
<Gallery
android:id="@+id/gallery1"
android:layout_width="match_parent"
android:layout_height="match_parent" />
</RelativeLayout>
you can create different xml files for different screen sizes and put them in their respective folders .
for example for medium screen size put the .xml in res/layout-medium folder.
for large— res/layout-large
for extralarge—res/layout-xlarge
the name of all the xml files must be same in all the folders.
for more information read this