Author: rgardler
Date: Tue Jan 31 00:23:15 2012
New Revision: 1238104

URL: http://svn.apache.org/viewvc?rev=1238104&view=rev
Log:
CMS commit to wookie by rgardler

Modified:
    incubator/wookie/site/trunk/content/wookie/docs/developer/features.mdtext

Modified: 
incubator/wookie/site/trunk/content/wookie/docs/developer/features.mdtext
URL: 
http://svn.apache.org/viewvc/incubator/wookie/site/trunk/content/wookie/docs/developer/features.mdtext?rev=1238104&r1=1238103&r2=1238104&view=diff
==============================================================================
--- incubator/wookie/site/trunk/content/wookie/docs/developer/features.mdtext 
(original)
+++ incubator/wookie/site/trunk/content/wookie/docs/developer/features.mdtext 
Tue Jan 31 00:23:15 2012
@@ -16,15 +16,37 @@ Notice:    Licensed to the Apache Softwa
            specific language governing permissions and limitations
            under the License.
 
-Features are used to add extra capability to Wookie widgets at runtime. 
Features typically inject scripts and stylesheets into widgets when they are 
viewed in the browser, for example to give access to a particular API or 
feature.
+Features are used to add extra capability to Wookie widgets at runtime. 
+Features typically inject scripts and stylesheets into widgets when they are 
+viewed in the browser, for example to give access to a particular API or 
+feature. Using features in your widgets will make them less portable across 
+different platforms, so use them with care and, wherever possible, ensure your
+widgets degrade gracefully when an optional feature is not available.
 
-To create a feature:
+# Using features
+
+A feature is enabled in a widget by adding a [<feature...>][1] element to the
+widgets config.xml file.
+
+# Available features
+
+Wookie provides a number of features out of the box. These include:
+
+  * camera - provides basic BONDI API access to a camera ([camera][2] example)
+  * jqmobile - provides JQuery Mobile ([seed-widget][3] example)
+  * [oauth][5] - provides an OAuth library ([Facebook][4] example, 
[documentation][5])
+  * polling
+  * wave - an implementation of the [Wave Protocol][6] ([Chat widget][7] 
example)
+  * wookie-ext - Wookie Extensions API
+
+
+# Create a feature
 
 1. Create a new directory in the Wookie /features directory for your feature
 2. Create any JavaScript (.js) or Stylesheet (.css) files you need in this 
directory
 3. Create a file called features.xml with the structure defined below.
 
-# Features.xml
+## Features.xml
 
 A features.xml file must have `<feature>` as its root element, must contain a 
single `<name>` child element, and can have any number of `<script>` and 
`<stylesheet>` child elements.
 
@@ -33,7 +55,7 @@ The `<name>` element should contain an I
 
 The `<script>` and `<stylesheet>` elements should contain a `src` attribute 
with the filename to load. This must be relative to the folder for the feature 
- typically this is just the filename but you can also store CSS and JS files 
in subfolders within your feature directory if you wish.
 
-#Example features.xml
+### Example features.xml
 
 
     <feature>
@@ -43,13 +65,13 @@ The `<script>` and `<stylesheet>` elemen
        <stylesheet src="shared/jquery.mobile-1.0a4.min.css"/>
     </feature>
 
-#Installing features
+## Installing features
 
 By default Wookie will look in its /features directory on launch and load any 
features it finds.
 
 (There is currently no way to dynamically load a feature while Wookie is still 
running)
 
-#Configuring feature deployment
+##Configuring feature deployment
 
 When you build and deploy Wookie using Ant, the features that are deployed are 
determined by two properties set in your build.properties file.
 
@@ -64,4 +86,13 @@ If `include.extra.features` is not comme
 
 If `include.scratchpad.features` is not commented out, any features in the 
`scratchpad/features` directory of the working directory will be deployed. 
 
-If both properties are commented out in build.properties then only the Google 
Wave Gadget API feature will be installed.
\ No newline at end of file
+If both properties are commented out in build.properties then only the Google 
Wave Gadget API feature will be installed.
+
+
+  [1]: http://www.w3.org/TR/widgets/#the-feature-element-and-its-attributes
+  [2]: http://svn.apache.org/repos/asf/incubator/wookie/trunk/widgets/camera/
+  [3]: 
http://svn.apache.org/repos/asf/incubator/wookie/trunk/widgets/widget-template/jqueryMobile/
+  [4]: 
http://svn.apache.org/repos/asf/incubator/wookie/trunk/scratchpad/widgets/fbfriend/
+  [5]: features/oauth.html
+  [6]: http://www.waveprotocol.org/
+  [7]: http://svn.apache.org/repos/asf/incubator/wookie/trunk/widgets/natter/
\ No newline at end of file


Reply via email to