Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>There's nothing that says <code>7"</code> or <code>10"</code> AFAIK. There are roughly two ways do get screen dimensions that the system uses when decoding bitmaps and whatnot. They're both found in the application's <a href="http://developer.android.com/reference/android/content/res/Resources.html"><code>Resources</code></a> object found in the <code>Context</code>.</p> <p>The first is the <a href="http://developer.android.com/reference/android/content/res/Configuration.html"><code>Configuration</code></a> object which can be obtained by <code>getContext().getResources().getConfiguration()</code>. In it you have:</p> <p><code>Configuration#densityDpi</code> - The target screen density being rendered to, corresponding to density resource qualifier.</p> <p><code>Configuration#screenHeightDp</code> - The current height of the available screen space, in dp units, corresponding to screen height resource qualifier.</p> <p><code>Configuration#screenWidthDp</code> - The current width of the available screen space, in dp units, corresponding to screen width resource qualifier.</p> <p><code>Configuration#smallestScreenWidthDp</code> - The smallest screen size an application will see in normal operation, corresponding to smallest screen width resource qualifier.</p> <p>With that, you can pretty much use the screen guidelines to figure out if your device is pulling from the respective specialized resource folders (<code>hdpi</code>, <code>xhdpi</code>, <code>large</code>, <code>xlarge</code>, etc.).</p> <p>Remember, these are some of the buckets:</p> <ul> <li>xlarge screens are at least 960dp x 720dp</li> <li>large screens are at least 640dp x 480dp</li> <li>normal screens are at least 470dp x 320dp</li> <li><p>small screens are at least 426dp x 320dp</p></li> <li><p>320dp: a typical phone screen (240x320 ldpi, 320x480 mdpi, 480x800 hdpi, etc).</p></li> <li>480dp: a tweener tablet like the Streak (480x800 mdpi).</li> <li>600dp: a 7” tablet (600x1024 mdpi).</li> <li>720dp: a 10” tablet (720x1280 mdpi, 800x1280 mdpi, etc).</li> </ul> <p><a href="http://developer.android.com/guide/practices/screens_support.html#qualifiers">More info</a></p> <p>The second is the <a href="http://developer.android.com/reference/android/util/DisplayMetrics.html"><code>DisplayMetrics</code></a> object obtained by <code>getContext().getResources().getDisplayMetrics()</code>. In that you have:</p> <p><code>DisplayMetrics#density</code> - The logical density of the display.</p> <p><code>DisplayMetrics#densityDpi</code> - The screen density expressed as dots-per-inch.</p> <p><code>DisplayMetrics#heightPixels</code> - The absolute height of the display in pixels.</p> <p><code>DisplayMetrics#widthPixels</code> - The absolute width of the display in pixels.</p> <p><code>DisplayMetrics#xdpi</code> - The exact physical pixels per inch of the screen in the X dimension.</p> <p><code>DisplayMetrics#ydpi</code> - The exact physical pixels per inch of the screen in the Y dimension.</p> <p>This is handy if you need exact pixel count of the screen rather than density. However, it is important to note that this is <strong>all</strong> the screen's pixels. Not just the ones available to you.</p>
    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.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      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