Note that there are some explanatory texts on larger screens.

plurals
  1. POissue with android layout for different screen sizes
    primarykey
    data
    text
    <p>I have an android app with various buttons and text views. The buttons, textviews and edittext fields are spaced around on the screen using measurment of dp. So for example a button will have: 'margintop from left 10dp' </p> <p>The problem is for high density phones. I have created a new layout for higher density screens and named them either layout-large or layout-sw600-sw720 (as the problem is with galaxy s3).</p> <p>But the phone still keeps calling the normal layout file which is suited to density screen 480 x 800. </p> <p>I read that the s3 calls the mormal layout file. So if I change the xml in the normal file to that of the high density, what should I do with the lowere density layout xml? what file name should I call it and will the phone call this file or the normal file again?</p> <p>Extract of XML layout:</p> <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" android:background="@drawable/duroodscreen" android:paddingLeft="5dp" android:paddingRight="5dp" android:paddingTop="5dp" &gt; &lt;Button android:id="@+id/dmute" android:layout_width="48dp" android:layout_height="33dp" android:layout_alignParentLeft="true" android:background="@drawable/soundon" /&gt; &lt;Button android:id="@+id/dreset" style="?android:attr/buttonStyleSmall" android:layout_width="48dp" android:layout_height="33dp" android:layout_alignParentRight="true" android:background="@drawable/customresetbutton" /&gt; &lt;TextView android:id="@+id/dcount" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignParentLeft="true" android:layout_below="@+id/dmute" android:layout_marginLeft="25dp" android:layout_marginTop="36dp" android:gravity="center" android:singleLine="true" android:text="Numbers" android:textSize="25sp" /&gt; </code></pre> <p>Refference in Manifest:</p> <pre><code>&lt;supports-screens android:resizeable="true" android:smallScreens="true" android:normalScreens="true" android:largeScreens="true" android:anyDensity="true" /&gt; </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload