Loading core/java/android/util/DisplayMetrics.java +3 −0 Original line number Diff line number Diff line Loading @@ -24,6 +24,9 @@ import android.os.*; /** * A structure describing general information about a display, such as its * size, density, and font scaling. * <p>To access the DisplayMetrics members, initialize an object like this:</p> * <pre> DisplayMetrics metrics = new DisplayMetrics(); * getWindowManager().getDefaultDisplay().getMetrics(metrics);</pre> */ public class DisplayMetrics { /** Loading docs/html/guide/guide_toc.cs +5 −0 Original line number Diff line number Diff line Loading @@ -145,7 +145,9 @@ <li><a href="<?cs var:toroot ?>guide/topics/manifest/provider-element.html"><provider></a></li> <li><a href="<?cs var:toroot ?>guide/topics/manifest/receiver-element.html"><receiver></a></li> <li><a href="<?cs var:toroot ?>guide/topics/manifest/service-element.html"><service></a></li> <li><a href="<?cs var:toroot ?>guide/topics/manifest/supports-screens-element.html"><supports-screens></a></li> <!-- ##api level 4## --> <li><a href="<?cs var:toroot ?>guide/topics/manifest/uses-configuration-element.html"><uses-configuration></a></li> <li><a href="<?cs var:toroot ?>guide/topics/manifest/uses-feature-element.html"><uses-feature></a></li> <!-- ##api level 4## --> <li><a href="<?cs var:toroot ?>guide/topics/manifest/uses-library-element.html"><uses-library></a></li> <li><a href="<?cs var:toroot ?>guide/topics/manifest/uses-permission-element.html"><uses-permission></a></li> <li><a href="<?cs var:toroot ?>guide/topics/manifest/uses-sdk-element.html"><uses-sdk></a></li> Loading Loading @@ -407,6 +409,9 @@ <span class="zh-TW">附錄</span> </h2> <ul> <li><a href="<?cs var:toroot ?>guide/appendix/api-levels.html"> <span class="en">Android API Levels</span> </a></li> <li><a href="<?cs var:toroot ?>guide/appendix/media-formats.html"> <span class="en">Supported Media Formats</span> </a></li> Loading docs/html/guide/topics/manifest/manifest-intro.jd +6 −3 Original line number Diff line number Diff line Loading @@ -78,10 +78,11 @@ other mention of the element name. <a href="{@docRoot}guide/topics/manifest/permission-element.html"><permission /></a> <a href="{@docRoot}guide/topics/manifest/permission-tree-element.html"><permission-tree /></a> <a href="{@docRoot}guide/topics/manifest/permission-group-element.html"><permission-group /></a> <a href="{@docRoot}guide/topics/manifest/instrumentation-element.html"><instrumentation /></a> <a href="{@docRoot}guide/topics/manifest/uses-sdk-element.html"><uses-sdk /></a> <a href="{@docRoot}guide/topics/manifest/uses-configuration-element.html"><uses-configuration /></a> <!-- ##api level 3## --> <a href="{@docRoot}guide/topics/manifest/uses-feature-element.html"><uses-feature /></a> <!-- ##api level 4## --> <a href="{@docRoot}guide/topics/manifest/supports-screens-element.html"><supports-screens /></a> <!-- ##api level 4## --> <a href="{@docRoot}guide/topics/manifest/application-element.html"><application></a> Loading Loading @@ -115,7 +116,6 @@ other mention of the element name. <a href="{@docRoot}guide/topics/manifest/provider-element.html"></provider></a> <a href="{@docRoot}guide/topics/manifest/uses-library-element.html"><uses-library /></a> <a href="{@docRoot}guide/topics/manifest/uses-configuration-element.html"><uses-configuration /></a> <!-- ##api level 3## --> <a href="{@docRoot}guide/topics/manifest/application-element.html"></application></a> Loading Loading @@ -146,7 +146,9 @@ add your own elements or attributes. <br/><code><a href="{@docRoot}guide/topics/manifest/provider-element.html"><provider></a></code> <br/><code><a href="{@docRoot}guide/topics/manifest/receiver-element.html"><receiver></a></code> <br/><code><a href="{@docRoot}guide/topics/manifest/service-element.html"><service></a></code> <br/><code><a href="{@docRoot}guide/topics/manifest/supports-screens-element.html"><supports-screens></a></code> <!-- ##api level 4## --> <br/><code><a href="{@docRoot}guide/topics/manifest/uses-configuration-element.html"><uses-configuration></a></code> <!-- ##api level 3## --> <br/><code><a href="{@docRoot}guide/topics/manifest/uses-feature-element.html"><uses-feature></a></code> <!-- ##api level 4## --> <br/><code><a href="{@docRoot}guide/topics/manifest/uses-library-element.html"><uses-library></a></code> <br/><code><a href="{@docRoot}guide/topics/manifest/uses-permission-element.html"><uses-permission></a></code> <br/><code><a href="{@docRoot}guide/topics/manifest/uses-sdk-element.html"><uses-sdk></a></code> Loading @@ -154,6 +156,7 @@ add your own elements or attributes. <h2 id="filec">File Conventions</h2> <p> Loading docs/html/guide/topics/manifest/supports-screens-element.jd 0 → 100644 +123 −0 Original line number Diff line number Diff line page.title=<supports-screens> @jd:body <dl class="xml"> <dt>syntax:</dt> <dd> <pre class="stx"> <supports-screens android:<a href="#small">smallScreens</a>=["true" | "false"] android:<a href="#normal">normalScreens</a>=["true" | "false"] android:<a href="#large">largeScreens</a>=["true" | "false"] android:<a href="#any">anyDensity</a>=["true" | "false"] /> </pre> </dd> <dt>contained in:</dt> <dd><code><a href="{@docRoot}guide/topics/manifest/manifest-element.html"><manifest></a></code></dd> <dt>description:</dt> <dd>Lets you specify the screen dimensions the application supports. By default a modern application (using API Level 4 or higher) supports all screen sizes and must explicitly disable certain screen sizes here; older applications are assumed to support only the "normal" screen size. Note that screen size is a separate axis from density. Screen size is determined as the available pixels to an application after density scaling has been applied. <p>Based on the target device screen density, the Android framework will scale down assets by a factor of 0.75 (low dpi screens) or scale them up by a factor of 1.5 (high dpi screens). The screen density is expressed as dots-per-inch (dpi).</p> <p>Currently supported densities:</p> <ul> <li>Low density: 120 dpi</li> <li>Medium density: 160 dpi</li> <li>High density: 240 dpi</li> </ul> <p>Table of display types:</p> <table> <tr> <th></th><th>Low Density</th><th>Medium Density</th><th>High Density</th> </tr> <tr> <th>Small Screen</th> <td>QVGA</td> <td>n/a</td> <td>VGA</td> </tr> <tr> <th>Normal Screen</th> <td>WQVGA</td> <td>HVGA</td> <td>WVGA, FWVGA</td> </tr> <tr> <th>Large Screen</th> <td>n/a</td> <td>VGA, WVGA, FWVGA</td> <td>n/a</td> </tr> </table> </dd> <dt>attributes:</dt> <dd> <dl class="attr"><dt><a name="small"></a>{@code android:smallScreens}</dt> <dd>Indicates whether the application supports smaller screen form-factors. A small screen is defined as one with a smaller aspect ratio than the "normal" (traditional HVGA) screen. An application that does not support small screens <em>will not be available</em> for small screen devices, because there is little the platform can do to make such an application work on a smaller screen. Applications using API Level 4 or higher default this to "true", others are "false". </dd> <dt><a name="normal"></a>{@code android:normalScreens}</dt> <dd>Indicates whether an application supports the "normal" screen form-factors. Traditionally this is an HVGA medium density screen, but WQVGA low density and WVGA high density are also considered to be normal. This attribute is "true" by default, and applications currently should leave it that way. </dd> <dt><a name="large"></a>{@code android:largeScreens}</dt> <dd>Indicates whether the application supports larger screen form-factors. A large screen is defined as a screen that is significantly larger than a "normal" phone screen, and thus may require some special care on the application's part to make good use of it. An application that does not support large screens will be placed as a "postage stamp" on such a screen, so that it retains the dimensions it was originally designed for. Applications using API Level 4 or higher default to "true", others are "false". </dd> <dt><a name="any"></a>{@code android:anyDensity}</dt> <dd>Indicates whether the application can accommodate any screen density. Older applications (pre API Level 4) are assumed unable to accomodate all densities and this is "false" by default. Applications using API Level 4 or higher are assumed able to and this is "true" by default. You can explicitly supply your abilities here. </dd> </dl></dd> <!-- ##api level indication## --> <dt>introduced in:</dt> <dd>API Level 4</dd> <dt>see also:</dt> <dd> <ul> <li>{@link android.util.DisplayMetrics}</li> </ul> </dd> </dl> docs/html/guide/topics/manifest/uses-configuration-element.jd +7 −2 Original line number Diff line number Diff line Loading @@ -168,9 +168,14 @@ The value must be one of the following strings: <dd>API Level 3</dd> <dt>see also:</dt> <dd><code><a href="{@docRoot}guide/topics/manifest/activity-element.html#config">configChanges</a></code> <dd> <ul> <li><code><a href="{@docRoot}guide/topics/manifest/activity-element.html#config">configChanges</a></code> attribute of the <code><a href="{@docRoot}guide/topics/manifest/activity-element.html"><activity></a></code> element</dd> element</dd></li> <li>{@link android.content.pm.ConfigurationInfo}</li> </ul> </dd> </dl> Loading
core/java/android/util/DisplayMetrics.java +3 −0 Original line number Diff line number Diff line Loading @@ -24,6 +24,9 @@ import android.os.*; /** * A structure describing general information about a display, such as its * size, density, and font scaling. * <p>To access the DisplayMetrics members, initialize an object like this:</p> * <pre> DisplayMetrics metrics = new DisplayMetrics(); * getWindowManager().getDefaultDisplay().getMetrics(metrics);</pre> */ public class DisplayMetrics { /** Loading
docs/html/guide/guide_toc.cs +5 −0 Original line number Diff line number Diff line Loading @@ -145,7 +145,9 @@ <li><a href="<?cs var:toroot ?>guide/topics/manifest/provider-element.html"><provider></a></li> <li><a href="<?cs var:toroot ?>guide/topics/manifest/receiver-element.html"><receiver></a></li> <li><a href="<?cs var:toroot ?>guide/topics/manifest/service-element.html"><service></a></li> <li><a href="<?cs var:toroot ?>guide/topics/manifest/supports-screens-element.html"><supports-screens></a></li> <!-- ##api level 4## --> <li><a href="<?cs var:toroot ?>guide/topics/manifest/uses-configuration-element.html"><uses-configuration></a></li> <li><a href="<?cs var:toroot ?>guide/topics/manifest/uses-feature-element.html"><uses-feature></a></li> <!-- ##api level 4## --> <li><a href="<?cs var:toroot ?>guide/topics/manifest/uses-library-element.html"><uses-library></a></li> <li><a href="<?cs var:toroot ?>guide/topics/manifest/uses-permission-element.html"><uses-permission></a></li> <li><a href="<?cs var:toroot ?>guide/topics/manifest/uses-sdk-element.html"><uses-sdk></a></li> Loading Loading @@ -407,6 +409,9 @@ <span class="zh-TW">附錄</span> </h2> <ul> <li><a href="<?cs var:toroot ?>guide/appendix/api-levels.html"> <span class="en">Android API Levels</span> </a></li> <li><a href="<?cs var:toroot ?>guide/appendix/media-formats.html"> <span class="en">Supported Media Formats</span> </a></li> Loading
docs/html/guide/topics/manifest/manifest-intro.jd +6 −3 Original line number Diff line number Diff line Loading @@ -78,10 +78,11 @@ other mention of the element name. <a href="{@docRoot}guide/topics/manifest/permission-element.html"><permission /></a> <a href="{@docRoot}guide/topics/manifest/permission-tree-element.html"><permission-tree /></a> <a href="{@docRoot}guide/topics/manifest/permission-group-element.html"><permission-group /></a> <a href="{@docRoot}guide/topics/manifest/instrumentation-element.html"><instrumentation /></a> <a href="{@docRoot}guide/topics/manifest/uses-sdk-element.html"><uses-sdk /></a> <a href="{@docRoot}guide/topics/manifest/uses-configuration-element.html"><uses-configuration /></a> <!-- ##api level 3## --> <a href="{@docRoot}guide/topics/manifest/uses-feature-element.html"><uses-feature /></a> <!-- ##api level 4## --> <a href="{@docRoot}guide/topics/manifest/supports-screens-element.html"><supports-screens /></a> <!-- ##api level 4## --> <a href="{@docRoot}guide/topics/manifest/application-element.html"><application></a> Loading Loading @@ -115,7 +116,6 @@ other mention of the element name. <a href="{@docRoot}guide/topics/manifest/provider-element.html"></provider></a> <a href="{@docRoot}guide/topics/manifest/uses-library-element.html"><uses-library /></a> <a href="{@docRoot}guide/topics/manifest/uses-configuration-element.html"><uses-configuration /></a> <!-- ##api level 3## --> <a href="{@docRoot}guide/topics/manifest/application-element.html"></application></a> Loading Loading @@ -146,7 +146,9 @@ add your own elements or attributes. <br/><code><a href="{@docRoot}guide/topics/manifest/provider-element.html"><provider></a></code> <br/><code><a href="{@docRoot}guide/topics/manifest/receiver-element.html"><receiver></a></code> <br/><code><a href="{@docRoot}guide/topics/manifest/service-element.html"><service></a></code> <br/><code><a href="{@docRoot}guide/topics/manifest/supports-screens-element.html"><supports-screens></a></code> <!-- ##api level 4## --> <br/><code><a href="{@docRoot}guide/topics/manifest/uses-configuration-element.html"><uses-configuration></a></code> <!-- ##api level 3## --> <br/><code><a href="{@docRoot}guide/topics/manifest/uses-feature-element.html"><uses-feature></a></code> <!-- ##api level 4## --> <br/><code><a href="{@docRoot}guide/topics/manifest/uses-library-element.html"><uses-library></a></code> <br/><code><a href="{@docRoot}guide/topics/manifest/uses-permission-element.html"><uses-permission></a></code> <br/><code><a href="{@docRoot}guide/topics/manifest/uses-sdk-element.html"><uses-sdk></a></code> Loading @@ -154,6 +156,7 @@ add your own elements or attributes. <h2 id="filec">File Conventions</h2> <p> Loading
docs/html/guide/topics/manifest/supports-screens-element.jd 0 → 100644 +123 −0 Original line number Diff line number Diff line page.title=<supports-screens> @jd:body <dl class="xml"> <dt>syntax:</dt> <dd> <pre class="stx"> <supports-screens android:<a href="#small">smallScreens</a>=["true" | "false"] android:<a href="#normal">normalScreens</a>=["true" | "false"] android:<a href="#large">largeScreens</a>=["true" | "false"] android:<a href="#any">anyDensity</a>=["true" | "false"] /> </pre> </dd> <dt>contained in:</dt> <dd><code><a href="{@docRoot}guide/topics/manifest/manifest-element.html"><manifest></a></code></dd> <dt>description:</dt> <dd>Lets you specify the screen dimensions the application supports. By default a modern application (using API Level 4 or higher) supports all screen sizes and must explicitly disable certain screen sizes here; older applications are assumed to support only the "normal" screen size. Note that screen size is a separate axis from density. Screen size is determined as the available pixels to an application after density scaling has been applied. <p>Based on the target device screen density, the Android framework will scale down assets by a factor of 0.75 (low dpi screens) or scale them up by a factor of 1.5 (high dpi screens). The screen density is expressed as dots-per-inch (dpi).</p> <p>Currently supported densities:</p> <ul> <li>Low density: 120 dpi</li> <li>Medium density: 160 dpi</li> <li>High density: 240 dpi</li> </ul> <p>Table of display types:</p> <table> <tr> <th></th><th>Low Density</th><th>Medium Density</th><th>High Density</th> </tr> <tr> <th>Small Screen</th> <td>QVGA</td> <td>n/a</td> <td>VGA</td> </tr> <tr> <th>Normal Screen</th> <td>WQVGA</td> <td>HVGA</td> <td>WVGA, FWVGA</td> </tr> <tr> <th>Large Screen</th> <td>n/a</td> <td>VGA, WVGA, FWVGA</td> <td>n/a</td> </tr> </table> </dd> <dt>attributes:</dt> <dd> <dl class="attr"><dt><a name="small"></a>{@code android:smallScreens}</dt> <dd>Indicates whether the application supports smaller screen form-factors. A small screen is defined as one with a smaller aspect ratio than the "normal" (traditional HVGA) screen. An application that does not support small screens <em>will not be available</em> for small screen devices, because there is little the platform can do to make such an application work on a smaller screen. Applications using API Level 4 or higher default this to "true", others are "false". </dd> <dt><a name="normal"></a>{@code android:normalScreens}</dt> <dd>Indicates whether an application supports the "normal" screen form-factors. Traditionally this is an HVGA medium density screen, but WQVGA low density and WVGA high density are also considered to be normal. This attribute is "true" by default, and applications currently should leave it that way. </dd> <dt><a name="large"></a>{@code android:largeScreens}</dt> <dd>Indicates whether the application supports larger screen form-factors. A large screen is defined as a screen that is significantly larger than a "normal" phone screen, and thus may require some special care on the application's part to make good use of it. An application that does not support large screens will be placed as a "postage stamp" on such a screen, so that it retains the dimensions it was originally designed for. Applications using API Level 4 or higher default to "true", others are "false". </dd> <dt><a name="any"></a>{@code android:anyDensity}</dt> <dd>Indicates whether the application can accommodate any screen density. Older applications (pre API Level 4) are assumed unable to accomodate all densities and this is "false" by default. Applications using API Level 4 or higher are assumed able to and this is "true" by default. You can explicitly supply your abilities here. </dd> </dl></dd> <!-- ##api level indication## --> <dt>introduced in:</dt> <dd>API Level 4</dd> <dt>see also:</dt> <dd> <ul> <li>{@link android.util.DisplayMetrics}</li> </ul> </dd> </dl>
docs/html/guide/topics/manifest/uses-configuration-element.jd +7 −2 Original line number Diff line number Diff line Loading @@ -168,9 +168,14 @@ The value must be one of the following strings: <dd>API Level 3</dd> <dt>see also:</dt> <dd><code><a href="{@docRoot}guide/topics/manifest/activity-element.html#config">configChanges</a></code> <dd> <ul> <li><code><a href="{@docRoot}guide/topics/manifest/activity-element.html#config">configChanges</a></code> attribute of the <code><a href="{@docRoot}guide/topics/manifest/activity-element.html"><activity></a></code> element</dd> element</dd></li> <li>{@link android.content.pm.ConfigurationInfo}</li> </ul> </dd> </dl>