diff options
author | Roman Nurik <romannurik@google.com> | 2011-12-22 14:27:55 -0800 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2011-12-22 14:27:55 -0800 |
commit | 38ee0dae2cf0ff1860973523e5cda6e38642e904 (patch) | |
tree | 80b9b6c075af5d9c8135e2901463ce7a4243bbca /docs | |
parent | c892e177c4f7a41e910c70f68d4e213589da1396 (diff) | |
parent | 2b43f3f4441d92d6418017f6a0a448936b9e5e1b (diff) | |
download | frameworks_base-38ee0dae2cf0ff1860973523e5cda6e38642e904.zip frameworks_base-38ee0dae2cf0ff1860973523e5cda6e38642e904.tar.gz frameworks_base-38ee0dae2cf0ff1860973523e5cda6e38642e904.tar.bz2 |
Merge "docs: Update App Widgets dev guide size discussion" into ics-mr1
Diffstat (limited to 'docs')
-rw-r--r-- | docs/html/guide/topics/appwidgets/index.jd | 56 |
1 files changed, 27 insertions, 29 deletions
diff --git a/docs/html/guide/topics/appwidgets/index.jd b/docs/html/guide/topics/appwidgets/index.jd index 2cb23c1..7b869a0 100644 --- a/docs/html/guide/topics/appwidgets/index.jd +++ b/docs/html/guide/topics/appwidgets/index.jd @@ -186,36 +186,34 @@ folder.</p> <p>Here's a summary of the <code><appwidget-provider></code> attributes:</p> <ul> <li>The values for the <code>minWidth</code> and <code>minHeight</code> -attributes specify the minimum - area required by the App Widget's layout. - <p>The default Home screen positions App Widgets in its window based on a -grid of - cells that have a defined height and width. If the values for an App -Widget's minimum width - or height don't match the dimensions of the cells, - then the App Widget dimensions round <em>up</em> to the nearest cell size. - (See the <a -href="{@docRoot}guide/practices/ui_guidelines/widget_design.html">App Widget -Design - Guidelines</a> for more information on the Home screen cell sizes.)</p> - <p>Because the Home screen's layout orientation (and thus, the cell sizes) -can change, - as a rule of thumb, you should assume the worst-case cell size of 74 pixels -for the height - <em>and</em> width of a cell. However, you must subtract 2 from the final -dimension to account - for any integer rounding errors that occur in the pixel count. To find your -minimum width - and height in density-independent pixels (dp), use this formula:<br/> - <code>(number of cells * 74) - 2</code><br/> - Following this formula, you should use 72 dp for a height of one cell, 294 -dp and for a width of four cells.</p> -<p class="note"><strong>Note:</strong> To make your app widget portable across -devices, your app widget's minimum size should never be larger than 4 x 4 cells. -See the <a -href="{@docRoot}guide/practices/ui_guidelines/widget_design.html#sizes">App -Widget Design Guidelines</a> for more discussion of Home screen cell sizes.</p> + attributes specify the minimum amount of space the App Widget consumes + <em>by default</em>. The default Home screen positions App Widgets in its + window based on a grid of cells that have a defined height and width. If + the values for an App Widget's minimum width or height don't match the + dimensions of the cells, then the App Widget dimensions round + <em>up</em> to the nearest cell size. + <p>See the <a href="{@docRoot}guide/practices/ui_guidelines/widget_design.html#anatomy_determining_size"> + App Widget Design Guidelines</a> for more information on sizing your App + Widgets.</p> + + <p class="note"><strong>Note:</strong> To make your app widget portable + across devices, your app widget's minimum size should never be larger + than 4 x 4 cells.</p> </li> + + <li>The <code>minResizeWidth</code> and <code>minResizeHeight</code> attributes + specify the App Widget's absolute minimum size. These values should specify + the size below which the App Widget would be illegible or otherwise unusable. + Using these attributes allows the user to resize the widget to a size that + may be smaller than the default widget size defined by the + <code>minWidth</code> and <code>minHeight</code> attributes. + Introduced in Android 3.1. + + <p>See the <a href="{@docRoot}guide/practices/ui_guidelines/widget_design.html#anatomy_determining_size"> + App Widget Design Guidelines</a> for more information on sizing your App + Widgets.</p> + </li> + <li>The <code>updatePeriodMillis</code> attribute defines how often the App Widget framework should request an update from the {@link android.appwidget.AppWidgetProvider} by calling the |