You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pivot.apache.org by tv...@apache.org on 2011/02/07 03:36:18 UTC

svn commit: r1067847 [14/27] - in /pivot/site/trunk/deploy: ./ assets/ demos/ images/ lib/ styles/ tutorials/ tutorials/component_and_container/ tutorials/platform_overview/ tutorials/windows/

Added: pivot/site/trunk/deploy/tutorials/expanders.html
URL: http://svn.apache.org/viewvc/pivot/site/trunk/deploy/tutorials/expanders.html?rev=1067847&view=auto
==============================================================================
--- pivot/site/trunk/deploy/tutorials/expanders.html (added)
+++ pivot/site/trunk/deploy/tutorials/expanders.html Mon Feb  7 02:36:04 2011
@@ -0,0 +1,124 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<!--
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to you under the Apache License,
+Version 2.0 (the "License"); you may not use this file except in
+compliance with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+--><html xmlns="http://www.w3.org/1999/xhtml"><head><meta content="text/html; charset=UTF-8" http-equiv="Content-Type" /><title>Expanders | Apache Pivot</title><link xmlns="" type="text/css" rel="stylesheet" href="/styles/pivot.css"><script xmlns="http://www.w3.org/1999/xhtml" type="text/javascript">
+                var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
+                document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
+                </script><script type="text/javascript">
+                try {
+                var pageTracker = _gat._getTracker("UA-7977275-3");
+                pageTracker._trackPageview();
+                } catch(err) {}</script></head><body><div xmlns="" id="wrapper"><div id="main"><div id="header"><div class="logo"><a href="/index.html"><img title="Apache Pivot Homepage" alt="Apache Pivot" src="/images/logo.png"></a></div><div class="tagline"><img style="visibility:hidden" alt="Rich Internet Applications in Java" src="/images/tagline.png"></div><ul class="navi"><li><a href="/demos/">Demos</a></li><li><a href="/download.cgi#2.0">Download</a></li><li><a href="/tutorials/">Tutorial</a></li><li><a href="/get-involved.html">Get Involved</a></li><li><a href="/about.html">About</a></li></ul></div><div class="group" id="contentBase"><h1>Expanders</h1><ul class="naviLeft"><li><a href="/tutorials/sample-application.html">Sample Application</a></li><li><a href="/tutorials/platform-overview.html">Platform Overview</a></li><li><a href="/tutorials/hello-world.html">Hello, World!</a></li><li><a href="/tutorials/hello-bxml.html">Hello, BXML!</a></li><li><a href="/tutorials/
 component-and-container.html">Component &amp; Container</a></li><li><a href="/tutorials/labels-and-image-views.html">Labels &amp; Image Views</a></li><li><a href="/tutorials/svg-images.html">SVG Images</a></li><li><a href="/tutorials/buttons.html">Buttons</a></li><li><a href="/tutorials/push-buttons.html">Push Buttons</a></li><li><a href="/tutorials/toggle-buttons.html">Toggle Buttons</a></li><li><a href="/tutorials/radio-buttons.html">Radio Buttons</a></li><li><a href="/tutorials/checkboxes.html">Checkboxes</a></li><li><a href="/tutorials/link-buttons.html">Link Buttons</a></li><li><a href="/tutorials/lists.html">Lists</a></li><li><a href="/tutorials/list-buttons.html">List Buttons</a></li><li><a href="/tutorials/repeatable-list-buttons.html">Repeatable List Buttons</a></li><li><a href="/tutorials/text.html">Text</a></li><li><a href="/tutorials/suggestion-popups.html">Suggestion Popups</a></li><li><a href="/tutorials/text-areas.html">Text Areas</a></li><li><a href="/tutoria
 ls/separators.html">Separators</a></li><li><a href="/tutorials/layout-containers.html">Layout Containers</a></li><li><a href="/tutorials/flow-panes.html">Flow Panes</a></li><li><a href="/tutorials/box-panes.html">Box Panes</a></li><li><a href="/tutorials/grid-panes.html">Grid Panes</a></li><li><a href="/tutorials/table-panes.html">Table Panes</a></li><li><a href="/tutorials/borders.html">Borders</a></li><li><a href="/tutorials/stack-panes.html">Stack Panes</a></li><li><a href="/tutorials/split-panes.html">Split Panes</a></li><li><a href="/tutorials/forms.html">Forms</a></li><li><a href="/tutorials/panels.html">Panels</a></li><li><a href="/tutorials/navigation-containers.html">Navigation Containers</a></li><li><a href="/tutorials/card-panes.html">Card Panes</a></li><li><a href="/tutorials/tab-panes.html">Tab Panes</a></li><li><a href="/tutorials/accordions.html">Accordions</a></li><li><a href="/tutorials/expanders.html">Expanders</a></li><li><a href="/tutorials/rollups.html">
 Rollups</a></li><li><a href="/tutorials/viewports.html">Viewports</a></li><li><a href="/tutorials/scroll-panes.html">Scroll Panes</a></li><li><a href="/tutorials/panoramas.html">Panoramas</a></li><li><a href="/tutorials/progress-indicators.html">Progress Indicators</a></li><li><a href="/tutorials/meters.html">Meters</a></li><li><a href="/tutorials/activity-indicators.html">Activity Indicators</a></li><li><a href="/tutorials/bounded-range-components.html">Bounded Range Components</a></li><li><a href="/tutorials/sliders.html">Sliders</a></li><li><a href="/tutorials/scroll-bars.html">Scroll Bars</a></li><li><a href="/tutorials/spinners.html">Spinners</a></li><li><a href="/tutorials/calendars.html">Calendars</a></li><li><a href="/tutorials/menus.html">Menus</a></li><li><a href="/tutorials/context-menus.html">Context Menus</a></li><li><a href="/tutorials/menu-bars.html">Menu Bars</a></li><li><a href="/tutorials/menu-buttons.html">Menu Buttons</a></li><li><a href="/tutorials/color
 -choosers.html">Color Choosers</a></li><li><a href="/tutorials/table-views.html">Table Views</a></li><li><a href="/tutorials/table-views.json.html">JSON-based TableView</a></li><li><a href="/tutorials/table-views.custom.html">Custom TableView</a></li><li><a href="/tutorials/tree-views.html">Tree Views</a></li><li><a href="/tutorials/file-browsing.html">File Browsing</a></li><li><a href="/tutorials/windows.html">Windows</a></li><li><a href="/tutorials/clipboard.html">Clipboard</a></li><li><a href="/tutorials/drag-and-drop.html">Drag and Drop</a></li><li><a href="/tutorials/effects.html">Effects</a></li><li><a href="/tutorials/effects.transitions.html">Transitions</a></li><li><a href="/tutorials/data-binding.html">Data Binding</a></li><li><a href="/tutorials/property-binding.html">Property Binding</a></li><li><a href="/tutorials/localization.html">Localization</a></li><li><a href="/tutorials/background-tasks.html">Background Tasks</a></li><li><a href="/tutorials/web-queries.ht
 ml">Web Queries</a></li><li><a href="/tutorials/query-servlet.html">QueryServlet</a></li><li><a href="/tutorials/scripting.html">Scripting</a></li><li><a href="/tutorials/summary.html">Summary</a></li><li><a href="/tutorials/stock-tracker.html">The "Stock Tracker" Application</a></li><li><a href="/tutorials/stock-tracker.ui.html">UI Markup Using BXML</a></li><li><a href="/tutorials/stock-tracker.events.html">Event Handling</a></li><li><a href="/tutorials/stock-tracker.web-queries.html">Web Queries</a></li><li><a href="/tutorials/stock-tracker.data-binding.html">Data Binding</a></li><li><a href="/tutorials/stock-tracker.localization.html">Localization</a></li><li><a href="/tutorials/bxml-primer.html">BXML Primer</a></li></ul><div class="content"><style type="text/css">
+            applet {
+                border: 1px solid #999999;
+            }
+        </style><!--NOTE: Syntax highlighting script is LGPL--><script src="http://alexgorbatchev.com/pub/sh/current/scripts/shCore.js" type="text/javascript"></script><script src="http://alexgorbatchev.com/pub/sh/current/scripts/shBrushJava.js" type="text/javascript"></script><script src="http://alexgorbatchev.com/pub/sh/current/scripts/shBrushXml.js" type="text/javascript"></script><script src="http://alexgorbatchev.com/pub/sh/current/scripts/shBrushJScript.js" type="text/javascript"></script><link href="http://alexgorbatchev.com/pub/sh/current/styles/shCore.css" rel="stylesheet" type="text/css"><link href="http://alexgorbatchev.com/pub/sh/current/styles/shThemeDefault.css" rel="stylesheet" type="text/css"><script type="text/javascript">
+            SyntaxHighlighter.all();
+        </script><div class="section">
+        <p>
+            Expanders are often used to present small amounts of information to the user. Since the
+            information may not be relevant to the user all the time, expanders allow the user to
+            "collapse" the panel to make more room for other content, similar to rolling up a
+            window shade. The following example demonstrates the use of the <tt>Expander</tt>
+            component:
+        </p>
+
+        <script src="http://java.com/js/deployJava.js" type="text/javascript"></script><script type="text/javascript">
+            
+            var attributes = {
+                code:"org.apache.pivot.wtk.BrowserApplicationContext$HostApplet",
+                width:"220",
+                height:"360"
+            };
+
+            
+            
+
+            
+            var libraries = [];
+            libraries.push("/lib/pivot-core-2.0.jar");
+                libraries.push("/lib/pivot-wtk-2.0.jar");
+                libraries.push("/lib/pivot-wtk-terra-2.0.jar");
+                libraries.push("/lib/pivot-tutorials-2.0.jar");
+                
+                    libraries.push("/lib/svgSalamander-tiny.jar");
+                
+
+            attributes.archive = libraries.join(",");
+
+            
+            var parameters = {
+                codebase_lookup:false,
+                application_class_name:'org.apache.pivot.wtk.ScriptApplication'
+            };
+
+            
+            var javaArguments = ["-Dsun.awt.noerasebackground=true",
+                "-Dsun.awt.erasebackgroundonresize=true"];
+
+            
+
+            parameters.java_arguments = javaArguments.join(" ");
+
+            
+            
+                var startupProperties = [];
+                
+                    startupProperties.push("src=/org/apache/pivot/tutorials/navigation/expanders.bxml");
+                
+                parameters.startup_properties = startupProperties.join("&");
+            
+
+            deployJava.runApplet(attributes, parameters, "1.6");
+        </script>
+
+        <p>
+            The BXML source for this example is as follows. It declares three expanders contained
+            in a vertical flow pane, which itself is contained in a scroll pane. The contents of
+            the expanders are defined in several external BXML files that are included by the main
+            file:
+        </p>
+
+        <pre class="brush:xml">
+            
+            &lt;Window title="Expanders" maximized="true"
+                xmlns:bxml="http://pivot.apache.org/bxml"
+                xmlns="org.apache.pivot.wtk"&gt;
+                &lt;Border styles="{padding:6}"&gt;
+                    &lt;ScrollPane horizontalScrollBarPolicy="fill"&gt;
+                        &lt;BoxPane orientation="vertical" styles="{fill:true,
+                            padding:{left:2, right:2}}"&gt;
+                            &lt;Expander bxml:id="stocksExpander" title="Stocks"&gt;
+                                &lt;bxml:include src="stocks.bxml"/&gt;
+                            &lt;/Expander&gt;
+                            &lt;Expander bxml:id="weatherExpander" title="Weather" expanded="false"&gt;
+                                &lt;bxml:include src="weather.bxml"/&gt;
+                            &lt;/Expander&gt;
+                            &lt;Expander bxml:id="calendarExpander" title="Calendar" expanded="false"&gt;
+                                &lt;Calendar/&gt;
+                            &lt;/Expander&gt;
+                        &lt;/BoxPane&gt;
+                    &lt;/ScrollPane&gt;
+                &lt;/Border&gt;
+            &lt;/Window&gt;
+            
+        </pre>
+
+        <p>
+            Since this example does not require any logic, there is no associated Java or script
+            code.
+        </p>
+    </div><p>Next: <a href="rollups.html">Rollups</a></p></div></div></div><div class="group" id="footer"><div class="footerLogo">Copyright (c) 1999-2011<br>The Apache Software Foundation.</div><div class="footerLinks"><ul class="footerMenuGr"><li><strong>Demos</strong><ul><li><a href="/demos/kitchen-sink.html" target="_new">"Kitchen Sink"</a></li><li><a href="/demos/component-explorer.html" target="_new">Component Explorer</a></li><li><a href="http://ixnay.biz/pivot-jfree-demos/charts_demo.html" target="_new">Charting</a></li><li><a href="/demos/">More Demos</a></li></ul></li><li><strong>Documentation</strong><ul><li><a href="/getting-started.html">Getting Started</a></li><li><a href="/tutorials/">Tutorial</a></li><li><a href="/faq.html">FAQ</a></li><li><a href="/2.0/docs/api/">Javadoc (2.0)</a></li></ul></li><li><strong>Get Involved</strong><ul><li><a href="/svn.html">SVN Repositories</a></li><li><a href="/lists.html">Mailing Lists</a></li><li><a href="http://issues.apache
 .org/jira/browse/PIVOT">Bug Database</a></li><li><a href="http://cwiki.apache.org/PIVOT/">Wiki</a></li></ul></li><li><strong>Related</strong><ul><li><a href="http://code.google.com/p/pivot-jfree/">JFreeChart Provider</a></li></ul></li><li><strong>About</strong><ul><li><a href="/who-we-are.html">Who We Are</a></li><li><a href="/contact.html">Contact</a></li><li><a href="/news.html">News</a></li><li><a href="/legal.html">Legal/License</a></li></ul></li></ul></div></div></div></body></html>
\ No newline at end of file

Added: pivot/site/trunk/deploy/tutorials/file-browsing.html
URL: http://svn.apache.org/viewvc/pivot/site/trunk/deploy/tutorials/file-browsing.html?rev=1067847&view=auto
==============================================================================
--- pivot/site/trunk/deploy/tutorials/file-browsing.html (added)
+++ pivot/site/trunk/deploy/tutorials/file-browsing.html Mon Feb  7 02:36:04 2011
@@ -0,0 +1,217 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<!--
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to you under the Apache License,
+Version 2.0 (the "License"); you may not use this file except in
+compliance with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+--><html xmlns="http://www.w3.org/1999/xhtml"><head><meta content="text/html; charset=UTF-8" http-equiv="Content-Type" /><title>File Browsing | Apache Pivot</title><link xmlns="" type="text/css" rel="stylesheet" href="/styles/pivot.css"><script xmlns="http://www.w3.org/1999/xhtml" type="text/javascript">
+                var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
+                document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
+                </script><script type="text/javascript">
+                try {
+                var pageTracker = _gat._getTracker("UA-7977275-3");
+                pageTracker._trackPageview();
+                } catch(err) {}</script></head><body><div xmlns="" id="wrapper"><div id="main"><div id="header"><div class="logo"><a href="/index.html"><img title="Apache Pivot Homepage" alt="Apache Pivot" src="/images/logo.png"></a></div><div class="tagline"><img style="visibility:hidden" alt="Rich Internet Applications in Java" src="/images/tagline.png"></div><ul class="navi"><li><a href="/demos/">Demos</a></li><li><a href="/download.cgi#2.0">Download</a></li><li><a href="/tutorials/">Tutorial</a></li><li><a href="/get-involved.html">Get Involved</a></li><li><a href="/about.html">About</a></li></ul></div><div class="group" id="contentBase"><h1>File Browsing</h1><ul class="naviLeft"><li><a href="/tutorials/sample-application.html">Sample Application</a></li><li><a href="/tutorials/platform-overview.html">Platform Overview</a></li><li><a href="/tutorials/hello-world.html">Hello, World!</a></li><li><a href="/tutorials/hello-bxml.html">Hello, BXML!</a></li><li><a href="/tutori
 als/component-and-container.html">Component &amp; Container</a></li><li><a href="/tutorials/labels-and-image-views.html">Labels &amp; Image Views</a></li><li><a href="/tutorials/svg-images.html">SVG Images</a></li><li><a href="/tutorials/buttons.html">Buttons</a></li><li><a href="/tutorials/push-buttons.html">Push Buttons</a></li><li><a href="/tutorials/toggle-buttons.html">Toggle Buttons</a></li><li><a href="/tutorials/radio-buttons.html">Radio Buttons</a></li><li><a href="/tutorials/checkboxes.html">Checkboxes</a></li><li><a href="/tutorials/link-buttons.html">Link Buttons</a></li><li><a href="/tutorials/lists.html">Lists</a></li><li><a href="/tutorials/list-buttons.html">List Buttons</a></li><li><a href="/tutorials/repeatable-list-buttons.html">Repeatable List Buttons</a></li><li><a href="/tutorials/text.html">Text</a></li><li><a href="/tutorials/suggestion-popups.html">Suggestion Popups</a></li><li><a href="/tutorials/text-areas.html">Text Areas</a></li><li><a href="/tut
 orials/separators.html">Separators</a></li><li><a href="/tutorials/layout-containers.html">Layout Containers</a></li><li><a href="/tutorials/flow-panes.html">Flow Panes</a></li><li><a href="/tutorials/box-panes.html">Box Panes</a></li><li><a href="/tutorials/grid-panes.html">Grid Panes</a></li><li><a href="/tutorials/table-panes.html">Table Panes</a></li><li><a href="/tutorials/borders.html">Borders</a></li><li><a href="/tutorials/stack-panes.html">Stack Panes</a></li><li><a href="/tutorials/split-panes.html">Split Panes</a></li><li><a href="/tutorials/forms.html">Forms</a></li><li><a href="/tutorials/panels.html">Panels</a></li><li><a href="/tutorials/navigation-containers.html">Navigation Containers</a></li><li><a href="/tutorials/card-panes.html">Card Panes</a></li><li><a href="/tutorials/tab-panes.html">Tab Panes</a></li><li><a href="/tutorials/accordions.html">Accordions</a></li><li><a href="/tutorials/expanders.html">Expanders</a></li><li><a href="/tutorials/rollups.ht
 ml">Rollups</a></li><li><a href="/tutorials/viewports.html">Viewports</a></li><li><a href="/tutorials/scroll-panes.html">Scroll Panes</a></li><li><a href="/tutorials/panoramas.html">Panoramas</a></li><li><a href="/tutorials/progress-indicators.html">Progress Indicators</a></li><li><a href="/tutorials/meters.html">Meters</a></li><li><a href="/tutorials/activity-indicators.html">Activity Indicators</a></li><li><a href="/tutorials/bounded-range-components.html">Bounded Range Components</a></li><li><a href="/tutorials/sliders.html">Sliders</a></li><li><a href="/tutorials/scroll-bars.html">Scroll Bars</a></li><li><a href="/tutorials/spinners.html">Spinners</a></li><li><a href="/tutorials/calendars.html">Calendars</a></li><li><a href="/tutorials/menus.html">Menus</a></li><li><a href="/tutorials/context-menus.html">Context Menus</a></li><li><a href="/tutorials/menu-bars.html">Menu Bars</a></li><li><a href="/tutorials/menu-buttons.html">Menu Buttons</a></li><li><a href="/tutorials/c
 olor-choosers.html">Color Choosers</a></li><li><a href="/tutorials/table-views.html">Table Views</a></li><li><a href="/tutorials/table-views.json.html">JSON-based TableView</a></li><li><a href="/tutorials/table-views.custom.html">Custom TableView</a></li><li><a href="/tutorials/tree-views.html">Tree Views</a></li><li><a href="/tutorials/file-browsing.html">File Browsing</a></li><li><a href="/tutorials/windows.html">Windows</a></li><li><a href="/tutorials/clipboard.html">Clipboard</a></li><li><a href="/tutorials/drag-and-drop.html">Drag and Drop</a></li><li><a href="/tutorials/effects.html">Effects</a></li><li><a href="/tutorials/effects.transitions.html">Transitions</a></li><li><a href="/tutorials/data-binding.html">Data Binding</a></li><li><a href="/tutorials/property-binding.html">Property Binding</a></li><li><a href="/tutorials/localization.html">Localization</a></li><li><a href="/tutorials/background-tasks.html">Background Tasks</a></li><li><a href="/tutorials/web-querie
 s.html">Web Queries</a></li><li><a href="/tutorials/query-servlet.html">QueryServlet</a></li><li><a href="/tutorials/scripting.html">Scripting</a></li><li><a href="/tutorials/summary.html">Summary</a></li><li><a href="/tutorials/stock-tracker.html">The "Stock Tracker" Application</a></li><li><a href="/tutorials/stock-tracker.ui.html">UI Markup Using BXML</a></li><li><a href="/tutorials/stock-tracker.events.html">Event Handling</a></li><li><a href="/tutorials/stock-tracker.web-queries.html">Web Queries</a></li><li><a href="/tutorials/stock-tracker.data-binding.html">Data Binding</a></li><li><a href="/tutorials/stock-tracker.localization.html">Localization</a></li><li><a href="/tutorials/bxml-primer.html">BXML Primer</a></li></ul><div class="content"><style type="text/css">
+            applet {
+                border: 1px solid #999999;
+            }
+        </style><!--NOTE: Syntax highlighting script is LGPL--><script src="http://alexgorbatchev.com/pub/sh/current/scripts/shCore.js" type="text/javascript"></script><script src="http://alexgorbatchev.com/pub/sh/current/scripts/shBrushJava.js" type="text/javascript"></script><script src="http://alexgorbatchev.com/pub/sh/current/scripts/shBrushXml.js" type="text/javascript"></script><script src="http://alexgorbatchev.com/pub/sh/current/scripts/shBrushJScript.js" type="text/javascript"></script><link href="http://alexgorbatchev.com/pub/sh/current/styles/shCore.css" rel="stylesheet" type="text/css"><link href="http://alexgorbatchev.com/pub/sh/current/styles/shThemeDefault.css" rel="stylesheet" type="text/css"><script type="text/javascript">
+            SyntaxHighlighter.all();
+        </script><div class="section">
+        <p>
+            Pivot includes support for easily adding local file system access to an application.
+            The following example demonstrates the use of the <tt>FileBrowserSheet</tt> class:
+        </p>
+
+        <script src="http://java.com/js/deployJava.js" type="text/javascript"></script><script type="text/javascript">
+            
+            var attributes = {
+                code:"org.apache.pivot.wtk.BrowserApplicationContext$HostApplet",
+                width:"640",
+                height:"480"
+            };
+
+            
+            
+
+            
+            var libraries = [];
+            libraries.push("/lib/pivot-core-2.0.signed.jar");
+                libraries.push("/lib/pivot-wtk-2.0.signed.jar");
+                libraries.push("/lib/pivot-wtk-terra-2.0.signed.jar");
+                libraries.push("/lib/pivot-tutorials-2.0.signed.jar");
+                
+                    libraries.push("/lib/svgSalamander-tiny.signed.jar");
+                
+
+            attributes.archive = libraries.join(",");
+
+            
+            var parameters = {
+                codebase_lookup:false,
+                application_class_name:'org.apache.pivot.wtk.ScriptApplication'
+            };
+
+            
+            var javaArguments = ["-Dsun.awt.noerasebackground=true",
+                "-Dsun.awt.erasebackgroundonresize=true"];
+
+            
+
+            parameters.java_arguments = javaArguments.join(" ");
+
+            
+            
+                var startupProperties = [];
+                
+                    startupProperties.push("src=/org/apache/pivot/tutorials/filebrowsing/file_browsing.bxml");
+                
+                parameters.startup_properties = startupProperties.join("&");
+            
+
+            deployJava.runApplet(attributes, parameters, "1.6");
+        </script>
+
+        <p>
+            It allows the user to browse the local file system using one of four supported modes:
+        </p>
+
+        <ul>
+            <li><p><b>Open</b> - select a single file to open</p></li>
+            <li><p><b>Open Multiple</b> - select multiple files to open</p></li>
+            <li><p><b>Save As</b> - select a file name to save as</p></li>
+            <li><p><b>Save To</b> - select a folder to save to</p></li>
+        </ul>
+
+        <p>
+            The BXML source for the application is as follows:
+        </p>
+
+        <pre class="brush:xml">
+            
+            &lt;filebrowsing:FileBrowsing title="File Browsing" maximized="true"
+                xmlns:bxml="http://pivot.apache.org/bxml"
+                xmlns:filebrowsing="org.apache.pivot.tutorials.filebrowsing"
+                xmlns="org.apache.pivot.wtk"&gt;
+                &lt;bxml:define&gt;
+                    &lt;ButtonGroup bxml:id="fileBrowserSheetModeGroup"/&gt;
+                &lt;/bxml:define&gt;
+
+                &lt;Border styles="{padding:6}"&gt;
+                    &lt;BoxPane orientation="vertical" styles="{spacing:6}"&gt;
+                        &lt;Label text="Mode:" styles="{font:{bold:true}}"/&gt;
+
+                        &lt;RadioButton buttonData="Open" buttonGroup="$fileBrowserSheetModeGroup" selected="true"&gt;
+                            &lt;userData mode="open"/&gt;
+                        &lt;/RadioButton&gt;
+                        &lt;RadioButton buttonData="Open Multiple" buttonGroup="$fileBrowserSheetModeGroup"&gt;
+                            &lt;userData mode="open_multiple"/&gt;
+                        &lt;/RadioButton&gt;
+                        &lt;RadioButton buttonData="Save As" buttonGroup="$fileBrowserSheetModeGroup"&gt;
+                            &lt;userData mode="save_as"/&gt;
+                        &lt;/RadioButton&gt;
+                        &lt;RadioButton buttonData="Save To" buttonGroup="$fileBrowserSheetModeGroup"&gt;
+                            &lt;userData mode="save_to"/&gt;
+                        &lt;/RadioButton&gt;
+
+                        &lt;PushButton bxml:id="openSheetButton" buttonData="Open Sheet"/&gt;
+                    &lt;/BoxPane&gt;
+                &lt;/Border&gt;
+            &lt;/filebrowsing:FileBrowsing&gt;
+            
+        </pre>
+
+        <p>
+            The Java source code is shown below. When the user presses the "Open Sheet" button,
+            it creates a <tt>FileBrowserSheet</tt> using the selected mode and opens the sheet.
+            When the sheet is closed, it simply displays an alert to the user reflecting the
+            selection:
+        </p>
+
+        <pre class="brush:java">
+            
+            package org.apache.pivot.tutorials.filebrowsing;
+
+            import java.io.File;
+            import java.net.URL;
+
+            import org.apache.pivot.beans.BXML;
+            import org.apache.pivot.beans.Bindable;
+            import org.apache.pivot.collections.ArrayList;
+            import org.apache.pivot.collections.Map;
+            import org.apache.pivot.collections.Sequence;
+            import org.apache.pivot.util.Resources;
+            import org.apache.pivot.wtk.Alert;
+            import org.apache.pivot.wtk.Button;
+            import org.apache.pivot.wtk.ButtonGroup;
+            import org.apache.pivot.wtk.ButtonPressListener;
+            import org.apache.pivot.wtk.FileBrowserSheet;
+            import org.apache.pivot.wtk.ListView;
+            import org.apache.pivot.wtk.MessageType;
+            import org.apache.pivot.wtk.PushButton;
+            import org.apache.pivot.wtk.Sheet;
+            import org.apache.pivot.wtk.SheetCloseListener;
+            import org.apache.pivot.wtk.Window;
+
+            public class FileBrowsing extends Window implements Bindable {
+                @BXML private ButtonGroup fileBrowserSheetModeGroup = null;
+                @BXML private PushButton openSheetButton = null;
+
+                @Override
+                public void initialize(Map&lt;String, Object&gt; namespace, URL location, Resources resources) {
+                    openSheetButton.getButtonPressListeners().add(new ButtonPressListener() {
+                        @Override
+                        public void buttonPressed(Button button) {
+                            Button selection = fileBrowserSheetModeGroup.getSelection();
+
+                            String mode = (String)selection.getUserData().get("mode");
+                            FileBrowserSheet.Mode fileBrowserSheetMode = FileBrowserSheet.Mode.valueOf(mode.toUpperCase());
+                            final FileBrowserSheet fileBrowserSheet = new FileBrowserSheet();
+
+                            if (fileBrowserSheetMode == FileBrowserSheet.Mode.SAVE_AS) {
+                                fileBrowserSheet.setSelectedFile(new File(fileBrowserSheet.getRootDirectory(), "New File"));
+                            }
+
+                            fileBrowserSheet.setMode(fileBrowserSheetMode);
+                            fileBrowserSheet.open(FileBrowsing.this, new SheetCloseListener() {
+                                @Override
+                                public void sheetClosed(Sheet sheet) {
+                                    if (sheet.getResult()) {
+                                        Sequence&lt;File&gt; selectedFiles = fileBrowserSheet.getSelectedFiles();
+
+                                        ListView listView = new ListView();
+                                        listView.setListData(new ArrayList&lt;File&gt;(selectedFiles));
+                                        listView.setSelectMode(ListView.SelectMode.NONE);
+                                        listView.getStyles().put("backgroundColor", null);
+
+                                        Alert.alert(MessageType.INFO, "You selected:", listView, FileBrowsing.this);
+                                    } else {
+                                        Alert.alert(MessageType.INFO, "You didn't select anything.", FileBrowsing.this);
+                                    }
+                                }
+                            });
+                        }
+                    });
+                }
+            }
+            
+        </pre>
+
+        <p>
+            Note that, internally, <tt>FileBrowserSheet</tt> uses an instance of the
+            <tt>org.apache.pivot.wtk.FileBrowser</tt> class to perform the actual file system
+            navigation. It is actually possible to use this component directly within an
+            application to create a custom file browser; however, a discussion of the
+            <tt>FileBrowser</tt> class is outside the scope of this tutorial.
+        </p>
+    </div><p>Next: <a href="windows.html">Windows</a></p></div></div></div><div class="group" id="footer"><div class="footerLogo">Copyright (c) 1999-2011<br>The Apache Software Foundation.</div><div class="footerLinks"><ul class="footerMenuGr"><li><strong>Demos</strong><ul><li><a href="/demos/kitchen-sink.html" target="_new">"Kitchen Sink"</a></li><li><a href="/demos/component-explorer.html" target="_new">Component Explorer</a></li><li><a href="http://ixnay.biz/pivot-jfree-demos/charts_demo.html" target="_new">Charting</a></li><li><a href="/demos/">More Demos</a></li></ul></li><li><strong>Documentation</strong><ul><li><a href="/getting-started.html">Getting Started</a></li><li><a href="/tutorials/">Tutorial</a></li><li><a href="/faq.html">FAQ</a></li><li><a href="/2.0/docs/api/">Javadoc (2.0)</a></li></ul></li><li><strong>Get Involved</strong><ul><li><a href="/svn.html">SVN Repositories</a></li><li><a href="/lists.html">Mailing Lists</a></li><li><a href="http://issues.apache
 .org/jira/browse/PIVOT">Bug Database</a></li><li><a href="http://cwiki.apache.org/PIVOT/">Wiki</a></li></ul></li><li><strong>Related</strong><ul><li><a href="http://code.google.com/p/pivot-jfree/">JFreeChart Provider</a></li></ul></li><li><strong>About</strong><ul><li><a href="/who-we-are.html">Who We Are</a></li><li><a href="/contact.html">Contact</a></li><li><a href="/news.html">News</a></li><li><a href="/legal.html">Legal/License</a></li></ul></li></ul></div></div></div></body></html>
\ No newline at end of file

Added: pivot/site/trunk/deploy/tutorials/flow-panes.html
URL: http://svn.apache.org/viewvc/pivot/site/trunk/deploy/tutorials/flow-panes.html?rev=1067847&view=auto
==============================================================================
--- pivot/site/trunk/deploy/tutorials/flow-panes.html (added)
+++ pivot/site/trunk/deploy/tutorials/flow-panes.html Mon Feb  7 02:36:04 2011
@@ -0,0 +1,223 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<!--
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to you under the Apache License,
+Version 2.0 (the "License"); you may not use this file except in
+compliance with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+--><html xmlns="http://www.w3.org/1999/xhtml"><head><meta content="text/html; charset=UTF-8" http-equiv="Content-Type" /><title>Flow Panes | Apache Pivot</title><link xmlns="" type="text/css" rel="stylesheet" href="/styles/pivot.css"><script xmlns="http://www.w3.org/1999/xhtml" type="text/javascript">
+                var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
+                document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
+                </script><script type="text/javascript">
+                try {
+                var pageTracker = _gat._getTracker("UA-7977275-3");
+                pageTracker._trackPageview();
+                } catch(err) {}</script></head><body><div xmlns="" id="wrapper"><div id="main"><div id="header"><div class="logo"><a href="/index.html"><img title="Apache Pivot Homepage" alt="Apache Pivot" src="/images/logo.png"></a></div><div class="tagline"><img style="visibility:hidden" alt="Rich Internet Applications in Java" src="/images/tagline.png"></div><ul class="navi"><li><a href="/demos/">Demos</a></li><li><a href="/download.cgi#2.0">Download</a></li><li><a href="/tutorials/">Tutorial</a></li><li><a href="/get-involved.html">Get Involved</a></li><li><a href="/about.html">About</a></li></ul></div><div class="group" id="contentBase"><h1>Flow Panes</h1><ul class="naviLeft"><li><a href="/tutorials/sample-application.html">Sample Application</a></li><li><a href="/tutorials/platform-overview.html">Platform Overview</a></li><li><a href="/tutorials/hello-world.html">Hello, World!</a></li><li><a href="/tutorials/hello-bxml.html">Hello, BXML!</a></li><li><a href="/tutorials
 /component-and-container.html">Component &amp; Container</a></li><li><a href="/tutorials/labels-and-image-views.html">Labels &amp; Image Views</a></li><li><a href="/tutorials/svg-images.html">SVG Images</a></li><li><a href="/tutorials/buttons.html">Buttons</a></li><li><a href="/tutorials/push-buttons.html">Push Buttons</a></li><li><a href="/tutorials/toggle-buttons.html">Toggle Buttons</a></li><li><a href="/tutorials/radio-buttons.html">Radio Buttons</a></li><li><a href="/tutorials/checkboxes.html">Checkboxes</a></li><li><a href="/tutorials/link-buttons.html">Link Buttons</a></li><li><a href="/tutorials/lists.html">Lists</a></li><li><a href="/tutorials/list-buttons.html">List Buttons</a></li><li><a href="/tutorials/repeatable-list-buttons.html">Repeatable List Buttons</a></li><li><a href="/tutorials/text.html">Text</a></li><li><a href="/tutorials/suggestion-popups.html">Suggestion Popups</a></li><li><a href="/tutorials/text-areas.html">Text Areas</a></li><li><a href="/tutori
 als/separators.html">Separators</a></li><li><a href="/tutorials/layout-containers.html">Layout Containers</a></li><li><a href="/tutorials/flow-panes.html">Flow Panes</a></li><li><a href="/tutorials/box-panes.html">Box Panes</a></li><li><a href="/tutorials/grid-panes.html">Grid Panes</a></li><li><a href="/tutorials/table-panes.html">Table Panes</a></li><li><a href="/tutorials/borders.html">Borders</a></li><li><a href="/tutorials/stack-panes.html">Stack Panes</a></li><li><a href="/tutorials/split-panes.html">Split Panes</a></li><li><a href="/tutorials/forms.html">Forms</a></li><li><a href="/tutorials/panels.html">Panels</a></li><li><a href="/tutorials/navigation-containers.html">Navigation Containers</a></li><li><a href="/tutorials/card-panes.html">Card Panes</a></li><li><a href="/tutorials/tab-panes.html">Tab Panes</a></li><li><a href="/tutorials/accordions.html">Accordions</a></li><li><a href="/tutorials/expanders.html">Expanders</a></li><li><a href="/tutorials/rollups.html"
 >Rollups</a></li><li><a href="/tutorials/viewports.html">Viewports</a></li><li><a href="/tutorials/scroll-panes.html">Scroll Panes</a></li><li><a href="/tutorials/panoramas.html">Panoramas</a></li><li><a href="/tutorials/progress-indicators.html">Progress Indicators</a></li><li><a href="/tutorials/meters.html">Meters</a></li><li><a href="/tutorials/activity-indicators.html">Activity Indicators</a></li><li><a href="/tutorials/bounded-range-components.html">Bounded Range Components</a></li><li><a href="/tutorials/sliders.html">Sliders</a></li><li><a href="/tutorials/scroll-bars.html">Scroll Bars</a></li><li><a href="/tutorials/spinners.html">Spinners</a></li><li><a href="/tutorials/calendars.html">Calendars</a></li><li><a href="/tutorials/menus.html">Menus</a></li><li><a href="/tutorials/context-menus.html">Context Menus</a></li><li><a href="/tutorials/menu-bars.html">Menu Bars</a></li><li><a href="/tutorials/menu-buttons.html">Menu Buttons</a></li><li><a href="/tutorials/colo
 r-choosers.html">Color Choosers</a></li><li><a href="/tutorials/table-views.html">Table Views</a></li><li><a href="/tutorials/table-views.json.html">JSON-based TableView</a></li><li><a href="/tutorials/table-views.custom.html">Custom TableView</a></li><li><a href="/tutorials/tree-views.html">Tree Views</a></li><li><a href="/tutorials/file-browsing.html">File Browsing</a></li><li><a href="/tutorials/windows.html">Windows</a></li><li><a href="/tutorials/clipboard.html">Clipboard</a></li><li><a href="/tutorials/drag-and-drop.html">Drag and Drop</a></li><li><a href="/tutorials/effects.html">Effects</a></li><li><a href="/tutorials/effects.transitions.html">Transitions</a></li><li><a href="/tutorials/data-binding.html">Data Binding</a></li><li><a href="/tutorials/property-binding.html">Property Binding</a></li><li><a href="/tutorials/localization.html">Localization</a></li><li><a href="/tutorials/background-tasks.html">Background Tasks</a></li><li><a href="/tutorials/web-queries.h
 tml">Web Queries</a></li><li><a href="/tutorials/query-servlet.html">QueryServlet</a></li><li><a href="/tutorials/scripting.html">Scripting</a></li><li><a href="/tutorials/summary.html">Summary</a></li><li><a href="/tutorials/stock-tracker.html">The "Stock Tracker" Application</a></li><li><a href="/tutorials/stock-tracker.ui.html">UI Markup Using BXML</a></li><li><a href="/tutorials/stock-tracker.events.html">Event Handling</a></li><li><a href="/tutorials/stock-tracker.web-queries.html">Web Queries</a></li><li><a href="/tutorials/stock-tracker.data-binding.html">Data Binding</a></li><li><a href="/tutorials/stock-tracker.localization.html">Localization</a></li><li><a href="/tutorials/bxml-primer.html">BXML Primer</a></li></ul><div class="content"><style type="text/css">
+            applet {
+                border: 1px solid #999999;
+            }
+        </style><!--NOTE: Syntax highlighting script is LGPL--><script src="http://alexgorbatchev.com/pub/sh/current/scripts/shCore.js" type="text/javascript"></script><script src="http://alexgorbatchev.com/pub/sh/current/scripts/shBrushJava.js" type="text/javascript"></script><script src="http://alexgorbatchev.com/pub/sh/current/scripts/shBrushXml.js" type="text/javascript"></script><script src="http://alexgorbatchev.com/pub/sh/current/scripts/shBrushJScript.js" type="text/javascript"></script><link href="http://alexgorbatchev.com/pub/sh/current/styles/shCore.css" rel="stylesheet" type="text/css"><link href="http://alexgorbatchev.com/pub/sh/current/styles/shThemeDefault.css" rel="stylesheet" type="text/css"><script type="text/javascript">
+            SyntaxHighlighter.all();
+        </script><div class="section">
+        <p>
+            Flow panes arrange components in a horizontal line, wrapping when the contents don't
+            fit on a single line. Components may be horizontally aligned to left, right, or center
+            when there is space left over within a given line, and may optionally be vertically
+            aligned by to their baselines.
+        </p>
+
+        <p>
+            The following example demonstrates the use of the <tt>FlowPane</tt> container. The
+            buttons on the right can be used to modify the alignment properties. A
+            <tt>BaselineDecorator</tt> is used to highlight the flow pane's baseline. This
+            decorator draws a red line across a component's baseline. If the component does not
+            have a baseline, it draws a blue line across the component's vertical midpoint:
+        </p>
+
+        <script src="http://java.com/js/deployJava.js" type="text/javascript"></script><script type="text/javascript">
+            
+            var attributes = {
+                code:"org.apache.pivot.wtk.BrowserApplicationContext$HostApplet",
+                width:"512",
+                height:"240"
+            };
+
+            
+            
+
+            
+            var libraries = [];
+            libraries.push("/lib/pivot-core-2.0.jar");
+                libraries.push("/lib/pivot-wtk-2.0.jar");
+                libraries.push("/lib/pivot-wtk-terra-2.0.jar");
+                libraries.push("/lib/pivot-tutorials-2.0.jar");
+                
+                    libraries.push("/lib/svgSalamander-tiny.jar");
+                
+
+            attributes.archive = libraries.join(",");
+
+            
+            var parameters = {
+                codebase_lookup:false,
+                application_class_name:'org.apache.pivot.wtk.ScriptApplication'
+            };
+
+            
+            var javaArguments = ["-Dsun.awt.noerasebackground=true",
+                "-Dsun.awt.erasebackgroundonresize=true"];
+
+            
+
+            parameters.java_arguments = javaArguments.join(" ");
+
+            
+            
+                var startupProperties = [];
+                
+                    startupProperties.push("src=/org/apache/pivot/tutorials/layout/flow_panes.bxml");
+                
+                parameters.startup_properties = startupProperties.join("&");
+            
+
+            deployJava.runApplet(attributes, parameters, "1.6");
+        </script>
+
+        <p>
+            The BXML source for this example is shown below:
+        </p>
+
+        <pre class="brush:xml">
+            
+            &lt;layout:FlowPanes title="Flow Panes" maximized="true"
+                xmlns:bxml="http://pivot.apache.org/bxml"
+                xmlns:effects="org.apache.pivot.wtk.effects"
+                xmlns:layout="org.apache.pivot.tutorials.layout"
+                xmlns="org.apache.pivot.wtk"&gt;
+                &lt;SplitPane splitRatio="0.75"&gt;
+                    &lt;left&gt;
+                        &lt;Border styles="{padding:4}"&gt;
+                            &lt;BoxPane orientation="vertical" styles="{fill:true}"&gt;
+                                &lt;FlowPane bxml:id="flowPane" styles="{padding:2}"&gt;
+                                    &lt;decorators&gt;
+                                        &lt;effects:BaselineDecorator/&gt;
+                                    &lt;/decorators&gt;
+
+                                    &lt;PushButton buttonData="0" styles="{minimumAspectRatio:1.5}"/&gt;
+                                    &lt;PushButton buttonData="1" styles="{minimumAspectRatio:1.5}"/&gt;
+                                    &lt;PushButton buttonData="2" styles="{minimumAspectRatio:1.5}"/&gt;
+                                    &lt;PushButton buttonData="3" preferredWidth="20" preferredHeight="20"/&gt;
+                                    &lt;PushButton buttonData="4" preferredWidth="30" preferredHeight="30"/&gt;
+                                    &lt;PushButton buttonData="5" preferredWidth="40" preferredHeight="40"/&gt;
+                                    &lt;PushButton buttonData="6" styles="{minimumAspectRatio:1.5}"/&gt;
+                                    &lt;PushButton buttonData="7" styles="{minimumAspectRatio:1.5}"/&gt;
+                                &lt;/FlowPane&gt;
+                            &lt;/BoxPane&gt;
+                        &lt;/Border&gt;
+                    &lt;/left&gt;
+
+                    &lt;right&gt;
+                        &lt;Border styles="{padding:{top:2, left:6}}"&gt;
+                            &lt;BoxPane orientation="vertical"&gt;
+                                &lt;Label text="Alignment" styles="{font:{bold:true}}"/&gt;
+
+                                &lt;bxml:define&gt;
+                                    &lt;ButtonGroup bxml:id="alignment"/&gt;
+                                &lt;/bxml:define&gt;
+                                &lt;RadioButton bxml:id="leftRadioButton" buttonData="Left" buttonGroup="$alignment" selected="true"/&gt;
+                                &lt;RadioButton bxml:id="rightRadioButton" buttonData="Right" buttonGroup="$alignment"/&gt;
+                                &lt;RadioButton bxml:id="centerRadioButton" buttonData="Center" buttonGroup="$alignment"/&gt;
+
+                                &lt;BoxPane styles="{padding:{top:6}}"&gt;
+                                    &lt;Checkbox bxml:id="alignToBaselineCheckbox" buttonData="Align to baseline"/&gt;
+                                &lt;/BoxPane&gt;
+                            &lt;/BoxPane&gt;
+                    &lt;/Border&gt;
+                    &lt;/right&gt;
+                &lt;/SplitPane&gt;
+            &lt;/layout:FlowPanes&gt;
+            
+        </pre>
+
+        <p>
+            The Java source is as follows. It wires up the event handlers that respond to changes
+            in the radio buttons' state:
+        </p>
+
+        <pre class="brush:java">
+            
+            package org.apache.pivot.tutorials.layout;
+
+            import java.net.URL;
+
+            import org.apache.pivot.beans.Bindable;
+            import org.apache.pivot.collections.Map;
+            import org.apache.pivot.util.Resources;
+            import org.apache.pivot.wtk.Button;
+            import org.apache.pivot.wtk.ButtonStateListener;
+            import org.apache.pivot.wtk.Checkbox;
+            import org.apache.pivot.wtk.FlowPane;
+            import org.apache.pivot.wtk.HorizontalAlignment;
+            import org.apache.pivot.wtk.RadioButton;
+            import org.apache.pivot.wtk.Window;
+
+            public class FlowPanes extends Window implements Bindable {
+                private FlowPane flowPane = null;
+                private RadioButton leftRadioButton = null;
+                private RadioButton rightRadioButton = null;
+                private RadioButton centerRadioButton = null;
+                private Checkbox alignToBaselineCheckbox = null;
+
+                @Override
+                public void initialize(Map&lt;String, Object&gt; namespace, URL location, Resources resources) {
+                    flowPane = (FlowPane)namespace.get("flowPane");
+                    leftRadioButton = (RadioButton)namespace.get("leftRadioButton");
+                    rightRadioButton = (RadioButton)namespace.get("rightRadioButton");
+                    centerRadioButton = (RadioButton)namespace.get("centerRadioButton");
+                    alignToBaselineCheckbox = (Checkbox)namespace.get("alignToBaselineCheckbox");
+
+                    ButtonStateListener buttonStateListener = new ButtonStateListener() {
+                        @Override
+                        public void stateChanged(Button button, Button.State previousState) {
+                            updateFlowPaneState();
+                        }
+                    };
+
+                    leftRadioButton.getButtonStateListeners().add(buttonStateListener);
+                    rightRadioButton.getButtonStateListeners().add(buttonStateListener);
+                    centerRadioButton.getButtonStateListeners().add(buttonStateListener);
+                    alignToBaselineCheckbox.getButtonStateListeners().add(buttonStateListener);
+
+                    updateFlowPaneState();
+                }
+
+                private void updateFlowPaneState() {
+                    HorizontalAlignment alignment = null;
+
+                    if (leftRadioButton.isSelected()) {
+                        alignment = HorizontalAlignment.LEFT;
+                    } else if (rightRadioButton.isSelected()) {
+                        alignment = HorizontalAlignment.RIGHT;
+                    } else if (centerRadioButton.isSelected()) {
+                        alignment = HorizontalAlignment.CENTER;
+                    }
+
+                    if (alignment != null) {
+                        flowPane.getStyles().put("alignment", alignment);
+                    }
+
+                    flowPane.getStyles().put("alignToBaseline", alignToBaselineCheckbox.isSelected());
+                }
+            }
+            
+        </pre>
+    </div><p>Next: <a href="box-panes.html">Box Panes</a></p></div></div></div><div class="group" id="footer"><div class="footerLogo">Copyright (c) 1999-2011<br>The Apache Software Foundation.</div><div class="footerLinks"><ul class="footerMenuGr"><li><strong>Demos</strong><ul><li><a href="/demos/kitchen-sink.html" target="_new">"Kitchen Sink"</a></li><li><a href="/demos/component-explorer.html" target="_new">Component Explorer</a></li><li><a href="http://ixnay.biz/pivot-jfree-demos/charts_demo.html" target="_new">Charting</a></li><li><a href="/demos/">More Demos</a></li></ul></li><li><strong>Documentation</strong><ul><li><a href="/getting-started.html">Getting Started</a></li><li><a href="/tutorials/">Tutorial</a></li><li><a href="/faq.html">FAQ</a></li><li><a href="/2.0/docs/api/">Javadoc (2.0)</a></li></ul></li><li><strong>Get Involved</strong><ul><li><a href="/svn.html">SVN Repositories</a></li><li><a href="/lists.html">Mailing Lists</a></li><li><a href="http://issues.ap
 ache.org/jira/browse/PIVOT">Bug Database</a></li><li><a href="http://cwiki.apache.org/PIVOT/">Wiki</a></li></ul></li><li><strong>Related</strong><ul><li><a href="http://code.google.com/p/pivot-jfree/">JFreeChart Provider</a></li></ul></li><li><strong>About</strong><ul><li><a href="/who-we-are.html">Who We Are</a></li><li><a href="/contact.html">Contact</a></li><li><a href="/news.html">News</a></li><li><a href="/legal.html">Legal/License</a></li></ul></li></ul></div></div></div></body></html>
\ No newline at end of file

Added: pivot/site/trunk/deploy/tutorials/forms.html
URL: http://svn.apache.org/viewvc/pivot/site/trunk/deploy/tutorials/forms.html?rev=1067847&view=auto
==============================================================================
--- pivot/site/trunk/deploy/tutorials/forms.html (added)
+++ pivot/site/trunk/deploy/tutorials/forms.html Mon Feb  7 02:36:04 2011
@@ -0,0 +1,278 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<!--
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to you under the Apache License,
+Version 2.0 (the "License"); you may not use this file except in
+compliance with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+--><html xmlns="http://www.w3.org/1999/xhtml"><head><meta content="text/html; charset=UTF-8" http-equiv="Content-Type" /><title>Forms | Apache Pivot</title><link xmlns="" type="text/css" rel="stylesheet" href="/styles/pivot.css"><script xmlns="http://www.w3.org/1999/xhtml" type="text/javascript">
+                var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
+                document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
+                </script><script type="text/javascript">
+                try {
+                var pageTracker = _gat._getTracker("UA-7977275-3");
+                pageTracker._trackPageview();
+                } catch(err) {}</script></head><body><div xmlns="" id="wrapper"><div id="main"><div id="header"><div class="logo"><a href="/index.html"><img title="Apache Pivot Homepage" alt="Apache Pivot" src="/images/logo.png"></a></div><div class="tagline"><img style="visibility:hidden" alt="Rich Internet Applications in Java" src="/images/tagline.png"></div><ul class="navi"><li><a href="/demos/">Demos</a></li><li><a href="/download.cgi#2.0">Download</a></li><li><a href="/tutorials/">Tutorial</a></li><li><a href="/get-involved.html">Get Involved</a></li><li><a href="/about.html">About</a></li></ul></div><div class="group" id="contentBase"><h1>Forms</h1><ul class="naviLeft"><li><a href="/tutorials/sample-application.html">Sample Application</a></li><li><a href="/tutorials/platform-overview.html">Platform Overview</a></li><li><a href="/tutorials/hello-world.html">Hello, World!</a></li><li><a href="/tutorials/hello-bxml.html">Hello, BXML!</a></li><li><a href="/tutorials/comp
 onent-and-container.html">Component &amp; Container</a></li><li><a href="/tutorials/labels-and-image-views.html">Labels &amp; Image Views</a></li><li><a href="/tutorials/svg-images.html">SVG Images</a></li><li><a href="/tutorials/buttons.html">Buttons</a></li><li><a href="/tutorials/push-buttons.html">Push Buttons</a></li><li><a href="/tutorials/toggle-buttons.html">Toggle Buttons</a></li><li><a href="/tutorials/radio-buttons.html">Radio Buttons</a></li><li><a href="/tutorials/checkboxes.html">Checkboxes</a></li><li><a href="/tutorials/link-buttons.html">Link Buttons</a></li><li><a href="/tutorials/lists.html">Lists</a></li><li><a href="/tutorials/list-buttons.html">List Buttons</a></li><li><a href="/tutorials/repeatable-list-buttons.html">Repeatable List Buttons</a></li><li><a href="/tutorials/text.html">Text</a></li><li><a href="/tutorials/suggestion-popups.html">Suggestion Popups</a></li><li><a href="/tutorials/text-areas.html">Text Areas</a></li><li><a href="/tutorials/s
 eparators.html">Separators</a></li><li><a href="/tutorials/layout-containers.html">Layout Containers</a></li><li><a href="/tutorials/flow-panes.html">Flow Panes</a></li><li><a href="/tutorials/box-panes.html">Box Panes</a></li><li><a href="/tutorials/grid-panes.html">Grid Panes</a></li><li><a href="/tutorials/table-panes.html">Table Panes</a></li><li><a href="/tutorials/borders.html">Borders</a></li><li><a href="/tutorials/stack-panes.html">Stack Panes</a></li><li><a href="/tutorials/split-panes.html">Split Panes</a></li><li><a href="/tutorials/forms.html">Forms</a></li><li><a href="/tutorials/panels.html">Panels</a></li><li><a href="/tutorials/navigation-containers.html">Navigation Containers</a></li><li><a href="/tutorials/card-panes.html">Card Panes</a></li><li><a href="/tutorials/tab-panes.html">Tab Panes</a></li><li><a href="/tutorials/accordions.html">Accordions</a></li><li><a href="/tutorials/expanders.html">Expanders</a></li><li><a href="/tutorials/rollups.html">Roll
 ups</a></li><li><a href="/tutorials/viewports.html">Viewports</a></li><li><a href="/tutorials/scroll-panes.html">Scroll Panes</a></li><li><a href="/tutorials/panoramas.html">Panoramas</a></li><li><a href="/tutorials/progress-indicators.html">Progress Indicators</a></li><li><a href="/tutorials/meters.html">Meters</a></li><li><a href="/tutorials/activity-indicators.html">Activity Indicators</a></li><li><a href="/tutorials/bounded-range-components.html">Bounded Range Components</a></li><li><a href="/tutorials/sliders.html">Sliders</a></li><li><a href="/tutorials/scroll-bars.html">Scroll Bars</a></li><li><a href="/tutorials/spinners.html">Spinners</a></li><li><a href="/tutorials/calendars.html">Calendars</a></li><li><a href="/tutorials/menus.html">Menus</a></li><li><a href="/tutorials/context-menus.html">Context Menus</a></li><li><a href="/tutorials/menu-bars.html">Menu Bars</a></li><li><a href="/tutorials/menu-buttons.html">Menu Buttons</a></li><li><a href="/tutorials/color-cho
 osers.html">Color Choosers</a></li><li><a href="/tutorials/table-views.html">Table Views</a></li><li><a href="/tutorials/table-views.json.html">JSON-based TableView</a></li><li><a href="/tutorials/table-views.custom.html">Custom TableView</a></li><li><a href="/tutorials/tree-views.html">Tree Views</a></li><li><a href="/tutorials/file-browsing.html">File Browsing</a></li><li><a href="/tutorials/windows.html">Windows</a></li><li><a href="/tutorials/clipboard.html">Clipboard</a></li><li><a href="/tutorials/drag-and-drop.html">Drag and Drop</a></li><li><a href="/tutorials/effects.html">Effects</a></li><li><a href="/tutorials/effects.transitions.html">Transitions</a></li><li><a href="/tutorials/data-binding.html">Data Binding</a></li><li><a href="/tutorials/property-binding.html">Property Binding</a></li><li><a href="/tutorials/localization.html">Localization</a></li><li><a href="/tutorials/background-tasks.html">Background Tasks</a></li><li><a href="/tutorials/web-queries.html">
 Web Queries</a></li><li><a href="/tutorials/query-servlet.html">QueryServlet</a></li><li><a href="/tutorials/scripting.html">Scripting</a></li><li><a href="/tutorials/summary.html">Summary</a></li><li><a href="/tutorials/stock-tracker.html">The "Stock Tracker" Application</a></li><li><a href="/tutorials/stock-tracker.ui.html">UI Markup Using BXML</a></li><li><a href="/tutorials/stock-tracker.events.html">Event Handling</a></li><li><a href="/tutorials/stock-tracker.web-queries.html">Web Queries</a></li><li><a href="/tutorials/stock-tracker.data-binding.html">Data Binding</a></li><li><a href="/tutorials/stock-tracker.localization.html">Localization</a></li><li><a href="/tutorials/bxml-primer.html">BXML Primer</a></li></ul><div class="content"><style type="text/css">
+            applet {
+                border: 1px solid #999999;
+            }
+        </style><!--NOTE: Syntax highlighting script is LGPL--><script src="http://alexgorbatchev.com/pub/sh/current/scripts/shCore.js" type="text/javascript"></script><script src="http://alexgorbatchev.com/pub/sh/current/scripts/shBrushJava.js" type="text/javascript"></script><script src="http://alexgorbatchev.com/pub/sh/current/scripts/shBrushXml.js" type="text/javascript"></script><script src="http://alexgorbatchev.com/pub/sh/current/scripts/shBrushJScript.js" type="text/javascript"></script><link href="http://alexgorbatchev.com/pub/sh/current/styles/shCore.css" rel="stylesheet" type="text/css"><link href="http://alexgorbatchev.com/pub/sh/current/styles/shThemeDefault.css" rel="stylesheet" type="text/css"><script type="text/javascript">
+            SyntaxHighlighter.all();
+        </script><div class="section">
+        <p>
+            Forms are often used to collect related pieces of information from a user. For example,
+            an application that manages a user's music collection might provide a form that allows
+            the user to enter such information as song title, artist, and album name, and a content
+            management system might provide a form that allows a user to specify the title, author,
+            and publication date of an article.
+        </p>
+
+        <p>
+            Form contents are commonly organized into sections, to make it easier for the user to
+            read. A contact management application might use a form such as the one shown below to
+            collect information about the user's contacts. The form is divided into four sections,
+            one for each aspect of the contact record: name, addresses, phone numbers, and email
+            addresses. Note the use of the <tt>&lt;Form.Section&gt;</tt> elements to define the
+            sections; the <tt>Form</tt>'s skin automatically inserts
+            <a href="separators.html">separators</a> to visually partition the section content and
+            uses the <tt>Form.Section</tt> heading as the <tt>Separator</tt> heading:
+        </p>
+
+        <script src="http://java.com/js/deployJava.js" type="text/javascript"></script><script type="text/javascript">
+            
+            var attributes = {
+                code:"org.apache.pivot.wtk.BrowserApplicationContext$HostApplet",
+                width:"512",
+                height:"384"
+            };
+
+            
+            
+
+            
+            var libraries = [];
+            libraries.push("/lib/pivot-core-2.0.jar");
+                libraries.push("/lib/pivot-wtk-2.0.jar");
+                libraries.push("/lib/pivot-wtk-terra-2.0.jar");
+                libraries.push("/lib/pivot-tutorials-2.0.jar");
+                
+                    libraries.push("/lib/svgSalamander-tiny.jar");
+                
+
+            attributes.archive = libraries.join(",");
+
+            
+            var parameters = {
+                codebase_lookup:false,
+                application_class_name:'org.apache.pivot.wtk.ScriptApplication'
+            };
+
+            
+            var javaArguments = ["-Dsun.awt.noerasebackground=true",
+                "-Dsun.awt.erasebackgroundonresize=true"];
+
+            
+
+            parameters.java_arguments = javaArguments.join(" ");
+
+            
+            
+                var startupProperties = [];
+                
+                    startupProperties.push("src=/org/apache/pivot/tutorials/layout/forms.bxml");
+                
+                parameters.startup_properties = startupProperties.join("&");
+            
+
+            deployJava.runApplet(attributes, parameters, "1.6");
+        </script>
+
+        <p>
+            The BXML for this example is shown below:
+        </p>
+
+        <pre class="brush:xml">
+            
+            &lt;layout:Forms title="Forms" maximized="true"
+                xmlns:bxml="http://pivot.apache.org/bxml"
+                xmlns:layout="org.apache.pivot.tutorials.layout"
+                xmlns="org.apache.pivot.wtk"&gt;
+                &lt;Border styles="{padding:6}"&gt;
+                    &lt;TablePane&gt;
+                        &lt;columns&gt;
+                            &lt;TablePane.Column width="1*"/&gt;
+                        &lt;/columns&gt;
+
+                        &lt;TablePane.Row height="1*"&gt;
+                            &lt;Form&gt;
+                                &lt;Form.Section&gt;
+                                    &lt;BoxPane bxml:id="nameBoxPane" Form.label="Name"&gt;
+                                        &lt;TextInput bxml:id="lastNameTextInput" prompt="Last"/&gt;
+                                        &lt;TextInput bxml:id="firstNameTextInput" prompt="First"/&gt;
+                                    &lt;/BoxPane&gt;
+                                &lt;/Form.Section&gt;
+
+                                &lt;Form.Section heading="Addresses"&gt;
+                                    &lt;BoxPane Form.label="Home" orientation="vertical"&gt;
+                                        &lt;TextInput prompt="Street" textSize="24"/&gt;
+                                        &lt;BoxPane&gt;
+                                            &lt;TextInput prompt="City"/&gt;
+                                            &lt;TextInput prompt="State" textSize="6"/&gt;
+                                            &lt;TextInput prompt="Zip" textSize="10"/&gt;
+                                        &lt;/BoxPane&gt;
+                                    &lt;/BoxPane&gt;
+
+                                    &lt;BoxPane Form.label="Work" orientation="vertical"&gt;
+                                        &lt;TextInput prompt="Street" textSize="24"/&gt;
+                                        &lt;BoxPane&gt;
+                                            &lt;TextInput prompt="City"/&gt;
+                                            &lt;TextInput prompt="State" textSize="6"/&gt;
+                                            &lt;TextInput prompt="Zip" textSize="10"/&gt;
+                                        &lt;/BoxPane&gt;
+                                    &lt;/BoxPane&gt;
+                                &lt;/Form.Section&gt;
+
+                                &lt;Form.Section heading="Phone Numbers"&gt;
+                                    &lt;TextInput Form.label="Home"/&gt;
+                                    &lt;TextInput Form.label="Work"/&gt;
+                                &lt;/Form.Section&gt;
+
+                                &lt;Form.Section heading="Email Addresses"&gt;
+                                    &lt;TextInput Form.label="Home"/&gt;
+                                    &lt;TextInput Form.label="Work"/&gt;
+                                &lt;/Form.Section&gt;
+                            &lt;/Form&gt;
+                        &lt;/TablePane.Row&gt;
+
+                        &lt;TablePane.Row height="-1"&gt;
+                            &lt;Separator/&gt;
+                        &lt;/TablePane.Row&gt;
+
+                        &lt;TablePane.Row height="-1"&gt;
+                            &lt;TablePane&gt;
+                                &lt;columns&gt;
+                                    &lt;TablePane.Column width="1*"/&gt;
+                                    &lt;TablePane.Column width="-1"/&gt;
+                                &lt;/columns&gt;
+
+                                &lt;TablePane.Row&gt;
+                                    &lt;BoxPane styles="{verticalAlignment:'center'}"&gt;
+                                        &lt;Label bxml:id="errorLabel" styles="{color:22}"/&gt;
+                                    &lt;/BoxPane&gt;
+                                    &lt;BoxPane styles="{horizontalAlignment:'right', verticalAlignment:'center'}"&gt;
+                                        &lt;PushButton bxml:id="submitButton" buttonData="Submit"
+                                            styles="{minimumAspectRatio:3}"/&gt;
+                                    &lt;/BoxPane&gt;
+                                &lt;/TablePane.Row&gt;
+                            &lt;/TablePane&gt;
+                        &lt;/TablePane.Row&gt;
+                    &lt;/TablePane&gt;
+                &lt;/Border&gt;
+            &lt;/layout:Forms&gt;
+            
+        </pre>
+
+        <p>
+            Also note the use of the <tt>Form.label</tt> attribute - this is an example of an
+            "attached property", also called an "attribute" in WTK. An attribute is a property that
+            can be specified on a component only when it is a child of the container that defines
+            the property. The same result can be achieved programmatically by calling the static
+            <tt>Form.setName()</tt> method on a component after it has been added to the form.
+            Several other containers, including <tt>TabPane</tt> and <tt>TablePane</tt>, define
+            similar attributes.
+        </p>
+
+        <p>
+            Note also that section components are not required to be typical form elements such as
+            <tt>TextInput</tt> or <tt>PushButton</tt>. They can also be containers, allowing the
+            arrangement of components within a section to be customized.
+        </p>
+
+        <h2>Form Validation</h2>
+        <p>
+            Pressing the "Submit" button performs some simple validation on the name fields,
+            ensuring that the user has provided some text in each field. If either field is empty,
+            an error message is displayed at the bottom of the form, and the row containing the
+            text fields is highlighted with a red flag. This demonstrates the use of another
+            <tt>Form</tt> attribute: the flag. A flag is an instance of <tt>Form.Flag</tt> that
+            allows a user to tag a form element as requiring attention from the user. It is a
+            simple class that contains a message type (error, warning, info, etc.) and a message.
+            Mousing over the flag displays a tooltip containing the message.
+        </p>
+
+        <p>
+            The button press handler in the code sample below shows how a flag is set on the name
+            fields:
+        </p>
+
+        <pre class="brush:java">
+            
+            package org.apache.pivot.tutorials.layout;
+
+            import java.net.URL;
+
+            import org.apache.pivot.beans.Bindable;
+            import org.apache.pivot.collections.Map;
+            import org.apache.pivot.util.Resources;
+            import org.apache.pivot.wtk.Button;
+            import org.apache.pivot.wtk.ButtonPressListener;
+            import org.apache.pivot.wtk.BoxPane;
+            import org.apache.pivot.wtk.Form;
+            import org.apache.pivot.wtk.Label;
+            import org.apache.pivot.wtk.MessageType;
+            import org.apache.pivot.wtk.Prompt;
+            import org.apache.pivot.wtk.PushButton;
+            import org.apache.pivot.wtk.TextInput;
+            import org.apache.pivot.wtk.Window;
+
+            public class Forms extends Window implements Bindable {
+                private BoxPane nameBoxPane = null;
+                private TextInput lastNameTextInput = null;
+                private TextInput firstNameTextInput = null;
+                private PushButton submitButton = null;
+                private Label errorLabel = null;
+
+                @Override
+                public void initialize(Map&lt;String, Object&gt; namespace, URL location, Resources resources) {
+                    nameBoxPane = (BoxPane)namespace.get("nameBoxPane");
+                    lastNameTextInput = (TextInput)namespace.get("lastNameTextInput");
+                    firstNameTextInput = (TextInput)namespace.get("firstNameTextInput");
+                    submitButton = (PushButton)namespace.get("submitButton");
+                    errorLabel = (Label)namespace.get("errorLabel");
+
+                    submitButton.getButtonPressListeners().add(new ButtonPressListener() {
+                        @Override
+                        public void buttonPressed(Button button) {
+                            String lastName = lastNameTextInput.getText();
+                            String firstName = firstNameTextInput.getText();
+
+                            Form.Flag flag = null;
+                            if (lastName.length() == 0
+                                || firstName.length() == 0) {
+                                flag = new Form.Flag(MessageType.ERROR, "Name is required.");
+                            }
+
+                            Form.setFlag(nameBoxPane, flag);
+
+                            if (flag == null) {
+                                errorLabel.setText(null);
+                                Prompt.prompt("Pretending to submit...", Forms.this);
+                            } else {
+                                errorLabel.setText("Some required information is missing.");
+                            }
+                        }
+                    });
+                }
+            }
+            
+        </pre>
+    </div><p>Next: <a href="panels.html">Panels</a></p></div></div></div><div class="group" id="footer"><div class="footerLogo">Copyright (c) 1999-2011<br>The Apache Software Foundation.</div><div class="footerLinks"><ul class="footerMenuGr"><li><strong>Demos</strong><ul><li><a href="/demos/kitchen-sink.html" target="_new">"Kitchen Sink"</a></li><li><a href="/demos/component-explorer.html" target="_new">Component Explorer</a></li><li><a href="http://ixnay.biz/pivot-jfree-demos/charts_demo.html" target="_new">Charting</a></li><li><a href="/demos/">More Demos</a></li></ul></li><li><strong>Documentation</strong><ul><li><a href="/getting-started.html">Getting Started</a></li><li><a href="/tutorials/">Tutorial</a></li><li><a href="/faq.html">FAQ</a></li><li><a href="/2.0/docs/api/">Javadoc (2.0)</a></li></ul></li><li><strong>Get Involved</strong><ul><li><a href="/svn.html">SVN Repositories</a></li><li><a href="/lists.html">Mailing Lists</a></li><li><a href="http://issues.apache.o
 rg/jira/browse/PIVOT">Bug Database</a></li><li><a href="http://cwiki.apache.org/PIVOT/">Wiki</a></li></ul></li><li><strong>Related</strong><ul><li><a href="http://code.google.com/p/pivot-jfree/">JFreeChart Provider</a></li></ul></li><li><strong>About</strong><ul><li><a href="/who-we-are.html">Who We Are</a></li><li><a href="/contact.html">Contact</a></li><li><a href="/news.html">News</a></li><li><a href="/legal.html">Legal/License</a></li></ul></li></ul></div></div></div></body></html>
\ No newline at end of file