diff options
Diffstat (limited to 'docs/html/guide/practices')
18 files changed, 97 insertions, 97 deletions
diff --git a/docs/html/guide/practices/index.jd b/docs/html/guide/practices/index.jd index b61272b91ad7..f34a6ba2eef4 100644 --- a/docs/html/guide/practices/index.jd +++ b/docs/html/guide/practices/index.jd @@ -1,7 +1,7 @@ page.title=Best Practices excludeFromSuggestions=true page.landing=true -page.landing.intro=Design and build apps the right way. Learn how to create apps that look great and perform well on as many devices as possible, from phones to tablets and more. +page.landing.intro=Design and build apps the right way. Learn how to create apps that look great and perform well on as many devices as possible, from phones to tablets and more. page.landing.image= @jd:body @@ -10,20 +10,20 @@ page.landing.image= <div class="col-12"> <h3>Blog Articles</h3> - + <a href="http://android-developers.blogspot.com/2010/10/improving-app-quality.html"> <h4>Improving App Quality</h4> <p>One way of improving your app’s visibility in the ecosystem is by deploying well-targeted mobile advertising campaigns and cross-app promotions. However, there’s another time-tested method of fueling the impression-install-ranking cycle: improve the product!</p> </a> - + <a href="http://android-developers.blogspot.com/2012/01/say-goodbye-to-menu-button.html"> <h4>Say Goodbye to the Menu Button</h4> <p>As Ice Cream Sandwich rolls out to more devices, it's important that you begin to migrate your designs to the action bar in order to promote a consistent Android user experience.</p> </a> - + <a href="http://android-developers.blogspot.com/2011/07/new-tools-for-managing-screen-sizes.html"> <h4>New Tools For Managing Screen Sizes</h4> <p>Android 3.2 includes new tools for supporting devices with a wide range of screen sizes. @@ -31,14 +31,14 @@ One important result is better support for a new size of screen; what is typical tablet. This release also offers several new APIs to simplify developers’ work in adjusting to different screen sizes.</p> </a> - + <a href="http://android-developers.blogspot.com/2011/03/identifying-app-installations.html"> <h4>Identifying App Installations</h4> <p>It is very common, and perfectly reasonable, for a developer to want to track individual installations of their apps. It sounds plausible just to call TelephonyManager.getDeviceId() and use that value to identify the installation. There are problems with this</p> </a> - + <a href="http://android-developers.blogspot.com/2011/11/making-android-games-that-play-nice.html"> <h4>Making Android Games that Play Nice</h4> @@ -46,7 +46,7 @@ href="http://android-developers.blogspot.com/2011/11/making-android-games-that-p often multi-core, multi-purpose system like Android is trickier. Even the best developers frequently make mistakes in the way they interact with the Android system and with other applications</p> </a> - + </div> diff --git a/docs/html/guide/practices/optimizing-for-3.0.jd b/docs/html/guide/practices/optimizing-for-3.0.jd index 8d07eb9847d8..db45e19ce0da 100644 --- a/docs/html/guide/practices/optimizing-for-3.0.jd +++ b/docs/html/guide/practices/optimizing-for-3.0.jd @@ -4,7 +4,7 @@ excludeFromSuggestions=true <div id="deprecatedSticker"> - <a href="#" + <a href="#" onclick="$('#naMessage').show();$('#deprecatedSticker').hide();return false"> <strong>This doc is deprecated</strong></a> </div> @@ -181,7 +181,7 @@ larger screens.</p> <li>Perform your usual tests to be sure everything works and looks as expected.</li> </ol> </li> - + <li><b>Apply the new "holographic" theme to your application</b> <ol> <li>Open your manifest file and update the <a @@ -191,7 +191,7 @@ href="{@docRoot}guide/topics/manifest/uses-sdk-element.html#target">{@code android:targetSdkVersion}</a> to {@code "11"}. For example: <pre> <manifest ... > - <uses-sdk android:minSdkVersion="4" + <uses-sdk android:minSdkVersion="4" android:targetSdkVersion="11" /> <application ... > ... @@ -446,7 +446,7 @@ Multi-choice List</a>: An example of how to provide multiple-choice selection fo GridView.</li> <li><a href="{@docRoot}resources/samples/ApiDemos/src/com/example/android/apis/app/LoaderThrottle.html"> -Content Loaders</a>: An example using new Loader APIs to asynchronously load data.</li> +Content Loaders</a>: An example using new Loader APIs to asynchronously load data.</li> <li><a href="{@docRoot}resources/samples/ApiDemos/src/com/example/android/apis/animation/index.html"> Property Animation</a>: Several samples using the new animation APIs to animate object @@ -624,7 +624,7 @@ landscape orientation and that is how most users will use them. So, you should e application can function in landscape. Even if you want to avoid rotating the screen while your application is running, you should not assume that portrait is the device's default orientation. You should either ensure that your layout is usable in both portrait and landscape orientations or -provide an <a href="{@docRoot}guide/topics/resources/providing-resources.html#AlternativeResources" +provide an <a href="{@docRoot}guide/topics/resources/providing-resources.html#AlternativeResources" >alternative layout resource</a> for landscape orientation.</p> <p>If you believe your application or game provides its best experience when the screen is tall, diff --git a/docs/html/guide/practices/screen-compat-mode.jd b/docs/html/guide/practices/screen-compat-mode.jd index 34580ba824cf..18a089e1d119 100644 --- a/docs/html/guide/practices/screen-compat-mode.jd +++ b/docs/html/guide/practices/screen-compat-mode.jd @@ -75,7 +75,7 @@ android:targetSdkVersion}</a> to {@code "4"} or higher, or set <a href="{@docRoot}guide/topics/manifest/supports-screens-element.html#resizeable">{@code android:resizeable}</a> to {@code "true"}.</p> </dd> - + <dt>Version 2 (Android 3.2 and greater)</dt> <dd>The system draws the application's layout the same as it would on a normal size handset (approximately emulating a 320dp x 480dp screen), then scales it @@ -151,9 +151,9 @@ android:xlargeScreens}</a> attribute to {@code "true"}:</p> system will always resize your layout to fit the screen. This works regardless of what values you've set in the <a href="{@docRoot}guide/topics/manifest/uses-sdk-element.html">{@code <uses-sdk>}</a> -attributes.</p> +attributes.</p> </li> - + <li><strong>Easy but has other effects:</strong> <p>In your manifest's <a href="{@docRoot}guide/topics/manifest/uses-sdk-element.html">{@code <uses-sdk>}</a> diff --git a/docs/html/guide/practices/screens_support.jd b/docs/html/guide/practices/screens_support.jd index 2223dbf3096d..ea9f988daac7 100644 --- a/docs/html/guide/practices/screens_support.jd +++ b/docs/html/guide/practices/screens_support.jd @@ -139,7 +139,7 @@ or position in a density-independent way. <p>The density-independent pixel is equivalent to one physical pixel on a 160 dpi screen, which is the baseline density assumed by the system for a "medium" density screen. At runtime, the system transparently handles any scaling of the dp units, as necessary, based on the actual density of the -screen in use. The conversion of dp units to screen pixels is simple: +screen in use. The conversion of dp units to screen pixels is simple: <nobr><code>px = dp * (dpi / 160)</code></nobr>. For example, on a 240 dpi screen, 1 dp equals 1.5 physical pixels. You should always use dp units when defining your application's UI, to ensure proper display of your UI on screens with different @@ -214,7 +214,7 @@ changes in screen density.</p> </ul> <p class="note"><strong>Note:</strong> These minimum screen sizes were not as well defined prior to -Android 3.0, so you may encounter some devices that are mis-classified between normal and large. +Android 3.0, so you may encounter some devices that are mis-classified between normal and large. These are also based on the physical resolution of the screen, so may vary across devices—for example a 1024x720 tablet with a system bar actually has a bit less space available to the application due to it being used by the system bar.</p> @@ -904,7 +904,7 @@ href="{@docRoot}guide/topics/manifest/supports-screens-element.html"><support manifest element:</p> <dl> - + <dt><a href="{@docRoot}guide/topics/manifest/supports-screens-element.html#requiresSmallest"> {@code android:requiresSmallestWidthDp}</a></dt> diff --git a/docs/html/guide/practices/tablets-and-handsets.jd b/docs/html/guide/practices/tablets-and-handsets.jd index 85327b6d7036..a1bafd3d7dec 100644 --- a/docs/html/guide/practices/tablets-and-handsets.jd +++ b/docs/html/guide/practices/tablets-and-handsets.jd @@ -89,7 +89,7 @@ href="{@docRoot}guide/components/fragments.html">Fragments</a> developer guide.< </li> - <li><strong>Use the action bar</strong>, but follow best practices and ensure your design + <li><strong>Use the action bar</strong>, but follow best practices and ensure your design is flexible enough for the system to adjust the action bar layout based on the screen size. <p>The {@link android.app.ActionBar} is a UI component for activities that replaces the traditional diff --git a/docs/html/guide/practices/ui_guidelines/activity_task_design.jd b/docs/html/guide/practices/ui_guidelines/activity_task_design.jd index f6669e4f36b4..b66fdd42a1f4 100644 --- a/docs/html/guide/practices/ui_guidelines/activity_task_design.jd +++ b/docs/html/guide/practices/ui_guidelines/activity_task_design.jd @@ -8,7 +8,7 @@ parent.link=index.html <div id="deprecatedSticker"> - <a href="#" + <a href="#" onclick="$('#naMessage').show();$('#deprecatedSticker').hide();return false"> <strong>This doc is deprecated</strong></a> </div> @@ -105,7 +105,7 @@ need to</a></li> <p> It illustrates activities and tasks with examples, and describes some of their underlying principles and mechanisms, such as navigation, - multitasking, activity re-use, intents, and the activity stack. + multitasking, activity re-use, intents, and the activity stack. The document also highlights design decisions that are available to you and what control they give you over the UI of your application. </p> @@ -146,7 +146,7 @@ document), <p> An Android <em>application</em> typically consists of one or more - related, loosely bound activities <!--(and possibly + related, loosely bound activities <!--(and possibly <a href=#services_broadcast_receivers title="other components">other components</a>)--> for the user to interact with, typically bundled up in a single file (with an .apk suffix). Android ships with a rich set @@ -186,10 +186,10 @@ document), seamless, activity after activity, <a href="#tasks">task</a> after task. </p> - + <p> An activity handles a particular type of content (data) and accepts a - set of related user actions. Each activity has a + set of related user actions. Each activity has a <a href="{@docRoot}guide/components/activities.html#Lifecycle">lifecycle</a> that is independent of the other activities in its application or task — each activity is @@ -283,7 +283,7 @@ independent of the other to the activity stack, so that pressing <em>Back</em> displays the previous activity on the stack. However, the user cannot use the <em>Back</em> button to go back further than the last visit to Home. The adding of an activity to - the current stack happens whether or not that activity begins a new + the current stack happens whether or not that activity begins a new <a href=#tasks title=task>task</a> (as long as that task was started without going Home), so going back can let the user go back to activities in previous tasks. The user can get to tasks earlier than @@ -297,7 +297,7 @@ independent of the other designing the navigation, if you have screen A and you want the user to be able go to a subsequent screen B and then use the <em>Back</em> button to go back to screen A, then the screen A needs to be implemented as an - activity. The one exception to this rule is if your application + activity. The one exception to this rule is if your application <a href="#taking_over_back_key">takes control of the <em>Back</em> button</a> and manages the navigation itself. @@ -340,7 +340,7 @@ itself. Send a text message with an attachment </li> <li> - View a YouTube video and share it by email with someone else + View a YouTube video and share it by email with someone else </li> </ul> @@ -666,7 +666,7 @@ itself. mailto:info@example.com link, they are actually initiating an Intent object, or just an <em>intent</em>, which then gets resolved to a particular component (we consider only activity components here). - So, the result of a user touching a mailto: link is an Intent object + So, the result of a user touching a mailto: link is an Intent object that the system tries to match to an activity. If that Intent object was written explicitly naming an activity (an <em>explicit intent</em>), then the system immediately launches that activity in response to the user @@ -925,7 +925,7 @@ href="{@docRoot}guide/components/intents-filters.html">Intents and Intent Filter For instance, you could disable the user control that initiates the Intent object, or display a message to the user that lets them go to a location, such as Google Play, to download its application. - In this way, your code can start the activity (using either startActivity() + In this way, your code can start the activity (using either startActivity() or startActivityForResult()) only if the intent has tested to resolve to an activity that is actually present. </p> @@ -947,7 +947,7 @@ href="{@docRoot}guide/components/intents-filters.html">Intents and Intent Filter launcher</em> (typically implemented as a sliding drawer on the Home screen), or from a shortcut icon on the Home screen, or from the task switcher. (The mechanism for this is for the - activity to have an + activity to have an <a href={@docRoot}guide/components/intents-filters.html>intent filter</a> with action MAIN and category LAUNCHER.) @@ -1103,7 +1103,7 @@ MAIN and activity to be run. </p> - + <h3 id="notifications_get_back_tip">Notifications and App Widgets should provide consistent back behavior</h3> <p> Notifications and app widgets are two common ways that a user can launch diff --git a/docs/html/guide/practices/ui_guidelines/icon_design.jd b/docs/html/guide/practices/ui_guidelines/icon_design.jd index 07266607ed4c..6b546c9fd21d 100644 --- a/docs/html/guide/practices/ui_guidelines/icon_design.jd +++ b/docs/html/guide/practices/ui_guidelines/icon_design.jd @@ -58,7 +58,7 @@ Screens</a></li> <div class="note design"> -<p><strong>New Guides for App Designers!</strong></p> +<p><strong>New Guides for App Designers!</strong></p> <p>Check out the new documents for designers at <strong><a href="{@docRoot}design/index.html">Android Design</a></strong>, including more guidelines for <a href="{@docRoot}design/style/iconography.html">Iconography</a>.</p> @@ -72,13 +72,13 @@ professional to users.</p> <p>This document provides information to help you create icons for various parts of your application’s user interface that match the general styles used by the -Android 2.x framework. Following these guidelines will help you to create a +Android 2.x framework. Following these guidelines will help you to create a polished and unified experience for the user.</p> <p>The following documents discuss detailed guidelines for the common types of icons used throughout Android applications:</p> -<dl> +<dl> <dt><strong><a href="icon_design_launcher.html">Launcher Icons</a></strong></dt> <dd>A Launcher icon is a graphic that represents your application on the device's Home screen and in the Launcher window.</dd> @@ -103,7 +103,7 @@ icons used throughout Android applications:</p> graphically represent list items. An example is the Settings application.</dd> </dl> -<p>To get started creating your icons more quickly, you can download +<p>To get started creating your icons more quickly, you can download the Android Icon Templates Pack.</p> @@ -142,7 +142,7 @@ section in the box at the top-right corner of this page.</p> <p>Android is designed to run on a variety of devices that offer a range of screen sizes and resolutions. When you design the icons for your application, it's important keep in mind that your application may be installed on any of -those devices. As described in the <a +those devices. As described in the <a href="{@docRoot}guide/practices/screens_support.html">Supporting Multiple Screens</a> document, the Android platform makes it straightforward for you to provide icons in such a way that they will be displayed properly on any device, @@ -158,7 +158,7 @@ your application, see <a href="{@docRoot}guide/practices/screens_support.html#qualifiers">Resource directory qualifiers for screen size and density</a>. </p> -<p>For tips on how to create and manage icon sets for multiple densities, see +<p>For tips on how to create and manage icon sets for multiple densities, see <a href="#design-tips">Tips for Designers</a>.</p> @@ -290,7 +290,7 @@ initially draw launcher icons on an 864x864 artboard, it will be easier and cleaner to tweak the icons when you scale the artboard down to the target sizes for final asset creation.</p> - + <h3>When scaling, redraw bitmap layers as needed</h3> diff --git a/docs/html/guide/practices/ui_guidelines/icon_design_action_bar.jd b/docs/html/guide/practices/ui_guidelines/icon_design_action_bar.jd index 831de4569edd..37657f4d1ecc 100644 --- a/docs/html/guide/practices/ui_guidelines/icon_design_action_bar.jd +++ b/docs/html/guide/practices/ui_guidelines/icon_design_action_bar.jd @@ -31,7 +31,7 @@ Screens</a></li> </div> <div class="note design"> -<p><strong>New Guides for App Designers!</strong></p> +<p><strong>New Guides for App Designers!</strong></p> <p>Check out the new documents for designers at <strong><a href="{@docRoot}design/index.html">Android Design</a></strong>, including more guidelines for <a href="{@docRoot}design/style/iconography.html">Iconography</a>.</p> diff --git a/docs/html/guide/practices/ui_guidelines/icon_design_dialog.jd b/docs/html/guide/practices/ui_guidelines/icon_design_dialog.jd index c958ed9a655e..a7ee73f41a78 100644 --- a/docs/html/guide/practices/ui_guidelines/icon_design_dialog.jd +++ b/docs/html/guide/practices/ui_guidelines/icon_design_dialog.jd @@ -29,7 +29,7 @@ Screens</a></li> </div> <div class="note design"> -<p><strong>New Guides for App Designers!</strong></p> +<p><strong>New Guides for App Designers!</strong></p> <p>Check out the new documents for designers at <strong><a href="{@docRoot}design/index.html">Android Design</a></strong>, including more guidelines for <a href="{@docRoot}design/style/iconography.html">Iconography</a>.</p> diff --git a/docs/html/guide/practices/ui_guidelines/icon_design_launcher.jd b/docs/html/guide/practices/ui_guidelines/icon_design_launcher.jd index f47e186790a9..3bb1a627c85c 100644 --- a/docs/html/guide/practices/ui_guidelines/icon_design_launcher.jd +++ b/docs/html/guide/practices/ui_guidelines/icon_design_launcher.jd @@ -28,7 +28,7 @@ Screens</a></li> <div class="note design"> -<p><strong>New Guides for App Designers!</strong></p> +<p><strong>New Guides for App Designers!</strong></p> <p>Check out the new documents for designers at <strong><a href="{@docRoot}design/index.html">Android Design</a></strong>, including more guidelines for <a href="{@docRoot}design/style/iconography.html">Iconography</a>.</p> diff --git a/docs/html/guide/practices/ui_guidelines/icon_design_launcher_archive.jd b/docs/html/guide/practices/ui_guidelines/icon_design_launcher_archive.jd index 2df3a2250ef5..483e076ac52f 100644 --- a/docs/html/guide/practices/ui_guidelines/icon_design_launcher_archive.jd +++ b/docs/html/guide/practices/ui_guidelines/icon_design_launcher_archive.jd @@ -95,7 +95,7 @@ but rather they are meant to emphasize the common approaches that your icons can share with others on the device. Figure 1, at right, provides examples. </p> <div class="figure"> - <img src="{@docRoot}images/icon_design/IconGraphic_Icons_i.png" + <img src="{@docRoot}images/icon_design/IconGraphic_Icons_i.png" width="340"> <p class="img-caption"> <strong>Figure 1.</strong> Example launcher icons for Android 2.0 and diff --git a/docs/html/guide/practices/ui_guidelines/icon_design_list.jd b/docs/html/guide/practices/ui_guidelines/icon_design_list.jd index 29e1a9380de7..fa350bc2b6a7 100644 --- a/docs/html/guide/practices/ui_guidelines/icon_design_list.jd +++ b/docs/html/guide/practices/ui_guidelines/icon_design_list.jd @@ -30,7 +30,7 @@ Screens</a></li> <div class="note design"> -<p><strong>New Guides for App Designers!</strong></p> +<p><strong>New Guides for App Designers!</strong></p> <p>Check out the new documents for designers at <strong><a href="{@docRoot}design/index.html">Android Design</a></strong>, including more guidelines for <a href="{@docRoot}design/style/iconography.html">Iconography</a>.</p> diff --git a/docs/html/guide/practices/ui_guidelines/icon_design_menu.jd b/docs/html/guide/practices/ui_guidelines/icon_design_menu.jd index a5b35977fc0e..25b23d0f628c 100644 --- a/docs/html/guide/practices/ui_guidelines/icon_design_menu.jd +++ b/docs/html/guide/practices/ui_guidelines/icon_design_menu.jd @@ -34,7 +34,7 @@ Screens</a></li> <div class="note design"> -<p><strong>New Guides for App Designers!</strong></p> +<p><strong>New Guides for App Designers!</strong></p> <p>Check out the new documents for designers at <strong><a href="{@docRoot}design/index.html">Android Design</a></strong>, including more guidelines for <a href="{@docRoot}design/style/iconography.html">Iconography</a>.</p> @@ -267,7 +267,7 @@ menu icon <a href="#palette1">color palette</a>. </li> appropriate. For example, in Figure 3 the logical place for rounded corners is the roof and not the rest of the building.</span></li> -<li>All dimensions specified on this page are based on a 48x48 pixel artboard +<li>All dimensions specified on this page are based on a 48x48 pixel artboard size with a 6 pixel safeframe.</li> <li>The menu icon effect (the outer glow) described in <a @@ -277,7 +277,7 @@ safeframe.</li> <li><strong>Final art must be exported as a transparent PNG file.</strong></li> -<li>Templates for creating menu icons in Adobe Photoshop are available in the +<li>Templates for creating menu icons in Adobe Photoshop are available in the Icon Templates Pack.</li> </ul> diff --git a/docs/html/guide/practices/ui_guidelines/icon_design_status_bar.jd b/docs/html/guide/practices/ui_guidelines/icon_design_status_bar.jd index 4993adb0328b..27df450e1673 100644 --- a/docs/html/guide/practices/ui_guidelines/icon_design_status_bar.jd +++ b/docs/html/guide/practices/ui_guidelines/icon_design_status_bar.jd @@ -42,7 +42,7 @@ Screens</a></li> <div class="note design"> -<p><strong>New Guides for App Designers!</strong></p> +<p><strong>New Guides for App Designers!</strong></p> <p>Check out the new documents for designers at <strong><a href="{@docRoot}design/index.html">Android Design</a></strong>, including more guidelines for <a href="{@docRoot}design/style/iconography.html">Iconography</a>.</p> diff --git a/docs/html/guide/practices/ui_guidelines/icon_design_tab.jd b/docs/html/guide/practices/ui_guidelines/icon_design_tab.jd index cbe6706fb067..308e6d092c1e 100644 --- a/docs/html/guide/practices/ui_guidelines/icon_design_tab.jd +++ b/docs/html/guide/practices/ui_guidelines/icon_design_tab.jd @@ -34,7 +34,7 @@ Screens</a></li> <div class="note design"> -<p><strong>New Guides for App Designers!</strong></p> +<p><strong>New Guides for App Designers!</strong></p> <p>Check out the new documents for designers at <strong><a href="{@docRoot}design/index.html">Android Design</a></strong>, including more guidelines for <a href="{@docRoot}design/style/iconography.html">Iconography</a>.</p> @@ -291,10 +291,10 @@ your application. </p> the Android platform.</p> <p class="warning"><strong>Warning:</strong> -Because these resources can change between platform versions, you +Because these resources can change between platform versions, you should not reference the system's copy of the resources. If you want to use any icons or other internal drawable resources, you should store a -local copy of those icons or drawables in your application resources, +local copy of those icons or drawables in your application resources, then reference the local copy from your application code. In that way, you can maintain control over the appearance of your icons, even if the system's copy changes. Note that the grid below is not intended to be complete.</p> diff --git a/docs/html/guide/practices/ui_guidelines/index.jd b/docs/html/guide/practices/ui_guidelines/index.jd index 91a0725b82e3..713109cf2bcf 100644 --- a/docs/html/guide/practices/ui_guidelines/index.jd +++ b/docs/html/guide/practices/ui_guidelines/index.jd @@ -7,7 +7,7 @@ excludeFromSuggestions=true <div class="note design" style="background:none;overflow:auto;padding:10px 5px"> <a href="{@docRoot}design/index.html"><img src="{@docRoot}images/home/android-design.png" alt="" style="float:left;margin:0 1em 0 0;"/></a> -<p><strong>New Guides for App Designers!</strong></p> +<p><strong>New Guides for App Designers!</strong></p> <p>The Android UX team has put together a set of guidelines for the interaction and visual design of Android applications. The new collection provides an overview of Android styles, design patterns, building blocks for exceptional Android designs, and more.</p> diff --git a/docs/html/guide/practices/ui_guidelines/menu_design.jd b/docs/html/guide/practices/ui_guidelines/menu_design.jd index bf87bdd124e7..949752588a12 100644 --- a/docs/html/guide/practices/ui_guidelines/menu_design.jd +++ b/docs/html/guide/practices/ui_guidelines/menu_design.jd @@ -8,7 +8,7 @@ parent.link=index.html <div id="deprecatedSticker"> - <a href="#" + <a href="#" onclick="$('#naMessage').show();$('#deprecatedSticker').hide();return false"> <strong>This doc is deprecated</strong></a> </div> @@ -16,7 +16,7 @@ parent.link=index.html <div id="naMessage" style="display:block"> <div><p><strong>This document has been deprecated.</strong></p> - <p>For design guidelines about adding user actions and other options, read the design guidelines + <p>For design guidelines about adding user actions and other options, read the design guidelines for <a href="{@docRoot}design/patterns/actionbar.html">Action Bar</a> or the developer guide about <a href="{@docRoot}guide/topics/ui/menus.html">Menus</a>.</p> @@ -25,7 +25,7 @@ for <a href="{@docRoot}design/patterns/actionbar.html">Action Bar</a> or the dev onclick="$('#naMessage').hide();$('#deprecatedSticker').show()" /> </div> </div> - + @@ -37,7 +37,7 @@ onclick="$('#naMessage').hide();$('#deprecatedSticker').show()" /> <div id="qv-wrapper"> <div id="qv"> - + <h2>Quickview</h2> <ul> @@ -85,15 +85,15 @@ onclick="$('#naMessage').hide();$('#deprecatedSticker').show()" /> </ol> </div> -</div> +</div> <p> A menu holds a set of commands (user actions) that are normally hidden, and are accessible by a button, key, or gesture. Menu commands provide a means - for performing operations and for navigating to other parts of your + for performing operations and for navigating to other parts of your application or other applications. Menus are useful for freeing screen space, as an alternative to placing functionality and navigation, in buttons or other - user controls in the content area of your application. + user controls in the content area of your application. </p> <p> @@ -102,7 +102,7 @@ onclick="$('#naMessage').hide();$('#deprecatedSticker').show()" /> the functionality and navigation for your application. Briefly: <ul> <li>The <em>Options menu</em> contains primary functionality that applies - globally to the current activity or starts a related activity. + globally to the current activity or starts a related activity. It is typically invoked by a user pressing a hard button, often labeled <em>Menu</em>.</li> <li>The <em>Context menu</em> contains secondary functionality for the currently selected item. It is typically invoked by a user's touch & hold @@ -113,11 +113,11 @@ onclick="$('#naMessage').hide();$('#deprecatedSticker').show()" /> <p> All but the simplest applications have menus. The system automatically - lays the menus out and provides standard ways for users to access them. + lays the menus out and provides standard ways for users to access them. In this sense, they are familiar and dependable ways for users to access functionality across all applications. All menus are panels that "float" on top of the activity screen and are smaller than full screen, so that the - application is still visible around its edges. This is a visual reminder + application is still visible around its edges. This is a visual reminder that a menu is an intermediary operation that disappears once it's used. </p> @@ -127,8 +127,8 @@ onclick="$('#naMessage').hide();$('#deprecatedSticker').show()" /> <h2 id="tour_of_the_menus">Tour of the Menus</h2> -<p class="note"><strong>Note:</strong> Your menus and screens might not look -like those shown in this document; they may vary from one version of Android +<p class="note"><strong>Note:</strong> Your menus and screens might not look +like those shown in this document; they may vary from one version of Android or device to another. </p> @@ -137,13 +137,13 @@ or device to another. <p> The Options menu contains commands that apply globally across the current activity, or can start another activity. They do not apply to a selected - item in the content (a <a href="#context_menu">Context menu</a> does that). + item in the content (a <a href="#context_menu">Context menu</a> does that). </p> <p> - On most devices, a user presses the <em>Menu</em> button to access the Options menu, - as shown in the screenshot below. To close the menu, the user presses - <em>Menu</em> again, or presses the <em>Back</em> button. + On most devices, a user presses the <em>Menu</em> button to access the Options menu, + as shown in the screenshot below. To close the menu, the user presses + <em>Menu</em> again, or presses the <em>Back</em> button. In fact, to cancel out of any menu, press the <em>Back</em> button. (Pressing the <em>Menu</em> button or touching outside the menu also works.) Note that how to invoke this menu may be different on different devices. @@ -153,15 +153,15 @@ or device to another. Each <a href="{@docRoot}guide/practices/ui_guidelines/activity_task_design.html#activities">activity</a> activity has its own set of operations and therefore its own Options menu. - An application with multiple activities would have a different Options menu - for each activity. + An application with multiple activities would have a different Options menu + for each activity. </p> <p> For example, in the message list view of an email program, the Options menu - might let you search the messages, compose a new message, refresh the list, - or change the email settings. The compose view of an email program would - have a different Options menu, such as adding a CC field, attaching a file, + might let you search the messages, compose a new message, refresh the list, + or change the email settings. The compose view of an email program would + have a different Options menu, such as adding a CC field, attaching a file, or discarding the message. </p> @@ -179,7 +179,7 @@ or device to another. <li> <b>Options expanded menu</b> - If the activity has more menu items than will fit on the icon menu, then the last icon is labeled "More" — selecting it - displays a list that can contain any number of menu items and will scroll + displays a list that can contain any number of menu items and will scroll as necessary. </li> </ul> @@ -202,18 +202,18 @@ or device to another. <p> A user can touch & hold on content on the screen to - access a Context menu (if one exists), as shown in the screenshot below. + access a Context menu (if one exists), as shown in the screenshot below. A Context menu is a list of menu items (commands) that can operate on the selected content. The command can either be part of the current - activity, or the system can pass the selected content along to - an operation in another activity (by way of an + activity, or the system can pass the selected content along to + an operation in another activity (by way of an <a href="{@docRoot}guide/practices/ui_guidelines/activity_task_design.html#intents">intent</a>). </p> <p> For example, in an email message list, a user can touch & hold on an email message to open a Context menu containing commands to read, - archive, or delete the message. + archive, or delete the message. </p> <p id="location"> @@ -231,7 +231,7 @@ or device to another. In the above example, if the user performs touch & hold on the contact "Obi Wan Kenobi", a Context menu opens. The commands provided in this Context menu are the complete set of actions that can be performed - on this contact. + on this contact. </p> <p> @@ -246,7 +246,7 @@ or device to another. <p> Also note, as shown in the following screenshot, the Context menu and the next screen both hold the same complete set of commands that can be performed - on this contact. The Context menu displays the commands in a list, + on this contact. The Context menu displays the commands in a list, while the "View contact" activity splits them into various items in the Options menu, icon buttons and list items. </p> @@ -268,10 +268,10 @@ or device to another. <h4>Text Commands in Context Menu</h4> <p> - Text links and text fields in the content both have system-provided operations + Text links and text fields in the content both have system-provided operations that are common across all applications: operations such as "Select all", "Select text", - "Copy all", and "Add to dictionary". If the text field is editable, it also - has other operations, such as "Cut all" and "Input Method", and if text + "Copy all", and "Add to dictionary". If the text field is editable, it also + has other operations, such as "Cut all" and "Input Method", and if text is also on the clipboard, it has "Paste". The system automatically inserts the appropriate menu items into the Context menu of text links and text fields, as shown in the following screenshot. @@ -342,7 +342,7 @@ or device to another. An example of a selection-specific Context menu is when a user performs a touch & hold on a person's name in a list view of a contacts application. The Context menu would typically contain commands "View contact", "Call contact", - and "Edit contact". + and "Edit contact". </p> <h3 id="most_frequently_used">Place the most frequently used operations first</h3> @@ -365,7 +365,7 @@ or device to another. <h3 id="dont_put_commands">Don't put commands <em>only</em> in a Context menu</h3> <p> - If a user can fully access your application without using Context menus, + If a user can fully access your application without using Context menus, then it's designed properly! In general, if part of your application is inaccessible without using Context menus, then you need to duplicate those commands elsewhere. </p> @@ -373,8 +373,8 @@ or device to another. <p> Before opening a Context menu, it has no visual representation that identifies its presence (whereas the Options menu has the <em>Menu</em> button), and so is not - particularly discoverable. - Therefore, in general, a Context menu should <em>duplicate</em> commands + particularly discoverable. + Therefore, in general, a Context menu should <em>duplicate</em> commands found in the corresponding activity screen. For example, while it's useful to let the user call a phone number from a Context menu invoked by touch & hold on a name in a list of contacts, that operation should <em>also</em> @@ -388,7 +388,7 @@ or device to another. As described under <a href="#context_menu_shortcut">shortcut</a>, touching on an item in the content should activate the same command as touching the first item in the Context menu. Both cases should be the most intuitive - operation for that item. + operation for that item. </p> <h3 id="selecting_content_item">Selecting an item in the content should perform the most intuitive operation</h3> @@ -427,13 +427,13 @@ or device to another. <h3 id="context_menu_should_identify">A Context menu should identify the selected item</h3> <p> - When a user does touch & hold on an item, the Context menu should - contain the name of the selected item. Therefore, + When a user does touch & hold on an item, the Context menu should + contain the name of the selected item. Therefore, when creating a Context menu, be sure to include a title and the name of the - selected item so that it's clear to the user what the context is. + selected item so that it's clear to the user what the context is. For example, if a user selects a contact "Joan of Arc", put that name in the title of the Context menu (using - {@link android.view.ContextMenu#setHeaderTitle(java.lang.CharSequence) setHeaderTitle}). + {@link android.view.ContextMenu#setHeaderTitle(java.lang.CharSequence) setHeaderTitle}). Likewise, a command to edit the contact should be called "Edit contact", not just "Edit". </p> @@ -442,7 +442,7 @@ or device to another. <h3 id="most_important_commands">Put only the most important commands fixed on the screen</h3> <p> - By putting commands in menus, you free up the screen to hold more content. + By putting commands in menus, you free up the screen to hold more content. On the other hand, fixing commands in the content area of an activity makes them more prominent and easy to use. </p> @@ -456,7 +456,7 @@ or device to another. To give a command the highest prominence, ensuring the command is obvious and won't be overlooked.<br> Example: A "Buy" button in a store application. </li> - <li> + <li> When quick access to the command is important and going to the menu would be tedious or slow.<br> Example: Next/Previous buttons or Zoom In/Out buttons in an image viewing application. @@ -494,7 +494,7 @@ or device to another. When a dialog is displayed, pressing the <em>Menu</em> button should do nothing. This also holds true for activities that look like dialogs. A dialog box is recognizable by being - smaller than full-screen, having zero to three buttons, is non-scrollable, and + smaller than full-screen, having zero to three buttons, is non-scrollable, and possibly a list of selectable items that can include checkboxes or radio buttons. <!--For examples of dialogs, see Text Guidelines.--> </p> @@ -520,12 +520,12 @@ true <p> Sometimes a menu item's action cannot be performed — for example, - the "Forward" button in a browser cannot work until after the "Back" + the "Forward" button in a browser cannot work until after the "Back" button has been pressed. We recommend: </p> <ul> - <li> + <li> <b>In Options menu</b> - disable the menu item, which dims the text and icon, turning it gray. This applies to menu items in both the icon menu and the "More" menu. It would be disorienting for the icon menu to change from 6 diff --git a/docs/html/guide/practices/ui_guidelines/widget_design.jd b/docs/html/guide/practices/ui_guidelines/widget_design.jd index cf2cd64d483a..95c594dba972 100644 --- a/docs/html/guide/practices/ui_guidelines/widget_design.jd +++ b/docs/html/guide/practices/ui_guidelines/widget_design.jd @@ -46,7 +46,7 @@ parent.link=index.html <div class="note design"> -<p><strong>New Guides for App Designers!</strong></p> +<p><strong>New Guides for App Designers!</strong></p> <p>Check out the new documents for designers at <strong><a href="{@docRoot}design/index.html">Android Design</a></strong>.</p> </div> |
