summaryrefslogtreecommitdiffstats
path: root/chrome/common/extensions/docs/static/browserAction.html
diff options
context:
space:
mode:
authoraa@chromium.org <aa@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-20 09:11:30 +0000
committeraa@chromium.org <aa@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-20 09:11:30 +0000
commitecbb931bdfae3004686d0274242a85dcbf04dbea (patch)
tree8d742dbfc4effacf296d9099fb97908b7890c3a0 /chrome/common/extensions/docs/static/browserAction.html
parent96069b56398172b1b0891fc796f8bb9ceb149d72 (diff)
downloadchromium_src-ecbb931bdfae3004686d0274242a85dcbf04dbea.zip
chromium_src-ecbb931bdfae3004686d0274242a85dcbf04dbea.tar.gz
chromium_src-ecbb931bdfae3004686d0274242a85dcbf04dbea.tar.bz2
First cut at new page and browser action docs based
on new API. Deleted old stuff. TBR=kathyw@google.com,rafaelw@chromium.org git-svn-id: svn://svn.chromium.org/chrome/trunk/src@29500 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common/extensions/docs/static/browserAction.html')
-rwxr-xr-xchrome/common/extensions/docs/static/browserAction.html93
1 files changed, 93 insertions, 0 deletions
diff --git a/chrome/common/extensions/docs/static/browserAction.html b/chrome/common/extensions/docs/static/browserAction.html
new file mode 100755
index 0000000..310fbeb
--- /dev/null
+++ b/chrome/common/extensions/docs/static/browserAction.html
@@ -0,0 +1,93 @@
+<div id="pageData-title" class="pageData">Browser Actions</div>
+
+<!-- BEGIN AUTHORED CONTENT -->
+<p>Browser actions are buttons
+ that are displayed in the main Chrome toolbar
+ to the right of the omnibox.</p>
+
+<img src="images/browser-action.png"
+ width="363" height="226" />
+
+<h2 id="icons">Icons</h2>
+
+<p>Browser action icons can be up to 19px square.
+ Larger icons will be resized to fit, but for best results,
+ using a 19px icon is recommended.</p>
+
+<p>Icons can be set two ways:
+ using a static image or using the
+ HTML5 <a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/the-canvas-element.html">canvas element</a>.
+ Using static images is easier for simple applications,
+ but you can do more dynamic UIs
+ using the canvas element.
+
+<p>Static images can be in any format WebKit can display.
+ These include: png, bmp, ico, jpg, gif.</p>
+
+<h2 id="badges">Badges</h2>
+
+<p>Browser actions can optionally display a badge,
+ which is a bit of text that is layered over the icon.
+ Badges make it easy to update the browser action
+ to display a small amount of information
+ about the state of the extension.</p>
+
+<p>The badge APIs allow any length of text,
+ but limiting badges to a max of four characters
+ is recommended.</p>
+
+<h2 id="popups">Popups</h2>
+
+<p>Popups allow browser actions to show additional UI
+ when the user activates them.
+ Popups contents are implemented using HTML
+ and the popup is automatically sized
+ to the content size.</p>
+
+<h2>Style Guide</h2>
+
+<p>For the best visual impact,
+ we recommend observing
+ the following guidelines:</p>
+
+<ul>
+ <li><b>Do</b> use browser actions for features
+ that make sense on most pages.
+ <li><b>Don't</b> use browser actions for features
+ that only make sense for a few pages.
+ Use <a href="pageAction.html">page actions</a> instead.
+ <li><b>Do</b> use big, colorful icons that fully utilize
+ the 19px square space.
+ Browser action icons should seem a little bigger
+ and heavier than page action icons.
+ <li><b>Don't</b> attempt to mimic
+ Chrome's monochrome "wrench" and "page" icons.
+ This won't work well with themes, and anyway,
+ extensions should stand out a little.
+ <li><b>Do</b> use alpha transparency
+ to add soft edges to your icon.
+ Remember: many users theme Chrome,
+ so your icon should look nice
+ on a variety of background colors.
+ <li><b>Don't</b> constantly animate your icon.
+ That's just annoying.
+</ul>
+
+<h2 id="manifest">Manifest</h2>
+
+<p>Developers declare their browser action
+ using the following syntax:</p>
+
+<pre>"browser_action": {
+ "default_title": "Google Mail", // Optional. Shown in tooltip.
+ "default_icon": "images/icon19.png", // Optional.
+ "popup": "popup.html" // Optional
+}</pre>
+
+<p><b>Note:</b> Even if you don't include
+ any of the values, you must include an empty
+ browser_action entry in your manifest
+ so that the system knows to reserve space
+ for your browser action in the toolbar.</p>
+
+<!-- END AUTHORED CONTENT -->