summaryrefslogtreecommitdiffstats
path: root/docs/html/guide/topics/resources
diff options
context:
space:
mode:
authorScott Main <smain@google.com>2011-07-14 13:55:29 -0700
committerScott Main <smain@google.com>2011-07-27 11:59:17 -0700
commit759c89322548dd88b35a3f3b4b5e636c515bbc57 (patch)
treee8b8c23323d4d68e145388cc93cd59d5c76e1a61 /docs/html/guide/topics/resources
parent2e6c04b460db2cf8cd7f1e5590b1df11ca4f6253 (diff)
downloadframeworks_base-759c89322548dd88b35a3f3b4b5e636c515bbc57.zip
frameworks_base-759c89322548dd88b35a3f3b4b5e636c515bbc57.tar.gz
frameworks_base-759c89322548dd88b35a3f3b4b5e636c515bbc57.tar.bz2
Change-Id: I2134948e83bdca3f85c501b5d4f65c1c630f1b85
docs: revise the supporting screens doc for more clarification
Diffstat (limited to 'docs/html/guide/topics/resources')
-rw-r--r--docs/html/guide/topics/resources/providing-resources.jd54
1 files changed, 34 insertions, 20 deletions
diff --git a/docs/html/guide/topics/resources/providing-resources.jd b/docs/html/guide/topics/resources/providing-resources.jd
index 9dcda39..252c153 100644
--- a/docs/html/guide/topics/resources/providing-resources.jd
+++ b/docs/html/guide/topics/resources/providing-resources.jd
@@ -334,7 +334,7 @@ indicates the current locale.</p>
</td>
</tr>
<tr id="SmallestScreenWidthQualifier">
- <td>Smallest available width</td>
+ <td>smallestWidth</td>
<td><code>sw&lt;N&gt;dp</code><br/><br/>
Examples:<br/>
<code>sw320dp</code><br/>
@@ -343,18 +343,23 @@ indicates the current locale.</p>
etc.
</td>
<td>
- <p>Specifies the "smallest width" in {@code dp} units that must be available to your
- application in order for the resources to be used, regardless of the screen's current
- orientation. For example, if your layout requires that its shortest side be at least 600
- dp in length at all times, then you can use this to create the layout resources, {@code
- res/layout-sw600dp/}, and the system will use them only when the shortest side of
- available screen space it at least 600dp.</p>
- <p>The width against which the system compares your value takes into account screen
- decorations and system UI. For example, if the device has some persistent UI elements on the
- left or right edge of the display, the system declares its own available width as one that
- is smaller than the actual screen size, accounting for these UI elements because those are
- screen pixels not available for your UI. Thus, the value you use should be the actual
- smallest width required by your layout.</p>
+ <p>The fundamental size of a screen, as indicated by the shortest dimension of the available
+screen area. Specifically, the device's smallestWidth is the shortest of the screen's available
+height and width (you may also think of it as the "smallest possible width" for the screen). You can
+use this qualifier to ensure that, regardless of the screen's current orientation, your
+application's has at least {@code &lt;N&gt;} dps of width available for it UI.</p>
+ <p>For example, if your layout requires that its smallest dimension of screen area be at
+least 600 dp at all times, then you can use this qualifer to create the layout resources, {@code
+res/layout-sw600dp/}. The system will use these resources only when the smallest dimension of
+available screen is at least 600dp, regardless of whether the 600dp side is the user-perceived
+height or width. The smallestWidth is a fixed screen size characteristic of the device; <strong>the
+device's smallestWidth does not change when the screen's orientation changes</strong>.</p>
+ <p>The smallestWidth of a device takes into account screen decorations and system UI. For
+example, if the device has some persistent UI elements on the screen that account for space along
+the axis of the smallestWidth, the system declares the smallestWidth to be smaller than the actual
+screen size, because those are screen pixels not available for your UI. Thus, the value you use
+should be the actual smallest dimension <em>required by your layout</em> (usually, this value is the
+"smallest width" that your layout supports, regardless of the screen's current orientation).</p>
<p>Some values you might use here for common screen sizes:</p>
<ul>
<li>320, for devices with screen configurations such as:
@@ -369,15 +374,18 @@ indicates the current locale.</p>
<li>720, for screens such as 720x1280 mdpi (10" tablet).</li>
</ul>
<p>When your application provides multiple resource directories with different values for
- this qualifier, the system uses the one closest to (without exceeding) the smallest width
- for the available space. </p>
+ the smallestWidth qualifier, the system uses the one closest to (without exceeding) the
+device's smallestWidth. </p>
<p><em>Added in API level 13.</em></p>
<p>Also see the <a
- href="{@docRoot}guide/topics/manifest/supports-screens-element.html#requiresSmallest">{@code
- android:requiresSmallestWidthDp}</a> attribute, which declares the smallest available width
- with which your application is compatible, and the {@link
- android.content.res.Configuration#smallestScreenWidthDp} configuration field, which holds
- the current smallest screen width for the device.</p>
+href="{@docRoot}guide/topics/manifest/supports-screens-element.html#requiresSmallest">{@code
+android:requiresSmallestWidthDp}</a> attribute, which declares the minimum smallestWidth with which
+your application is compatible, and the {@link
+android.content.res.Configuration#smallestScreenWidthDp} configuration field, which holds the
+device's smallestWidth value.</p>
+ <p>For more information about designing for different screens and using this
+qualifier, see the <a href="{@docRoot}guide/practices/screens_support.html">Supporting
+Multiple Screens</a> developer guide.</p>
</td>
</tr>
<tr id="ScreenWidthQualifier">
@@ -403,6 +411,9 @@ indicates the current locale.</p>
<p><em>Added in API level 13.</em></p>
<p>Also see the {@link android.content.res.Configuration#screenWidthDp}
configuration field, which holds the current screen width.</p>
+ <p>For more information about designing for different screens and using this
+qualifier, see the <a href="{@docRoot}guide/practices/screens_support.html">Supporting
+Multiple Screens</a> developer guide.</p>
</td>
</tr>
<tr id="ScreenHeightQualifier">
@@ -432,6 +443,9 @@ indicates the current locale.</p>
<p><em>Added in API level 13.</em></p>
<p>Also see the {@link android.content.res.Configuration#screenHeightDp}
configuration field, which holds the current screen width.</p>
+ <p>For more information about designing for different screens and using this
+qualifier, see the <a href="{@docRoot}guide/practices/screens_support.html">Supporting
+Multiple Screens</a> developer guide.</p>
</td>
</tr>
<tr id="ScreenSizeQualifier">