Home | History | Annotate | Download | only in ui_guidelines
      1 page.title=Status Bar Icons
      2 parent.title=Icon Design Guidelines
      3 parent.link=icon_design.html
      4 @jd:body
      5 
      6 <div id="qv-wrapper">
      7 <div id="qv">
      8 
      9 <h2>In this document</h2>
     10 
     11 <ol>
     12 <li><a href="#icon11">Android 3.0 and Later</a>
     13   <ol>
     14     <li><a href="#overview11">Overview of changes</a></li>
     15     <li><a href="#size11">Size and format</a></li>
     16     <li><a href="#style11">Style, colors, and effects</a></li>
     17     <li><a href="#dimming11">Automatic dimming</a></li>
     18     <li><a href="#examples11">Example icons</a></li>
     19   </ol>
     20 </li>
     21 <li><a href="#icon9">Android 2.3</a>
     22   <ol>
     23     <li><a href="#size9">Size</a></li>
     24     <li><a href="#style9">Style, color, and effects</a></li>
     25     <li><a href="#dosdonts9">Do's and don'ts</a></li>
     26     <li><a href="#examples9">Example icons</a></li>
     27   </ol>
     28 </li>
     29 <li><a href="#icon1">Android 2.2 and Earlier</a></li>
     30 </ol>
     31 
     32 <h2>See also</h2>
     33 
     34 <ol>
     35 <li><a href="{@docRoot}guide/practices/screens_support.html">Supporting Multiple
     36 Screens</a></li>
     37 </ol>
     38 
     39 </div>
     40 </div>
     41 
     42 
     43 
     44 <p>Status bar icons are used to represent notifications from your application in
     45 the status bar.</p>
     46 
     47 <p>As described in <a
     48 href="{@docRoot}guide/practices/ui_guidelines/icon_design.html#icon-sets">Providing Density-Specific
     49 Icon Sets</a> and <a href="{@docRoot}guide/practices/screens_support.html">Supporting Multiple
     50 Screens</a>, you should create separate icons for all generalized screen densities, including low-,
     51 medium-, high-, and extra-high-density screens. This ensures that your icons will display properly
     52 across the range of devices on which your application can be installed. See <a
     53 href="{@docRoot}guide/practices/ui_guidelines/icon_design.html#design-tips">Tips for Designers</a>
     54 for suggestions on how to work with multiple sets of icons.</p>
     55 
     56 <p>Templates for creating icons in Adobe Photoshop are available in the <a
     57 href="{@docRoot}guide/practices/ui_guidelines/icon_design.html#templatespack">Icon
     58 Templates Pack</a>.</p>
     59 
     60 
     61 <div class="warning">
     62 
     63 <p><strong>Warning:</strong>The style and dimensions of status bar icons have changed dramatically
     64 in Android 3.0 and 2.3 compared to <a href="#icon1">previous versions</a>. <strong>To
     65 provide support for all Android versions</strong>, developers should:</p>
     66 
     67 <ol>
     68 <li>Place status bar icons for Android 3.0 and later in the
     69   <code>drawable-xhdpi-v11</code>, <code>drawable-hdpi-v11</code>,<code>drawable-mdpi-v11</code>,
     70   and <code>drawable-ldpi-v11</code> directories.</li>
     71 <li>Place status bar icons for Android 2.3 in the
     72   <code>drawable-xhdpi-v9</code>, <code>drawable-hdpi-v9</code>, <code>drawable-mdpi-v9</code>,
     73   and <code>drawable-ldpi-v9</code> directories.</li>
     74 <li>Place status bar icons for previous versions in
     75   <code>drawable-xhdpi</code>, <code>drawable-hdpi</code>, <code>drawable-mdpi</code>,
     76   and <code>drawable-ldpi</code> directories.</li>
     77 </ol>
     78 
     79 </div>
     80 
     81 
     82 
     83 
     84 <h2 id="icon11">Android 3.0 and Later</h2>
     85 
     86 <p>The following guidelines describe how to design status bar icons for Android
     87 3.0 (API Level 11) and later.</p>
     88 
     89 
     90 <h3 id="overview11">Overview of changes</h3>
     91 
     92 <p>The design for status bar (notification) icons has been revised in Android 3.0. Status bar icons
     93   used in Android 3.0 and later are easier to create, and they allow for more flexible presentation
     94   in a variety of situations:</p>
     95 
     96 <ul>
     97   <li>Status bar icons are composed simply of <strong>white pixels on a transparent
     98     backdrop</strong>, with alpha blending used for smooth edges and internal texture where
     99     appropriate.</li>
    100   <li>Icons are square icon contents should <strong>fill the available space</strong>, although a
    101     small amount of internal padding can help maintain balance across status bar icons. See
    102     <a href="#size11">Size and format</a> below for details.</li>
    103 </ul>
    104 
    105 <p>These larger and brighter icons, while highly legible, are too intense for use on dark phone
    106 status bars. These icons would be too distracting if used directly in the status bar. Therefore:
    107 </p>
    108 
    109 <ul>
    110   <li><strong>The system automatically resizes and dims</strong> these icons in such situations and
    111     developers do not need to supply a separate icon for this purpose. See
    112     <a href="#dimming11">Automatic dimming</a> below for more on this behavior.</li>
    113 </ul>
    114 
    115 
    116 <h3 id="size11">Size and format</h2>
    117 
    118 <p>Status bar icons should be 32-bit PNGs with an alpha channel for transparency. The finished
    119 status bar icon dimensions corresponding to a given generalized screen density are shown in the
    120 table below.</p>
    121 
    122 <p class="note"><strong>Note:</strong> The system will shrink and dim status bar icons to minimize
    123 distractions, allowing users to focus on the foreground activity.</p>
    124 
    125 
    126 <p class="table-caption" id="screens_table"><strong>Table 1.</strong> Summary of
    127 finished icon dimensions for each generalized screen density.</p>
    128 
    129 <table>
    130   <tbody>
    131   <tr>
    132     <th></th>
    133     <th>
    134       <code>ldpi</code> (120 dpi)<br>
    135       <small style="font-weight: normal">(Low density screen)</small>
    136     </th>
    137     <th>
    138       <code>mdpi</code> (160 dpi)<br>
    139       <small style="font-weight: normal">(Medium density screen)</small>
    140     </th>
    141     <th>
    142       <code>hdpi</code> (240 dpi)<br>
    143       <small style="font-weight: normal">(High density screen)</small>
    144     </th>
    145     <th>
    146       <code>xhdpi</code> (320 dpi)<br>
    147       <small style="font-weight: normal">(Extra-high density screen)</small>
    148     </th>
    149   </tr>
    150   <tr>
    151     <th style="background-color:#f3f3f3;font-weight:normal">
    152       Status Bar Icon Size<br><small>(Android 3.0 and Later)</small>
    153     </th>
    154     <td>
    155       18 x 18 px
    156     </td>
    157     <td>
    158       24 x 24 px
    159     </td>
    160     <td>
    161       36 x 36 px
    162     </td>
    163     <td>
    164       48 x 48 px
    165     </td>
    166   </tr>
    167   </tbody>
    168 </table>
    169 
    170 <p>You can also include a few pixels of padding in status bar icons to maintain a
    171 consistent visual weight with adjacent icons. For example, a 48 x 48 pixel <code>xhdpi</code>
    172 status bar icon can contain a 44 x 44 pixel shape with 2 pixels on each side for padding.</p>
    173 
    174 
    175 <h3 id="style11">Style, colors, and effects</h3>
    176 
    177 <p>Status bar icons are flat, pictured face on, and must be white on a transparent background.</p>
    178 
    179 <p>In order to maintain consistency across all status bar notifications, status bar icons should
    180 use the styling shown in Figure 1.</p>
    181 
    182 
    183 
    184 <table class="image-caption">
    185 <tr>
    186 <td class="image-caption-i">
    187   <img src="{@docRoot}images/icon_design/status_bar_honeycomb_style.png"
    188     alt="A view of effects for status bar icons.">
    189 </td>
    190 <td class="image-caption-c">
    191   <div class="caption grad-rule-top">
    192     <p><strong>Figure 1. </strong>Style for status bar icons.</p>
    193     <div class="image-caption-nested">
    194     <table>
    195       <tr><td><em>1.</em></td><td nowrap>Fill color:</td><td><code>#ffffff</code><br><br></td></tr>
    196       <tr><td><em>2.</em></td><td nowrap>Inner content:</td><td>Inner content should subtract from
    197         the outer shape and consist purely of transparent pixels.</td></tr>
    198     </table>
    199     </div>
    200   </div>
    201 </td>
    202 </tr>
    203 </table>
    204 
    205 
    206 <h3 id="dimming11">Automatic dimming</h3>
    207 
    208 <p>The system may dim and shrink status bar icons to allow users to focus on the foreground
    209 activity. For example, in Android 4.0, the platform-standard status bar for handset-size devices
    210 reduces icons to 18 x 18 dip and 40% opacity in the status bar, while drawing them full-size and at
    211 full intensity in the expanded notification panel. An example of what this looks like is shown below
    212 in Figure 2.</p>
    213 
    214 
    215 <img src="{@docRoot}images/icon_design/status_bar_honeycomb_dimming.png"
    216   alt="Automatic shrinking and dimming behavior in Android 3.0 and later">
    217 <p class="img-caption">
    218   <strong>Figure 2.</strong> Automatic shrinking and dimming behavior in Android 3.0 and later.
    219 </p>
    220 
    221 
    222 <h3 id="examples11">Example icons</h3>
    223 
    224 <p>Shown below are example extra-high-density status bar icons that are used throughout Android
    225 system applications.</p>
    226 
    227 <p class="warning"><strong>Warning:</strong> Because resources can change between platform versions,
    228 you should not reference built-in icons using the Android platform resource IDs (i.e. status bar
    229 icons under <code>android.R.drawable</code>). If you want to use any icons or other internal
    230 drawable resources, you should store a local copy of those icons or drawables in your application
    231 resources, then reference the local copy from your application code. In that way, you can maintain
    232 control over the appearance of your icons, even if the system's copy changes. Note that the grid
    233 below is not intended to be complete.</p>
    234 
    235 <img src="{@docRoot}images/icon_design/status_bar_honeycomb_examples.png" />
    236 
    237 
    238 
    239 
    240 
    241 <h2 id="icon9">Android 2.3</h2>
    242 
    243 <p>The following guidelines describe how to design status bar icons for Android
    244 2.3 (API Levels 9 and 10).</p>
    245 
    246 <h3 id="size9">Size and positioning</h3>
    247 
    248 <p>Status bar icons should use simple shapes and forms and those must be
    249 scaled and positioned inside the final asset.</p>
    250 
    251 <p>Figure 3 illustrates various ways of positioning the icon inside the
    252 asset. You should size the icons <em>smaller than the actual bounds of the
    253 asset</em>. <strong>Status bar icons may vary in width, but only
    254 minimally.</strong></p>
    255 
    256 <p>In order to indicate the recommended size for the icon, each example in
    257 Figure 3 includes two different guide rectangles:</p>
    258 
    259 <ul>
    260 <li>The red box is the bounding box for the full asset.</li>
    261 <li>The blue box is the recommended bounding box for the actual icon.
    262 The icon box is sized smaller vertically than the full asset box to allow for
    263 varying icon shapes while maintaining a consistent visual weight.</li>
    264 </ul>
    265 
    266 <table>
    267 <tr>
    268 
    269 <td style="border:0;">
    270 <ol class="nolist">
    271   <li>Status bar icon dimensions for high-density (<code>hdpi</code>) screens:</li>
    272   <ol class="nolist">
    273     <li>Full Asset: 24w x 38h px (preferred, width may vary)</li>
    274     <li>Icon: 24w x 24h px (preferred, width may vary)</li>
    275   </ol>
    276   </li>
    277 </ol>
    278 </td>
    279 <td style="border:0;">
    280   <img src="{@docRoot}images/icon_design/statusbar_size_hdpi.png" width="318">
    281 </td>
    282 </tr>
    283 <tr>
    284 <td style="border:0;">
    285   <ol class="nolist">
    286   <li>Status bar icon dimensions for medium-density (<code>mdpi</code>) screens:</li>
    287     <ol class="nolist">
    288       <li>Full Asset: 16w x 25 px (preferred, width may vary)</li>
    289       <li>Icon: 16w x 16w px (preferred, width may vary)</li>
    290     </ol>
    291   </li>
    292 </ol>
    293 </td>
    294 
    295 <td style="border:0;">
    296  <img src="{@docRoot}images/icon_design/statusbar_size_mdpi.png" width="318">
    297 </td>
    298 </tr>
    299 <tr>
    300 <td style="border:0;">
    301   <ol class="nolist">
    302   <li>Status bar icon dimensions for low-density (<code>ldpi</code>) screens:</li>
    303     <ol class="nolist">
    304       <li>Full Asset: 12w x 19h px (preferred, width may vary)</li>
    305       <li>Icon: 12w x 12h px (preferred, width may vary)</li>
    306     </ol>
    307   </li>
    308 </ol>
    309 </td>
    310 
    311 <td style="border:0;">
    312  <img src="{@docRoot}images/icon_design/statusbar_size_ldpi.png" width="318">
    313 </td>
    314 </tr>
    315 
    316 <tr>
    317 <td style="border:0;"></td>
    318 <td style="border:0;">
    319  <p class="table-caption"><strong>Figure 3.</strong>
    320  Status bar icon sizing and positioning inside the bounds of the
    321  icon asset.</p>
    322 </td>
    323 </tr>
    324 
    325 </table>
    326 
    327 
    328 
    329 
    330 <h3 id="style9">Style, colors, and effects</h3>
    331 
    332 <p>Status bar icons are flat, matte, and pictured face-on.</p>
    333 
    334 
    335 <table class="image-caption">
    336 <tr>
    337 <td class="image-caption-i">
    338   <img src="{@docRoot}images/icon_design/statusbar_style.png" alt="A view of effects for status bar icons."/>
    339 </td>
    340 <td class="image-caption-c">
    341   <div class="caption grad-rule-top">
    342     <p><strong>Figure 4. </strong>Style and effects for status icons.</p>
    343     <div class="image-caption-nested">
    344     <p><em>Note: all pixel dimensions are for medium density and should be scaled appropriately for other densities.</em></p>
    345     <table>
    346     <tr><td><em>1.</em></td><td nowrap>Fill gradient:</td><td>90&deg;, from <code>#828282</code> to <code>#919191</code><br><br></td></tr>
    347     <tr><td><em>2.</em></td><td nowrap>Inner shadow:</td><td><code>#FFFFFF</code>, 10% opacity<br>angle 90&deg;<br>distance 1px<br>size 0px<br><br></td></tr>
    348     <tr><td><em>3.</em></td><td nowrap>Inner content:</td><td>Inner content should subtract from the outer shape and consist purely of transparent pixels.</td></tr>
    349     </table>
    350     </div>
    351   </div>
    352 </td>
    353 </tr>
    354 </table>
    355 
    356 
    357 
    358 
    359 <h3 id="dosdonts9">Do's and don'ts</h3>
    360 
    361 <p>Below are some "do and don't" examples to consider when creating status bar icons for
    362 your application. </p>
    363 
    364 
    365 <img src="{@docRoot}images/icon_design/do_dont_statusicons.png">
    366 
    367 
    368 
    369 
    370 <h3 id="examples9">Example icons</h3>
    371 
    372 <p>Shown below are standard high-density status bar icons that are used in
    373 the Android platform.</p>
    374 
    375 <p class="warning"><strong>Warning:</strong> Because these resources can change
    376 between platform versions, you should not reference these icons using the
    377 Android platform resource IDs (i.e. status bar icons under
    378 <code>android.R.drawable</code>). If you want to use any icons or other internal
    379 drawable resources, you should store a local copy of those icons or drawables in
    380 your application resources, then reference the local copy from your application
    381 code. In that way, you can maintain control over the appearance of your icons,
    382 even if the system's copy changes. Note that the grid below is not intended to
    383 be complete.</p>
    384 
    385 <img src="{@docRoot}images/icon_design/statusbar_standard.png" />
    386 
    387 
    388 
    389 <h2 id="icon1">Android 2.2 and Earlier</h2>
    390 
    391 <p>The following guidelines describe how to design status bar icons for Android
    392 2.2 (API Level 8) and earlier.</p>
    393 
    394 <h3 id="structure1">Structure</h3>
    395 
    396 <ul>
    397 <li>Rounded corners must always be applied to the base shape and to the details
    398 of a status bar icon shown Figure 5.</li>
    399 
    400 <li>All dimensions specified are based on a 25x25 pixel artboard size with a 2
    401 pixel safeframe.</li>
    402 
    403 <li>Status bar icons can overlap the safeframe to the left and right when
    404 necessary, but must not overlap the safeframe at the top and bottom.</li>
    405 
    406 <li><strong>Final art must be exported as a transparent PNG file.</strong></li>
    407 
    408 <li>Templates for creating status bar icons using Adobe Photoshop are available
    409 in the Icon Templates Pack.</li>
    410 </ul>
    411 
    412 <table class="image-caption">
    413 <tr>
    414 <td class="image-caption-i">
    415   <img src="{@docRoot}images/icon_design/statusbar_structure.png" alt="A view of
    416 status bar icon structure." />
    417 </td>
    418 <td class="image-caption-c">
    419   <div class="caption grad-rule-top">
    420     <p><strong>Figure 5. </strong>Safeframe and corner-rounding for status bar
    421 icons. Icon size is 25x25.</p>
    422   </div>
    423 </td>
    424 </tr>
    425 </table>
    426 
    427 
    428 <h3 id="style1">Light, effects, and shadows</h3>
    429 
    430 <p>Status bar icons are slightly debossed, high in contrast, and pictured
    431 face-on to enhance clarity at small sizes.</p>
    432 
    433 <table class="image-caption">
    434 <tr>
    435 <td class="image-caption-i">
    436   <img src="{@docRoot}images/icon_design/statusbar_light.png"/>
    437 </td>
    438 <td class="image-caption-c">
    439   <div class="caption grad-rule-top">
    440     <p><strong>Figure 6. </strong>Light, effects, and shadows for status bar icons.</p>
    441     <div class="image-caption-nested">
    442     <table>
    443     <tr><td><em>1.</em></td><td>Front part:</td><td>Use fill gradient from primary color palette</td></tr>
    444     <tr><td><em>2.</em></td><td>Inner bevel:</td><td>depth 100% | direction down<br>size 0px | angle 90 |<br>altitude 30<br>highlight white 75% opacity<br>shadow black 75% opacity</td></tr>
    445     <tr><td><em>3.</em></td><td>Detail:</td><td>white</td></tr>
    446     <tr><td><em>4.</em></td><td>Disabled detail:</td><td>grey gradient from palette<br>+ inner bevel: smooth | depth 1% | direction down | size 0px | angle 117 | <br>altitude 42 | highlight white 70% | no shadow</td></tr>
    447     </table>
    448     </div>
    449   </div>
    450 </td>
    451 </tr>
    452 </table>
    453 
    454 <table>
    455 <tr>
    456 <td style="border:0">
    457 
    458 <h4 id="palette1">Color palette</h4>
    459 
    460 <p>Only status bar icons related to the phone function use full color; all other status bar icons should remain monochromatic.</p>
    461 
    462 <table>
    463 <tr>
    464 <td class="image-caption-i"><img src="{@docRoot}images/icon_design/statusbar_palette_white.png"/></td>
    465 <td class="image-caption-c">White<br>r 255 | g 255 | b 255<br>Used for details within the icons and bevel highlight.</td>
    466 </tr>
    467 
    468 <tr>
    469 <td class="image-caption-i"><img src="{@docRoot}images/icon_design/statusbar_palette_grey.png"/></td>
    470 <td class="image-caption-c">Grey gradient<br><em>1:&nbsp;&nbsp;</em>r 169 | g 169 | b 169<br><em>2:&nbsp;&nbsp;</em>r 126 | g 126 | b 126<br>Used for disabled details within the icon.</td>
    471 </tr>
    472 
    473 <tr>
    474 <td class="image-caption-i"><img src="{@docRoot}images/icon_design/statusbar_palette_fill.png"/></td>
    475 <td class="image-caption-c">Fill gradient<br><em>1:&nbsp;&nbsp;</em>1 r 105 | g 105 | b 105<br><em>2:&nbsp;&nbsp;</em>r 10   | g 10   | b 10<br>Used as color fill.</td>
    476 </tr>
    477 
    478 <tr>
    479 <td class="image-caption-i"><img src="{@docRoot}images/icon_design/statusbar_palette_black.png"/></td>
    480 <td class="image-caption-c">Black<br>r 0 | g 0 | b 0<br>Used for bevel shadow.</td>
    481 </tr>
    482 
    483 </table>
    484 
    485 </td>
    486 
    487 <td style="border:0">
    488 
    489 <h4 id="steps1">Step by step</h4>
    490 
    491 <ol>
    492 <li>In a tool like Adobe Photoshop, create the base shape within a 25x25 px
    493 image on a transparent background. Mind the safeframe, and keep the upper and
    494 lower 2 pixels free.</li>
    495 <li>Add rounded corners as specified in Figure 5.</li>
    496 <li>Add light, effects, and shadows as specified in Figure 6.</li>
    497 <li>Export the icon at 25x25 as a PNG file with transparency enabled.</li>
    498 </ol>
    499 
    500 </td>
    501 </tr>
    502 </table>
    503