After reading this (http://developer.android.com/guide/practices/screens_support.html), I have developed an entire app using the dp unit inside the xml files. However, when I test the app in different screens, the layouts are either too big or too small.
I thought the dp unit would fix that for me. Why didn't it? I do not want to use the weight attribute since everything is already done.
One xml layout:
<ImageView
android:layout_width="match_parent"
android:layout_height="140dp"
android:src="@drawable/logo3"
android:scaleType="centerCrop"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/select_level"
android:textColor="#4cb122"
android:layout_gravity="center_horizontal"
android:gravity="center_horizontal"
android:textSize="20dp"
android:layout_marginTop="20dp"
/>
<Button
android:background="@drawable/red_button"
android:layout_width="200dp"
android:layout_height="55dp"
android:layout_gravity="center_horizontal"
android:layout_marginTop="25dp"
android:text="@string/easy"
android:textSize="15dp"
android:onClick="playEasy"
style="custom_button"
/>
<Button
android:background="@drawable/green_button"
android:layout_width="200dp"
android:layout_height="55dp"
android:layout_gravity="center_horizontal"
android:layout_marginTop="10dp"
android:text="@string/medium"
android:textSize="15dp"
android:onClick="playMedium"
style="custom_button"
/>
<Button
android:background="@drawable/blue_button"
android:layout_width="200dp"
android:layout_height="55dp"
android:layout_gravity="center_horizontal"
android:layout_marginTop="10dp"
android:textSize="15dp"
android:text="@string/unbeatable"
android:onClick="playUnbeatable"
style="custom_button"
/>
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_horizontal"
android:layout_marginTop="113dp"
android:textSize="15dp"
android:textColor="@color/secondTextColor"
android:text="@string/developed_by"
/>
What could I do? Thanks!