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 [17/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/menu-bars.html
URL: http://svn.apache.org/viewvc/pivot/site/trunk/deploy/tutorials/menu-bars.html?rev=1067847&view=auto
==============================================================================
--- pivot/site/trunk/deploy/tutorials/menu-bars.html (added)
+++ pivot/site/trunk/deploy/tutorials/menu-bars.html Mon Feb  7 02:36:04 2011
@@ -0,0 +1,361 @@
+<!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>Menu Bars | 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>Menu Bars</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>
+            Menu bars are generally used to provide convenient access to major application
+            features. They act as a repository for top-level hierarchical menus, keeping the menus
+            out of sight until they are needed.
+        </p>
+
+        <p>
+            Like all other components, menu bars can actually be placed anywhere in an
+            application's user interface. However, they are most often located at the top of an
+            application's main window. Pivot provides framework-level support for simplifying the
+            task of defining a menu bar positioned in this way. The <tt>Frame</tt> class defines
+            a "menuBar" property that is handled specially by the application using the
+            <tt>configureMenuBar()</tt> and <tt>cleanupMenuBar()</tt> methods of the
+            <tt>MenuHandler</tt> interface. These methods are called by the framework as the focus
+            changes within a window, to allow the application to customize the contents of the menu
+            bar based on the currently focused component.
+        </p>
+
+        <p>
+            The example application below shows a menu bar containing two common top-level menu
+            items: "File" and "Edit" (note that the applet is signed since it makes use of the
+            <tt>FileBrowserSheet</tt> component, which requires access to the local file system):
+        </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/menus/menu_bars.bxml");
+                
+                parameters.startup_properties = startupProperties.join("&");
+            
+
+            deployJava.runApplet(attributes, parameters, "1.6");
+        </script>
+
+        <p>
+            Each sub-menu item is associated with an <tt>Action</tt> that is executed when the
+            item is selected. For example, the action attached to the "File &gt; Open" menu item
+            simulates opening a document by showing a file browser sheet and adding a new tab to
+            the application's tab pane. Each component in the "document" has a menu handler
+            attached to it that configures the menu contents as appropriate for the current
+            selection. When a text input component has the focus, the "Paste" menu item is enabled.
+            If text is selected in the text input, the "Cut" and "Copy" menu items are also
+            enabled.
+        </p>
+
+        <p>
+            The BXML source for this example is shown below. It creates the initial menu structure
+            as well as the tab pane that will host the simulated documents. It also defines a set
+            of "action mappings" in the root frame's "actionMappings" sequence. Action mappings
+            associate keystrokes with actions; when a keystroke matching an action in the sequence
+            is processed by the window, the action is invoked. Action mappings are often called
+            "keyboard shortcuts".
+        </p>
+
+        <p>
+            Note that the actions in this example are associated with the "CMD" key. This is a
+            Pivot-specific, platform-independent modifier. It maps to the Control key (CTRL)
+            on Windows and Linux and the Command key (META) on Mac OS X:
+        </p>
+
+        <pre class="brush:xml">
+            
+            &lt;menus:MenuBars title="Menu Bars" maximized="true"
+                styles="{padding:{top:0, left:4, bottom:4, right:4}, showWindowControls:false}"
+                xmlns:bxml="http://pivot.apache.org/bxml"
+                xmlns:content="org.apache.pivot.wtk.content"
+                xmlns:menus="org.apache.pivot.tutorials.menus"
+                xmlns="org.apache.pivot.wtk"&gt;
+                &lt;bxml:define&gt;
+                    &lt;FileBrowserSheet bxml:id="fileBrowserSheet"/&gt;
+                &lt;/bxml:define&gt;
+
+                &lt;actionMappings&gt;
+                    &lt;Window.ActionMapping action="fileNew" keyStroke="CMD-N"/&gt;
+                    &lt;Window.ActionMapping action="fileOpen" keyStroke="CMD-O"/&gt;
+                &lt;/actionMappings&gt;
+
+                &lt;menuBar&gt;
+                    &lt;MenuBar&gt;
+                        &lt;MenuBar.Item buttonData="File"&gt;
+                            &lt;Menu&gt;
+                                &lt;Menu.Section&gt;
+                                    &lt;Menu.Item action="fileNew"&gt;
+                                        &lt;buttonData&gt;
+                                            &lt;content:MenuItemData text="New" keyboardShortcut="CMD-N"/&gt;
+                                        &lt;/buttonData&gt;
+                                    &lt;/Menu.Item&gt;
+
+                                    &lt;Menu.Item action="fileOpen"&gt;
+                                        &lt;buttonData&gt;
+                                            &lt;content:MenuItemData text="Open" keyboardShortcut="CMD-O"/&gt;
+                                        &lt;/buttonData&gt;
+                                    &lt;/Menu.Item&gt;
+                                &lt;/Menu.Section&gt;
+                            &lt;/Menu&gt;
+                        &lt;/MenuBar.Item&gt;
+
+                        &lt;MenuBar.Item buttonData="Edit"&gt;
+                            &lt;Menu&gt;
+                                &lt;Menu.Section&gt;
+                                    &lt;Menu.Item action="cut"&gt;
+                                        &lt;buttonData&gt;
+                                            &lt;content:MenuItemData text="Cut" keyboardShortcut="CMD-X"/&gt;
+                                        &lt;/buttonData&gt;
+                                    &lt;/Menu.Item&gt;
+                                    &lt;Menu.Item action="copy"&gt;
+                                        &lt;buttonData&gt;
+                                            &lt;content:MenuItemData text="Copy" keyboardShortcut="CMD-C"/&gt;
+                                        &lt;/buttonData&gt;
+                                    &lt;/Menu.Item&gt;
+                                    &lt;Menu.Item action="paste"&gt;
+                                        &lt;buttonData&gt;
+                                            &lt;content:MenuItemData text="Paste" keyboardShortcut="CMD-V"/&gt;
+                                        &lt;/buttonData&gt;
+                                    &lt;/Menu.Item&gt;
+                                &lt;/Menu.Section&gt;
+                            &lt;/Menu&gt;
+                        &lt;/MenuBar.Item&gt;
+                    &lt;/MenuBar&gt;
+                &lt;/menuBar&gt;
+
+                &lt;Border styles="{backgroundColor:null, padding:2}"&gt;
+                    &lt;TabPane bxml:id="tabPane"/&gt;
+                &lt;/Border&gt;
+            &lt;/menus:MenuBars&gt;
+            
+        </pre>
+
+        <p>
+            The Java source for the example is shown below. In the constructor, the application's
+            actions are created and added to the global action dictionary. Note that, since the
+            BXML file refers to the actions by ID, it is essential that the actions be available
+            before the BXML is read.
+        </p>
+
+        <pre class="brush:java">
+            
+            package org.apache.pivot.tutorials.menus;
+
+            import java.io.IOException;
+            import java.net.URL;
+
+            import org.apache.pivot.beans.BXML;
+            import org.apache.pivot.beans.BXMLSerializer;
+            import org.apache.pivot.beans.Bindable;
+            import org.apache.pivot.collections.Map;
+            import org.apache.pivot.serialization.SerializationException;
+            import org.apache.pivot.util.Resources;
+            import org.apache.pivot.wtk.Action;
+            import org.apache.pivot.wtk.Border;
+            import org.apache.pivot.wtk.Component;
+            import org.apache.pivot.wtk.FileBrowserSheet;
+            import org.apache.pivot.wtk.Frame;
+            import org.apache.pivot.wtk.MenuBar;
+            import org.apache.pivot.wtk.MenuHandler;
+            import org.apache.pivot.wtk.TabPane;
+            import org.apache.pivot.wtk.TextInput;
+            import org.apache.pivot.wtk.TextInputSelectionListener;
+            import org.apache.pivot.wtk.TextInputContentListener;
+
+            public class MenuBars extends Frame implements Bindable {
+                @BXML private FileBrowserSheet fileBrowserSheet;
+                @BXML private TabPane tabPane = null;
+
+                private MenuHandler menuHandler = new MenuHandler.Adapter() {
+                    TextInputContentListener textInputTextListener = new TextInputContentListener.Adapter() {
+                        @Override
+                        public void textChanged(TextInput textInput) {
+                            updateActionState(textInput);
+                        }
+                    };
+
+                    TextInputSelectionListener textInputSelectionListener = new TextInputSelectionListener() {
+                        @Override
+                        public void selectionChanged(TextInput textInput, int previousSelectionStart,
+                            int previousSelectionLength) {
+                            updateActionState(textInput);
+                        }
+                    };
+
+                    @Override
+                    public void configureMenuBar(Component component, MenuBar menuBar) {
+                        if (component instanceof TextInput) {
+                            TextInput textInput = (TextInput)component;
+
+                            updateActionState(textInput);
+                            Action.getNamedActions().get("paste").setEnabled(true);
+
+                            textInput.getTextInputContentListeners().add(textInputTextListener);
+                            textInput.getTextInputSelectionListeners().add(textInputSelectionListener);
+                        } else {
+                            Action.getNamedActions().get("cut").setEnabled(false);
+                            Action.getNamedActions().get("copy").setEnabled(false);
+                            Action.getNamedActions().get("paste").setEnabled(false);
+                        }
+                    }
+
+                    @Override
+                    public void cleanupMenuBar(Component component, MenuBar menuBar) {
+                        if (component instanceof TextInput) {
+                            TextInput textInput = (TextInput)component;
+                            textInput.getTextInputContentListeners().remove(textInputTextListener);
+                            textInput.getTextInputSelectionListeners().remove(textInputSelectionListener);
+                        }
+                    }
+
+                    private void updateActionState(TextInput textInput) {
+                        Action.getNamedActions().get("cut").setEnabled(textInput.getSelectionLength() &gt; 0);
+                        Action.getNamedActions().get("copy").setEnabled(textInput.getSelectionLength() &gt; 0);
+                    }
+                };
+
+                public MenuBars() {
+                    Action.getNamedActions().put("fileNew", new Action() {
+                        @Override
+                        public void perform(Component source) {
+                            BXMLSerializer bxmlSerializer = new BXMLSerializer();
+                            bxmlSerializer.getNamespace().put("menuHandler", menuHandler);
+
+                            Component tab;
+                            try {
+                                tab = new Border((Component)bxmlSerializer.readObject(MenuBars.class, "document.bxml"));
+                            } catch (IOException exception) {
+                                throw new RuntimeException(exception);
+                            } catch (SerializationException exception) {
+                                throw new RuntimeException(exception);
+                            }
+
+                            tabPane.getTabs().add(tab);
+                            TabPane.setTabData(tab, "Document " + tabPane.getTabs().getLength());
+                            tabPane.setSelectedIndex(tabPane.getTabs().getLength() - 1);
+                        }
+                    });
+
+                    Action.getNamedActions().put("fileOpen", new Action() {
+                        @Override
+                        public void perform(Component source) {
+                            fileBrowserSheet.open(MenuBars.this);
+                        }
+                    });
+
+                    Action.getNamedActions().put("cut", new Action(false) {
+                        @Override
+                        public void perform(Component source) {
+                            TextInput textInput = (TextInput)MenuBars.this.getFocusDescendant();
+                            textInput.cut();
+                        }
+                    });
+
+                    Action.getNamedActions().put("copy", new Action(false) {
+                        @Override
+                        public void perform(Component source) {
+                            TextInput textInput = (TextInput)MenuBars.this.getFocusDescendant();
+                            textInput.copy();
+                        }
+                    });
+
+                    Action.getNamedActions().put("paste", new Action(false) {
+                        @Override
+                        public void perform(Component source) {
+                            TextInput textInput = (TextInput)MenuBars.this.getFocusDescendant();
+                            textInput.paste();
+                        }
+                    });
+                }
+
+                @Override
+                public void initialize(Map&lt;String, Object&gt; namespace, URL location, Resources resources) {
+                }
+            }
+            
+        </pre>
+
+        <p>
+            The class also defines an anonymous inner implementation of the <tt>MenuHandler</tt>
+            interface that is used to configure the menu bar based on the focused component. In
+            <tt>configureMenuBar()</tt>, the actions associated with the "cut", "copy", and "paste"
+            operations are enabled and disabled as appropriate. Listeners are also added to the
+            focused component (if it is a <tt>TextInput</tt>) to ensure that the action's state
+            accurately reflects the current selection. The listeners are removed in
+            <tt>cleanupMenuBar()</tt>, if necessary.
+        </p>
+
+        <p>
+            Note that menu bar configuration via <tt>MenuHandler</tt> isn't limited to enabling or
+            disabling actions - new menu items can be dynamically created, menu item selection
+            state can be changed, etc. However, unlike context menus, the framework does not
+            automatically clean up any changes made to the menu bar. It is up to the application
+            to ensure that the menu bar remains in a consistent state using the
+            <tt>configureMenuBar()</tt> and <tt>cleanupMenuBar()</tt> methods.
+        </p>
+    </div><p>Next: <a href="menu-buttons.html">Menu Buttons</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://iss
 ues.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/menu-buttons.html
URL: http://svn.apache.org/viewvc/pivot/site/trunk/deploy/tutorials/menu-buttons.html?rev=1067847&view=auto
==============================================================================
--- pivot/site/trunk/deploy/tutorials/menu-buttons.html (added)
+++ pivot/site/trunk/deploy/tutorials/menu-buttons.html Mon Feb  7 02:36:04 2011
@@ -0,0 +1,192 @@
+<!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>Menu Buttons | 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>Menu Buttons</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="/tutoria
 ls/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="/tuto
 rials/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.htm
 l">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/co
 lor-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
 .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>
+            Menu buttons are similar to <a href="list-buttons.html">list buttons</a>, but provide
+            access to "drop-down" menus rather than list views. They are often used in toolbars,
+            but can be placed anywhere within an application's user interface.
+        </p>
+
+        <p>
+            The following sample application demonstrates the use of a menu button. Selecting an
+            option from the menu button on the left adds the corresponding component type to the
+            content area on the right:
+        </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:"360",
+                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/menus/menu_buttons.bxml");
+                
+                parameters.startup_properties = startupProperties.join("&");
+            
+
+            deployJava.runApplet(attributes, parameters, "1.6");
+        </script>
+
+        <p>
+            The BXML source for the application is as follows:
+        </p>
+
+        <pre class="brush:xml">
+            
+            &lt;menus:MenuButtons title="Menu Buttons" maximized="true"
+                xmlns:bxml="http://pivot.apache.org/bxml"
+                xmlns:content="org.apache.pivot.wtk.content"
+                xmlns:menus="org.apache.pivot.tutorials.menus"
+                xmlns="org.apache.pivot.wtk"&gt;
+                &lt;Border styles="{padding:8}"&gt;
+                    &lt;TablePane styles="{horizontalSpacing:4}"&gt;
+                        &lt;columns&gt;
+                            &lt;TablePane.Column width="-1"/&gt;
+                            &lt;TablePane.Column width="1*"/&gt;
+                        &lt;/columns&gt;
+
+                        &lt;TablePane.Row height="1*"&gt;
+                            &lt;BoxPane orientation="vertical"&gt;
+                                &lt;MenuButton buttonData="Add Component"&gt;
+                                    &lt;Menu&gt;
+                                        &lt;Menu.Section&gt;
+                                            &lt;Menu.Item buttonData="Push Button" action="addPushButton"/&gt;
+                                            &lt;Menu.Item buttonData="Checkbox" action="addCheckbox"/&gt;
+                                            &lt;Menu.Item buttonData="Radio Button" action="addRadioButton"/&gt;
+                                        &lt;/Menu.Section&gt;
+                                    &lt;/Menu&gt;
+                                &lt;/MenuButton&gt;
+                            &lt;/BoxPane&gt;
+
+                            &lt;Border&gt;
+                                &lt;ScrollPane&gt;
+                                    &lt;BoxPane bxml:id="componentBoxPane" orientation="vertical"
+                                        styles="{padding:4, spacing:4}"/&gt;
+                                &lt;/ScrollPane&gt;
+                            &lt;/Border&gt;
+                        &lt;/TablePane.Row&gt;
+                    &lt;/TablePane&gt;
+                &lt;/Border&gt;
+            &lt;/menus:MenuButtons&gt;
+            
+        </pre>
+
+        <p>
+            Like the previous example, it defines a set of menu items that are associated with
+            named actions. The Java source, which defines the actions, is shown below:
+        </p>
+
+        <pre class="brush:java">
+            
+            package org.apache.pivot.tutorials.menus;
+
+            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.Action;
+            import org.apache.pivot.wtk.BoxPane;
+            import org.apache.pivot.wtk.Checkbox;
+            import org.apache.pivot.wtk.Component;
+            import org.apache.pivot.wtk.PushButton;
+            import org.apache.pivot.wtk.RadioButton;
+            import org.apache.pivot.wtk.Window;
+
+            public class MenuButtons extends Window implements Bindable {
+                private BoxPane componentBoxPane = null;
+
+                public MenuButtons() {
+                    Action.getNamedActions().put("addPushButton", new Action() {
+                        @Override
+                        public void perform(Component source) {
+                            componentBoxPane.add(new PushButton("Push button"));
+
+                        }
+                    });
+
+                    Action.getNamedActions().put("addCheckbox", new Action() {
+                        @Override
+                        public void perform(Component source) {
+                            componentBoxPane.add(new Checkbox("Checkbox"));
+                        }
+                    });
+
+                    Action.getNamedActions().put("addRadioButton", new Action() {
+                        @Override
+                        public void perform(Component source) {
+                            componentBoxPane.add(new RadioButton("Radio button"));
+                        }
+                    });
+                }
+
+                @Override
+                public void initialize(Map&lt;String, Object&gt; namespace, URL location, Resources resources) {
+                    componentBoxPane = (BoxPane)namespace.get("componentBoxPane");
+                }
+            }
+            
+        </pre>
+    </div><p>Next: <a href="color-choosers.html">Color Choosers</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/menus.html
URL: http://svn.apache.org/viewvc/pivot/site/trunk/deploy/tutorials/menus.html?rev=1067847&view=auto
==============================================================================
--- pivot/site/trunk/deploy/tutorials/menus.html (added)
+++ pivot/site/trunk/deploy/tutorials/menus.html Mon Feb  7 02:36:04 2011
@@ -0,0 +1,56 @@
+<!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>Menus | 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>Menus</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>
+            Menus are used to present a user with a hierarchical selection of options. Pivot
+            supports three primary means of incorporating menus into an application:
+        </p>
+
+        <ul>
+            <li>
+                <a href="context-menus.html"><b>Context Menus</b></a> - generally provide
+                convenient "right-click" access to context-sensitive functionality.
+            </li>
+            <li>
+                <a href="menu-bars.html"><b>Menu Bars</b></a> - collection of menus generally
+                located at the top of an application window that provide access to major
+                application features.
+            </li>
+            <li>
+                <a href="menu-buttons.html"><b>Menu Buttons</b></a> - provide access to "drop-down"
+                menus, similar to <a href="list-buttons.html">list buttons</a>; often used in
+                toolbars.
+            </li>
+        </ul>
+
+        <p>
+            Context menus are discussed first.
+        </p>
+    </div><p>Next: <a href="context-menus.html">Context Menus</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://i
 ssues.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/meters.html
URL: http://svn.apache.org/viewvc/pivot/site/trunk/deploy/tutorials/meters.html?rev=1067847&view=auto
==============================================================================
--- pivot/site/trunk/deploy/tutorials/meters.html (added)
+++ pivot/site/trunk/deploy/tutorials/meters.html Mon Feb  7 02:36:04 2011
@@ -0,0 +1,240 @@
+<!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>Meters | 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>Meters</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/com
 ponent-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/
 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">Rol
 lups</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-ch
 oosers.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>
+            Meters are used to report progress to the user, generally the completion percentage of
+            a background task such as a file load operation. An example is shown below. Clicking
+            the Start button initiates a background task that simulates a long-running operation.
+            Periodically, the task updates the meter to reflect its progress:
+        </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:"300",
+                height:"100"
+            };
+
+            
+            
+
+            
+            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/progress/meters.bxml");
+                
+                parameters.startup_properties = startupProperties.join("&");
+            
+
+            deployJava.runApplet(attributes, parameters, "1.6");
+        </script>
+
+        <p>
+            The BXML source for the example is shown below:
+        </p>
+
+        <pre class="brush:xml">
+            
+            &lt;progress:Meters title="Meters" maximized="true"
+                xmlns:bxml="http://pivot.apache.org/bxml"
+                xmlns:progress="org.apache.pivot.tutorials.progress"
+                xmlns="org.apache.pivot.wtk"&gt;
+                &lt;TablePane&gt;
+                    &lt;columns&gt;
+                        &lt;TablePane.Column width="1*"/&gt;
+                    &lt;/columns&gt;
+
+                    &lt;TablePane.Row height="1*"&gt;
+                        &lt;Border styles="{padding:2}"&gt;
+                            &lt;BoxPane styles="{horizontalAlignment:'center', verticalAlignment:'center'}"&gt;
+                                &lt;Label text="Progress:"/&gt;
+                                &lt;Meter bxml:id="meter" preferredWidth="200" preferredHeight="16"/&gt;
+                            &lt;/BoxPane&gt;
+                        &lt;/Border&gt;
+                    &lt;/TablePane.Row&gt;
+
+                    &lt;TablePane.Row height="-1"&gt;
+                        &lt;BoxPane styles="{horizontalAlignment:'center', padding:6}"&gt;
+                            &lt;PushButton bxml:id="progressButton" styles="{minimumAspectRatio:3}"/&gt;
+                        &lt;/BoxPane&gt;
+                    &lt;/TablePane.Row&gt;
+                &lt;/TablePane&gt;
+            &lt;/progress:Meters&gt;
+            
+        </pre>
+
+        <p>
+            The Java source is as follows. The main window class defines an inner class that
+            extends the <tt>org.apache.pivot.util.concurrent.Task</tt> class to simulate a background
+            operation. This task simply sleeps for 100ms at a time and updates the meter when it
+            wakes up to reflect the current count. Since all UI updates must be performed on the
+            UI thread, the task queues a callback to set the meter's percent complete; a
+            <tt>org.apache.pivot.wtk.TaskAdapter</tt> is used to process the task notifications for
+            the same reason:
+        </p>
+
+        <pre class="brush:java">
+            
+            package org.apache.pivot.tutorials.progress;
+
+            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.util.concurrent.Task;
+            import org.apache.pivot.util.concurrent.TaskExecutionException;
+            import org.apache.pivot.util.concurrent.TaskListener;
+            import org.apache.pivot.wtk.ApplicationContext;
+            import org.apache.pivot.wtk.Button;
+            import org.apache.pivot.wtk.ButtonPressListener;
+            import org.apache.pivot.wtk.Meter;
+            import org.apache.pivot.wtk.PushButton;
+            import org.apache.pivot.wtk.TaskAdapter;
+            import org.apache.pivot.wtk.Window;
+
+            public class Meters extends Window implements Bindable {
+                public class SampleTask extends Task&lt;Void&gt; {
+                    private int percentage = 0;
+
+                    @Override
+                    public Void execute() throws TaskExecutionException {
+                        // Simulate a long-running operation
+                        percentage = 0;
+
+                        while (percentage &lt; 100
+                            &amp;&amp; !abort) {
+                            try {
+                                Thread.sleep(100);
+                                percentage++;
+
+                                // Update the meter on the UI thread
+                                ApplicationContext.queueCallback(new Runnable() {
+                                    @Override
+                                    public void run() {
+                                        meter.setPercentage((double)percentage / 100);
+                                    }
+                                });
+                            } catch(InterruptedException exception) {
+                                throw new TaskExecutionException(exception);
+                            }
+                        }
+
+                        return null;
+                    }
+                }
+
+                private Meter meter = null;
+                private PushButton progressButton = null;
+
+                private SampleTask sampleTask = null;
+
+                @Override
+                public void initialize(Map&lt;String, Object&gt; namespace, URL location, Resources resources) {
+                    meter = (Meter)namespace.get("meter");
+                    progressButton = (PushButton)namespace.get("progressButton");
+
+                    progressButton.getButtonPressListeners().add(new ButtonPressListener() {
+                        @Override
+                        public void buttonPressed(Button button) {
+                            if (sampleTask == null) {
+                                // Create and start the simulated task; wrap it in a
+                                // task adapter so the result handlers are called on the
+                                // UI thread
+                                sampleTask = new SampleTask();
+                                sampleTask.execute(new TaskAdapter&lt;Void&gt;(new TaskListener&lt;Void&gt;() {
+                                    @Override
+                                    public void taskExecuted(Task&lt;Void&gt; task) {
+                                        reset();
+                                    }
+
+                                    @Override
+                                    public void executeFailed(Task&lt;Void&gt; task) {
+                                        reset();
+                                    }
+
+                                    private void reset() {
+                                        // Reset the meter and button
+                                        sampleTask = null;
+                                        meter.setPercentage(0);
+                                        updateProgressButton();
+                                    }
+                                }));
+                            } else {
+                                // Cancel the task
+                                sampleTask.abort();
+                            }
+
+                            updateProgressButton();
+                        }
+                    });
+
+                    updateProgressButton();
+                }
+
+                private void updateProgressButton() {
+                    if (sampleTask == null) {
+                        progressButton.setButtonData("Start");
+                    } else {
+                        progressButton.setButtonData("Cancel");
+                    }
+                }
+            }
+            
+        </pre>
+    </div><p>Next: <a href="activity-indicators.html">Activity Indicators</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 hr
 ef="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/navigation-containers.html
URL: http://svn.apache.org/viewvc/pivot/site/trunk/deploy/tutorials/navigation-containers.html?rev=1067847&view=auto
==============================================================================
--- pivot/site/trunk/deploy/tutorials/navigation-containers.html (added)
+++ pivot/site/trunk/deploy/tutorials/navigation-containers.html Mon Feb  7 02:36:04 2011
@@ -0,0 +1,92 @@
+<!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>Navigation Containers | 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>Navigation Containers</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 hr
 ef="/tutorials/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/ro
 llups.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="/tut
 orials/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/we
 b-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>
+            Navigation containers are used to maximize screen real estate, showing or hiding their
+            children as needed. Navigation containers include:
+        </p>
+
+        <ul>
+            <li>
+                <p>
+                    <a href="card-panes.html"><b>CardPane</b></a> - A simple "card stack" of
+                    components, only one of which is visible at a time.
+                </p>
+            </li>
+            <li>
+                <p>
+                    <a href="tab-panes.html"><b>TabPane</b></a> - Similar to <tt>CardPane</tt> but
+                    with built-in "tabs" for navigation; may optionally be "collapsed" such that
+                    only the tab buttons show.
+                </p>
+            </li>
+            <li>
+                <p>
+                    <a href="accordions.html"><b>Accordion</b></a> - Similar to <tt>TabPane</tt>,
+                    but subcomponents are presented like the folds of an accordion, with headers
+                    for navigating between panels.
+                </p>
+            </li>
+            <li>
+                <p>
+                    <a href="expanders.html"><b>Expander</b></a> - Similar to a border but
+                    collapsible such that only the title shows.
+                </p>
+            </li>
+            <li>
+                <p>
+                    <a href="rollups.html"><b>Rollup</b></a> - Similar to <tt>Expander</tt> but
+                    supports a configurable "header" component; when collapsed, only the header is
+                    visible. Can be nested to create the appearance of a "tree" structure.
+                </p>
+            </li>
+            <li>
+                <p>
+                    <a href="viewports.html"><b><i>Viewport</i></b></a> - Abstract base class for a
+                    scrollable region. Sublcasses of <tt>Viewport</tt> include:
+                    <ul>
+                        <li>
+                            <a href="scroll-panes.html"><b>ScrollPane</b></a> - A scrollable area
+                            with optional vertical and horizontal scroll bars as well as row and
+                            column headers.
+                        </li>
+                        <li>
+                            <a href="panoramas.html"><b>Panorama</b></a> - A scrollable area with
+                            optional up/down/left/right arrows.
+                        </li>
+                    </ul>
+                </p>
+            </li>
+        </ul>
+
+        <p>
+            Each of these are discussed in detail in the following sections.
+        </p>
+    </div><p>Next: <a href="card-panes.html">Card 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.
 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