Home | History | Annotate | Download | only in patterns
      1 page.title=Settings
      2 @jd:body
      3 
      4 <p>Settings is a place in your app where users indicate their preferences for how your app should
      5 behave. This benefits users because:</p>
      6 
      7 <ul>
      8 <li>You don't need to interrupt them with the same questions over and over when certain situations
      9 arise. The settings predetermine what will always happen in those situations (see design
     10 principle: <a href="{@docRoot}design/get-started/principles.html#decide-for-me">Decide for me but
     11 let me have the final say</a>).</li>
     12 <li>You help them feel at home and in control (see design principle:
     13 <a href="{@docRoot}design/get-started/principles.html#make-it-mine">Let me make it mine</a>).</li>
     14 </ul>
     15 
     16 <h2 id="flow-structure">Flow and Structure</h2>
     17 
     18 <h4 id="settings-access">Provide access to Settings in the action overflow</h4>
     19 
     20 <p>Settings is given low prominence in the UI because it's not frequently needed. Even if there's
     21 room in the <a href="{@docRoot}design/patterns/actionbar.html">action bar</a>, never make Settings
     22 an action button. Always keep it in the action overflow and label it "Settings". Place it below
     23 all other items except "Help".</p>
     24 
     25 <img src="{@docRoot}design/media/settings_overflow.png">
     26 
     27 <div class="vspace size-2">&nbsp;</div>
     28 
     29 <h4 id="what-to-make-a-setting">Avoid the temptation to make everything a setting</h4>
     30 
     31 <p>Because Settings is a few navigational steps away, no matter how many items you have, they'll
     32 never clutter up the core part of your UI. This may seem like good news, but it also poses a
     33 challenge.</p>
     34 
     35 <p>Settings can be a tempting place to keep a lot of stuff&mdash;like a hall closet where things
     36 get stashed when you tidy up before company comes over. It's not a place where you spend lots of
     37 time, so it's easy to rationalize and ignore its cluttered condition. But when users visit
     38 Settings&mdash;however infrequently&mdash;they'll have the same expectations for the experience as
     39 they do everywhere else in your app. More settings means more choices to make, and too many are
     40 overwhelming.</p>
     41 
     42 <p>So don't punt on the difficult product decisions and debates that can bring on the urge to
     43 "just make it a setting". For each control you're considering adding to Settings, make sure it
     44 meets the bar:</p>
     45 
     46 <img src="{@docRoot}design/media/settings_flowchart.png">
     47 
     48 <div class="vspace size-3">&nbsp;</div>
     49 
     50 <div class="layout-content-row">
     51   <div class="layout-content-col span-5 with-callouts">
     52 
     53 <h4 id="group-settings">If you still have lots of settings, group related settings together</h4>
     54 
     55 <p>The number of items an average human can hold in short-term memory is 7&plusmn;2. If you
     56 present a list of 10 or more settings (even after applying the criteria above), users will have
     57 more difficulty scanning, comprehending, and processing them.</p>
     58 
     59 <p>You can remedy this by dividing some or all of the settings into groups, effectively turning
     60 one long list into multiple shorter lists. A group of related settings can be presented in one of
     61 two ways:</p>
     62 
     63 <ol>
     64 <li><h4>Under a section divider</h4></li>
     65 <li><h4>In a separate subscreen</h4></li>
     66 </ol>
     67 
     68 <p>You can use one or both these grouping techniques to organize your app's settings.</p>
     69 
     70 <p>For example, in the main screen of the Android Settings app, each item in the list navigates
     71 to a subscreen of related settings. In addition, the items themselves are grouped under section
     72 dividers.</p>
     73 
     74   </div>
     75   <div class="layout-content-col span-8">
     76 
     77     <img src="{@docRoot}design/media/settings_grouping.png">
     78 
     79   </div>
     80 </div>
     81 
     82 <p>Grouping settings is not an exact science, but here's some advice for how to approach it, based
     83 on the total number of settings in your app.</p>
     84 
     85 <div class="vspace size-1">&nbsp;</div>
     86 
     87 <div class="layout-content-row">
     88   <div class="layout-content-col span-2">
     89 
     90 <h4>7 or fewer</h4>
     91 
     92   </div>
     93   <div class="layout-content-col span-11">
     94 
     95 <p>Don't group them at all. It won't benefit users and will seem like overkill.</p>
     96 
     97   </div>
     98 </div>
     99 
    100 <div class="layout-content-row">
    101   <div class="layout-content-col span-2">
    102 
    103 <h4>8 to 10</h4>
    104 
    105   </div>
    106   <div class="layout-content-col span-11">
    107 
    108 <p>Try grouping related settings under 1 or 2 section dividers. If you have any "singletons"
    109 (settings that don't relate to any other settings and can't be grouped under your section
    110 dividers), treat them as follows:</p>
    111 
    112 <ul>
    113 <li>If they include some of your most important settings, list them at the top without a section
    114 divider.</li>
    115 <li>Otherwise, list them at the bottom with a section divider called "OTHER", in order of
    116 importance.</li>
    117 </ul>
    118 
    119   </div>
    120 </div>
    121 
    122 <div class="layout-content-row">
    123   <div class="layout-content-col span-2">
    124 
    125 <h4>11 to 15</h4>
    126 
    127   </div>
    128   <div class="layout-content-col span-11">
    129 
    130 <p>Same advice as above, but try 2 to 4 section dividers.</p>
    131 
    132 <p>Also, try the following to reduce the list:</p>
    133 
    134 <ul>
    135 <li>If 2 or more of the settings are mainly for power users, move them out of your main Settings
    136 screen and into an "Advanced" subscreen. Place an item in the action overflow called "Advanced" to
    137 navigate to it.</li>
    138 <li>Look for "doubles": two settings that relate to one another, but not to any other settings.
    139 Try to combine them into one setting, using the design patterns described later in this section.
    140 For example, you might be able to redesign two related checkbox settings into one multiple choice
    141 setting.</li>
    142 </ul>
    143 
    144   </div>
    145 </div>
    146 
    147 <div class="layout-content-row">
    148   <div class="layout-content-col span-2">
    149 
    150 <h4>16 or more</h4>
    151 
    152   </div>
    153   <div class="layout-content-col span-11">
    154 
    155 <p>If you have any instances of 4 or more related settings, group them under a subscreen. Then use
    156 the advice suggested above for the reduced list size.</p>
    157 
    158   </div>
    159 </div>
    160 
    161 
    162 <h2 id="patterns">Design Patterns</h2>
    163 
    164 <div class="layout-content-row">
    165   <div class="layout-content-col span-3">
    166 
    167 <h4>Checkbox</h4>
    168 <p>Use this pattern for a setting that is either selected or not selected.</p>
    169 
    170   </div>
    171   <div class="layout-content-col span-10">
    172 
    173 <img src="{@docRoot}design/media/settings_checkbox.png">
    174 
    175   </div>
    176 </div>
    177 
    178 <div class="layout-content-row">
    179   <div class="layout-content-col span-3">
    180 
    181 <h4>Multiple choice</h4>
    182 <p>Use this pattern for a setting that needs to present a discrete set of options, from which the
    183 user can choose only one.</p>
    184 
    185   </div>
    186   <div class="layout-content-col span-10">
    187 
    188 <img src="{@docRoot}design/media/settings_multiple_choice.png">
    189 
    190   </div>
    191 </div>
    192 
    193 <div class="layout-content-row">
    194   <div class="layout-content-col span-3">
    195 
    196 <h4>Slider</h4>
    197 <p>Use this pattern for a setting where the range of values are not discrete and fall along a
    198 continuum.</p>
    199 
    200   </div>
    201   <div class="layout-content-col span-10">
    202 
    203 <img src="{@docRoot}design/media/settings_slider.png">
    204 
    205   </div>
    206 </div>
    207 
    208 <div class="layout-content-row">
    209   <div class="layout-content-col span-3">
    210 
    211 <h4>Date/time</h4>
    212 <p>Use this pattern for a setting that needs to collect a date and/or time from the user.</p>
    213 
    214   </div>
    215   <div class="layout-content-col span-10">
    216 
    217 <img src="{@docRoot}design/media/settings_date_time.png">
    218 
    219   </div>
    220 </div>
    221 
    222 <div class="layout-content-row">
    223   <div class="layout-content-col span-3">
    224 
    225 <h4>Subscreen navigation</h4>
    226 <p>Use this pattern for navigating to a subscreen or sequence of subscreens that guide the user
    227 through a more complex setup process.</p>
    228 <ul>
    229 <li>If navigating to a single subscreen, use the same title in both the subscreen and the label
    230 navigating to it.</li>
    231 <li>If navigating to a sequence of subscreens (as in this example), use a title that describes the
    232 first step in the sequence.</li>
    233 </ul>
    234 
    235   </div>
    236   <div class="layout-content-col span-10">
    237 
    238 <img src="{@docRoot}design/media/settings_subscreen_navigation.png">
    239 
    240   </div>
    241 </div>
    242 
    243 <div class="layout-content-row">
    244   <div class="layout-content-col span-3">
    245 
    246 <h4>List subscreen</h4>
    247 <p>Use this pattern for a setting or category of settings that contains a list of equivalent items.
    248 </p>
    249 <p>The label provides the name of the item, and secondary text may be used for status. (In this
    250 example, status is reinforced with an icon to the right of the label.) Any actions associated with
    251 the list appear in the action bar rather than the list itself.</p>
    252 
    253   </div>
    254   <div class="layout-content-col span-10">
    255 
    256 <img src="{@docRoot}design/media/settings_list_subscreen.png">
    257 
    258   </div>
    259 </div>
    260 
    261 <div class="layout-content-row">
    262   <div class="layout-content-col span-3">
    263 
    264 <h4>Master on/off switch</h4>
    265 <p>Use this pattern for a category of settings that need a mechanism for turning on or off as a
    266 whole.</p>
    267 <p>An on/off switch is placed as the first item in the action bar of a subscreen. When the switch
    268 is turned off, the items in the list disappear, replaced by text that describes why the list is
    269 empty. If any actions require the switch to be on, they become disabled.</p>
    270 
    271   </div>
    272   <div class="layout-content-col span-10">
    273 
    274 <img src="{@docRoot}design/media/settings_master_on_off.png">
    275 
    276   </div>
    277 </div>
    278 
    279 <div class="layout-content-row">
    280   <div class="layout-content-col span-3">
    281 
    282 <div class="vspace size-2">&nbsp;</div>
    283 
    284 <p>You can also echo the master on/off switch in the menu item that leads to the subscreen.
    285 However, you should only do this in cases where users rarely need to access the subscreen once
    286 it's initially set up and more often just want to toggle the switch.</p>
    287 
    288   </div>
    289   <div class="layout-content-col span-10">
    290 
    291 <img src="{@docRoot}design/media/settings_master_on_off_2.png">
    292 
    293   </div>
    294 </div>
    295 
    296 <div class="layout-content-row">
    297   <div class="layout-content-col span-3">
    298 
    299 <h4>Individual on/off switch</h4>
    300 <p>Use this pattern for an individual setting that requires a more elaborate description than can
    301 be provided in checkbox form.</p>
    302 <p>The on/off switch only appears in the subscreen so that users aren't able to toggle it without
    303 also being exposed to the descriptive text. Secondary text appears below the setting label to
    304 reflect the current selection.</p>
    305 <p>In this example, Android Beam is on by default. Since users might not know what this setting
    306 does, we made the status more descriptive than just "On".</p>
    307 
    308   </div>
    309   <div class="layout-content-col span-10">
    310 
    311 <img src="{@docRoot}design/media/settings_individual_on_off.png">
    312 
    313   </div>
    314 </div>
    315 
    316 <div class="layout-content-row">
    317   <div class="layout-content-col span-3">
    318 
    319 <h4>Dependency</h4>
    320 <p>Use this pattern for a setting that changes availability based on the value of another setting.
    321 </p>
    322 <p>The disabled setting appears below its dependency, without any indentation. If the setting
    323 includes a status line, it says "Unavailable", and if the reason isn't obvious, a brief
    324 explanation is included in the status.</p>
    325 <p>If a given setting is a dependency to 3 or more settings, consider using a subscreen with a
    326 master on/off switch so that your main settings screen isn't cluttered by lots of disabled items.
    327 </p>
    328 
    329   </div>
    330   <div class="layout-content-col span-10">
    331 
    332 <img src="{@docRoot}design/media/settings_dependency.png">
    333 
    334   </div>
    335 </div>
    336 
    337 <h2 id="defaults">Defaults</h2>
    338 
    339 <p>Take great care in choosing default values for each of your settings. Because settings
    340 determine app behavior, your choices will contribute to users' first impressions of your app. Even
    341 though users can change settings, they'll expect the initial states to be sensible. The following
    342 questions (when applicable) may help inform your decisions:</p>
    343 
    344 <ul>
    345 <li>Which choice would most users be likely to choose on their own if there were no default?</li>
    346 <li>Which choice is the most neutral or middle-of-the-road?</li>
    347 <li>Which choice is the least risky, controversial, or over-the-top?</li>
    348 <li>Which choice uses the least amount of battery or mobile data?</li>
    349 <li>Which choice best supports the design principle
    350 <a href="{@docRoot}design/get-started/principles.html#never-lose-my-stuff">Never lose my stuff</a>?</li>
    351 <li>Which choice best supports the design principle
    352 <a href="{@docRoot}design/get-started/principles.html#interrupt-only-if-important">Only interrupt
    353 me if it's important</a>?
    354 </li>
    355 </ul>
    356 
    357 <h2 id="writing">Writing Guidelines</h2>
    358 
    359 <h4>Label clearly and concisely</h4>
    360 
    361 <p>Writing a good label for a setting can be challenging because space is very limited. You only
    362 get one line, and it's incredibly short on the smallest of devices. Follow these guidelines to
    363 make your labels brief, meaningful, and scannable:</p>
    364 
    365 <ul>
    366 <li>Write each label in sentence case (i.e. only the first word and proper nouns are capitalized).
    367 </li>
    368 <li>Don't start a label with an instructional verb like "Set", "Change", "Edit", "Modify",
    369 "Manage", "Use", "Select", or "Choose". Users already understand that they can do these things to
    370 settings.</li>
    371 <li>Likewise, don't end a label with a word like "setting" or "settings". It's already implied.
    372 </li>
    373 <li>If the setting is part of a grouping, don't repeat the word(s) used in the section divider or
    374 subscreen title.</li>
    375 <li>Avoid starting a label with a negative word like "Don't" or "Never". For example, "Don't
    376 allow" could be rephrased to "Block".</li>
    377 <li>Steer clear of technical jargon as much as possible, unless it's a term widely understood by
    378 your target users. Use common verbs and nouns to convey the setting's purpose rather than its
    379 underlying technology.</li>
    380 <li>Don't refer to the user. For example, for a setting allowing the user to turn notifications on
    381 or off, label it "Notifications" instead of "Notify me".</li>
    382 </ul>
    383 
    384 <p>Once you've decided on labels for your settings, be sure to preview them on an
    385 <a href="{@docRoot}design/style/metrics-grids.html">LDPI handset</a> in portrait to make sure
    386 they'll fit everywhere.</p>
    387 
    388 <h4>Secondary text below is for status, not description&hellip;</h4>
    389 
    390 <p>Before Ice Cream Sandwich, we often displayed secondary text below a label to further describe
    391 it or provide instructions. Starting in Ice Cream Sandwich, we're using secondary text for status.
    392 </p>
    393 
    394 <div class="layout-content-row">
    395   <div class="layout-content-col span-4">
    396 
    397     <div class="do-dont-label bad emulate-content-left-padding">Before</div>
    398 
    399     <table class="ui-table bad emulate-content-left-padding">
    400     <thead>
    401       <tr>
    402         <th class="label">
    403         Screen timeout
    404         </th>
    405       </tr>
    406     </thead>
    407     <tbody>
    408       <tr>
    409         <td class="secondary-text">
    410         Adjust the delay before the screen automatically turns off
    411         </td>
    412       </tr>
    413     </tbody>
    414     </table>
    415 
    416   </div>
    417   <div class="layout-content-col span-4">
    418 
    419     <div class="do-dont-label good">After</div>
    420 
    421     <table class="ui-table good">
    422     <thead>
    423       <tr>
    424         <th class="label">
    425         Sleep
    426         </th>
    427       </tr>
    428     </thead>
    429     <tbody>
    430       <tr>
    431         <td class="secondary-text">
    432         After 10 minutes of activity
    433         </td>
    434       </tr>
    435     </tbody>
    436     </table>
    437 
    438   </div>
    439 </div>
    440 
    441 <p>Status in secondary text has the following benefits:</p>
    442 <ul>
    443 <li>Users can see at a glance what the current value of a setting is without having to navigate
    444 any further.</li>
    445 <li>It applies the design principle
    446 <a href="{@docRoot}design/get-started/principles.html#keep-it-brief">Keep it brief</a>, which
    447 users greatly appreciate.</li>
    448 </ul>
    449 
    450 <h4>&hellip;unless it's a checkbox setting</h4>
    451 <p>There's one important exception to the using secondary text for status: checkbox settings.
    452 Here, use secondary text for description, not status. Status below a checkbox is unnecessary
    453 because the checkbox already indicates it. The reason why it's appropriate to have a description
    454 below a checkbox setting is because&mdash;unlike other controls&mdash;it doesn't display a dialog
    455 or navigate to another screen where additional information can be provided.</p>
    456 
    457 <p>That said, if a checkbox setting's label is clear enough on its own, there's no need to also
    458 provide a description. Only include one if necessary.</p>
    459 
    460 <p>Follow these guidelines to write checkbox setting descriptions:</p>
    461 <ul>
    462 <li>Keep it to one sentence and don't use ending punctuation.</li>
    463 <li>Convey what happens when the setting is checked, phrased in the form of a command. Example:
    464 "Allow data exchange", not "Allows data exchange".</li>
    465 <li>Avoid repetition by choosing words that don't already appear in the label.</li>
    466 <li>Don't refer to the user unless it's necessary for understanding the setting.</li>
    467 <li>If you must refer to the user, do so in the second person ("you") rather than the first person
    468 ("I"). Android speaks to users, not on behalf of them.</li>
    469 </ul>
    470 
    471 <h4>Writing examples</h4>
    472 
    473 <p>The following are examples of changes we made to labels and secondary text in the Settings app
    474 in Ice Cream Sandwich.</p>
    475 
    476 <div class="layout-content-row">
    477   <div class="layout-content-col span-4">
    478 
    479     <div class="do-dont-label bad emulate-content-left-padding">Before</div>
    480 
    481     <table class="ui-table bad emulate-content-left-padding">
    482     <thead>
    483       <tr>
    484         <th class="label">
    485         Use tactile feedback
    486         </th>
    487       </tr>
    488     </thead>
    489     </table>
    490 
    491   </div>
    492   <div class="layout-content-col span-4">
    493 
    494     <div class="do-dont-label good">After</div>
    495 
    496     <table class="ui-table good">
    497     <thead>
    498       <tr>
    499         <th class="label">
    500         Vibrate on touch
    501         </th>
    502       </tr>
    503     </thead>
    504     </table>
    505 
    506   </div>
    507   <div class="layout-content-col span-5">
    508 
    509 <p>In this checkbox setting, we eliminated the throwaway word "Use" and rephrased the label to be
    510 more direct and understandable.</p>
    511 
    512   </div>
    513 
    514 </div>
    515 
    516 <div class="layout-content-row">
    517   <div class="layout-content-col span-4">
    518 
    519     <div class="do-dont-label bad emulate-content-left-padding">Before</div>
    520 
    521     <table class="ui-table bad emulate-content-left-padding">
    522     <thead>
    523       <tr>
    524         <th class="label">
    525         Screen timeout
    526         </th>
    527       </tr>
    528     </thead>
    529     <tbody>
    530       <tr>
    531         <td class="secondary-text">
    532         Adjust the delay before the screen automatically turns off
    533         </td>
    534       </tr>
    535     </tbody>
    536     </table>
    537 
    538   </div>
    539   <div class="layout-content-col span-4">
    540 
    541     <div class="do-dont-label good">After</div>
    542 
    543     <table class="ui-table good">
    544     <thead>
    545       <tr>
    546         <th class="label">
    547         Sleep
    548         </th>
    549       </tr>
    550     </thead>
    551     <tbody>
    552       <tr>
    553         <td class="secondary-text">
    554         After 10 minutes of activity
    555         </td>
    556       </tr>
    557     </tbody>
    558     </table>
    559 
    560   </div>
    561   <div class="layout-content-col span-5">
    562 
    563 <p>In this multiple choice setting, we changed the label to a friendlier term and also replaced
    564 the description with status. We put some descriptive words around the selected value, "10
    565 minutes", because on its own, the meaning could be misinterpreted as "sleep for 10 minutes".</p>
    566 
    567   </div>
    568 </div>
    569 
    570 <div class="layout-content-row">
    571   <div class="layout-content-col span-4">
    572 
    573     <div class="do-dont-label bad emulate-content-left-padding">Before</div>
    574 
    575     <table class="ui-table bad emulate-content-left-padding">
    576     <thead>
    577       <tr>
    578         <th class="label">
    579         Change screen lock
    580         </th>
    581       </tr>
    582     </thead>
    583     <tbody>
    584       <tr>
    585         <td class="secondary-text">
    586         Change or disable pattern, PIN, or password security
    587         </td>
    588       </tr>
    589     </tbody>
    590     </table>
    591 
    592   </div>
    593   <div class="layout-content-col span-4">
    594 
    595     <div class="do-dont-label good">After</div>
    596 
    597     <table class="ui-table good">
    598     <thead>
    599       <tr>
    600         <th class="label">
    601         Screen lock
    602         </th>
    603       </tr>
    604     </thead>
    605     <tbody>
    606       <tr>
    607         <td class="secondary-text">
    608         Pattern
    609         </td>
    610       </tr>
    611     </tbody>
    612     </table>
    613 
    614   </div>
    615   <div class="layout-content-col span-5">
    616 
    617 <p>This setting navigates to a a sequence of subscreens that allow users to choose a type of
    618 screen lock and then set it up. We eliminated the throwaway word "Change" in the label, and
    619 replaced the description with the current type of screen lock set up by the user. If the user
    620 hasn't set up a screen lock, the secondary text says "None".</p>
    621 
    622   </div>
    623 </div>
    624 
    625 <div class="layout-content-row">
    626   <div class="layout-content-col span-4">
    627 
    628     <div class="do-dont-label bad emulate-content-left-padding">Before</div>
    629 
    630     <table class="ui-table bad emulate-content-left-padding">
    631     <thead>
    632       <tr>
    633         <th class="label">
    634         NFC
    635         </th>
    636       </tr>
    637     </thead>
    638     <tbody>
    639       <tr>
    640         <td class="secondary-text">
    641         Use Near Field Communication to read and exchange tags
    642         </td>
    643       </tr>
    644     </tbody>
    645     </table>
    646 
    647   </div>
    648   <div class="layout-content-col span-4">
    649 
    650     <div class="do-dont-label good">After</div>
    651 
    652     <table class="ui-table good">
    653     <thead>
    654       <tr>
    655         <th class="label">
    656         NFC
    657         </th>
    658       </tr>
    659     </thead>
    660     <tbody>
    661       <tr>
    662         <td class="secondary-text">
    663         Allow data exchange when the phone touches another device
    664         </td>
    665       </tr>
    666     </tbody>
    667     </table>
    668 
    669   </div>
    670   <div class="layout-content-col span-5">
    671 
    672 <p>In this checkbox setting&mdash;although it's technical jargon&mdash;we kept the "NFC" label
    673 because: (1) we couldn't find a clear, concise alternative, and (2) user familiarity with the
    674 acronym is expected to increase dramatically in the next couple of years.</p>
    675 <p>We did, however, rewrite the description. It's far less technical than before and does a better
    676 job of conveying how and why you'd use NFC. We didn't include what the acronym stands for because
    677 it doesn't mean anything to most users and would have taken up a lot of space.</p>
    678 
    679   </div>
    680 </div>
    681 
    682 <h2 id="checklist">Checklist</h2>
    683 <ul>
    684 <li><p>Make sure each item in Settings meets the criteria for belonging there.</p></li>
    685 <li><p>If you have more than 7 items, explore ways to group related settings.</p></li>
    686 <li><p>Use design patterns wherever applicable so users don't face a learning curve.</p></li>
    687 <li><p>Choose defaults that are safe, neutral, and fit the majority of users.</p></li>
    688 <li><p>Give each setting a clear, concise label and use secondary text appropriately.</p></li>
    689 </ul>