changeset 6035:193626ad5b24

Automated merge with ssh://jfxsrc.us.oracle.com//javafx/8.0/MASTER/jfx/rt
author kcr
date Thu, 02 Jan 2014 10:58:15 -0800
parents dd789066e61e 6276ba3a4dfd
children c73ad04890cf
files apps/experiments/3DViewer/.classpath apps/experiments/3DViewer/.project apps/experiments/Modena/.classpath apps/experiments/Modena/.project apps/experiments/Modena/src/main/java/modena/SamplePageHelpers.java apps/experiments/Modena/src/main/java/modena/SamplePageTableHelper.java apps/samples/Ensemble8/.classpath apps/samples/Ensemble8/.project apps/samples/Ensemble8/src/samples/java/ensemble/samples/graphics2d/brickbreaker/Level.java modules/controls/src/main/resources/com/sun/javafx/scene/control/skin/modena/modena.css modules/fxpackager/src/main/man/ja_JP.UTF-8/html/javafxpackager.html modules/web/src/test/java/javafx/scene/web/CallbackTest.java
diffstat 231 files changed, 39237 insertions(+), 23477 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/experiments/.classpath	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+    <classpathentry kind="src" path="3DViewer/src/main/java"/>
+    <classpathentry kind="src" path="3DViewer/src/test/java"/>
+    <classpathentry kind="src" path="3DViewer/src/main/resources"/>
+    <classpathentry kind="src" path="3DViewer/src/test/resources"/>
+    <classpathentry kind="src" path="Modena/src/main/java"/>
+    <classpathentry kind="src" path="Modena/src/main/resources"/>
+    <classpathentry combineaccessrules="false" kind="src" path="/rt">
+    <attributes>
+        <attribute name="optional" value="true"/>
+        </attributes>
+    </classpathentry>
+    <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+    <classpathentry kind="output" path="bin"/>
+</classpath>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/experiments/.project	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+	<name>experiments</name>
+	<comment></comment>
+	<projects>
+	</projects>
+	<buildSpec>
+		<buildCommand>
+			<name>org.eclipse.jdt.core.javabuilder</name>
+			<arguments>
+			</arguments>
+		</buildCommand>
+	</buildSpec>
+	<natures>
+		<nature>org.eclipse.jdt.core.javanature</nature>
+	</natures>
+</projectDescription>
--- a/apps/experiments/3DViewer/.classpath	Sat Dec 28 08:05:35 2013 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,14 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src/main/java"/>
-	<classpathentry kind="src" path="src/test/java"/>
-	<classpathentry kind="src" path="src/main/resources"/>
-	<classpathentry kind="src" path="src/test/resources"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/rt">
-	<attributes>
-		<attribute name="optional" value="true"/>
-		</attributes>
-	</classpathentry>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
--- a/apps/experiments/3DViewer/.project	Sat Dec 28 08:05:35 2013 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>3DViewer</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
--- a/apps/experiments/Modena/.classpath	Sat Dec 28 08:05:35 2013 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,12 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src/main/java"/>
-	<classpathentry kind="src" path="src/main/resources"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/rt">
-	<attributes>
-		<attribute name="optional" value="true"/>
-		</attributes>
-	</classpathentry>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
--- a/apps/experiments/Modena/.project	Sat Dec 28 08:05:35 2013 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>Modena</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
--- a/apps/experiments/Modena/src/main/java/modena/Modena.java	Sat Dec 28 08:05:35 2013 -0800
+++ b/apps/experiments/Modena/src/main/java/modena/Modena.java	Thu Jan 02 10:58:15 2014 -0800
@@ -450,6 +450,7 @@
             if (retina) {
                 contentTabs.getTransforms().setAll(new Scale(2,2));
             }
+            root.applyCss();
             // update state
             Platform.runLater(new Runnable() {
                 @Override public void run() {
--- a/apps/experiments/Modena/src/main/java/modena/SamplePageHelpers.java	Sat Dec 28 08:05:35 2013 -0800
+++ b/apps/experiments/Modena/src/main/java/modena/SamplePageHelpers.java	Thu Jan 02 10:58:15 2014 -0800
@@ -100,16 +100,7 @@
         withState(node, state);
         Platform.runLater(new Runnable() {
             @Override public void run() {
-                if (node != null) {
-                    Node subNode = node.lookup(subNodeStyleClass);
-                    if (subNode != null) {
-                        withState(node.lookup(subNodeStyleClass), subNodeState);
-                    } else {
-                        System.err.println("node = " + node+" node.lookup("+subNodeStyleClass+") = " + subNode);
-                    }
-                } else {
-                    System.err.println("node = " + node);
-                }
+                withState(node.lookup(subNodeStyleClass), subNodeState);
             }
         });
         return node;
@@ -271,13 +262,9 @@
             createMenu("View"),
             createMenu("Help")
         );
-//        mb.setMouseTransparent(true);
         Platform.runLater(new Runnable() {
             @Override public void run() {
-                // get second menu and force into hover state
-                try {
-                    new ArrayList<Node>(mb.lookupAll(".menu")).get(1).pseudoClassStateChanged(PseudoClass.getPseudoClass("hover"), true);
-                } catch (Exception e) { e.printStackTrace(); }
+                new ArrayList<Node>(mb.lookupAll(".menu")).get(1).pseudoClassStateChanged(PseudoClass.getPseudoClass("hover"), true);
             }
         });
         return  mb;
@@ -313,7 +300,7 @@
                         menuContent.setMouseTransparent(true);
 //                        System.out.println("menuContent = " + menuContent);
 //                        System.out.println("menuContent.lookupAll(\".menu-item\") = " + menuContent.lookupAll(".menu-item"));
-                        
+
 //                        Platform.runLater(new Runnable() {
 //                            @Override public void run() {
 ////                        if (selectAll) {
@@ -335,27 +322,19 @@
     
     static MenuItem[] createMenuContents() {
         List<MenuItem> menuItems = new ArrayList<>();
-//        Menu menu11 = makeMenu("_New", new ImageView(new Image(getClass().getResourceAsStream("about_16.png"))));
-//        final Menu menu11 = new Menu("_New", new ImageView(new Image("helloworld/about_16.png")));
-//        MenuItem menu12 = new MenuItem("_Open", new ImageView(new Image("helloworld/folder_16.png")));
         final Menu menu11 = new Menu("_New");
         MenuItem menu12 = new MenuItem("_Open");
         menu12.getStyleClass().add("OpenMenuItem");
         menu12.setAccelerator(new KeyCharacterCombination("]", 
                 KeyCombination.SHIFT_DOWN, KeyCombination.META_DOWN));
         Menu menu13 = new Menu("_Submenu");
-//        CheckMenuItem showMessagesItem = new CheckMenuItem("Enable onShowing/onHiding _messages", 
-//                                             new ImageView(new Image("helloworld/about_16.png")));
-        CheckMenuItem showMessagesItem = new CheckMenuItem("Enable onShowing/onHiding _messages");
         MenuItem menu15 = new MenuItem("E_xit");
         final String change[] = {"Change Text", "Change Back"};
         final MenuItem menu16 = new MenuItem(change[0]);
-        final boolean toggle = false;
         menu16.setAccelerator(KeyCombination.keyCombination("Shortcut+C"));
         menuItems.add(menu11);
         menuItems.add(menu12);
         menuItems.add(menu13);
-//        menuItems.add(showMessagesItem);
         menuItems.add(menu16);
         menuItems.add(new SeparatorMenuItem());
         menuItems.add(CheckMenuItemBuilder.create().text("Check").build());
--- a/apps/experiments/Modena/src/main/java/modena/SamplePageTableHelper.java	Sat Dec 28 08:05:35 2013 -0800
+++ b/apps/experiments/Modena/src/main/java/modena/SamplePageTableHelper.java	Thu Jan 02 10:58:15 2014 -0800
@@ -273,9 +273,7 @@
                 System.out.println("Edit commit event: " + t.getNewValue());
             }
         });
-        final Node graphic1 = new ImageView(new Image("file:src/helloworld/about_16.png"));
         lastNameCol = new TableColumn<Person, String>();
-        lastNameCol.setGraphic(graphic1);
         lastNameCol.setText("Last");
         lastNameCol.setSortType(TableColumn.SortType.DESCENDING);
         lastNameCol.setCellValueFactory(new Callback<TableColumn.CellDataFeatures<Person, String>, ObservableValue<String>>() {
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/samples/.classpath	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="Ensemble8/src/app/java"/>
+	<classpathentry kind="src" path="Ensemble8/src/app/resources"/>
+	<classpathentry kind="src" path="Ensemble8/src/samples/java"/>
+	<classpathentry kind="src" path="Ensemble8/src/samples/resources"/>
+	<classpathentry kind="src" path="Ensemble8/src/compiletime/java"/>
+	<classpathentry kind="src" path="Ensemble8/src/generated/java"/>
+    <classpathentry kind="src" path="Ensemble8/src/generated/resources"/>
+	<classpathentry kind="lib" path="Ensemble8/lib/lucene-core-3.2.0.jar"/>
+	<classpathentry kind="lib" path="Ensemble8/lib/lucene-grouping-3.2.0.jar"/>
+	<classpathentry combineaccessrules="false" kind="src" path="/rt">
+	<attributes>
+		<attribute name="optional" value="true"/>
+		</attributes>
+	</classpathentry>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/samples/.project	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+	<name>samples</name>
+	<comment></comment>
+	<projects>
+	</projects>
+	<buildSpec>
+		<buildCommand>
+			<name>org.eclipse.jdt.core.javabuilder</name>
+			<arguments>
+			</arguments>
+		</buildCommand>
+	</buildSpec>
+	<natures>
+		<nature>org.eclipse.jdt.core.javanature</nature>
+	</natures>
+</projectDescription>
--- a/apps/samples/Ensemble8/.classpath	Sat Dec 28 08:05:35 2013 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry kind="src" path="src/app/java"/>
-	<classpathentry kind="src" path="src/app/resources"/>
-	<classpathentry kind="src" path="src/samples/java"/>
-	<classpathentry kind="src" path="src/samples/resources"/>
-	<classpathentry kind="src" path="src/compiletime/java"/>
-	<classpathentry kind="src" path="src/generated/java"/>
-    <classpathentry kind="src" path="src/generated/resources"/>
-	<classpathentry kind="lib" path="lib/lucene-core-3.2.0.jar"/>
-	<classpathentry kind="lib" path="lib/lucene-grouping-3.2.0.jar"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/rt">
-	<attributes>
-		<attribute name="optional" value="true"/>
-		</attributes>
-	</classpathentry>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry kind="output" path="bin"/>
-</classpath>
--- a/apps/samples/Ensemble8/.project	Sat Dec 28 08:05:35 2013 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-	<name>Ensemble8</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
--- a/apps/samples/Ensemble8/src/samples/java/ensemble/samples/graphics2d/brickbreaker/Level.java	Sat Dec 28 08:05:35 2013 -0800
+++ b/apps/samples/Ensemble8/src/samples/java/ensemble/samples/graphics2d/brickbreaker/Level.java	Thu Jan 02 10:58:15 2014 -0800
@@ -593,7 +593,7 @@
         initStartingTimeline();
         initTimeline();
         initInfoPanel();
-        ImageView background = new ImageView();
+        final ImageView background = new ImageView();
         background.setFocusTraversable(true);
         background.setImage(Config.getImages().get(Config.IMAGE_BACKGROUND));
         background.setFitWidth(Config.SCREEN_WIDTH);
@@ -601,16 +601,19 @@
         background.setOnMouseMoved(new EventHandler<MouseEvent>() {
             public void handle(MouseEvent me) {
                 moveBat(me.getX() - bat.getWidth() / 2);
+                me.consume();
             }
         });
         background.setOnMouseDragged(new EventHandler<MouseEvent>() {
             public void handle(MouseEvent me) {
                 // Support touch-only devices like some mobile phones
                 moveBat(me.getX() - bat.getWidth() / 2);
+                me.consume();
             }
         });
         background.setOnMousePressed(new EventHandler<MouseEvent>() {
             public void handle(MouseEvent me) {
+                background.requestFocus();
                 if (state == PLAYING) {
                     // Support touch-only devices like some mobile phones
                     moveBat(me.getX() - bat.getWidth() / 2);
@@ -621,6 +624,7 @@
                 if (state == GAME_OVER) {
                     mainFrame.changeState(MainFrame.SPLASH);
                 }
+                me.consume();
             }
         });
         background.setOnKeyPressed(new EventHandler<KeyEvent>() {
@@ -646,6 +650,9 @@
                 if ((ke.getCode() == KeyCode.RIGHT || ke.getCode() == KeyCode.TRACK_NEXT)) {
                     batDirection = Config.BAT_SPEED;
                 }
+                if (ke.getCode() != KeyCode.TAB) {
+                    ke.consume();
+                }
             }
         });
         background.setOnKeyReleased(new EventHandler<KeyEvent>() {
@@ -653,6 +660,7 @@
                 if (ke.getCode() == KeyCode.LEFT || ke.getCode() == KeyCode.RIGHT ||
                     ke.getCode() == KeyCode.TRACK_PREV || ke.getCode() == KeyCode.TRACK_NEXT) {
                     batDirection = 0;
+                    ke.consume();
                 }
             }
         });
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/.classpath	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+    <classpathentry kind="src" path="FX8-3DFeatures/src"/>
+    <classpathentry kind="src" path="FXSlideShow/src"/>
+    <classpathentry kind="src" path="Hello/src/main/java"/>
+    <classpathentry kind="src" path="Shape3DToy/src/main/java"/>
+    <classpathentry kind="src" path="Shape3DToy/src/main/resources"/>
+    <classpathentry kind="src" path="StretchyGrid/src/main/java"/>
+    <classpathentry combineaccessrules="false" kind="src" path="/rt">
+    <attributes>
+        <attribute name="optional" value="true"/>
+        </attributes>
+    </classpathentry>
+    <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+    <classpathentry kind="output" path="bin"/>
+</classpath>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/.project	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+	<name>toys</name>
+	<comment></comment>
+	<projects>
+	</projects>
+	<buildSpec>
+		<buildCommand>
+			<name>org.eclipse.jdt.core.javabuilder</name>
+			<arguments>
+			</arguments>
+		</buildCommand>
+	</buildSpec>
+	<natures>
+		<nature>org.eclipse.jdt.core.javanature</nature>
+	</natures>
+</projectDescription>
--- a/apps/toys/Hello/nbproject/project.xml	Sat Dec 28 08:05:35 2013 -0800
+++ b/apps/toys/Hello/nbproject/project.xml	Thu Jan 02 10:58:15 2014 -0800
@@ -1,16 +1,17 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project xmlns="http://www.netbeans.org/ns/project/1">
-    <type>org.netbeans.modules.java.j2seproject</type>
-    <configuration>
-        <data xmlns="http://www.netbeans.org/ns/j2se-project/3">
-            <name>Hello</name>
-            <source-roots>
-                <root id="src.dir"/>
-            </source-roots>
-            <test-roots>
-                <root id="test.src.dir"/>
-            </test-roots>
-        </data>
-        <references xmlns="http://www.netbeans.org/ns/ant-project-references/1"/>
-    </configuration>
-</project>
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://www.netbeans.org/ns/project/1">
+    <type>org.netbeans.modules.java.j2seproject</type>
+    <configuration>
+        <data xmlns="http://www.netbeans.org/ns/j2se-project/3">
+            <name>Hello</name>
+            <explicit-platform explicit-source-supported="true"/>
+            <source-roots>
+                <root id="src.dir"/>
+            </source-roots>
+            <test-roots>
+                <root id="test.src.dir"/>
+            </test-roots>
+        </data>
+        <references xmlns="http://www.netbeans.org/ns/ant-project-references/1"/>
+    </configuration>
+</project>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/alertdialog/Alert.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,116 @@
+/*
+ * Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package alertdialog;
+
+import javafx.stage.Window;
+
+/**
+ * This class handles creation of Alert dialog window.
+ * <hr>
+ * Procedural usage case example: 
+ * <pre>
+import xxxxx.Alert;
+
+boolean result = Alert.question(primaryStage, "Do you want to continue?");
+ * </pre>
+ * <hr>
+ */
+public class Alert {
+
+    /**
+     * The class has static methods only and can't be instantiated.
+     */
+    private Alert() {    
+    }
+    
+    /**
+     * Creates information type alert
+     *
+     * @param owner the parent window
+     * @param message Alert message
+     */
+    public static void inform(Window owner, String message) {
+        inform(owner, null, message);
+    }
+    
+    /**
+     * Creates information type alert
+     *
+     * @param owner the parent window
+     * @param title - Alert title
+     * @param message - Alert message
+     */
+    public static void inform(Window owner, String title, String message) {
+        AlertImpl.inform(owner, title, message);
+    }
+    
+    /**
+     * Creates question type alert
+     *
+     * @param owner the parent window
+     * @param message - Alert message
+     * @return User's reply: boolean representation of the reply (YES==TRUE, NO==FALSE)
+     */
+    public static boolean question(Window owner, String message) {
+        return question(owner, null, message);
+    }
+    
+    /**
+     * Creates question type alert
+     *
+     * @param owner the parent window
+     * @param title - Alert title
+     * @param message - Alert message
+     * @return User's reply: boolean representation of the reply (YES==TRUE, NO==FALSE)
+     */
+    public static boolean question(Window owner, String title, String message) {
+        return AlertImpl.question(owner, title, message);
+    }
+    
+    /**
+     * Creates confirmation type alert
+     *
+     * @param owner the parent window
+     * @param message - Alert message
+     * @return User's confirmation status: boolean representation of the reply (OK==TRUE, CANCEL==FALSE)
+     */
+    public static boolean confirm(Window owner, String message) {
+        return Alert.confirm(owner, null, message);
+    }
+    
+    /**
+     * Creates confirmation type alert
+     *
+     * @param owner the parent window
+     * @param title - Alert title
+     * @param message - Alert message
+     * @return User's confirmation status: boolean representation of the reply (OK==TRUE, CANCEL==FALSE)
+     */
+    public static boolean confirm(Window owner, String title, String message) {
+        return AlertImpl.confirm(owner, title, message);
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/alertdialog/AlertImpl.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,155 @@
+/*
+ * Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package alertdialog;
+
+import javafx.event.Event;
+import javafx.event.EventHandler;
+import javafx.geometry.Pos;
+import javafx.scene.Node;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.control.Label;
+import javafx.scene.layout.HBox;
+import javafx.scene.layout.StackPane;
+import javafx.scene.layout.VBox;
+import javafx.scene.text.Font;
+import javafx.stage.Modality;
+import javafx.stage.Stage;
+import javafx.stage.Window;
+
+public class AlertImpl {
+
+    private static enum AlertResult { YES, NO, OK, CANCEL }
+
+    private static enum AlertStyle  { DEFAULT_OPTION, YES_NO_OPTION, OK_CANCEL_OPTION };
+
+    private AlertResult result = null;
+    private Stage stage;
+
+    public static boolean question(Window owner, String title, String message) {
+        return show(owner, title, message, AlertStyle.YES_NO_OPTION) == AlertResult.YES;
+    }
+
+    public static void inform(Window owner, String title, String message) {
+        show(owner, title, message, AlertStyle.DEFAULT_OPTION);
+    }
+
+    public static boolean confirm(Window owner, String title, String message) {
+        return show(owner, title, message, AlertStyle.OK_CANCEL_OPTION) == AlertResult.OK;
+    }
+
+    private static AlertResult show(Window owner, String title, String message, AlertStyle style) {
+        AlertImpl control = new AlertImpl(owner, title, message, style);
+
+        // Show dialog and wait for it to be closed, then return the result
+        control.showAndWait();
+        return control.result;
+    }
+
+    private AlertImpl(Window owner, String title, String message, AlertStyle style) {
+        stage = new Stage();
+        stage.initModality(Modality.APPLICATION_MODAL);
+        stage.initOwner(owner);
+        stage.setTitle(title);
+
+        StackPane alertRoot = new StackPane();
+        Scene alertScene = new Scene(alertRoot, 250, 150);
+        alertRoot.getChildren().add(create(style, message));
+
+        this.stage.setScene(alertScene);
+
+    }
+
+    private void showAndWait() {
+        // Show dialog and wait for it to close.
+        stage.showAndWait();
+    }
+
+    private Node create(AlertStyle style, String message) {
+        final Button okButton     = new Button("OK");
+        final Button cancelButton = new Button("Cancel");
+        final Button yesButton    = new Button("Yes");
+        final Button noButton     = new Button("No");
+
+        okButton.setOnAction(new EventHandler() {
+            public void handle(Event event) {
+                result = AlertResult.OK;
+                closeWindow();
+            }
+        });
+        cancelButton.setOnAction(new EventHandler() {
+            public void handle(Event event) {
+                result = AlertResult.CANCEL;
+                closeWindow();
+            }
+        });
+        yesButton.setOnAction(new EventHandler() {
+            public void handle(Event event) {
+                result = AlertResult.YES;
+                closeWindow();
+            }
+        });
+        noButton.setOnAction(new EventHandler() {
+            public void handle(Event event) {
+                result = AlertResult.NO;
+                closeWindow();
+            }
+        });
+
+        Button[] buttons = null;
+
+        if (style == AlertStyle.OK_CANCEL_OPTION) {
+            buttons = new Button[] { okButton, cancelButton };
+        } else if (style == AlertStyle.YES_NO_OPTION) {
+            buttons = new Button[] { yesButton, noButton };
+        } else if (style == AlertStyle.DEFAULT_OPTION) {
+            buttons = new Button[] { okButton };
+        }
+
+        VBox alertContent = new VBox();
+        alertContent.setSpacing(10);
+        alertContent.setAlignment(Pos.CENTER);
+
+        Label messageLabel = new Label(message);
+        messageLabel.setWrapText(true);
+        messageLabel.setFont(new Font(16));
+
+        HBox buttonBox = new HBox();
+        buttonBox.setSpacing(10);
+        buttonBox.getChildren().addAll(buttons);
+        buttonBox.setAlignment(Pos.CENTER);
+
+        alertContent.getChildren().add(messageLabel);
+        alertContent.getChildren().add(buttonBox);
+
+        return alertContent;
+    }
+
+    private void closeWindow() {
+        stage.hide();
+    }
+
+}
Binary file apps/toys/Hello/src/main/java/hello/BlurryText.png has changed
Binary file apps/toys/Hello/src/main/java/hello/DukeReflection.png has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/FloodGame.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,303 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import java.util.HashSet;
+import java.util.Random;
+import java.util.Set;
+
+import javafx.animation.FadeTransition;
+import javafx.animation.Interpolator;
+import javafx.animation.SequentialTransition;
+import javafx.application.Application;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.control.Label;
+import javafx.scene.effect.Reflection;
+import javafx.scene.layout.HBox;
+import javafx.scene.layout.VBox;
+import javafx.scene.paint.Color;
+import javafx.scene.paint.CycleMethod;
+import javafx.scene.paint.LinearGradient;
+import javafx.scene.paint.Paint;
+import javafx.scene.paint.Stop;
+import javafx.scene.shape.Rectangle;
+import javafx.stage.Stage;
+import javafx.util.Duration;
+
+public class FloodGame extends Application {
+
+    final int NUMROWS = 6;
+    final int NUMCOLS = 8;
+            
+    static final Color[] colors = {
+        Color.web("#d02020"),
+        Color.web("#ff8010"),
+        Color.web("#d0e000"),
+        Color.web("#10c010"),
+        Color.web("#3030f0"),
+        Color.web("#d050ff"),
+    };
+
+    static Random rand = new Random();
+
+    private Color newColor;
+    private Cell[] cells = Cell.createCells();
+    private Set<Cell> changingCells = new HashSet<Cell>();
+  
+    boolean gameWon() {
+        Paint iColor = cells[0].getFill();
+        int count = 0;
+        for (Cell c : cells) {
+            if (iColor == c.getFill()) {
+                count++;
+            }
+        }
+        return count == NUMROWS * NUMCOLS;
+    };
+
+    public static Color randColor() {
+        return colors[rand.nextInt(colors.length)];
+    }
+   
+    private Cell cellAt(int r, int c) {
+        if (r < 0 || c < 0 || r >= NUMROWS || c >= NUMCOLS) {
+            return null;
+        } else {
+            return cells[r * NUMCOLS + c];
+        }
+    }
+
+    private Set findMatchingCells() {
+        Set set = new HashSet<Cell>(); 
+        flood(0, 0, (Color)cellAt(0, 0).getFill() , set);
+        return set;
+    }
+
+    private void flood(int r, int c, Color color, Set set){
+        Cell cell = cellAt(r, c);
+        if (cell == null)
+            return;
+        if (set.contains(cell))
+            return;
+        if (cell.getFill() == color) {
+            set.add(cell);
+            flood(r+1, c, color, set);
+            flood(r, c+1, color, set);
+            flood(r-1, c, color, set);
+            flood(r, c-1, color, set);
+        }
+    }
+
+    int numMoves = 0;
+    Label label ;
+    Label doneLabel;
+    
+    public void animate() {
+        for (Cell cell : changingCells) {
+              final Cell cellf = cell;
+             // fade out
+            FadeTransition fadeOut = new FadeTransition(Duration.millis(400), cell);
+            fadeOut.setFromValue(1);
+            fadeOut.setToValue(0);
+            fadeOut.setInterpolator(Interpolator.EASE_OUT);
+            fadeOut.setOnFinished( new EventHandler<ActionEvent>() {
+                @Override
+                public void handle(ActionEvent event) {
+                    // setFill
+                    cellf.setFill(newColor);
+                }
+            });
+
+            // fade in
+            FadeTransition fadeIn = new FadeTransition(Duration.millis(300), cell);
+            fadeIn.setFromValue(0);
+            fadeIn.setToValue(1);
+            fadeIn.setInterpolator(Interpolator.EASE_OUT);
+            fadeIn.setOnFinished(new EventHandler<ActionEvent>() {
+                // TODO not the best place to put the win check, since
+                // this gets called once for EVERY cell that's changing color
+                @Override
+                public void handle(ActionEvent event) {
+                    if (gameWon()) {
+                        doneLabel.setText("YOU WON!!");
+                    } else {
+                        doneLabel.setText("");
+                    }
+                }
+            });
+
+            SequentialTransition st = new SequentialTransition();
+            st.getChildren().addAll(fadeOut, fadeIn);
+                 
+            st.play();
+        }  
+       
+        //timeline.playFromStart();
+    }
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Flood Game in Java");
+        Scene scene = new Scene(new Group(), 500, 450);
+        Stop[] stops = new Stop[2];
+        stops[0] = new Stop(0.0f, Color.web("#e0e0e0"));
+        stops[1] = new Stop(1.0f, Color.web("#a0a0a0"));
+        LinearGradient lg = new LinearGradient(0f, 0f, 0f, 1f, true, CycleMethod.NO_CYCLE, stops);
+        scene.setFill(lg);
+
+        HBox hbox = new HBox();
+        ((Group)scene.getRoot()).getChildren().add(hbox);
+        hbox.setSpacing(30);
+        hbox.setLayoutX(30);
+        hbox.setLayoutY(30);
+
+        Group group = new Group();
+
+        Rectangle outerRect = new Rectangle();
+        outerRect.setWidth(326);
+        outerRect.setHeight(250);
+        outerRect.setFill(Color.web("#606060"));
+        outerRect.setArcWidth(16);
+        outerRect.setArcHeight(16);
+
+        group.getChildren().add(outerRect);
+
+        Group group2 = new Group();
+        group2.setLayoutX(15);
+        group2.setLayoutY(15);
+        group2.getChildren().addAll(cells);
+
+        Reflection effect = new Reflection();
+        effect.setTopOffset(30f);
+        effect.setTopOpacity(0.7f);
+        effect.setFraction(0.5f);
+        group.setEffect(effect);
+        
+        group.getChildren().add(group2);
+        hbox.getChildren().add(group);
+
+        VBox vbox = new VBox();
+        ((Group)scene.getRoot()).getChildren().add(vbox);
+
+        vbox.setSpacing(10);
+
+        for (final Color c : colors) {
+            Button button = new Button();
+            Rectangle rect = new Rectangle();
+            rect.setWidth(40);
+            rect.setHeight(10);
+            rect.setFill(c);
+            button.setGraphic(rect);
+            vbox.getChildren().add(button);
+          
+            button.setOnAction(new EventHandler<ActionEvent>() {
+                @Override public void handle(ActionEvent e) {
+                    System.out.println("Action on Button");
+                    changingCells.clear();
+                    changingCells = findMatchingCells();
+                    newColor = c;
+                    animate();
+                    numMoves += 1;
+                    label.setText("Moves: " + numMoves);
+                }
+            });
+        }
+        label = new Label();
+        label.setText("Moves: "+numMoves);
+        vbox.getChildren().add(label);
+
+        doneLabel = new Label();
+        doneLabel.setText("");
+        vbox.getChildren().add(doneLabel);
+
+        hbox.getChildren().add(vbox);
+
+        stage.setScene(scene);
+        stage.show();
+
+    }
+    /*
+     void computeKeyFrames() {
+     //            final KeyValue kv1 = new KeyValue(cell, cell.OPACITY, 0.0f);
+        //            final KeyFrame kf1 = new KeyFrame(Duration.millis(300), kv1);
+        //            kf1.setAction( new Function0<Void>() {
+        //                @Override
+        //                public Void invoke() {
+        //                   
+        //                        cell.setFill(newColor);
+        //                    
+        //                    return null;
+        //                }
+        //            });
+        //            //timeline.getKeyFrames().add(kf1);
+        //
+        //            final KeyValue kv2 = new KeyValue(cell, cell.OPACITY, 1.0f);
+        //            final KeyFrame kf2 = new KeyFrame(Duration.millis(300), kv2);
+        //            timeline.getKeyFrames().addAll(kf1, kf2);
+     }
+     */
+    
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+   
+}
+
+class Cell extends Rectangle {
+    int row;
+    int col;
+    public Cell(int row, int col) {
+        this.row = row;
+        this.col = col;
+    }
+
+    public static Cell[] createCells() {
+        Cell[] cells = new Cell[48];
+        int cellIndex = 0;
+        for (int r=0; r<6; r++) {
+            for (int c=0; c<8; c++) {
+                Cell cell = new Cell(r,c);
+                cell.setX(c * 38);
+                cell.setY(r * 38);
+                cell.setWidth(30);
+                cell.setHeight(30);
+                cell.setFill(FloodGame.randColor());
+                cell.setArcWidth(8);
+                cell.setArcHeight(8);
+                cells[cellIndex] = cell;
+                cellIndex++;
+            }
+        }
+        return cells;
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloAccordion.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,81 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.Accordion;
+import javafx.scene.control.Button;
+import javafx.scene.control.Label;
+import javafx.scene.control.TitledPane;
+import javafx.scene.paint.Color;
+import javafx.stage.Stage;
+
+public class HelloAccordion extends Application {
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Accordion Sample");
+        Scene scene = new Scene(new Group(), 500, 500);
+        scene.setFill(Color.GHOSTWHITE);
+
+        TitledPane t1 = new TitledPane();
+        t1.setId("Label 1");
+        t1.setText("Label 1");
+        t1.setContent(new Button("This is Button 1\n\nAnd there were a few empty lines just there!"));
+
+        TitledPane t2 = new TitledPane();
+        t2.setId("Label 2");
+        t2.setText("Label 2");
+        t2.setContent(new Label("This is Label 2\n\nAnd there were a few empty lines just there!"));
+
+        TitledPane t3 = new TitledPane();
+        t3.setId("Label 3");
+        t3.setText("Label 3");
+        t3.setContent(new Button("This is Button 3\n\nAnd there were a few empty lines just there!"));
+
+        Accordion accordion = new Accordion();
+
+        accordion.getPanes().add(t1);
+        accordion.getPanes().add(t2);
+        accordion.getPanes().add(t3);
+
+        Group root = (Group)scene.getRoot();
+        root.setTranslateX(50);
+        root.setTranslateY(50);
+        root.getChildren().clear();
+        root.getChildren().add(accordion);
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloAlert.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,131 @@
+/*
+ * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.animation.KeyFrame;
+import javafx.animation.KeyValue;
+import javafx.animation.Timeline;
+import javafx.application.Application;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.paint.Color;
+import javafx.scene.shape.Rectangle;
+import javafx.stage.Stage;
+import javafx.util.Duration;
+import alertdialog.Alert;
+
+public class HelloAlert extends Application {
+
+    @Override public void start(final Stage stage) {
+        stage.setTitle("Alert Test");
+
+        Group root = new Group();
+        Scene scene = new Scene(root, 600, 450);
+        scene.setFill(Color.ANTIQUEWHITE);
+
+        final Rectangle rect = new Rectangle();
+        rect.setX(100);
+        rect.setY(40);
+        rect.setWidth(100);
+        rect.setHeight(50);
+        rect.setFill(Color.RED);
+        root.getChildren().add(rect);
+        stage.setScene(scene);
+        stage.show();
+
+        final Timeline timeline = new Timeline();
+        timeline.setCycleCount(Timeline.INDEFINITE);
+        timeline.setAutoReverse(true);
+        final KeyValue kv = new KeyValue(rect.xProperty(), 200);
+        final KeyFrame kf = new KeyFrame(Duration.millis(4000), kv);
+        timeline.getKeyFrames().add(kf);
+        timeline.play();
+
+        final Button button1 = new Button();
+        button1.setText("Toggle color");
+        button1.setLayoutX(25);
+        button1.setLayoutY(40);
+        button1.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                boolean answer = Alert.confirm(stage, "Verify Change",
+                        "Really toggle the color?");
+                if (answer) {
+                    Color newColor = Color.RED.equals(rect.getFill())
+                            ? Color.GREEN : Color.RED;
+                    rect.setFill(newColor);
+                } else {
+                    System.err.println("Color change canceled");
+                }
+            }
+        });
+
+        root.getChildren().add(button1);
+
+        final Button button2 = new Button();
+        button2.setText("Question");
+        button2.setLayoutX(25);
+        button2.setLayoutY(80);
+        button2.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                boolean answer = Alert.question(stage, "SF Giants",
+                        "How about those Giants?");
+                if (answer) {
+                    System.err.println("Good answer");
+                } else {
+                    System.err.println("What do you mean 'NO' ???");
+                }
+            }
+        });
+
+        root.getChildren().add(button2);
+
+        final Button button3 = new Button();
+        button3.setText("Dialog");
+        button3.setLayoutX(25);
+        button3.setLayoutY(120);
+        button3.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                Alert.inform(stage, "Hi, I'll be your modal dialog today");
+                System.err.println("Continue");
+            }
+        });
+
+        root.getChildren().add(button3);
+
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloAnimation.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,73 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+
+import javafx.animation.KeyFrame;
+import javafx.animation.KeyValue;
+import javafx.animation.Timeline;
+import javafx.application.Application;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.paint.Color;
+import javafx.scene.shape.Rectangle;
+import javafx.stage.Stage;
+import javafx.util.Duration;
+
+public class HelloAnimation extends Application {
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello Animation");
+        final Scene scene = new Scene(new Group(), 600, 450);
+        scene.setFill(Color.LIGHTGREEN);
+        final Rectangle rect = new Rectangle();
+        rect.setX(25);
+        rect.setY(40);
+        rect.setWidth(100);
+        rect.setHeight(50);
+        rect.setFill(Color.RED);
+        ((Group)scene.getRoot()).getChildren().add(rect);
+        stage.setScene(scene);
+        stage.show();
+        
+        final Timeline timeline = new Timeline();
+        timeline.setCycleCount(Timeline.INDEFINITE);
+        timeline.setAutoReverse(true);
+        final KeyValue kv = new KeyValue(rect.xProperty(), 200);
+        final KeyFrame kf = new KeyFrame(Duration.millis(500), kv);
+        timeline.getKeyFrames().add(kf);
+        timeline.play();
+
+        System.out.println(Double.POSITIVE_INFINITY * 2);
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloAreaChart.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,69 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.collections.FXCollections;
+import javafx.collections.ObservableList;
+import javafx.scene.Scene;
+import javafx.scene.chart.AreaChart;
+import javafx.scene.chart.NumberAxis;
+import javafx.scene.chart.XYChart;
+import javafx.stage.Stage;
+
+public class HelloAreaChart extends Application {
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello AreaChart");
+        final NumberAxis xAxis = new NumberAxis();
+        final NumberAxis yAxis = new NumberAxis();
+        final AreaChart<Number,Number> ac = new AreaChart<Number,Number>(xAxis,yAxis);
+         xAxis.setLabel("X Axis");
+        yAxis.setLabel("Y Axis");
+        ac.setTitle("HelloAreaChart");
+//      // add starting data
+        ObservableList<XYChart.Data> data = FXCollections.observableArrayList();
+        XYChart.Series series = new XYChart.Series();
+        series.setName("Data Series 1");
+//        for (int i=0; i<10; i++) series.getData().add(new XYChart.Data(Math.random()*100, Math.random()*100));
+        series.getData().add(new XYChart.Data(20d, 50d));
+        series.getData().add(new XYChart.Data(40d, 80d));
+        series.getData().add(new XYChart.Data(50d, 90d));
+        series.getData().add(new XYChart.Data(70d, 30d));
+        series.getData().add(new XYChart.Data(90d, 20d));
+        Scene scene  = new Scene(ac,800,600);
+        ac.getData().add(series);
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloBarChart.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,95 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import java.util.Arrays;
+
+import javafx.application.Application;
+import javafx.collections.FXCollections;
+import javafx.scene.Scene;
+import javafx.scene.chart.BarChart;
+import javafx.scene.chart.CategoryAxis;
+import javafx.scene.chart.Chart;
+import javafx.scene.chart.NumberAxis;
+import javafx.scene.chart.XYChart;
+import javafx.stage.Stage;
+
+public class HelloBarChart extends Application {
+
+    static String[] years = {"2007", "2008", "2009"};
+    static double[] anvilsSold = { 567, 1292, 2423 };
+    static double[] skatesSold = { 956, 1665, 2559 };
+    static double[] pillsSold = { 1154, 1927, 2774 };
+    
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello BarChart");
+        Scene scene = new Scene(createBarChart(), 500, 500);
+
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    private Chart createBarChart() {
+
+        final CategoryAxis xAxis = new CategoryAxis();
+        final NumberAxis yAxis = new NumberAxis();
+        final BarChart<String,Number> bc = new BarChart<String,Number>(xAxis,yAxis);
+        bc.setTitle("Bar Chart Example");
+        xAxis.setLabel("X Axis");
+        xAxis.setCategories(FXCollections.<String>observableArrayList(Arrays.asList(years)));
+        yAxis.setLabel("Y Axis");
+        // add starting data
+        XYChart.Series<String,Number> series1 = new XYChart.Series<String,Number>();
+        series1.setName("Data Series 1");
+        XYChart.Series<String,Number> series2 = new XYChart.Series<String,Number>();
+        series2.setName("Data Series 2");
+        XYChart.Series<String,Number> series3 = new XYChart.Series<String,Number>();
+        series3.setName("Data Series 3");
+        series1.getData().add(new XYChart.Data<String,Number>(years[0], 567));
+        series1.getData().add(new XYChart.Data<String,Number>(years[1], 1292));
+        series1.getData().add(new XYChart.Data<String,Number>(years[2], 2180));
+
+        series2.getData().add(new XYChart.Data<String,Number>(years[0], 956));
+        series2.getData().add(new XYChart.Data<String,Number>(years[1], 1665));
+        series2.getData().add(new XYChart.Data<String,Number>(years[2], 2450));
+
+        series3.getData().add(new XYChart.Data<String,Number>(years[0], 800));
+        series3.getData().add(new XYChart.Data<String,Number>(years[1], 1000));
+        series3.getData().add(new XYChart.Data<String,Number>(years[2], 2800));
+
+        bc.getData().add(series1);
+        bc.getData().add(series2);
+        bc.getData().add(series3);
+        return bc;
+    }
+    
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloBorderPane.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,86 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.geometry.Insets;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.control.Label;
+import javafx.scene.control.Separator;
+import javafx.scene.control.ToolBar;
+import javafx.scene.effect.InnerShadow;
+import javafx.scene.layout.BorderPane;
+import javafx.scene.layout.FlowPane;
+import javafx.scene.paint.Color;
+import javafx.scene.shape.Circle;
+import javafx.stage.Stage;
+
+import com.sun.javafx.Logging;
+
+public class HelloBorderPane extends Application {
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+    @Override public void start(Stage stage) {
+
+        stage.setTitle("Hello BorderPane");
+
+        BorderPane borderpane = new BorderPane();
+        borderpane.setPadding(new Insets(10,10,10,10));
+        ToolBar toolbar = new ToolBar();
+        toolbar.getItems().addAll(new Button("Insert"), new Button("Delete"));
+        borderpane.setTop(toolbar);
+
+        FlowPane flow = new FlowPane();
+        flow.setHgap(4);
+        flow.setVgap(10);
+        flow.setPrefWrapLength(400);
+
+        InnerShadow shadow = new InnerShadow();
+        for (int r = 70; r > 3; r -= 4) {
+            Circle circle = new Circle();
+            circle.setEffect(shadow);
+            circle.setRadius(r);
+            circle.setFill(Color.RED);
+            flow.getChildren().add(circle);
+        }
+
+        borderpane.setCenter(flow);
+
+        borderpane.setBottom(new Label("My status is idle right now"));
+        borderpane.setLeft(new Separator());
+        borderpane.setRight(new Separator());
+
+        Scene scene = new Scene(borderpane, 500, 500);
+        stage.setScene(scene);
+        stage.show();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloBubbleChart.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,68 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.scene.Scene;
+import javafx.scene.chart.BubbleChart;
+import javafx.scene.chart.Chart;
+import javafx.scene.chart.NumberAxis;
+import javafx.scene.chart.XYChart;
+import javafx.stage.Stage;
+
+public class HelloBubbleChart extends Application {
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello BubbleChart");
+        Scene scene = new Scene(createBubbleChart(), 500, 500);
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    private Chart createBubbleChart() {
+        final NumberAxis xAxis = new NumberAxis();
+        final NumberAxis yAxis = new NumberAxis();
+        final BubbleChart<Number,Number> bc = new BubbleChart<Number,Number>(xAxis,yAxis);
+        bc.setTitle("Bubble Chart Example");
+        xAxis.setLabel("X Axis");
+        yAxis.setLabel("Y Axis");
+        // add starting data
+        XYChart.Series series1 = new XYChart.Series();
+        series1.setName("Data Series 1");
+        XYChart.Series series2 = new XYChart.Series();
+        series2.setName("Data Series 2");
+        for (int i=0; i<10; i++) series1.getData().add(new XYChart.Data(Math.random()*100, Math.random()*100, (Math.random()*10)));
+        bc.getData().add(series1);
+        return bc;
+    }
+
+     /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloButton.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,83 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+
+import javafx.application.Application;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.input.KeyEvent;
+import javafx.stage.Stage;
+
+public class HelloButton extends Application {
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello Button");
+        Scene scene = new Scene(new Group(), 600, 450);
+        Button button = new Button();
+        button.setText("Click Me");
+        button.setLayoutX(25);
+        button.setLayoutY(40);
+
+        button.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                System.out.println("Event: " + e);
+            }
+        });
+
+        button.addEventHandler(KeyEvent.KEY_RELEASED, new EventHandler<KeyEvent>() {
+            @Override public void handle(KeyEvent e) {
+                System.out.println("Event: " + e);
+            }
+        });
+
+        ((Group)scene.getRoot()).getChildren().add(button);
+
+        button = new Button();
+        button.setText("Click Me Too");
+        button.setLayoutX(25);
+        button.setLayoutY(70);
+        ((Group)scene.getRoot()).getChildren().add(button);
+
+        button = new Button();
+        button.setText("Click Me Three");
+        button.setLayoutX(25);
+        button.setLayoutY(100);
+        ((Group)scene.getRoot()).getChildren().add(button);
+
+        stage.setScene(scene);
+        stage.show();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloCSS.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,115 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.geometry.Orientation;
+import javafx.scene.Group;
+import javafx.scene.Node;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.control.Separator;
+import javafx.scene.layout.FlowPane;
+import javafx.scene.layout.StackPane;
+import javafx.scene.paint.Color;
+import javafx.scene.shape.Rectangle;
+import javafx.scene.text.Text;
+import javafx.stage.Stage;
+
+public class HelloCSS extends Application {
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello CSS");
+        Scene scene = new Scene(new Group(), 600, 450);
+        scene.setFill(Color.LIGHTGREEN);
+        scene.getStylesheets().add("hello/hello.css");
+        Rectangle rect = new Rectangle();
+        rect.getStyleClass().add("rect");
+        rect.setX(25);
+        rect.setY(40);
+        rect.setWidth(100);
+        rect.setHeight(50);
+        rect.setFill(Color.GREEN);
+        Rectangle rect2 = new Rectangle();
+        rect2.getStyleClass().add("rect");
+        rect2.setX(135);
+        rect2.setY(40);
+        rect2.setWidth(100);
+        rect2.setHeight(50);
+        rect2.setStyle(
+                "-fx-stroke: yellow;"
+              + "-fx-stroke-width: 3;"
+              + "-fx-stroke-dash-array: 5 7;"
+        );
+
+        Node swapTest = createSwapTest();
+        swapTest.setLayoutX(25);
+        swapTest.setLayoutY(110);
+
+        ((Group)scene.getRoot()).getChildren().addAll(rect,rect2,swapTest);
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    private Node createSwapTest() {
+
+        final StackPane r1 = new StackPane();
+        r1.setPrefSize(100,50);
+        r1.setStyle("-fx-base: red; -fx-border-color: red;");
+
+        final StackPane r2 = new StackPane();
+        r2.setPrefSize(100,50);
+        r2.setStyle("-fx-base: yellow; -fx-border-color: yellow;");
+
+        final Button swapButton = new Button("Move");
+        swapButton.setOnAction(new EventHandler<ActionEvent>() {
+            @Override
+            public void handle(ActionEvent actionEvent) {
+                if (swapButton.getParent() == r1) {
+                    r1.getChildren().remove(swapButton);
+                    r2.getChildren().add(swapButton);
+                } else if (swapButton.getParent() == r2) {
+                    r2.getChildren().remove(swapButton);
+                    r1.getChildren().add(swapButton);
+                }
+            }
+        });
+        r1.getChildren().add(swapButton);
+
+        FlowPane hBox = new FlowPane(Orientation.HORIZONTAL, 5, 5);
+        hBox.getChildren().addAll(r1, r2, new Text("Click button to move.\nButton's base color should match surrounding border."));
+
+        return hBox;
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloCheckBox.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,101 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.beans.binding.Bindings;
+import javafx.css.PseudoClass;
+import javafx.geometry.Insets;
+import javafx.geometry.Pos;
+import javafx.scene.Scene;
+import javafx.scene.control.CheckBox;
+import javafx.scene.control.Label;
+import javafx.scene.control.Separator;
+import javafx.scene.layout.VBox;
+import javafx.scene.paint.Color;
+import javafx.stage.Stage;
+
+public class HelloCheckBox extends Application {
+    
+    private CheckBox createSteadyStateControl(String text) {
+        
+        CheckBox checkBox = new CheckBox(text);
+        for(String pseudoClass : text.split(" ")) {
+            checkBox.pseudoClassStateChanged(PseudoClass.getPseudoClass(pseudoClass), true);
+        }
+        checkBox.setFocusTraversable(false);
+        checkBox.setMouseTransparent(true);
+        return checkBox;
+    }
+    
+    @Override public void start(Stage stage) {
+
+        CheckBox[] steadyStateControls = new CheckBox[] {
+            createSteadyStateControl("selected focused hover"),
+            createSteadyStateControl("selected focused"),
+            createSteadyStateControl("selected hover"),
+            createSteadyStateControl("indeterminate focused hover"),
+            createSteadyStateControl("indeterminate focused"),
+            createSteadyStateControl("indeterminate hover"),
+            createSteadyStateControl("hover focused"),
+            createSteadyStateControl("focused"),
+            createSteadyStateControl("hover")
+        };
+        
+        VBox steadyState = new VBox(7);
+        steadyState.setTranslateX(20);
+        steadyState.getChildren().add(new Label("Steady pseudo-class state samples")); 
+        steadyState.getChildren().addAll(steadyStateControls);
+        
+        CheckBox cbox = new CheckBox("Indeterminate CheckBox");
+        cbox.setIndeterminate(true);
+        cbox.setAllowIndeterminate(true);
+
+        Label label = new Label();
+        label.textProperty().bind(
+                Bindings.when(cbox.indeterminateProperty()).
+                        then("The check box is indeterminate").
+                        otherwise(
+                                Bindings.when(cbox.selectedProperty()).
+                                        then("The check box is selected").
+                                        otherwise("The check box is not selected"))
+        );
+
+        VBox vbox = new VBox(7);
+        vbox.setAlignment(Pos.CENTER);
+        vbox.getChildren().addAll(label, cbox, new Separator(), steadyState);
+        
+        Scene scene = new Scene(vbox, 400, 400);
+        scene.setFill(Color.SKYBLUE);
+        stage.setTitle("Hello CheckBox");
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloChoiceBox.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,76 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.control.ChoiceBox;
+import javafx.scene.layout.HBox;
+import javafx.scene.layout.VBox;
+import javafx.stage.Stage;
+
+/**
+ * Demo for {@code RadioButton}.
+ */
+public class HelloChoiceBox extends Application {
+
+    public static void main(String[] args) {
+//        com.sun.javafx.Logging.getFocusLogger().setLevel(PlatformLogger.FINE);
+        Application.launch(args);
+    }
+
+    @Override public void start(Stage stage) {
+        final ChoiceBox<String> choiceBox = new ChoiceBox<String>();
+        choiceBox.getItems().addAll("Leia Organa", "Luke Skywalker", "Han Solo");
+
+        // control buttons
+        VBox vbox = new VBox(5);
+        
+        Button slt = new Button("Select item 2");
+        slt.setOnAction(new EventHandler<ActionEvent>() {
+            public void handle(ActionEvent t) {
+                choiceBox.getSelectionModel().select(2);
+            }
+        });
+        vbox.getChildren().add(slt);
+        
+        Button clearItems = new Button("Clear items sequence");
+        clearItems.setOnAction(new EventHandler<ActionEvent>() {
+            public void handle(ActionEvent t) {
+                choiceBox.getItems().clear();
+            }
+        });
+        vbox.getChildren().add(clearItems);
+        
+        HBox hbox = new HBox(10);
+        hbox.getChildren().addAll(choiceBox, vbox);
+        stage.setScene(new Scene(hbox));
+        stage.show();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloColorPicker.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,67 @@
+/*
+ * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.event.Event;
+import javafx.event.EventHandler;
+import javafx.scene.Scene;
+import javafx.scene.control.ColorPicker;
+import javafx.scene.layout.VBox;
+import javafx.scene.paint.Color;
+import javafx.stage.Stage;
+
+public class HelloColorPicker extends Application {
+    
+    public static void main(String[] args) {
+        launch(args);
+    }
+    @Override public void start(Stage stage) {
+        stage.setTitle("ColorPicker");
+        
+        Scene scene = new Scene(new VBox(20), 620, 190);
+        VBox box = (VBox)scene.getRoot();
+        
+        final ColorPicker colorPicker = new ColorPicker();
+        // default mode is combobox (above)
+        // uncomment the line below for simple button mode
+//        colorPicker.getStyleClass().add("button");
+        // uncomment the line below for SplitMenuButton mode
+//        colorPicker.getStyleClass().add("split-button");
+        // Uncomment the line below if you do not wish to see the label next the color.
+//        colorPicker.setStyle("-fx-color-label-visible: false;");
+        box.getChildren().addAll(colorPicker);
+        
+        stage.setScene(scene);
+        stage.show();
+        colorPicker.setOnAction(new EventHandler() {
+            public void handle(Event t) {
+                Color c = colorPicker.getValue();
+                System.out.println("New Color's RGB = "+c.getRed()+" "+c.getGreen()+" "+c.getBlue());
+            }
+        });
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloComboBox.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,173 @@
+/*
+ * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.beans.value.ChangeListener;
+import javafx.beans.value.ObservableValue;
+import javafx.collections.FXCollections;
+import javafx.collections.ObservableList;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.ListCell;
+import javafx.scene.control.ListView;
+import javafx.scene.layout.HBox;
+import javafx.scene.layout.VBox;
+import javafx.scene.text.Font;
+import javafx.stage.Stage;
+import javafx.util.Callback;
+
+import javafx.scene.control.ComboBox;
+import javafx.scene.Node;
+import javafx.scene.control.Label;
+
+public class HelloComboBox extends Application {
+    
+    private final ObservableList<String> strings = FXCollections.observableArrayList(
+            "Option 1", "Option 2", "Option 3", 
+            "Option 4", "Option 5", "Option 6",
+            "Long ComboBox item 1 2 3 4 5 6 7 8 9",
+            "Option 7", "Option 8", "Option 9", "Option 10", "Option 12", "Option 13",
+            "Option 14", "Option 15", "Option 16", "Option 17", "Option 18", "Option 19",
+            "Option 20", "Option 21", "Option 22", "Option 23", "Option 24", "Option 25",
+            "Option 26", "Option 27", "Option 28", "Option 29", "Option 30", "Option 31",
+            "Option 32", "Option 33", "Option 34", "Option 35", "Option 36", "Option 37",
+            "Option 38", "Option 39", "Option 40", "Option 41", "Option 42", "Option 43",
+            "Option 44", "Option 45", "Option 46", "Option 47", "Option 48", "Option 49",
+            "Option 50", "Option 51", "Option 52", "Option 53", "Option 54", "Option 55",
+            "Option 56", "Option 57", "Option 58", "Option 59", "Option 60", "Option 61",
+            "Option 62", "Option 63", "Option 64", "Option 65", "Option 66", "Option 67",
+            "Option 68", "Option 69", "Option 70", "Option 71", "Option 72", "Option 73",
+            "Option 74", "Option 75"
+        );
+    
+    private final ObservableList<String> fonts = FXCollections.observableArrayList(Font.getFamilies());
+
+    public static void main(String[] args) {
+        launch(args);
+    }
+    
+    @Override public void start(Stage stage) {
+        stage.setTitle("ComboBox");
+        
+        // non-editable column
+        VBox nonEditBox = new VBox(15);
+        
+        ComboBox emptyPromptComboBox = new ComboBox();
+        emptyPromptComboBox.setPromptText("Prompting you here");
+        emptyPromptComboBox.setPlaceholder(new Label("There are no options available!"));
+        nonEditBox.getChildren().add(emptyPromptComboBox);
+        
+        ComboBox shortComboBox = new ComboBox();
+        shortComboBox.setItems(FXCollections.observableArrayList(strings.subList(0, 4)));
+        nonEditBox.getChildren().add(shortComboBox);
+        
+        ComboBox longComboBox = new ComboBox();
+        longComboBox.setPromptText("Make a choice...");
+        longComboBox.setItems(strings);
+        nonEditBox.getChildren().add(longComboBox);
+        
+        ComboBox fontComboBox = new ComboBox();
+        fontComboBox.setItems(fonts);
+        fontComboBox.setCellFactory(new Callback<ListView<String>, ListCell<String>>() {
+            @Override public ListCell<String> call(ListView<String> param) {
+                final ListCell<String> cell = new ListCell<String>() {
+                    @Override public void updateItem(String item, boolean empty) {
+                        super.updateItem(item, empty);
+                        if (item != null) {
+                            setText(item);
+                            setFont(new Font(item, 14));
+                        }
+                    }
+                };
+                return cell;
+            }
+        });
+        nonEditBox.getChildren().add(fontComboBox);
+        
+//        ColorPicker colorPicker = new ColorPicker();
+//        longComboBox.setItems(strings);
+//        nonEditBox.getChildren().add(colorPicker);
+        
+        // editable column
+        VBox editBox = new VBox(15);
+        
+        ComboBox comboBox2 = new ComboBox();
+        comboBox2.setId("first-editable");
+        comboBox2.setItems(FXCollections.observableArrayList(strings.subList(0, 4)));
+        comboBox2.setEditable(true);
+        editBox.getChildren().add(comboBox2);
+        
+        ComboBox<String> comboBox3 = new ComboBox<String>();
+        comboBox3.setId("second-editable");
+        comboBox3.setPromptText("Make a choice...");
+        comboBox3.setItems(strings);
+        comboBox3.setEditable(true);
+        editBox.getChildren().add(comboBox3);
+        comboBox3.valueProperty().addListener(new ChangeListener<String>() {
+            @Override public void changed(ObservableValue ov, String t, String t1) {
+                System.out.println("new value: " + t1);
+            }
+        });
+        
+        ComboBox editFontComboBox = new ComboBox();
+        editFontComboBox.setId("third-editable");
+        editFontComboBox.setItems(fonts);
+        editFontComboBox.setEditable(true);
+        editFontComboBox.setCellFactory(new Callback<ListView<String>, ListCell<String>>() {
+            @Override public ListCell<String> call(ListView<String> param) {
+                final ListCell<String> cell = new ListCell<String>() {
+                    @Override public void updateItem(String item, boolean empty) {
+                        super.updateItem(item, empty);
+                        if (item != null) {
+                            setText(item);
+                            setFont(new Font(item, 14));
+                        }
+                    }
+                };
+                return cell;
+            }
+        });
+        editBox.getChildren().add(editFontComboBox);
+        
+        
+        HBox vbox = new HBox(20);
+        vbox.setLayoutX(40);
+        vbox.setLayoutY(25);
+        
+        vbox.getChildren().addAll(nonEditBox, editBox);
+        Scene scene = new Scene(new Group(vbox), 620, 190);
+
+        stage.setScene(scene);
+        stage.show();
+        
+//        scene.impl_focusOwnerProperty().addListener(new ChangeListener<Node>() {
+//            public void changed(ObservableValue<? extends Node> ov, Node t, Node t1) {
+//                System.out.println("focus moved from " + t + " to " + t1);
+//            }
+//        });
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloControls.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,86 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+
+import javafx.application.Application;
+import javafx.geometry.Orientation;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.control.Slider;
+import javafx.scene.paint.Color;
+import javafx.stage.Stage;
+
+public class HelloControls extends Application {
+    private static String[] hellos = new String[] {
+        "Hello World",
+        "привет мир",
+        "Hola Mundo"
+    };
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello Controls");
+        Scene scene = new Scene(new Group(), 600, 450);
+        scene.setFill(Color.CHOCOLATE);
+        int offset = 0;
+        for(String hello : hellos) {
+            offset += 40;
+            Button button = new Button();
+            button.setLayoutX(25);
+            button.setLayoutY(offset);
+            button.setText(hello);
+            ((Group)scene.getRoot()).getChildren().add(button);
+        }
+        stage.setScene(scene);
+        stage.show();
+
+        // add a slider
+        offset += 40;
+        Slider slider = new Slider();
+        slider.setLayoutX(25);
+        slider.setLayoutY(offset);
+        slider.setShowTickMarks(true);
+        slider.setShowTickLabels(true);
+
+        ((Group)scene.getRoot()).getChildren().add(slider);
+
+        // add a vertical slider
+        offset += 40;
+        Slider vslider = new Slider();
+        vslider.setOrientation(Orientation.VERTICAL);
+        vslider.setLayoutX(25);
+        vslider.setLayoutY(offset);
+        ((Group)scene.getRoot()).getChildren().add(vslider);
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloCursors.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,91 @@
+/*
+ * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.scene.Cursor;
+import javafx.scene.Node;
+import javafx.scene.Scene;
+import javafx.scene.layout.StackPane;
+import javafx.scene.layout.TilePane;
+import javafx.scene.paint.Color;
+import javafx.scene.shape.Rectangle;
+import javafx.scene.text.Text;
+import javafx.stage.Stage;
+
+/**
+ */
+public class HelloCursors extends Application {
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello Cursors");
+        TilePane root = new TilePane(5, 5);
+        root.getChildren().addAll(
+            createBox(Cursor.DEFAULT),
+            createBox(Cursor.CROSSHAIR),
+            createBox(Cursor.TEXT),
+            createBox(Cursor.WAIT),
+            createBox(Cursor.SW_RESIZE),
+            createBox(Cursor.SE_RESIZE),
+            createBox(Cursor.NW_RESIZE),
+            createBox(Cursor.NE_RESIZE),
+            createBox(Cursor.N_RESIZE),
+            createBox(Cursor.S_RESIZE),
+            createBox(Cursor.W_RESIZE),
+            createBox(Cursor.E_RESIZE),
+            createBox(Cursor.OPEN_HAND),
+            createBox(Cursor.CLOSED_HAND),
+            createBox(Cursor.HAND),
+            createBox(Cursor.DISAPPEAR),
+            createBox(Cursor.MOVE),
+            createBox(Cursor.H_RESIZE),
+            createBox(Cursor.V_RESIZE),
+            createBox(Cursor.NONE)
+        );
+        Scene scene = new Scene(root, 600, 450);
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    private Node createBox(Cursor cursor) {
+        Rectangle r = new Rectangle();
+        r.setWidth(100);
+        r.setHeight(100);
+        r.setFill(Color.color(Math.random(), Math.random(), Math.random()));
+        Text t = new Text();
+        t.setText(cursor.toString());
+        StackPane stack = new StackPane();
+        stack.setCursor(cursor);
+        stack.getChildren().addAll(r, t);
+        return stack;
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloDeferSetVisible.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,76 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.application.Platform;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.paint.Color;
+import javafx.scene.shape.Rectangle;
+import javafx.stage.Stage;
+
+public class HelloDeferSetVisible extends Application {
+
+    @Override public void start(final Stage stage) {
+        stage.setTitle("Hello Rectangle (defer setVisible)");
+
+        Group root = new Group();
+        final Scene scene = new Scene(root, 600, 450);
+        scene.setFill(Color.LIGHTGREEN);
+
+        Rectangle rect = new Rectangle();
+        rect.setX(25);
+        rect.setY(40);
+        rect.setWidth(100);
+        rect.setHeight(50);
+        rect.setFill(Color.RED);
+        root.getChildren().add(rect);
+        stage.setScene(scene);
+
+        new Thread(new Runnable() {
+           public void run() {
+               System.err.println("Waiting to make stage visible");
+               try {
+                   Thread.sleep(1000);
+               } catch (InterruptedException ex) {}
+               System.err.println("Now make stage visible!");
+               Platform.runLater(new Runnable() {
+                   public void run() {
+                        stage.show();
+                   }
+               });
+           }
+        }).start();
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloEffects.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,399 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.collections.ObservableList;
+import javafx.geometry.VPos;
+import javafx.scene.Group;
+import javafx.scene.Node;
+import javafx.scene.Scene;
+import javafx.scene.effect.BlendMode;
+import javafx.scene.effect.Bloom;
+import javafx.scene.effect.BoxBlur;
+import javafx.scene.effect.DisplacementMap;
+import javafx.scene.effect.DropShadow;
+import javafx.scene.effect.FloatMap;
+import javafx.scene.effect.GaussianBlur;
+import javafx.scene.effect.InnerShadow;
+import javafx.scene.effect.Light;
+import javafx.scene.effect.Lighting;
+import javafx.scene.effect.MotionBlur;
+import javafx.scene.effect.PerspectiveTransform;
+import javafx.scene.effect.Reflection;
+import javafx.scene.paint.Color;
+import javafx.scene.shape.Circle;
+import javafx.scene.shape.Rectangle;
+import javafx.scene.text.Font;
+import javafx.scene.text.FontWeight;
+import javafx.scene.text.Text;
+import javafx.stage.Stage;
+
+public class HelloEffects extends Application {
+
+    Stage stage;
+    Scene scene;
+
+    @Override public void start(Stage stage) {
+        stage.show();
+
+        scene = new Scene(new Group(), 840, 680);
+        ObservableList<Node> content = ((Group)scene.getRoot()).getChildren();
+
+        /// Perspective
+        content.add(perspective());
+        /// DropShadow
+        content.add(dropShadow());
+        /// BlendMode
+        content.add(blendMode());
+        /// Bloom
+        content.add(bloom());
+        /// BoxBlur
+        content.add(boxBlur());
+        /// DisplacementMap
+        content.add(displacementMap());
+        /// InnerShadow
+        content.add(innerShadow());
+        /// Lighting
+        content.add(lighting());
+        /// MotionBlur
+        content.add(motionBlur());
+        /// Reflection
+        content.add(reflection());
+        /// GaussianBlur
+        content.add(gaussianBlur());
+        /// DistantLight
+        content.add(distantLight());
+        stage.setScene(scene);
+    }
+
+    static Node distantLight() {
+        Light.Distant light = new Light.Distant();
+        light.setAzimuth(-135.0f);
+        light.setElevation(30.0f);
+
+        Lighting l = new Lighting();
+        l.setLight(light);
+        l.setSurfaceScale(5.0f);
+
+        final Text t = new Text();
+        t.setText("DistantLight");
+        t.setFill(Color.RED);
+        t.setFont(Font.font("null", FontWeight.BOLD, 70));
+        t.setX(10.0f);
+        t.setY(10.0f);
+        t.setTextOrigin(VPos.TOP);
+
+        t.setEffect(l);
+
+        final Rectangle r = new Rectangle();
+        r.setFill(Color.BLACK);
+
+        Group g = new Group();
+        g.getChildren().add(r);
+        g.getChildren().add(t);
+
+        g.setTranslateY(460);
+
+        return g;
+    }
+
+    static Node perspective() {
+        Group g = new Group();
+        PerspectiveTransform pt = new PerspectiveTransform();
+        pt.setUlx(10.0f);
+        pt.setUly(10.0f);
+        pt.setUrx(310.0f);
+        pt.setUry(40.0f);
+        pt.setLrx(310.0f);
+        pt.setLry(60.0f);
+        pt.setLlx(10.0f);
+        pt.setLly(90.0f);
+
+        g.setEffect(pt);
+        g.setCache(true);
+
+        Rectangle r = new Rectangle();
+        r.setX(10.0f);
+        r.setY(10.0f);
+        r.setWidth(280.0f);
+        r.setHeight(80.0f);
+        r.setFill(Color.BLUE);
+
+        Text t = new Text();
+        t.setX(20.0f);
+        t.setY(65.0f);
+        t.setText("Perspective");
+        t.setFill(Color.YELLOW);
+        t.setFont(Font.font("null", FontWeight.BOLD, 36));
+
+        g.getChildren().add(r);
+        g.getChildren().add(t);
+        return g;
+    }
+
+    static Node gaussianBlur() {
+        Text t2 = new Text();
+        t2.setX(10.0f);
+        t2.setY(140.0f);
+        t2.setCache(true);
+        t2.setText("Blurry Text");
+        t2.setFill(Color.RED);
+        t2.setFont(Font.font("null", FontWeight.BOLD, 36));
+        t2.setEffect(new GaussianBlur());
+        return t2;
+    }
+
+    static Node reflection() {
+        Text t = new Text();
+        t.setX(10.0f);
+        t.setY(50.0f);
+        t.setCache(true);
+        t.setText("Reflections on JavaFX...");
+        t.setFill(Color.RED);
+        t.setFont(Font.font("null", FontWeight.BOLD, 30));
+
+        Reflection r = new Reflection();
+        r.setFraction(0.7f);
+
+        t.setEffect(r);
+
+        t.setTranslateY(400);
+        return t;
+    }
+
+    static Node motionBlur() {
+        Text t = new Text();
+        t.setX(20.0f);
+        t.setY(100.0f);
+        t.setText("Motion");
+        t.setFill(Color.RED);
+        t.setFont(Font.font("null", FontWeight.BOLD, 60));
+
+        MotionBlur mb = new MotionBlur();
+        mb.setRadius(15.0f);
+        mb.setAngle(-30.0f);
+
+        t.setEffect(mb);
+
+        t.setTranslateX(300);
+        t.setTranslateY(150);
+
+        return t;
+    }
+
+    static Node lighting() {
+        Light.Distant light = new Light.Distant();
+        light.setAzimuth(-135.0f);
+
+        Lighting l = new Lighting();
+        l.setLight(light);
+        l.setSurfaceScale(5.0f);
+
+        Text t = new Text();
+        t.setText("Lighting!");
+        t.setFill(Color.RED);
+        t.setFont(Font.font("null", FontWeight.BOLD, 70));
+        t.setX(10.0f);
+        t.setY(10.0f);
+        t.setTextOrigin(VPos.TOP);
+
+        t.setEffect(l);
+
+        t.setTranslateX(0);
+        t.setTranslateY(320);
+
+        return t;
+    }
+
+    static Node innerShadow() {
+        InnerShadow is = new InnerShadow();
+        is.setOffsetX(4.0f);
+        is.setOffsetY(4.0f);
+
+        Text t = new Text();
+        t.setEffect(is);
+        t.setX(20);
+        t.setY(100);
+        t.setText("InnerShadow");
+        t.setFill(Color.YELLOW);
+        t.setFont(Font.font("null", FontWeight.BOLD, 80));
+
+        t.setTranslateX(300);
+        t.setTranslateY(300);
+
+        return t;
+    }
+
+    static Node displacementMap() {
+        int w = 220;
+        int h = 100;
+        FloatMap map = new FloatMap();
+        map.setWidth(w);
+        map.setHeight(h);
+
+        for (int i = 0; i < w; i++) {
+            double v = (Math.sin(i / 50.0 * Math.PI) - 0.5) / 40.0;
+            for (int j = 0; j < h; j++) {
+                map.setSamples(i, j, 0.0f, (float) v);
+            }
+        }
+
+        Group g = new Group();
+        DisplacementMap dm = new DisplacementMap();
+        dm.setMapData(map);
+
+        Rectangle r = new Rectangle();
+        r.setX(20.0f);
+        r.setY(20.0f);
+        r.setWidth(w);
+        r.setHeight(h);
+        r.setFill(Color.BLUE);
+
+        g.getChildren().add(r);
+
+        Text t = new Text();
+        t.setX(40.0f);
+        t.setY(80.0f);
+        t.setText("Wavy Text");
+        t.setFill(Color.YELLOW);
+        t.setFont(Font.font("null", FontWeight.BOLD, 36));
+
+        g.getChildren().add(t);
+
+        g.setEffect(dm);
+        g.setCache(true);
+
+        g.setTranslateX(300);
+        g.setTranslateY(200);
+
+        return g;
+    }
+
+    static Node boxBlur() {
+        Text t = new Text();
+        t.setText("Blurry Text!");
+        t.setFill(Color.RED);
+        t.setFont(Font.font("null", FontWeight.BOLD, 36));
+        t.setX(10);
+        t.setY(40);
+
+        BoxBlur bb = new BoxBlur();
+        bb.setWidth(15);
+        bb.setHeight(15);
+        bb.setIterations(3);
+
+        t.setEffect(bb);
+        t.setTranslateX(300);
+        t.setTranslateY(100);
+
+        return t;
+    }
+
+    static Node blendMode() {
+        Rectangle r = new Rectangle();
+        r.setX(290);
+        r.setY(50);
+        r.setWidth(50);
+        r.setHeight(50);
+        r.setFill(Color.BLUE);
+
+        Circle c = new Circle();
+        c.setFill(Color.rgb(255, 0, 0, 0.5f));
+        c.setCenterX(290);
+        c.setCenterY(50);
+        c.setRadius(25);
+        c.setBlendMode(BlendMode.MULTIPLY);
+
+        Group g = new Group();
+        g.getChildren().add(r);
+        g.getChildren().add(c);
+        return g;
+    }
+
+    static Node dropShadow() {
+        Group g = new Group();
+        DropShadow ds = new DropShadow();
+        ds.setOffsetY(3.0f);
+        ds.setColor(Color.color(0.4f, 0.4f, 0.4f));
+
+        Text t = new Text();
+        t.setEffect(ds);
+        t.setCache(true);
+        t.setX(10.0f);
+        t.setY(270.0f);
+        t.setFill(Color.RED);
+        t.setText("JavaFX drop shadow...");
+        t.setFont(Font.font("null", FontWeight.BOLD, 32));
+
+        DropShadow ds1 = new DropShadow();
+        ds1.setOffsetY(4.0f);
+
+        Circle c = new Circle();
+        c.setEffect(ds1);
+        c.setCenterX(50.0f);
+        c.setCenterY(325.0f);
+        c.setRadius(30.0f);
+        c.setFill(Color.ORANGE);
+        c.setCache(true);
+
+        g.getChildren().add(t);
+        g.getChildren().add(c);
+        return g;
+    }
+
+    static Node bloom() {
+        Group g = new Group();
+
+        Rectangle r = new Rectangle();
+        r.setX(10);
+        r.setY(10);
+        r.setWidth(160);
+        r.setHeight(80);
+        r.setFill(Color.DARKBLUE);
+
+        Text t = new Text();
+        t.setText("Bloom!");
+        t.setFill(Color.YELLOW);
+        t.setFont(Font.font("null", FontWeight.BOLD, 36));
+        t.setX(25);
+        t.setY(65);
+
+        g.setCache(true);
+        g.setEffect(new Bloom());
+        g.getChildren().add(r);
+        g.getChildren().add(t);
+        g.setTranslateX(350);
+        return g;
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloFPS.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,110 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.animation.KeyFrame;
+import javafx.animation.KeyValue;
+import javafx.animation.Timeline;
+import javafx.application.Application;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.paint.Color;
+import javafx.scene.shape.Rectangle;
+import javafx.scene.text.Font;
+import javafx.scene.text.Text;
+import javafx.stage.Stage;
+import javafx.util.Duration;
+
+import com.sun.javafx.perf.PerformanceTracker;
+
+public class HelloFPS extends Application {
+
+    private static final Color colors[] = {
+        Color.RED,
+        Color.ORANGE,
+        Color.YELLOW,
+        Color.GREEN,
+        Color.BLUE,
+        Color.INDIGO,
+        Color.VIOLET
+    };
+
+    private int curColorIdx = 0;
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello FPS");
+        final Scene scene = new Scene(new Group(), 600, 450);
+        scene.setFill(Color.color(0.8, 0.8, 0.7));
+
+        final Rectangle rect = new Rectangle(5, 5, Color.GRAY);
+        rect.setLayoutX(5);
+        rect.setLayoutY(5);
+
+        final Text text = new Text("??? fps");
+        text.setFont(new Font(30));
+        text.setFill(colors[curColorIdx]);
+        text.setLayoutX(5);
+        text.setLayoutY(45);
+
+        ((Group)scene.getRoot()).getChildren().addAll(rect, text);
+        stage.setScene(scene);
+        stage.show();
+
+        final Timeline timeline = new Timeline();
+        timeline.setCycleCount(Timeline.INDEFINITE);
+        timeline.setAutoReverse(true);
+        final KeyValue kv = new KeyValue (rect.layoutXProperty(), 25);
+        final KeyFrame kf = new KeyFrame(Duration.millis(5000), kv);
+        timeline.getKeyFrames().add(kf);
+        timeline.play();
+
+        final PerformanceTracker tracker = PerformanceTracker.getSceneTracker(scene);
+
+        final Timeline tlTracker = new Timeline();
+        tlTracker.setCycleCount(Timeline.INDEFINITE);
+        final KeyFrame kfTracker = new KeyFrame(
+                Duration.millis(500),
+                new EventHandler<ActionEvent>() {
+            public void handle(ActionEvent event){
+                int fps = (int) Math.round(tracker.getInstantFPS());
+                text.setText("" + fps + " fps");
+                curColorIdx = (curColorIdx + 1) % colors.length;
+                text.setFill(colors[curColorIdx]);
+            }
+        });
+        tlTracker.getKeyFrames().add(kfTracker);
+        tlTracker.play();
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloFontSize.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,237 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import java.util.Set;
+import javafx.application.Application;
+import javafx.beans.property.BooleanProperty;
+import javafx.beans.property.BooleanPropertyBase;
+import javafx.beans.value.ChangeListener;
+import javafx.beans.value.ObservableValue;
+import javafx.css.PseudoClass;
+import javafx.event.EventHandler;
+import javafx.scene.Group;
+import javafx.scene.Node;
+import javafx.scene.Scene;
+import javafx.scene.control.*;
+import javafx.scene.input.MouseEvent;
+import javafx.scene.layout.HBox;
+import javafx.scene.layout.VBox;
+import javafx.scene.text.Font;
+import javafx.scene.text.Text;
+import javafx.stage.Stage;
+
+public class HelloFontSize extends Application {
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Font Size Test");
+        Group group = new Group();
+
+        Button button = new Button();
+        button.setText("Dummy Button");
+        button.setLayoutX(10);
+        button.setLayoutY(10);
+
+        Text textInstr = new Text("The following two strings should be of different sizes:");
+        textInstr.setFont(new Font(14.0f));
+        textInstr.setLayoutX(10);
+        textInstr.setLayoutY(100);
+
+        Text text12 = new Text("Tiny string: 10pt Font");
+        text12.setFont(new Font(10.0f));
+        text12.setLayoutX(10);
+        text12.setLayoutY(130);
+
+        Text text72 = new Text("Big string: 72pt Font");
+        text72.setFont(new Font(72.0f));
+        text72.setLayoutX(10);
+        text72.setLayoutY(200);
+
+        group.getChildren().addAll(textInstr, text12, text72, button);
+
+        ToggleGroup tg = new ToggleGroup();
+        ToggleButton t1 = new ToggleButton("First");
+        t1.setId("t1");
+        t1.setToggleGroup(tg);
+
+        ToggleGroup tg2 = new ToggleGroup();
+        ToggleButton t2 = new ToggleButton("Second");
+        t2.setId("t2");
+        t2.setToggleGroup(tg);
+
+        ToggleButton t4 = new ToggleButton("Disable");
+        t4.setToggleGroup(tg);
+        t4.setDisable(true);
+
+        ToggleButton t5 = new ToggleButton("Long ..... really Long");
+        t5.setId("t5");
+        t5.setToggleGroup(tg);
+
+        final ToggleButton t6 = new ToggleButton("Big!");
+        t6.setId("t6");
+        t6.setStyle("-fx-font-size: 1.5em;");
+        t6.setToggleGroup(tg);
+        t6.fontProperty().addListener(new ChangeListener<Font>(){
+
+            public void changed(ObservableValue<? extends Font> ov, Font t, Font t1) {
+                double fsize = t1.getSize();
+                fsize = Math.round(fsize*10.0)/10.0;                
+                t6.setText(fsize + "px");
+            }
+        });
+
+        final HBox hbox = new HBox();
+        hbox.setId("toggle-buttons");
+        hbox.setSpacing(3);
+        hbox.getChildren().addAll(t1,t2,t4,t5,t6);
+
+        final Slider slider = new Slider();
+        slider.setId("FontSizeSlider");
+        slider.setMin(9);
+        slider.setMax(28);
+        slider.setBlockIncrement(1);
+        slider.setMajorTickUnit(1);
+        slider.setSnapToTicks(true);
+
+        final Label lbl = new Label("Adjust font size here");
+
+        final HBox hbox2 = new HBox(5);
+        hbox2.getChildren().addAll(slider, lbl);
+        
+        final VBox vbox = new VBox(5);
+        vbox.getChildren().addAll(
+            new Text("Move the slider, click around, hover here and there.\n"
+                    +"Make sure the buttons don't magically resize.\n"
+                    +"The font size of the last button is 1.5em.\n"
+                    +"The text of the last button is the font size rounded to nearest 10th"), hbox, hbox2);
+        
+        vbox.setLayoutX(10);
+        vbox.setLayoutY(300);
+
+        final Group root = new Group();
+        root.getChildren().addAll(group, vbox);
+
+        slider.skinProperty().addListener(new ChangeListener<Skin>() {
+
+            public void changed(ObservableValue<? extends Skin> ov, Skin t, Skin t1) {
+                if (t1 != null) {
+                    slider.setValue(14);
+                }
+            }
+        });
+
+        slider.valueProperty().addListener(new ChangeListener<Number>() {
+
+            public void changed(ObservableValue<? extends Number> ov, Number t, Number t1) {
+                hbox.setStyle("-fx-font: " + t1.toString() + "px \"Comic Sans MS\";");
+            }
+        });
+        
+        hbox.styleProperty().addListener(new ChangeListener<String>() {
+
+            public void changed(ObservableValue<? extends String> ov, String t, String t1) {
+                lbl.setText(hbox.getStyle());
+            }
+        });
+
+        // RT-28635
+        final SpecialButton specialButton = new SpecialButton("Button");
+        
+        final VBox rt28635 = new VBox(5);
+        rt28635.getStylesheets().add(HelloFontSize.class.getResource("hello.css").toExternalForm());
+        
+        rt28635.getChildren().addAll(
+            new Text("A mouse-press on this button should cause the font size to be set to 20.\n" +
+                "The font size and button size should return to normal on mouse-release."), specialButton);
+        
+        rt28635.setLayoutX(10);
+        rt28635.setLayoutY(500);        
+        root.getChildren().add(rt28635);
+        
+        Scene scene = new Scene(root, 800, 600);  
+        stage.setScene(scene);
+        stage.show();
+    }
+    
+    private static class SpecialButton extends Button {
+        
+        public static final String PSEUDO_CLASS_NAME = "mouse_pressed";
+        public static final String STYLE_CLASS_NAME = "special-button";
+
+        {
+            getStyleClass().add(STYLE_CLASS_NAME);
+            
+            setOnMousePressed(new EventHandler<MouseEvent>() {
+                @Override
+                public void handle(MouseEvent t) {
+                    pseudoClassStateChanged(MOUSE_PRESSED_PSEUDO_CLASS,true);
+                }
+            });        
+
+            setOnMouseReleased(new EventHandler<MouseEvent>() {
+                @Override
+                public void handle(MouseEvent t) {
+                    pseudoClassStateChanged(MOUSE_PRESSED_PSEUDO_CLASS,false);
+                }
+            });      
+        }
+
+        public SpecialButton() {
+            super();
+        }
+
+        public SpecialButton(String str) {
+            super(str);
+        }
+
+        private static final PseudoClass MOUSE_PRESSED_PSEUDO_CLASS = 
+                PseudoClass.getPseudoClass(PSEUDO_CLASS_NAME);
+        
+        private BooleanProperty pressedPseudoState = new BooleanPropertyBase(false) {
+            @Override
+            protected void invalidated() {
+                pseudoClassStateChanged(MOUSE_PRESSED_PSEUDO_CLASS, get());
+            }
+
+            @Override
+            public Object getBean() {
+                return this;
+            }
+
+            @Override
+            public String getName() {
+                return PSEUDO_CLASS_NAME;
+            }
+        };
+    }
+    
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloFonts.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,218 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.collections.FXCollections;
+import javafx.scene.Node;
+import javafx.scene.Scene;
+import javafx.scene.control.*;
+import javafx.scene.control.cell.PropertyValueFactory;
+import javafx.scene.text.Font;
+import javafx.scene.text.FontPosture;
+import javafx.scene.text.FontWeight;
+import javafx.stage.Stage;
+import javafx.util.Callback;
+
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ */
+public class HelloFonts extends Application {
+    /**
+     * @param args command line args
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+    public static String sampleText = "ABCDEFGabcdefg";
+    public static float fontSize = 14;
+    public static class FontData {
+        String name; /*either font name or family*/
+        FontWeight weight;
+        FontPosture posture;
+        boolean nameIsFamily;
+        public FontData(String fontName) {
+            name = fontName;
+        }
+        public FontData(String family, FontWeight weight, FontPosture posture) {
+            name = family;
+            this.posture = posture;
+            this.weight = weight;
+            nameIsFamily = true;
+        }
+        public String getFontName() {return getFont().toString();}
+        public String getName() {return name;}
+        public String getWeight() {return weight.name();}
+        public String getPosture() {return posture.name();}
+        private Font font;
+        public Font getFont() {
+            if (font == null) {
+                if (nameIsFamily) {
+                    font = Font.font(name, weight, posture, fontSize);
+                } else {
+                    font = new Font(name, fontSize);
+                }
+            }
+            return font;
+        }
+    }
+
+    public Node createAllFontsTab() {
+        List<String> fonts = Font.getFontNames();
+        List<FontData> data = new ArrayList<FontData>();
+        for (String font : fonts) {
+            data.add(new FontData(font));
+        }
+        TableView<FontData> table = new TableView<FontData>();
+        TableColumn<FontData, String> column0 = new TableColumn<FontData, String>("Requested name");
+        column0.setCellValueFactory(
+                new PropertyValueFactory<FontData,String>("name")
+        );
+        TableColumn<FontData, String> column1 = new TableColumn<FontData, String>("Font name");
+        column1.setCellValueFactory(
+                new PropertyValueFactory<FontData,String>("fontName")
+        );
+        TableColumn<FontData, Font> column2 = new TableColumn<FontData, Font>("sample");
+        column2.setCellValueFactory(
+                new PropertyValueFactory<FontData,Font>("font")
+        );
+        column2.setCellFactory(new Callback<TableColumn<FontData, Font>, TableCell<FontData,Font>>() {
+            @Override
+            public TableCell<FontData, Font> call(TableColumn<FontData, Font> param) {
+                return new TableCell<FontData, Font>() {
+                    @Override
+                    protected void updateItem(Font item, boolean empty) {
+//                        if (item == getItem()) return;
+                        if (item == null) System.err.println("**********NULL why is it null");
+                        setText(sampleText);
+                        if (item != null) setFont(item);
+                    }
+                };
+            }
+        });
+        table.setItems(FXCollections.observableList(data));
+        table.getColumns().addAll(column0, column2, column1);
+        return table;
+    }
+
+    public Node createFontsByStyleTab() {
+        List<String> families = Font.getFamilies();
+        List<FontData> data = new ArrayList<FontData>();
+        for (String family : families) {
+            data.add(new FontData(family, FontWeight.NORMAL, FontPosture.REGULAR));
+            data.add(new FontData(family, FontWeight.BOLD, FontPosture.REGULAR));
+            data.add(new FontData(family, FontWeight.NORMAL, FontPosture.ITALIC));
+            data.add(new FontData(family, FontWeight.BOLD, FontPosture.ITALIC));
+        }
+        TableView<FontData> table = new TableView<FontData>();
+        TableColumn<FontData, String> column0 = new TableColumn<FontData, String>("Family");
+        column0.setCellValueFactory(
+                new PropertyValueFactory<FontData,String>("name")
+        );
+        TableColumn<FontData, String> column1 = new TableColumn<FontData, String>("Weight");
+        column1.setCellValueFactory(
+                new PropertyValueFactory<FontData,String>("weight")
+        );
+        TableColumn<FontData, String> column2 = new TableColumn<FontData, String>("Posture");
+        column2.setCellValueFactory(
+                new PropertyValueFactory<FontData,String>("posture")
+        );
+        TableColumn<FontData, String> column3 = new TableColumn<FontData, String>("Font");
+        column3.setCellValueFactory(
+                new PropertyValueFactory<FontData,String>("font")
+        );
+        TableColumn<FontData, Font> column4 = new TableColumn<FontData, Font>("Sample");
+        column4.setCellValueFactory(
+                new PropertyValueFactory<FontData,Font>("font")
+        );
+        column4.setCellFactory(new Callback<TableColumn<FontData, Font>, TableCell<FontData,Font>>() {
+            @Override
+            public TableCell<FontData, Font> call(TableColumn<FontData, Font> param) {
+                return new TableCell<FontData, Font>() {
+                    @Override
+                    protected void updateItem(Font item, boolean empty) {
+//                        if (item == getItem()) return;
+                        if (item == null) System.err.println("**********NULL why is it null");
+                        setText(sampleText);
+                        if (item != null) setFont(item);
+                    }
+                };
+            }
+        });
+
+        table.setItems(FXCollections.observableList(data));
+        table.getColumns().addAll(column0, column1, column2, column4, column3);
+        return table;
+    }
+
+    public Node createFontFamiliesTab() {
+        TreeItem<String> root = new TreeItem<String>();
+        TreeView<String> tree = new TreeView<String>(root);
+        tree.setShowRoot(false);
+        List<String> families = Font.getFamilies();
+        for (String family : families) {
+            TreeItem<String> item = new TreeItem<String>(family);
+            root.getChildren().add(item);
+            List<String> fonts = Font.getFontNames(family);
+            for (String font : fonts) {
+                TreeItem<String> subItem = new TreeItem<String>(font);
+                item.getChildren().add(subItem);
+            }
+        }
+        return tree;
+    }
+
+    @Override
+    public void start(Stage stage) throws Exception {
+        TabPane tabPane = new TabPane();
+        Tab tab = new Tab();
+        tab.setText("All fonts");
+        tab.setContent(createAllFontsTab());
+        tab.setClosable(false);
+        tabPane.getTabs().add(tab);
+
+        tab = new Tab();
+        tab.setText("Font families");
+        tab.setContent(createFontFamiliesTab());
+        tab.setClosable(false);
+        tabPane.getTabs().add(tab);
+
+        tab = new Tab();
+        tab.setText("Fonts by style");
+        tab.setContent(createFontsByStyleTab());
+        tab.setClosable(false);
+        tabPane.getTabs().add(tab);
+
+        Scene scene = new Scene(tabPane, 800, 400);
+        stage.setTitle("Font loading testcase");
+        stage.setScene(scene);
+        stage.show();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloFullscreen.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,88 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.application.Platform;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.paint.Color;
+import javafx.scene.shape.Rectangle;
+import javafx.stage.Stage;
+
+public class HelloFullscreen extends Application {
+
+    @Override public void start(final Stage stage) {
+        stage.setFullScreen(true);
+        stage.setTitle("Hello Fullscreen");
+
+        Group root = new Group();
+        Scene scene = new Scene(root, 600, 450);
+        scene.setFill(Color.LIGHTGREEN);
+        Rectangle rect = new Rectangle();
+        rect.setX(15);
+        rect.setY(20);
+        rect.setWidth(100);
+        rect.setHeight(50);
+        rect.setFill(Color.RED);
+        root.getChildren().add(rect);
+
+        Button button = new Button();
+        button.setText("Exit");
+        button.setLayoutX(15);
+        button.setLayoutY(100);
+        button.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                Platform.exit();
+            }
+        });
+        root.getChildren().add(button);
+
+        Button button2 = new Button();
+        button2.setText("Close");
+        button2.setLayoutX(75);
+        button2.setLayoutY(100);
+        button2.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                stage.hide();
+            }
+        });
+        root.getChildren().add(button2);
+
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloFullscreenAnim.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,105 @@
+/*
+ * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+
+import javafx.animation.KeyFrame;
+import javafx.animation.KeyValue;
+import javafx.animation.Timeline;
+import javafx.application.Application;
+import javafx.application.Platform;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.geometry.Rectangle2D;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.paint.Color;
+import javafx.scene.shape.Rectangle;
+import javafx.stage.Screen;
+import javafx.stage.Stage;
+import javafx.util.Duration;
+
+public class HelloFullscreenAnim extends Application {
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello Animation");
+        stage.setFullScreen(true);
+
+        Rectangle2D screenBounds = Screen.getPrimary().getBounds();
+        Group root = new Group();
+        final Scene scene = new Scene(root, screenBounds.getWidth(), screenBounds.getHeight());
+        scene.setFill(Color.LIGHTGREEN);
+
+        final Rectangle rect1 = new Rectangle();
+        rect1.setX(25);
+        rect1.setY(200);
+        rect1.setWidth(100);
+        rect1.setHeight(50);
+        rect1.setFill(Color.BLUEVIOLET);
+        root.getChildren().add(rect1);
+
+        final Rectangle rect2 = new Rectangle();
+        rect2.setX(700);
+        rect2.setY(475);
+        rect2.setWidth(100);
+        rect2.setHeight(50);
+        rect2.setFill(Color.RED);
+        root.getChildren().add(rect2);
+
+        Button button = new Button();
+        button.setText("Exit");
+        button.setLayoutX(15);
+        button.setLayoutY(100);
+        button.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                Platform.exit();
+            }
+        });
+        root.getChildren().add(button);
+
+        stage.setScene(scene);
+        stage.show();
+
+        final Timeline timeline = new Timeline();
+        timeline.setCycleCount(Timeline.INDEFINITE);
+        timeline.setAutoReverse(true);
+        final KeyValue kv1 = new KeyValue(rect1.xProperty(), 200);
+        final KeyValue kv2 = new KeyValue(rect2.xProperty(), 1100);
+        final KeyFrame kf = new KeyFrame(Duration.millis(1000), kv1, kv2);
+        timeline.getKeyFrames().add(kf);
+        timeline.play();
+
+        System.out.println(Double.POSITIVE_INFINITY * 2);
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloFullscreenToggle.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,67 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.paint.Color;
+import javafx.stage.Stage;
+
+public class HelloFullscreenToggle extends Application {
+
+    @Override public void start(final Stage stage) {
+        stage.setTitle("Hello Fullscreen Toggle");
+
+        Group root = new Group();
+        Scene scene = new Scene(root, 600, 450);
+        scene.setFill(Color.LIGHTBLUE);
+
+        Button button = new Button();
+        button.setText("Toggle Fullscreen");
+        button.setLayoutX(25);
+        button.setLayoutY(40);
+        button.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                stage.setFullScreen(!stage.isFullScreen());
+            }
+        });
+
+        root.getChildren().add(button);
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloHTMLEditor.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,82 @@
+/*
+ * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+
+import javafx.application.Application;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.geometry.Insets;
+import javafx.geometry.Orientation;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.layout.FlowPane;
+import javafx.scene.paint.Color;
+import javafx.scene.web.HTMLEditor;
+import javafx.stage.Stage;
+
+public class HelloHTMLEditor extends Application {
+    private HTMLEditor htmlEditor = null;
+
+    @Override
+    public void start(Stage stage) {
+        stage.setTitle("Hello HTMLEditor");
+        stage.setWidth(800);
+        stage.setHeight(600);
+        Scene scene = new Scene(new Group());
+        scene.setFill(Color.GHOSTWHITE);
+
+        FlowPane root = new FlowPane();
+        root.setOrientation(Orientation.VERTICAL);
+        scene.setRoot(root);
+
+        root.setPadding(new Insets(8, 8, 8, 8));
+        root.setVgap(8);
+
+        htmlEditor = new HTMLEditor();
+        root.getChildren().add(htmlEditor);
+
+        Button dumpHTMLButton = new Button("Dump HTML");
+        dumpHTMLButton.setOnAction(new EventHandler<ActionEvent>() {
+            @Override
+            public void handle(ActionEvent arg0) {
+                System.out.println(htmlEditor.getHtmlText());
+            }
+        });
+
+        root.getChildren().add(dumpHTMLButton);
+
+        htmlEditor.setHtmlText("<html><body>Hello, World!</body></html>");
+
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    public static void main(String[] args) {
+        Application.launch(HelloHTMLEditor.class, args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloHyperlink.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,78 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.Hyperlink;
+import javafx.scene.image.Image;
+import javafx.scene.image.ImageView;
+import javafx.scene.paint.Color;
+import javafx.stage.Stage;
+
+public class HelloHyperlink extends Application {
+
+    private static final String animImageURL = "file:animated_89_c.gif";
+
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello Hyperlink");
+        Scene scene = new Scene(new Group(), 600, 450);
+        scene.setFill(Color.GHOSTWHITE);
+
+        Hyperlink link = new Hyperlink();
+        link.setLayoutX(25);
+        link.setLayoutY(40);
+        link.setText("I am a hyperlink!");
+        ((Group)scene.getRoot()).getChildren().add(link);
+
+        Hyperlink animatedLink = new Hyperlink();
+        animatedLink.setLayoutX(25);
+        animatedLink.setLayoutY(100);
+        animatedLink.setText("I am a hyperlink with an animated Image!");
+        animatedLink.setGraphic(imageView(animImageURL, 0, 0, 16, 16));
+        ((Group)scene.getRoot()).getChildren().add(animatedLink);
+
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    private static ImageView imageView(String url, int x, int y, int w, int h) {
+        ImageView imageView = new ImageView();
+        imageView.setX(x);
+        imageView.setY(y);
+        imageView.setFitWidth(w);
+        imageView.setFitHeight(h);
+        imageView.setPreserveRatio(true);
+        imageView.setImage(new Image(url));
+        return imageView;
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloImage.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,110 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.collections.ObservableList;
+import javafx.geometry.Dimension2D;
+import javafx.scene.Cursor;
+import javafx.scene.Group;
+import javafx.scene.ImageCursor;
+import javafx.scene.Node;
+import javafx.scene.Scene;
+import javafx.scene.image.Image;
+import javafx.scene.image.ImageView;
+import javafx.scene.paint.Color;
+import javafx.stage.Stage;
+
+public class HelloImage extends Application {
+
+    private static final String imageURL = "hello/JavaFX.png";
+    //1862x2327 size of duke
+    private static final String slowImageURL =
+            "http://duke.kenai.com/misc/DrinkingBeer.jpg";
+    private static final String animImageURL = "hello/animated_89_c.gif";
+    private static final String animCursorURL = "hello/javafx-loading-32x32.gif";
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello Image");
+
+        Scene scene = new Scene(new Group(), 600, 450);
+        scene.setFill(Color.LIGHTGRAY);
+        ObservableList<Node> seq = ((Group)scene.getRoot()).getChildren();
+
+        Dimension2D d = ImageCursor.getBestSize(1,1);
+
+        System.err.println("BestCursor Size ="+d);
+
+        Image animImage = new Image(animImageURL);
+        
+        addImageToObservableList(seq, 160, 20, 420, 120, new Image(imageURL),
+                           createImageCursor(animImageURL, 16, 16));
+//        addImageToObservableList(seq, 20, 20, 120, 120, animImage,
+//                           createImageCursor(animCursorURL, 0, 0));
+        
+        final Image slowImage = new Image(slowImageURL, true);
+        addImageToObservableList(seq, 20, 160, 560, 250, slowImage, Cursor.CROSSHAIR);
+
+
+        addImageToObservableList(seq, 20, 20, 120, 120, animImage,
+                           createImageCursor(slowImageURL, 1862*0.4f, 0));
+
+        stage.getIcons().add(slowImage);
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    private static void addImageToObservableList(ObservableList<Node> seq,
+                                           int x, int y,
+                                           int w, int h,
+                                           Image image,
+                                           Cursor cursor) {
+        ImageView imageView = new ImageView();
+        imageView.setX(x);
+        imageView.setY(y);
+        imageView.setFitWidth(w);
+        imageView.setFitHeight(h);
+        imageView.setPreserveRatio(true);
+        imageView.setImage(image);
+        imageView.setCursor(cursor);
+        seq.add(imageView);
+    }
+
+    private static Cursor createImageCursor(final String url,
+                                            final float hotspotX,
+                                            final float hotspotY) {
+
+        final Image cursorImage = new Image(url, 32, 32, false, true, true);
+        return new ImageCursor(cursorImage, hotspotX, hotspotY);
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloImageClipboard.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,153 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.image.ImageView;
+import javafx.scene.input.Clipboard;
+import javafx.scene.input.ClipboardContent;
+import javafx.scene.input.DragEvent;
+import javafx.scene.input.TransferMode;
+import javafx.scene.paint.Color;
+import javafx.scene.shape.Rectangle;
+import javafx.stage.Stage;
+
+public class HelloImageClipboard extends Application {
+
+    private Button  clearBtn, copyBtn, pasteBtn;
+    final ImageView imageView = new ImageView();
+
+    @Override public void start(Stage stage) {
+        //stage.initStyle(StageStyle.UNDECORATED);
+        stage.setTitle("Hello Image Clipboard");
+        Scene scene = new Scene(new Group(), 1024, 768);
+        scene.setFill(Color.LIGHTGREEN);
+
+        Rectangle overlay = new Rectangle();
+        overlay.setWidth(800);
+        overlay.setHeight(600);
+        overlay.setFill(Color.TRANSPARENT);
+        EventHandler<DragEvent> drop =  new EventHandler<DragEvent>() {
+                public void handle(DragEvent de) {
+                    checkBoard(de.getDragboard(), de);
+                }
+            };
+            
+        EventHandler<DragEvent> enter =  new EventHandler<DragEvent>() {
+                public void handle(DragEvent de) {
+                    if (de != null && de.getDragboard() != null && de.getDragboard().hasImage()) {
+                        de.acceptTransferModes(TransferMode.ANY);
+                    }
+                }
+            };
+
+        EventHandler<DragEvent> dragged =  new EventHandler<DragEvent>() {
+                public void handle(DragEvent de) {
+                    if (de != null && de.getDragboard() != null && de.getDragboard().hasImage()) {
+                        de.acceptTransferModes(TransferMode.ANY);
+                    }
+                }
+            };
+
+        overlay.setOnDragDropped(drop);
+        overlay.setOnDragEntered(enter);
+        overlay.setOnDragOver(dragged);
+
+        clearBtn = new Button("Clear");
+        clearBtn.setTranslateX(50);
+        clearBtn.setTranslateY(30);
+
+        copyBtn = new Button("Copy");
+        copyBtn.setTranslateX(125);
+        copyBtn.setTranslateY(30);
+        
+        pasteBtn = new Button("Paste");
+        pasteBtn.setTranslateX(200);
+        pasteBtn.setTranslateY(30);
+
+        clearBtn.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) { clear(); }
+        });
+        copyBtn.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                ClipboardContent content = new ClipboardContent();
+                content.putImage(imageView.getImage());
+                Clipboard.getSystemClipboard().setContent(content);
+            }
+        });
+        pasteBtn.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) { checkBoard(Clipboard.getSystemClipboard(), null); }
+        });
+        
+        Group root = (Group)scene.getRoot();
+        root.getChildren().add(overlay);
+        root.getChildren().add(imageView);
+        root.getChildren().add(clearBtn);
+        root.getChildren().add(copyBtn);
+        root.getChildren().add(pasteBtn);
+        
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    private void clear() {
+    }
+    /*
+     * Called either when the user clicks the 'paste' button, or when they drop
+     * files onto the scene overlay. Supports animating multiple files, or just
+     * accepting one file.
+     */
+    private void checkBoard(Clipboard board, DragEvent de) {
+        // clean up from any previous runs
+        clear();
+
+        if (board == null) {
+            System.out.println("HelloImageClipboard: sorry - null Clipboard");
+        }
+
+        if (board.hasImage()) {
+            if (de != null) de.acceptTransferModes(TransferMode.ANY);
+            imageView.setImage(board.getImage());
+            if (de != null) de.setDropCompleted(true);
+            System.out.println("HelloImageClipboard: single image");
+        } else {
+            if (de != null) de.setDropCompleted(false);
+            System.out.println("HelloImageClipboard: sorry - no images on the Clipboard");
+        }
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloLabel.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,144 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.scene.Scene;
+import javafx.scene.control.Label;
+import javafx.scene.control.OverrunStyle;
+import javafx.scene.layout.HBox;
+import javafx.scene.layout.VBox;
+import javafx.scene.paint.Color;
+import javafx.scene.shape.Circle;
+import javafx.scene.shape.Rectangle;
+import javafx.stage.Stage;
+
+public class HelloLabel extends Application {
+
+    static HBox wrapHBoxAroundLabel(Label label) {
+        HBox hbox = new HBox();
+        hbox.setId("hbox");
+        hbox.getChildren().add(new Rectangle(10,10, Color.BLACK));
+        label.setId(label.getText() != null? label.getText() : "no text");
+        hbox.getChildren().add(label);
+        hbox.getChildren().add(new Rectangle(12,12));
+        return hbox;
+    }
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello Label");
+        VBox vbox = new VBox();
+        vbox.setId("vbox");
+        vbox.setSpacing(8);
+        vbox.getStyleClass().add("hellovlabel-vbox");
+
+        Scene scene = new Scene(vbox, 280,480);
+        //scene.getStylesheets().add("hello/hello.css");
+        
+
+        Label label = new Label("Text");
+        vbox.getChildren().add(wrapHBoxAroundLabel(label));
+
+        label = new Label();
+        label.setGraphic(new Circle(12));
+        vbox.getChildren().add(wrapHBoxAroundLabel(label));
+
+        label = new Label(" and Text");
+        label.setId(label.getText());
+        label.setGraphic(new Circle(12));
+        vbox.getChildren().add(wrapHBoxAroundLabel(label));
+
+        label = new Label("textWrap == true but shouldn't wrap");
+        label.setId(label.getText());
+        label.setWrapText(true);
+        vbox.getChildren().add(wrapHBoxAroundLabel(label));
+
+        label = new Label("textWrap == true and prefwidth == 50 so should wrap and let's make this really really really long");
+        label.setId(label.getText());
+        label.setWrapText(true);
+        label.setPrefSize(50,70);
+        vbox.getChildren().add(wrapHBoxAroundLabel(label));
+
+        label = new Label("textOverrun == CLIP");
+        label.setId(label.getText());
+        label.setTextOverrun(OverrunStyle.CLIP);
+        label.setPrefWidth(60);
+        vbox.getChildren().add(wrapHBoxAroundLabel(label));
+
+        label = new Label("textOverrun == CENTER_ELLIPSIS");
+        label.setId(label.getText());
+        label.setTextOverrun(OverrunStyle.CENTER_ELLIPSIS);
+        label.setPrefWidth(60);
+        vbox.getChildren().add(wrapHBoxAroundLabel(label));
+
+        label = new Label("textOverrun == CENTER_WORD_ELLIPSIS");
+        label.setId(label.getText());
+        label.setTextOverrun(OverrunStyle.CENTER_WORD_ELLIPSIS);
+        label.setPrefWidth(60);
+        vbox.getChildren().add(wrapHBoxAroundLabel(label));
+
+        label = new Label("textOverrun == ELLIPSIS");
+        label.setId(label.getText());
+        label.setTextOverrun(OverrunStyle.ELLIPSIS);
+        label.setPrefWidth(60);
+        vbox.getChildren().add(wrapHBoxAroundLabel(label));
+
+        label = new Label("textOverrun == LEADING ELLIPSIS");
+        label.setId(label.getText());
+        label.setTextOverrun(OverrunStyle.LEADING_ELLIPSIS);
+        label.setPrefWidth(60);
+        vbox.getChildren().add(wrapHBoxAroundLabel(label));
+
+        label = new Label("textOverrun == LEADING WORD ELLIPSIS");
+        label.setId(label.getText());
+        label.setTextOverrun(OverrunStyle.LEADING_WORD_ELLIPSIS);
+        label.setPrefWidth(60);
+        vbox.getChildren().add(wrapHBoxAroundLabel(label));
+
+        label = new Label("textOverrun == WORD_ELLIPSIS");
+        label.setId(label.getText());
+        label.setTextOverrun(OverrunStyle.WORD_ELLIPSIS);
+        label.setPrefWidth(60);
+        vbox.getChildren().add(wrapHBoxAroundLabel(label));
+
+        label = new Label("line one.\nno spacing.");
+        vbox.getChildren().add(wrapHBoxAroundLabel(label));
+  
+        label = new Label("line one.\nspacing please.");
+        label.setLineSpacing(10);
+        vbox.getChildren().add(wrapHBoxAroundLabel(label));
+
+        scene.setRoot(vbox);
+        stage.setScene(scene);
+        stage.show();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloLabelBorders.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,95 @@
+/*
+ * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import com.sun.javafx.css.Rule;
+import com.sun.javafx.css.Selector;
+import com.sun.javafx.css.SimpleSelector;
+import com.sun.javafx.css.Stylesheet;
+import com.sun.javafx.css.parser.CSSParser;
+import javafx.application.Application;
+import javafx.geometry.Pos;
+import javafx.scene.Scene;
+import javafx.scene.control.Label;
+import javafx.scene.layout.VBox;
+import javafx.stage.Stage;
+
+import java.io.IOException;
+import java.net.URL;
+
+/**
+ * Different stroke and image borders around a Label
+ */
+public class HelloLabelBorders  extends Application {
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(HelloLabelBorders.class, args);
+    }
+
+    @Override
+    public void start(Stage primaryStage) {
+
+        VBox root = new VBox(10);
+        root.setAlignment(Pos.CENTER);
+
+        Scene scene = new Scene(root, 400, 600);
+
+        root.getChildren().add(new Label("no-border"));
+
+        try {
+            URL url = HelloLabelBorders.class.getResource("LabelBorders.css");
+            System.out.println(url.toExternalForm());
+
+            scene.getStylesheets().add(url.toExternalForm());
+
+            Stylesheet ss = CSSParser.getInstance().parse(url);
+            for (Rule rule : ss.getRules()) {
+                for(Selector selector : rule.getSelectors()) {
+                    if (selector instanceof SimpleSelector) {
+
+                        SimpleSelector simpleSelector = (SimpleSelector)selector;
+                        String id = simpleSelector.getId();
+
+                        System.out.println("add Label \"" + id + "\"");
+
+                        Label lbl = new Label(id);
+                        lbl.setId(id);
+                        root.getChildren().add(lbl);
+                    }
+                }
+            }
+        } catch (IOException e) {
+            e.printStackTrace();
+        }
+
+        primaryStage.setScene(scene);
+        primaryStage.show();
+
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloLaunchOnNewThread.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,99 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.paint.Color;
+import javafx.scene.shape.Rectangle;
+import javafx.stage.Stage;
+
+public class HelloLaunchOnNewThread extends Application {
+    public HelloLaunchOnNewThread() {
+        System.err.println("Constructor: currentThread="
+                + Thread.currentThread().getName());
+    }
+
+    @Override public void init() {
+        System.err.println("init: currentThread="
+                + Thread.currentThread().getName());
+    }
+
+    @Override public void start(Stage stage) {
+        System.err.println("start: currentThread="
+                + Thread.currentThread().getName());
+
+        stage.setTitle("Launch from New Thread");
+
+        Group root = new Group();
+        Scene scene = new Scene(root, 600, 450);
+        scene.setFill(Color.LIGHTGREEN);
+
+        Rectangle rect = new Rectangle();
+        rect.setX(25);
+        rect.setY(40);
+        rect.setWidth(100);
+        rect.setHeight(50);
+        rect.setFill(Color.RED);
+
+        root.getChildren().add(rect);
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    @Override public void stop() {
+        System.err.println("cancel: currentThread="
+                + Thread.currentThread().getName());
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(final String[] args) {
+        new Thread(new Runnable() {
+            public void run() {
+                // Sleep for a very short time to ensure main thread exits,
+                // since that will provoke RT-9824
+                try {
+                    Thread.sleep(100);
+                } catch (InterruptedException ex) {}
+                System.err.println("Calling Application.launch from currentThread="
+                        + Thread.currentThread().getName());
+                System.err.print("LAUNCHING...");
+                System.err.flush();
+                long startTime = System.nanoTime();
+                Application.launch(HelloLaunchOnNewThread.class, args);
+                long endTime = System.nanoTime();
+                long elapsedMsec = (endTime - startTime + 500000) / 1000000;
+                System.err.println("DONE: elapsed time = " + elapsedMsec + " msec");
+                System.err.println("You should now see the 'HelloWorld' rectangle in the window");
+            }
+        }).start();
+        System.err.println("Main thread exiting: currentThread="
+                    + Thread.currentThread().getName());
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloLineChart.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,78 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.collections.FXCollections;
+import javafx.collections.ObservableList;
+import javafx.scene.Scene;
+import javafx.scene.chart.Chart;
+import javafx.scene.chart.LineChart;
+import javafx.scene.chart.NumberAxis;
+import javafx.scene.chart.XYChart;
+import javafx.stage.Stage;
+
+public class HelloLineChart extends Application {
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello LineChart");
+        Scene scene = new Scene(createLineChart(), 500, 500);
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    private Chart createLineChart() {
+
+        final NumberAxis xAxis = new NumberAxis();
+        final NumberAxis yAxis = new NumberAxis();
+        final LineChart<Number,Number> lc = new LineChart<Number,Number>(xAxis,yAxis);
+        // setup chart
+        lc.setTitle("Line Chart Example");
+        xAxis.setLabel("X Axis");
+        yAxis.setLabel("Y Axis");
+
+        // add starting data
+        ObservableList<XYChart.Data> data = FXCollections.observableArrayList();
+        XYChart.Series series = new XYChart.Series();
+        series.setName("Data Series 1");
+//        for (int i=0; i<10; i++) series.getData().add(new XYChart.Data(Math.random()*100, Math.random()*100));
+        series.getData().add(new XYChart.Data(20d, 50d));
+        series.getData().add(new XYChart.Data(40d, 80d));
+        series.getData().add(new XYChart.Data(50d, 90d));
+        series.getData().add(new XYChart.Data(70d, 30d));
+        series.getData().add(new XYChart.Data(170d, 122d));
+        lc.getData().add(series);
+
+        return lc;
+    }
+    
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloListView.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,1166 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+
+import java.text.NumberFormat;
+import java.util.AbstractList;
+import java.util.BitSet;
+import java.util.Collection;
+import java.util.Comparator;
+import java.util.Date;
+import java.util.HashMap;
+import java.util.Map;
+import javafx.animation.Interpolator;
+import javafx.animation.KeyFrame;
+import javafx.animation.KeyValue;
+import javafx.animation.Timeline;
+
+import javafx.application.Application;
+import javafx.beans.InvalidationListener;
+import javafx.beans.Observable;
+import javafx.beans.value.ChangeListener;
+import javafx.beans.value.ObservableValue;
+import javafx.collections.FXCollections;
+import javafx.collections.ListChangeListener;
+import javafx.collections.ObservableList;
+import javafx.collections.transformation.SortedList;
+import javafx.collections.transformation.FilteredList;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.geometry.Insets;
+import javafx.geometry.Orientation;
+import javafx.scene.Group;
+import javafx.scene.Node;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.control.ChoiceBox;
+import javafx.scene.control.Label;
+import javafx.scene.control.ListCell;
+import javafx.scene.control.ListView;
+import javafx.scene.control.ListView.EditEvent;
+import javafx.scene.control.RadioButton;
+import javafx.scene.control.SelectionMode;
+import javafx.scene.control.Tab;
+import javafx.scene.control.TabPane;
+import javafx.scene.control.TextField;
+import javafx.scene.control.ToggleGroup;
+import javafx.scene.control.Tooltip;
+import javafx.scene.input.KeyCode;
+import javafx.scene.input.KeyEvent;
+import javafx.scene.input.MouseEvent;
+import javafx.scene.layout.GridPane;
+import javafx.scene.layout.Priority;
+import javafx.scene.layout.VBox;
+import javafx.scene.paint.Color;
+import javafx.stage.Stage;
+import javafx.util.Callback;
+import javafx.util.Duration;
+
+public class HelloListView extends Application implements InvalidationListener {
+
+    private static ObservableList<String> data = FXCollections.<String>observableArrayList();
+    private static ObservableList<String> names = FXCollections.<String>observableArrayList();
+    private static ObservableList<Number> money = FXCollections.<Number>observableArrayList();
+    private static ObservableList<Map<String, String>> mapData = FXCollections.<Map<String, String>>observableArrayList();
+
+    private static final String FIRST_NAME = "firstName";
+    private static final String LAST_NAME = "lastName";
+
+    static {
+        data.addAll("Row 1", "Row 2",
+//                "Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Row 3",
+                "Row 4", "Row 5", "Row 6",
+                "Row 7", "Row 8", "Row 9", "Row 10", "Row 11", "Row 12", "Row 13",
+                "Row 14", "Row 15", "Row 16", "Row 17", "Row 18", "Row 19", "Row 20",
+
+                "Row 1", "Row 2", "Long Row 3", "Row 4", "Row 5", "Row 6",
+                "Row 7", "Row 8", "Row 9", "Row 10", "Row 11", "Row 12", "Row 13",
+                "Row 14", "Row 15", "Row 16", "Row 17", "Row 18", "Row 19", "Row 20",
+
+                "Row 1", "Row 2", "Long Row 3", "Row 4", "Row 5", "Row 6",
+                "Row 7", "Row 8", "Row 9", "Row 10", "Row 11", "Row 12", "Row 13",
+                "Row 14", "Row 15", "Row 16", "Row 17", "Row 18", "Row 19", "Row 20",
+
+                "Row 1", "Row 2", "Long Row 3", "Row 4", "Row 5", "Row 6",
+                "Row 7", "Row 8", "Row 9", "Row 10", "Row 11", "Row 12", "Row 13",
+                "Row 14", "Row 15", "Row 16", "Row 17", "Row 18", "Row 19", "Row 20",
+
+                "Row 1", "Row 2", "Long Row 3", "Row 4", "Row 5", "Row 6",
+                "Row 7", "Row 8", "Row 9", "Row 10", "Row 11", "Row 12", "Row 13",
+                "Row 14", "Row 15", "Row 16", "Row 17", "Row 18", "Row 19", "Row 20",
+
+                "Row 1", "Row 2", "Long Row 3", "Row 4", "Row 5", "Row 6",
+                "Row 7", "Row 8", "Row 9", "Row 10", "Row 11", "Row 12", "Row 13",
+                "Row 14", "Row 15", "Row 16", "Row 17", "Row 18", "Row 19", "Row 20",
+
+                "Row 1", "Row 2", "Long Row 3", "Row 4", "Row 5", "Row 6",
+                "Row 7", "Row 8", "Row 9", "Row 10", "Row 11", "Row 12", "Row 13",
+                "Row 14", "Row 15", "Row 16", "Row 17", "Row 18", "Row 19", "===== Row 20 ====",
+
+                "Row 1", "Row 2", "Long Row 3", "Row 4", "Row 5", "Row 6",
+                "Row 7", "Row 8", "Row 9", "Row 10", "Row 11", "Row 12", "Row 13",
+                "Row 14", "Row 15", "Row 16", "Row 17", "Row 18", "Row 19", "Row 20",
+
+                "Row 1", "Row 2", "Long Row 3", "Row 4", "Row 5", "Row 6",
+                "Row 7", "Row 8", "Row 9", "Row 10", "Row 11", "Row 12", "Row 13",
+                "Row 14", "Row 15", "Row 16", "Row 17", "Row 18", "Row 19", "Row 20",
+
+                "Row 1", "Row 2", "Long Row 3", "Row 4", "Row 5", "Row 6",
+                "Row 7", "Row 8", "Row 9", "Row 10", "Row 11", "Row 12", "Row 13",
+                "Row 14", "Row 15", "Row 16", "Row 17", "Row 18", "Row 19", "Row 20"
+        );
+
+        names.addAll(
+            // Top 100 boys names for 2010, taken from
+            // http://www.babycenter.com/top-baby-names-2010
+            "Aiden", "Jacob", "Jackson", "Ethan", "Jayden", "Noah", "Logan", "Caden",
+//            "Lucas", "Liam", "Mason", "Caleb", "Jack", "Brayden", "Connor", "Ryan",
+//            "Matthew", "Michael", "Alexander", "Landon,Nicholas", "Nathan", "Dylan",
+//            "Evan", "Benjamin", "Andrew", "Joshua", "Luke", "Gabriel", "William",
+//            "James", "Elijah", "Owen", "Tyler", "Gavin", "Carter", "Cameron", "Daniel",
+//            "Zachary", "Christian", "Joseph", "Wyatt", "Anthony", "Samuel", "Chase",
+//            "Max", "Isaac", "Christopher", "John", "Eli", "Austin", "Colton",
+//            "Hunter", "Tristan", "Jonathan", "David", "Alex", "Colin", "Dominic",
+//            "Cooper", "Henry", "Carson", "Isaiah", "Charlie", "Julian", "Grayson",
+//            "Cole", "Oliver", "Jordan", "Thomas", "Sean", "Brody", "Adam", "Levi",
+//            "Aaron", "Parker", "Sebastian", "Xavier", "Ian", "Miles", "Blake", "Jake",
+//            "Riley", "Jason", "Nathaniel", "Adrian", "Brandon", "Justin", "Nolan",
+//            "Jeremiah", "Hayden", "Devin", "Brady", "Robert", "Josiah", "Hudson",
+//            "Ryder", "Bryce", "Micah", "Sam",
+//
+//            // Top 100 girls names for 2010, taken from
+//            // http://www.babycenter.com/top-baby-names-2010
+            "Sophia", "Isabella", "Olivia", "Emma", "Chloe", "Ava", "Lily", "Madison"
+//            "Addison", "Abigail", "Madelyn", "Emily", "Zoe", "Hailey", "Riley",
+//            "Ella", "Mia", "Kaitlyn", "Kaylee", "Peyton", "Layla,Avery", "Hannah",
+//            "Mackenzie", "Elizabeth", "Kylie", "Sarah", "Anna", "Grace", "Brooklyn",
+//            "Natalie", "Alyssa", "Alexis", "Aubrey", "Samantha", "Isabelle",
+//            "Arianna", "Charlotte,Makayla", "Claire", "Lillian", "Gabriella",
+//            "Lyla", "Amelia", "Sophie", "Aaliyah", "Taylor", "Audrey", "Bella",
+//            "Leah", "Allison", "Sydney", "Alana", "Maya", "Keira", "Lucy", "Kayla",
+//            "Lauren", "Savannah", "Brianna", "Ellie", "Reagan", "Evelyn", "Carly",
+//            "Julia", "Bailey", "Jordyn", "Victoria", "Annabelle", "Cadence",
+//            "Katherine", "Stella", "Molly", "Kennedy", "Jasmine,Gianna", "Abby",
+//            "Makenna", "Morgan", "Caroline", "Maria", "Brooke", "Nora", "Alexa",
+//            "Camryn", "Paige", "Eva", "Scarlett", "Adriana", "Juliana", "Ashlyn",
+//            "Megan", "Kendall", "Harper", "Jada", "Violet", "Alexandra", "Gracie",
+//            "Nevaeh", "Sadie"
+        );
+
+        money.addAll(43.68, 102.35, -23.67, 110.23, -43.93, 87.21);
+
+        Map<String, String> map1 = new HashMap<String, String>();
+        map1.put(FIRST_NAME, "Jonathan");
+        map1.put(LAST_NAME, "Giles");
+        Map<String, String> map2 = new HashMap<String, String>();
+        map2.put(FIRST_NAME, "Brian");
+        map2.put(LAST_NAME, "Beck");
+        Map<String, String> map3 = new HashMap<String, String>();
+        map3.put(FIRST_NAME, "Richard");
+        map3.put(LAST_NAME, "Bair");
+        Map<String, String> map4 = new HashMap<String, String>();
+        map4.put(FIRST_NAME, "Jasper");
+        map4.put(LAST_NAME, "Potts");
+        Map<String, String> map5 = new HashMap<String, String>();
+        map5.put(FIRST_NAME, "Will");
+        map5.put(LAST_NAME, "Walker");
+        mapData.addAll(map1, map2, map3, map4, map5);
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello ListView");
+        final Scene scene = new Scene(new Group(), 875, 700);
+        scene.setFill(Color.LIGHTGRAY);
+        Group root = (Group)scene.getRoot();
+
+
+        // TabPane
+        final TabPane tabPane = new TabPane();
+        tabPane.setTabClosingPolicy(TabPane.TabClosingPolicy.UNAVAILABLE);
+        tabPane.setPrefWidth(scene.getWidth());
+        tabPane.setPrefHeight(scene.getHeight());
+
+        InvalidationListener sceneListener = new InvalidationListener() {
+            @Override public void invalidated(Observable ov) {
+                tabPane.setPrefWidth(scene.getWidth());
+                tabPane.setPrefHeight(scene.getHeight());
+            }
+        };
+        scene.widthProperty().addListener(sceneListener);
+        scene.heightProperty().addListener(sceneListener);
+
+        // simple list view example
+        Tab simpleTab = new Tab("Simple");
+        buildSimpleTab(simpleTab);
+        tabPane.getTabs().add(simpleTab);
+
+        // horizontal list view example
+        Tab horizontalTab = new Tab("Horizontal");
+        buildHorizontalTab(horizontalTab);
+        tabPane.getTabs().add(horizontalTab);
+
+        // Cell Factory Tab
+        Tab cellFactoriesTab = new Tab("Cell Factories");
+        buildCellFactoriesTab(cellFactoriesTab);
+        tabPane.getTabs().add(cellFactoriesTab);
+
+        // Cell Editing Tab
+        Tab cellEditingTab = new Tab("Cell Editing");
+        buildCellEditingTab(cellEditingTab);
+        tabPane.getTabs().add(cellEditingTab);
+
+        // Cell Editing Tab
+        Tab disappearingNodesTab = new Tab("RT-12822");
+        buildDisappearingNodesTab(disappearingNodesTab);
+        tabPane.getTabs().add(disappearingNodesTab);
+
+        // sorted and filtered list view example
+        Tab sortAndFilterTab = new Tab("Sort & Filter");
+        buildSortAndFilterTab(sortAndFilterTab);
+        tabPane.getTabs().add(sortAndFilterTab);
+
+        // big list view example
+        Tab bigListTab = new Tab("Big List");
+        buildBigListTab(bigListTab);
+        tabPane.getTabs().add(bigListTab);
+
+        // big DnD example
+        Tab dndTab = new Tab("DnD");
+        buildDndTab(dndTab);
+        tabPane.getTabs().add(dndTab);
+
+        root.getChildren().add(tabPane);
+
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    public void invalidated(Observable observable) {
+        System.out.println("Event: " + observable);
+    }
+
+    private void buildSimpleTab(Tab tab) {
+        GridPane grid = new GridPane();
+//        grid.setGridLinesVisible(true);
+        grid.setPadding(new Insets(5, 5, 5, 5));
+        grid.setHgap(5);
+        grid.setVgap(5);
+
+        // simple list view
+        final ListView<String> listView = new ListView<String>();
+        listView.setItems(data);
+        listView.getSelectionModel().setSelectionMode(SelectionMode.MULTIPLE);
+
+        listView.setOnEditStart(new EventHandler<EditEvent<String>>() {
+            @Override public void handle(EditEvent<String> t) {
+                System.out.println("Edit Start: " + t.getIndex());
+            }
+        });
+        listView.setOnEditCancel(new EventHandler<EditEvent<String>>() {
+            @Override public void handle(EditEvent<String> t) {
+                System.out.println("Edit Cancel: " + t.getIndex());
+            }
+        });
+        listView.setOnEditCommit(new EventHandler<EditEvent<String>>() {
+            @Override public void handle(EditEvent<String> t) {
+                System.out.println("Edit Commit: " + t.getIndex());
+            }
+        });
+
+        grid.add(listView, 0, 0, 1, 10);
+        GridPane.setVgrow(listView, Priority.ALWAYS);
+        GridPane.setHgrow(listView, Priority.ALWAYS);
+        // --- simple listview
+
+
+        // control buttons
+        Button row5btn = new Button("Select 'Row 5'");
+        row5btn.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                listView.getSelectionModel().clearSelection();
+                listView.getSelectionModel().select("Row 5");
+            }
+        });
+        grid.add(row5btn, 1, 0);
+
+        Button deselectRow5btn = new Button("Deselect item in 5th row");
+        deselectRow5btn.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                listView.getSelectionModel().clearSelection(4);
+            }
+        });
+        grid.getChildren().add(deselectRow5btn);
+        GridPane.setConstraints(deselectRow5btn, 1, 1);
+
+
+        Button row20focusBtn = new Button("Focus on item in 20th row");
+        row20focusBtn.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                listView.getFocusModel().focus(19);
+            }
+        });
+        grid.getChildren().add(row20focusBtn);
+        GridPane.setConstraints(row20focusBtn, 1, 2);
+
+        Button insertBeforeRow1btn = new Button("Add row before 0th row");
+        insertBeforeRow1btn.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                data.add(0, new Date().toString());
+            }
+        });
+        grid.getChildren().add(insertBeforeRow1btn);
+        GridPane.setConstraints(insertBeforeRow1btn, 1, 3);
+
+        Button insertBeforeRow5btn = new Button("Add row before 5th row");
+        insertBeforeRow5btn.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                data.add(5, new Date().toString());
+            }
+        });
+        grid.getChildren().add(insertBeforeRow5btn);
+        GridPane.setConstraints(insertBeforeRow5btn, 1, 4);
+
+        Button delete0thRow = new Button("Delete 0th row");
+        delete0thRow.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                data.remove(0);
+            }
+        });
+        grid.getChildren().add(delete0thRow);
+        GridPane.setConstraints(delete0thRow, 1, 5);
+
+        Button delete5thRow = new Button("Delete 5th row");
+        delete5thRow.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                data.remove(4);
+            }
+        });
+        grid.getChildren().add(delete5thRow);
+        GridPane.setConstraints(delete5thRow, 1, 6);
+
+        Button moveToRow40btn = new Button("Move to row 40");
+        moveToRow40btn.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                listView.scrollTo(39);
+            }
+        });
+        grid.getChildren().add(moveToRow40btn);
+        GridPane.setConstraints(moveToRow40btn, 1, 8);
+
+        tab.setContent(grid);
+
+        //
+        // observation code for debugging the simple list view multiple selection
+        listView.getSelectionModel().selectedIndexProperty().addListener(new InvalidationListener() {
+            public void invalidated(Observable ov) {
+                System.out.println("SelectedIndex: " + listView.getSelectionModel().getSelectedIndex());
+            }
+        });
+////        listView.getSelectionModel().selectedItemProperty().addListener(new InvalidationListener() {
+////            public void invalidated(ObservableValue ov) {
+////                System.out.println("\tSelectedItem: " + listView.getSelectionModel().getSelectedItem());
+////            }
+////        });
+////        listView.getFocusModel().focusedIndexProperty().addListener(new InvalidationListener() {
+////            public void invalidated(ObservableValue ov) {
+////                System.out.println("\tFocusedIndex: " + listView.getFocusModel().getFocusedIndex());
+////            }
+////        });
+////        listView.getFocusModel().focusedItemProperty().addListener(new InvalidationListener() {
+////            public void invalidated(ObservableValue ov) {
+////                System.out.println("\tFocusedItem: " + listView.getFocusModel().getFocusedItem());
+////            }
+////        });
+//////        listView.getFocusModel().addInvalidationListener(FocusModel.FOCUSED_ITEM, this);
+////
+        listView.getSelectionModel().getSelectedIndices().addListener(new ListChangeListener<Integer>() {
+            public void onChanged(Change<? extends Integer> change) {
+                while (change.next()) {
+                    System.out.println("SelectedIndices: " + change.getList() +
+                            ", removed: " + change.getRemoved() +
+                            ", addedFrom: " + change.getFrom() +
+                            ", addedTo: " + change.getTo());
+                }
+            }
+        });
+////        ((MultipleSelectionModel)listView.getSelectionModel()).getSelectedItems().addListener(new ListChangeListener<String>() {
+////            public void onChanged(Change<? extends String> c) {
+////                System.out.println("SelectedIndices: " + c.getList() +
+////                        ", removed: " + c.getRemoved() +
+////                        ", addedFrom: " + c.getFrom() +
+////                        ", addedTo: " + c.getTo());
+////            }
+////        });
+    }
+
+    private void buildHorizontalTab(Tab tab) {
+        GridPane grid = new GridPane();
+        grid.setPadding(new Insets(5, 5, 5, 5));
+        grid.setHgap(5);
+        grid.setVgap(5);
+
+        // simple list view with content
+        ListView horizontalListView = new ListView();
+        horizontalListView.setOrientation(Orientation.HORIZONTAL);
+        horizontalListView.setItems(data);
+
+        grid.add(horizontalListView, 0, 0);
+        GridPane.setVgrow(horizontalListView, Priority.ALWAYS);
+        GridPane.setHgrow(horizontalListView, Priority.ALWAYS);
+
+        // simple list view with content
+        ListView emptyListView = new ListView();
+        emptyListView.setOrientation(Orientation.HORIZONTAL);
+
+        grid.add(emptyListView, 1, 0);
+        GridPane.setVgrow(emptyListView, Priority.ALWAYS);
+        GridPane.setHgrow(emptyListView, Priority.ALWAYS);
+
+        tab.setContent(grid);
+    }
+
+    private void buildCellFactoriesTab(Tab tab) {
+        GridPane grid = new GridPane();
+        grid.setPadding(new Insets(5, 5, 5, 5));
+        grid.setHgap(5);
+        grid.setVgap(5);
+
+        // number format listview
+        final ListView<Number> listView = new ListView<Number>(money);
+        listView.setCellFactory(new Callback<ListView<Number>, ListCell<Number>>() {
+            @Override public ListCell<Number> call(ListView<Number> list) {
+                return new MoneyFormatCell();
+            }
+        });
+        grid.add(listView, 0, 0);
+        GridPane.setVgrow(listView, Priority.ALWAYS);
+        GridPane.setHgrow(listView, Priority.ALWAYS);
+        // --- number format listview
+
+
+        // expanding cells listview
+        final ListView<String> listView2 = new ListView<String>(data);
+        listView2.setCellFactory(new Callback<ListView<String>, ListCell<String>>() {
+            @Override public ListCell<String> call(ListView<String> list) {
+                return new ExpandOnSelectionCell<String>();
+            }
+        });
+        grid.add(listView2, 1, 0);
+        GridPane.setVgrow(listView2, Priority.ALWAYS);
+        GridPane.setHgrow(listView2, Priority.ALWAYS);
+        // --- expanding cells listview
+
+
+        tab.setContent(grid);
+    }
+
+    private void buildDisappearingNodesTab(Tab tab) {
+        GridPane grid = new GridPane();
+        grid.setPadding(new Insets(5, 5, 5, 5));
+        grid.setHgap(5);
+        grid.setVgap(5);
+
+        // Create a ListView<Button>
+        ListView<Button> listView = new ListView<Button>();
+        listView.setPrefWidth(100.0F);
+        listView.setPrefHeight(100.0F);
+        Button button = new Button("Apples");
+        Tooltip tooltip = new Tooltip();
+        tooltip.setText("Tooltip Apples");
+        button.setTooltip(tooltip);
+        Button button2 = new Button("Oranges");
+        Tooltip tooltip2 = new Tooltip();
+        tooltip2.setText("Tooltip Oranges");
+        button2.setTooltip(tooltip2);
+        Button button3 = new Button("Peaches");
+        Tooltip tooltip3 = new Tooltip();
+        tooltip3.setText("Tooltip Peaches");
+        button3.setTooltip(tooltip3);
+        Button button4 = new Button("Plums");
+        Tooltip tooltip4 = new Tooltip();
+        tooltip4.setText("Tooltip Plums");
+        button4.setTooltip(tooltip4);
+        Button button5 = new Button("Apricots");
+        Tooltip tooltip5 = new Tooltip();
+        tooltip5.setText("Tooltip Apricots");
+        button5.setTooltip(tooltip5);
+        Button button6 = new Button("Lemons");
+        Tooltip tooltip6 = new Tooltip();
+        tooltip6.setText("Tooltip Lemons");
+        button6.setTooltip(tooltip6);
+        Button button7 = new Button("Grapefruit");
+        Tooltip tooltip7 = new Tooltip();
+        tooltip7.setText("Tooltip Grapefruit");
+        button7.setTooltip(tooltip7);
+        Button button8 = new Button("Cherries");
+        Tooltip tooltip8 = new Tooltip();
+        tooltip8.setText("Tooltip Cherries");
+        button8.setTooltip(tooltip8);
+        listView.setItems(javafx.collections.FXCollections.observableArrayList(
+                button, button2, button3, button4, button5, button6, button7, button8));
+
+        grid.add(listView, 0, 0, 1, 10);
+        tab.setContent(grid);
+    }
+
+    private void buildCellEditingTab(Tab tab) {
+        GridPane grid = new GridPane();
+        grid.setPadding(new Insets(5, 5, 5, 5));
+        grid.setHgap(5);
+        grid.setVgap(5);
+
+        // simple textfield list view
+        final ListView<String> textFieldListView = new ListView<String>();
+        textFieldListView.setEditable(true);
+        textFieldListView.setItems(data);
+        textFieldListView.getSelectionModel().setSelectionMode(SelectionMode.MULTIPLE);
+        textFieldListView.setCellFactory(new Callback<ListView<String>, ListCell<String>>() {
+            public ListCell<String> call(ListView<String> p) {
+                return new TextFieldCell();
+            }
+        });
+//        textFieldListView.setOnEditCommit(new EventHandler<EditEvent<String>>() {
+//            @Override public void handle(EditEvent<String> t) {
+//                System.out.println("Edit commit event: " + t);
+//                Object obj = t.getNewValue();
+//
+//                if (obj instanceof String) {
+//                    ListView lv = t.getSource();
+//                    lv.getItems().set(lv.getEditingIndex(), obj);
+//                }
+//            }
+//        });
+        textFieldListView.setOnEditStart(new EventHandler<EditEvent<String>>() {
+            @Override public void handle(EditEvent<String> t) {
+                System.out.println("On Edit Start: " + t);
+            }
+        });
+        textFieldListView.setOnEditCancel(new EventHandler<EditEvent<String>>() {
+            @Override public void handle(EditEvent<String> t) {
+                System.out.println("On Edit Cancel: " + t);
+            }
+        });
+        grid.add(textFieldListView, 0, 0, 1, 10);
+        GridPane.setVgrow(textFieldListView, Priority.ALWAYS);
+        GridPane.setHgrow(textFieldListView, Priority.ALWAYS);
+        // --- simple listview
+
+        // simple choicebox list view
+        final ObservableList<String> options = FXCollections.observableArrayList("Jenny", "Billy", "Timmy");
+        final ListView<String> choiceBoxListView = new ListView<String>();
+        choiceBoxListView.setEditable(true);
+        choiceBoxListView.setItems(data);
+        choiceBoxListView.getSelectionModel().setSelectionMode(SelectionMode.MULTIPLE);
+        choiceBoxListView.setCellFactory(new Callback<ListView<String>, ListCell<String>>() {
+            public ListCell<String> call(ListView<String> p) {
+                return new ChoiceBoxCell<String>(options);
+            }
+        });
+        choiceBoxListView.setOnEditCommit(new EventHandler<EditEvent<String>>() {
+            @Override public void handle(EditEvent<String> t) {
+                System.out.println("Edit commit event: " + t);
+                Object obj = t.getNewValue();
+
+                if (obj instanceof String) {
+                    ListView lv = t.getSource();
+                    lv.getItems().set(lv.getEditingIndex(), obj);
+                }
+            }
+        });
+//        choiceBoxListView.setOnEditStart(new EventHandler<ListView.EditEvent>() {
+//            @Override public void handle(ListView.EditEvent t) {
+//                System.out.println("On Edit Start: " + t);
+//            }
+//        });
+//        choiceBoxListView.setOnEditCancel(new EventHandler<ListView.EditEvent>() {
+//            @Override public void handle(ListView.EditEvent t) {
+//                System.out.println("On Edit Cancel: " + t);
+//            }
+//        });
+        grid.add(choiceBoxListView, 1, 0, 1, 10);
+        GridPane.setVgrow(choiceBoxListView, Priority.ALWAYS);
+        GridPane.setHgrow(choiceBoxListView, Priority.ALWAYS);
+        // --- simple listview
+
+
+        // control buttons
+        final Button editRow3btn = new Button("Edit row 3");
+        editRow3btn.setOnAction(new EventHandler<ActionEvent>() {
+            public void handle(ActionEvent t) {
+                textFieldListView.edit(2);
+                choiceBoxListView.edit(2);
+            }
+        });
+        grid.getChildren().add(editRow3btn);
+        GridPane.setConstraints(editRow3btn, 2, 0);
+
+        final Button cancelEditBtn = new Button("Cancel edit");
+        cancelEditBtn.setOnAction(new EventHandler<ActionEvent>() {
+            public void handle(ActionEvent t) {
+                textFieldListView.edit(-1);
+                choiceBoxListView.edit(-1);
+            }
+        });
+        grid.getChildren().add(cancelEditBtn);
+        GridPane.setConstraints(cancelEditBtn, 2, 1);
+
+        tab.setContent(grid);
+    }
+
+//    private void buildCellsTab(Tab tab) {
+//        GridPane grid = new GridPane();
+//        grid.setPadding(new Insets(5, 5, 5, 5));
+//        grid.setHgap(5);
+//        grid.setVgap(5);
+//
+//        // add a complex listview (using pre-built cell factory)
+//        final ListView<Number> listView2 = new ListView<Number>();
+//        listView2.setItems(money);
+//        listView2.setCellFactory(MoneyFormatCellFactory.listView());
+//        grid.getChildren().add(listView2);
+//        GridPane.setVgrow(listView2, Priority.ALWAYS);
+//        GridPane.setConstraints(listView2, 0, 0);
+//        // --- complex listview
+//
+//        // add another complex listview (using pre-built cell factory)
+//        final ListView<Map<String, String>> listView3 = new ListView<Map<String, String>>();
+//        listView3.setItems(mapData);
+////        listView3.setCellFactory(Cells.ListView.mapProperty(FIRST_NAME));
+//        listView3.setCellFactory(MapValueCellFactory.listView("First Name: %1$s\r\nLast Name: %2$s", FIRST_NAME, LAST_NAME));
+//        grid.getChildren().add(listView3);
+//        GridPane.setVgrow(listView3, Priority.ALWAYS);
+//        GridPane.setConstraints(listView3, 1, 0);
+//        // --- complex listview
+//
+//        tab.setContent(grid);
+//    }
+
+
+    private Comparator<String> alphabeticalComparator = new Comparator<String>() {
+        @Override public int compare(String o1, String o2) {
+            return o1.compareTo(o2);
+        }
+    };
+
+    private Comparator<String> reverseAlphabeticalComparator = new Comparator<String>() {
+        @Override public int compare(String o1, String o2) {
+            return o2.compareTo(o1);
+        }
+    };
+
+    private void buildSortAndFilterTab(Tab tab) {
+        // initially we match everything in the filter list
+
+        final SortedList<String> sortedList = new SortedList<String>(names);
+        final FilteredList<String> filteredList = new FilteredList<String>(names, e -> true);
+
+        GridPane grid = new GridPane();
+        grid.setPadding(new Insets(5, 5, 5, 5));
+        grid.setHgap(5);
+        grid.setVgap(5);
+
+        // --- unmodified listview
+        final ListView<String> unmodifiedListView = new ListView<String>();
+        unmodifiedListView.setId("Unmodified list");
+        unmodifiedListView.setItems(names);
+//        unmodifiedListView.setCellFactory(TextFieldCellFactory.listView());
+        Node unmodifiedLabel = createLabel("Original ListView:");
+        grid.getChildren().addAll(unmodifiedLabel, unmodifiedListView);
+        GridPane.setConstraints(unmodifiedLabel, 0, 0);
+        GridPane.setConstraints(unmodifiedListView, 0, 1);
+        GridPane.setVgrow(unmodifiedListView, Priority.ALWAYS);
+        // --- unmodified listview
+
+
+        // --- sorted listview
+        final ListView<String> sortedListView = new ListView<String>();
+        sortedListView.setId("sorted list");
+        sortedListView.setItems(sortedList);
+//        sortedListView.setCellFactory(TextFieldCellFactory.listView());
+        Node sortedLabel = createLabel("Sorted ListView:");
+        grid.getChildren().addAll(sortedLabel, sortedListView);
+        GridPane.setConstraints(sortedLabel, 1, 0);
+        GridPane.setConstraints(sortedListView, 1, 1);
+        GridPane.setVgrow(sortedListView, Priority.ALWAYS);
+        // --- sorted listview
+
+
+        // --- filtered listview
+        final ListView<String> filteredListView = new ListView<String>();
+        filteredListView.setId("filtered list");
+        filteredListView.setItems(filteredList);
+//        filteredListView.setCellFactory(TextFieldCellFactory.listView());
+        Node filteredLabel = createLabel("Filtered (and sorted) ListView:");
+        grid.getChildren().addAll(filteredLabel, filteredListView);
+        GridPane.setConstraints(filteredLabel, 2, 0);
+        GridPane.setConstraints(filteredListView, 2, 1);
+        GridPane.setVgrow(filteredListView, Priority.ALWAYS);
+        // --- filtered listview
+
+
+        // control buttons
+        VBox vbox = new VBox(10);
+
+        vbox.getChildren().add(new Label("Note: Double-click list cells to edit."));
+
+        final TextField filterInput = new TextField();
+        filterInput.setPromptText("Enter filter text");
+//        filterInput.setColumns(35);
+        filterInput.setOnKeyReleased(new EventHandler<KeyEvent>() {
+            public void handle(KeyEvent t) {
+                filteredList.setPredicate((String e) ->
+                        e.toUpperCase().contains(filterInput.getText().toUpperCase()));
+            }
+        });
+        vbox.getChildren().add(filterInput);
+
+        final TextField newItemInput = new TextField();
+        newItemInput.setPromptText("Enter text, then press enter to add item to list");
+//        newItemInput.setColumns(35);
+        newItemInput.setOnKeyReleased(new EventHandler<KeyEvent>() {
+            public void handle(KeyEvent t) {
+                if (t.getCode() == KeyCode.ENTER) {
+                    names.add(newItemInput.getText());
+                    newItemInput.setText("");
+                }
+            }
+        });
+        vbox.getChildren().add(newItemInput);
+
+        // sort ascending
+        final ToggleGroup toggleGroup = new ToggleGroup();
+        toggleGroup.selectedToggleProperty().addListener(new InvalidationListener() {
+            public void invalidated(Observable ov) {
+                if (toggleGroup.getSelectedToggle() == null) return;
+//                sortedList.setComparator((Comparator<String>)toggleGroup.getSelectedToggle().getUserData());
+                System.out.println("Disabled in HelloListView due to FilteredList bug");
+            }
+        });
+        final RadioButton sortAscBtn = new RadioButton("Sort Ascending");
+        sortAscBtn.setUserData(alphabeticalComparator);
+        sortAscBtn.setToggleGroup(toggleGroup);
+        sortAscBtn.setSelected(true);
+
+        final RadioButton sortDescBtn = new RadioButton("Sort Descending");
+        sortDescBtn.setUserData(reverseAlphabeticalComparator);
+        sortDescBtn.setToggleGroup(toggleGroup);
+
+        vbox.getChildren().addAll(sortAscBtn, sortDescBtn);
+
+        grid.setConstraints(vbox, 3, 1);
+        grid.getChildren().add(vbox);
+
+        tab.setContent(grid);
+    }
+
+    private void buildBigListTab(Tab tab) {
+        GridPane grid = new GridPane();
+        grid.setPadding(new Insets(5, 5, 5, 5));
+        grid.setHgap(5);
+        grid.setVgap(5);
+
+        BigList intList = new BigList();
+
+        // simple list view
+        final ListView<Integer> listView = new ListView<Integer>();
+        listView.setItems(intList);
+//        listView.getSelectionModel().setSelectionMode(SelectionMode.MULTIPLE_INTERVAL_SELECTION);
+        grid.add(listView, 0, 0);
+        GridPane.setVgrow(listView, Priority.ALWAYS);
+        GridPane.setHgrow(listView, Priority.ALWAYS);
+
+        tab.setContent(grid);
+    }
+
+    private void buildDndTab(Tab tab) {
+        GridPane grid = new GridPane();
+        grid.setPadding(new Insets(5, 5, 5, 5));
+        grid.setHgap(5);
+        grid.setVgap(5);
+
+        ObservableList<String> listOneItems = FXCollections.observableArrayList(names.subList(0, 8));
+        ObservableList<String> listTwoItems = FXCollections.observableArrayList(names.subList(8, 16));
+
+        // --- list one
+        final ListView<String> listOne = new ListView<String>();
+        listOne.setItems(listOneItems);
+        Node listOneLabel = createLabel("List One:");
+        grid.getChildren().addAll(listOneLabel, listOne);
+        GridPane.setConstraints(listOneLabel, 0, 0);
+        GridPane.setConstraints(listOne, 0, 1);
+        GridPane.setVgrow(listOne, Priority.ALWAYS);
+        // --- list one
+
+        // --- list two
+        final ListView<String> listTwo = new ListView<String>();
+        listTwo.setItems(listTwoItems);
+        Node listTwoLabel = createLabel("List Two:");
+        grid.getChildren().addAll(listTwoLabel, listTwo);
+        GridPane.setConstraints(listTwoLabel, 1, 0);
+        GridPane.setConstraints(listTwo, 1, 1);
+        GridPane.setVgrow(listTwo, Priority.ALWAYS);
+        // --- list two
+
+        tab.setContent(grid);
+    }
+
+    private Node createLabel(String text) {
+        Label label = new Label(text);
+        return label;
+    }
+
+//    public void handle(Bean bean, PropertyReference<?> pr) {
+//        SelectionModel sm = null;
+//        FocusModel fm = null;
+//        if (bean instanceof SelectionModel) {
+//            System.out.print("Selection Event: ");
+//            sm = (SelectionModel) bean;
+//        } else if (bean instanceof FocusModel) {
+//            System.out.print("Focus Event: ");
+//            fm = (FocusModel) bean;
+//        }
+//
+//
+//        if (pr == SelectionModel.SELECTED_INDEX) {
+//            System.out.println("\tSelectedIndex: " + sm.getSelectedIndex());
+//        } else if (pr == SelectionModel.SELECTED_ITEM) {
+//            System.out.println("\tSelectedItem: " + sm.getSelectedItem());
+//        } else if (pr == FocusModel.FOCUSED_INDEX) {
+//            System.out.println("\tFocusedIndex: " + fm.getFocusedIndex());
+//        } else if (pr == FocusModel.FOCUSED_ITEM) {
+//            System.out.println("\tFocusedItem: " + fm.getFocusedItem());
+//        }
+//    }
+
+    private static class BigList extends AbstractList<Integer> implements ObservableList<Integer> {
+
+        @Override
+        public Integer get(int index) {
+            return index;
+        }
+
+        @Override
+        public int size() {
+            return Integer.MAX_VALUE;
+        }
+
+        @Override
+        public void addListener(InvalidationListener listener) {
+            // no-op
+        }
+
+        @Override
+        public void removeListener(InvalidationListener listener) {
+            // no-op
+        }
+
+        public void addListener(ListChangeListener<? super Integer> ll) {
+            // no-op
+        }
+
+        public void removeListener(ListChangeListener<? super Integer> ll) {
+            // no-op
+        }
+
+        public boolean addAll(Integer... es) {
+            throw new UnsupportedOperationException("Not supported yet.");
+        }
+
+        public boolean setAll(Integer... es) {
+            throw new UnsupportedOperationException("Not supported yet.");
+        }
+
+        public boolean setAll(Collection<? extends Integer> clctn) {
+            throw new UnsupportedOperationException("Not supported yet.");
+        }
+
+        public boolean removeAll(Integer... es) {
+            throw new UnsupportedOperationException("Not supported yet.");
+        }
+
+        public boolean retainAll(Integer... es) {
+            throw new UnsupportedOperationException("Not supported yet.");
+        }
+
+        public void remove(int from, int to) {
+            throw new UnsupportedOperationException("Not supported yet.");
+        }
+
+    }
+
+    private static class MoneyFormatCell extends ListCell<Number> {
+        @Override
+        public void updateItem(Number item, boolean empty) {
+            super.updateItem(item, empty);
+
+            // format the number as if it were a monetary value using the
+            // formatting relevant to the current locale. This would format
+            // 43.68 as "$43.68", and -23.67 as "-$23.67"
+            setText(item == null ? "" : NumberFormat.getCurrencyInstance().format(item));
+
+            // change the label colour based on whether it is positive (green)
+            // or negative (red). If the cell is selected, the text will
+            // always be white (so that it can be read against the blue
+            // background), and if the value is zero, we'll make it black.
+            if (item != null) {
+                double value = item.doubleValue();
+                setTextFill(isSelected() ? Color.WHITE :
+                    value == 0 ? Color.BLACK :
+                    value < 0 ? Color.RED : Color.GREEN);
+            }
+        }
+    }
+
+
+    /**
+     * Class to demonstrate cell editing support with TextBoxes
+     */
+    private static class TextFieldCell extends ListCell<String> {
+
+        private TextField textBox;
+
+        public TextFieldCell() {
+            setEditable(true);
+        }
+
+        @Override
+        public void startEdit() {
+            super.startEdit();
+
+            if (textBox == null) {
+                createTextBox();
+            }
+            textBox.setText(getItem());
+
+            setText(null);
+            setGraphic(textBox);
+            textBox.selectAll();
+        }
+
+        @Override
+        public void cancelEdit() {
+            super.cancelEdit();
+
+            setText((String)getItem());
+            setGraphic(null);
+        }
+
+        @Override
+        public void updateItem(String item, boolean empty) {
+            super.updateItem(item, empty);
+
+            if (empty) {
+                setText(null);
+                setGraphic(null);
+            } else {
+                if (isEditing()) {
+                    if (textBox != null) {
+                        textBox.setText(item);
+                    }
+                    setText(null);
+                    setGraphic(textBox);
+                } else {
+                    setText(item);
+                    setGraphic(null);
+                }
+            }
+        }
+
+        private void createTextBox() {
+            textBox = new TextField(getItem());
+            textBox.setOnKeyReleased(new EventHandler<KeyEvent>() {
+                @Override public void handle(KeyEvent t) {
+                    if (t.getCode() == KeyCode.ENTER) {
+                        System.out.println("committing edit");
+                        commitEdit(textBox.getText());
+                    } else if (t.getCode() == KeyCode.ESCAPE) {
+                        System.out.println("cancelling edit");
+                        cancelEdit();
+                    }
+                }
+            });
+        }
+    }
+
+
+    /**
+     * Class to demonstrate cell editing support with ChoiceBox
+     */
+    private static class ChoiceBoxCell<T> extends ListCell<T> {
+
+        private final ObservableList<T> items;
+
+        private ChoiceBox<T> choiceBox;
+
+        public ChoiceBoxCell(ObservableList<T> items) {
+            this.items = items;
+            setEditable(true);
+        }
+
+        @Override
+        public void startEdit() {
+            if (choiceBox == null) {
+                createTextBox();
+            }
+
+            choiceBox.getSelectionModel().select(getItem());
+
+            super.startEdit();
+            setText(null);
+            setGraphic(choiceBox);
+        }
+
+        @Override
+        public void cancelEdit() {
+            super.cancelEdit();
+
+            updateItem(getItem(), isEmpty());
+        }
+
+        @Override
+        public void updateItem(T item, boolean empty) {
+            super.updateItem(item, empty);
+
+            if (isEditing()) {
+                if (choiceBox != null) {
+                    choiceBox.getSelectionModel().select(item);
+                }
+                setText(null);
+                setGraphic(choiceBox);
+            } else {
+                setText(item == null ? "" : item.toString());
+                setGraphic(null);
+            }
+        }
+
+        private void createTextBox() {
+            choiceBox = new ChoiceBox<T>(items);
+            choiceBox.setMaxWidth(Double.MAX_VALUE);
+            choiceBox.getSelectionModel().selectedItemProperty().addListener(new ChangeListener<T>() {
+                public void changed(ObservableValue<? extends T> ov, T oldValue, T newValue) {
+                    if (isEditing()) {
+                        commitEdit(newValue);
+                    }
+                }
+            });
+        }
+    }
+
+    private static class ExpandOnSelectionCell<T> extends ListCell<T> {
+        private static final double PREF_HEIGHT = 24;
+        private static final double EXPAND_HEIGHT = PREF_HEIGHT * 3;
+
+        private static final int duration = 350;
+
+        // records all expanded cells
+        private static final BitSet expandedCells = new BitSet();
+
+
+        public ExpandOnSelectionCell() {
+
+            prefHeightProperty().addListener(new InvalidationListener() {
+                public void invalidated(Observable o) {
+                    requestLayout();
+                }
+            });
+
+            addEventFilter(MouseEvent.MOUSE_CLICKED, new EventHandler<MouseEvent>() {
+                @Override public void handle(MouseEvent t) {
+
+                    double startHeight = getHeight();
+
+                    // the end height is the opposite of the current state -
+                    // we are animating out of this state after all
+                    double endHeight = isExpanded() ? PREF_HEIGHT : EXPAND_HEIGHT;
+
+                    // flip whether this cell index is expanded or not
+                    expandedCells.flip(getIndex());
+
+                    // create a timeline to expand/collapse the cell. All this
+                    // really does is modify the height of the content
+                    Timeline timeline = new Timeline();
+                    timeline.setCycleCount(1);
+                    timeline.setAutoReverse(false);
+
+                    timeline.getKeyFrames().addAll(
+                        new KeyFrame(Duration.ZERO, new KeyValue(prefHeightProperty(), startHeight, Interpolator.EASE_BOTH)),
+                        new KeyFrame(Duration.millis(duration), new KeyValue(prefHeightProperty(), endHeight, Interpolator.EASE_BOTH))
+                    );
+
+                    timeline.playFromStart();
+                }
+            });
+        }
+
+        @Override
+        public void updateItem(T item, boolean empty) {
+            super.updateItem(item, empty);
+            setText(item == null ? "null" : item.toString());
+        }
+
+        @Override
+        public void updateIndex(int i) {
+            super.updateIndex(i);
+
+            if (isExpanded()) {
+                // immediately expand this cell
+                setPrefHeight(EXPAND_HEIGHT);
+            } else {
+                // immediately collapse this cell
+                setPrefHeight(PREF_HEIGHT);
+            }
+        }
+
+        private boolean isExpanded() {
+            if (getIndex() < 0) return false;
+            return expandedCells.get(getIndex());
+        }
+
+        @Override
+        protected double computePrefHeight(double width) {
+            double ph = 0;
+            if (isExpanded()) {
+                ph = getPrefHeight();
+            } else {
+                ph = super.computePrefHeight(width);
+            }
+
+            return ph;
+        }
+
+        @Override protected double computeMinHeight(double width) {
+            return computePrefHeight(width);
+        }
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloMedia.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,172 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import java.util.List;
+import javafx.application.Application;
+import javafx.collections.ListChangeListener;
+import javafx.collections.ListChangeListener.Change;
+import javafx.collections.MapChangeListener;
+import javafx.event.EventHandler;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.image.Image;
+import javafx.scene.image.ImageView;
+import javafx.scene.media.Media;
+import javafx.scene.media.MediaErrorEvent;
+import javafx.scene.media.MediaException;
+import javafx.scene.media.MediaPlayer;
+import javafx.scene.media.MediaView;
+import javafx.scene.media.Track;
+import javafx.stage.Stage;
+
+public class HelloMedia extends Application {
+    private static final String DEFAULT_SOURCE = 
+        "http://download.oracle.com/otndocs/products/javafx/oow2010-2.flv";
+    private static String argSource = null;
+
+    @Override
+    public void start(Stage stage) {
+        String source = argSource == null ? DEFAULT_SOURCE : argSource;
+        stage.setTitle("Hello Media [" + source + "]");
+        final Scene scene = new Scene(new Group(), 1280, 720);
+        stage.setScene(scene);
+        stage.show();
+
+        try {
+            final Media media = new Media(source);
+
+            if (media.getError() == null) {
+                media.setOnError(new Runnable() {
+                    public void run() {
+                        System.err.println(">>> Media ERR: " + media.getError());
+                        exitOnError();
+                    }
+                });
+                media.getMetadata().addListener(new MapChangeListener<String, Object>() {
+                    public void onChanged(Change<? extends String, ? extends Object> change) {
+                        String key = change.getKey();
+
+                        // Print metadata tag and value to console.
+                        System.out.println(change.getKey() + " (" + change.getValueAdded().getClass().getName() + "): " + change.getValueAdded());
+
+                        // Display album cover tag value if present.
+                        if (key.equals("image")) {
+                            Image image = (Image) change.getValueAdded();
+                            ImageView imageView = new ImageView(image);
+                            ((Group) scene.getRoot()).getChildren().add(imageView);
+                        }
+                    }
+                });
+                
+                media.getTracks().addListener(new ListChangeListener<Track>() {
+                    public void onChanged(Change<? extends Track> change) {
+                        try {
+                            while (change.next()) {
+                                if (!change.wasPermutated() && !change.wasUpdated()) {
+                                    for (Track trk : change.getAddedSubList()) {
+                                        System.out.println("Media Track: "+trk);
+                                    }
+                                }
+                            }
+                        } catch (Exception e) {
+                            System.err.println("Exception getting tracks changes: "+e);
+                        }
+                    }
+                });
+                
+                try {
+                    final MediaPlayer mediaPlayer = new MediaPlayer(media);
+                    mediaPlayer.setOnError(new Runnable() {
+                        public void run() {
+                            System.err.println(">>> MediaPlayer ERR: " + mediaPlayer.getError());
+                            exitOnError();
+                        }
+                    });
+
+                    if (mediaPlayer.getError() == null) {
+                        mediaPlayer.setAutoPlay(true);
+                        mediaPlayer.setCycleCount(MediaPlayer.INDEFINITE);
+
+                        MediaView mediaView = new MediaView(mediaPlayer);
+                        mediaView.setOnError(new EventHandler<MediaErrorEvent>() {
+                            public void handle(MediaErrorEvent t) {
+                                System.err.println(">>> MediaView ERR: " + t);
+                                exitOnError();
+                            }
+                        });
+                        mediaView.getProperties().addListener(new MapChangeListener<Object, Object>() {
+                            public void onChanged(Change<? extends Object, ? extends Object> change) {
+                                System.err.println(change.getKey()
+                                        + ": " + change.getValueRemoved() + " -> " + change.getValueAdded());
+                            }
+                        });
+
+                        ((Group) scene.getRoot()).getChildren().add(mediaView);
+                    } else {
+                        System.err.println(">>> MediaPlayer ERR: " + mediaPlayer.getError());
+                        exitOnError();
+                    }
+                } catch (NullPointerException npe) {
+                    System.err.println(">>> MediaPlayer ERR: " + npe.toString());
+                    exitOnError();
+                } catch (MediaException me) {
+                    System.err.println(">>> MediaPlayer ERR: " + me.toString());
+                    exitOnError();
+                }
+            } else {
+                System.err.println(">>> Media ERR: " + media.getError());
+                exitOnError();
+            }
+        } catch (NullPointerException npe) {
+            System.err.println(">>> Media ERR: " + npe.toString());
+            exitOnError();
+        } catch (IllegalArgumentException iae) {
+            System.err.println(">>> Media ERR: " + iae.toString());
+            exitOnError();
+        } catch (UnsupportedOperationException uoe) {
+            System.err.println(">>> Media ERR: " + uoe.toString());
+            exitOnError();
+        } catch (MediaException me) {
+            System.err.println(">>> Media ERR: " + me.toString());
+            exitOnError();
+        }
+    }
+
+    private static void exitOnError() {
+        boolean exitOnError = true;
+        if (exitOnError) {
+            System.exit(1);
+        }
+    }
+
+    public static void main(String[] args) {
+        if (args.length > 0) {
+            argSource = args[0];
+        }
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloMenu.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,261 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.beans.InvalidationListener;
+import javafx.beans.Observable;
+import javafx.beans.property.BooleanProperty;
+import javafx.beans.value.ChangeListener;
+import javafx.beans.value.ObservableValue;
+import javafx.event.ActionEvent;
+import javafx.event.Event;
+import javafx.event.EventHandler;
+import javafx.geometry.Pos;
+import javafx.scene.Node;
+import javafx.scene.Scene;
+import javafx.scene.control.CheckMenuItem;
+import javafx.scene.control.Label;
+import javafx.scene.control.Menu;
+import javafx.scene.control.MenuBar;
+import javafx.scene.control.MenuItem;
+import javafx.scene.control.RadioMenuItem;
+import javafx.scene.control.SeparatorMenuItem;
+import javafx.scene.control.ToggleGroup;
+import javafx.scene.image.Image;
+import javafx.scene.image.ImageView;
+import javafx.scene.input.KeyCharacterCombination;
+import javafx.scene.input.KeyCode;
+import javafx.scene.input.KeyCodeCombination;
+import javafx.scene.input.KeyCombination;
+import javafx.scene.layout.HBox;
+import javafx.scene.layout.VBox;
+import javafx.stage.Stage;
+
+import java.text.SimpleDateFormat;
+import java.util.Date;
+
+public class HelloMenu extends Application {
+
+    //private static final String imageURL = "file:hello/about_16.png";
+
+    private CheckMenuItem showMessagesItem;
+    private final Label sysMenuLabel = new Label("Using System Menu");
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello Menu");
+        Scene scene = new Scene(new VBox(20), 400, 350);
+        final MenuBar menuBar = new MenuBar();
+        final String os = System.getProperty("os.name");
+        EventHandler actionHandler = new EventHandler<ActionEvent>() {
+            public void handle(ActionEvent t) {
+                if (t.getTarget() instanceof MenuItem) {
+                    System.out.println(((MenuItem)t.getTarget()).getText() + " - action called");
+                }
+            }
+        };
+
+        // --- Menu 1
+        final Menu menu1 = makeMenu("_Debug");
+
+        final Menu menu11 = makeMenu("_New", new ImageView(new Image("hello/about_16.png")));
+        MenuItem menu12 = new MenuItem("_Open", new ImageView(new Image("hello/folder_16.png")));
+        menu12.setAccelerator(new KeyCharacterCombination("]", 
+                KeyCombination.SHIFT_DOWN, KeyCombination.META_DOWN));
+        menu12.setOnAction(actionHandler);
+        Menu menu13 = makeMenu("_Submenu");
+        showMessagesItem = new CheckMenuItem("Enable onShowing/onHiding _messages", 
+                                             new ImageView(new Image("hello/about_16.png")));
+        MenuItem menu15 = new MenuItem("E_xit");
+        menu15.setOnAction(new EventHandler<ActionEvent>() {
+            public void handle(ActionEvent t) {
+                System.exit(0);
+            }
+        });
+        final String change[] = {"Change Text", "Change Back"};
+        final MenuItem menu16 = new MenuItem(change[0]);
+        final boolean toggle = false;
+        menu16.setAccelerator(KeyCombination.keyCombination("Shortcut+C"));
+        menu16.setOnAction(new EventHandler<ActionEvent>() {
+            public void handle(ActionEvent t) {
+                menu16.setText((menu16.getText().equals(change[0])) ? change[1] : change[0]);
+            }
+        });
+        menu1.getItems().addAll(menu11, menu12, menu13, showMessagesItem, new SeparatorMenuItem(), menu15, menu16);
+
+
+        // --- Menu 11 submenu
+        final MenuItem menu111 = new MenuItem("blah");
+        menu111.setOnAction(actionHandler);
+        final MenuItem menu112 = new MenuItem("foo");
+        menu112.setOnAction(actionHandler);
+        final CheckMenuItem menu113 = new CheckMenuItem("Show \"foo\" item");
+        menu113.setSelected(true);
+        menu113.selectedProperty().addListener(new InvalidationListener() {
+            @Override public void invalidated(Observable valueModel) {
+                menu112.setVisible(menu113.isSelected());
+                System.err.println("MenuItem \"foo\" is now " + (menu112.isVisible() ? "" : "not") + " visible.");
+            }
+        });
+        menu11.getItems().addAll(menu111, menu112, menu113);
+
+
+        // --- Menu 13 submenu
+        MenuItem menu131 = new MenuItem("Item _1");
+        menu131.setOnAction(actionHandler);
+        MenuItem menu132 = new MenuItem("Item _2");
+        menu132.setOnAction(actionHandler);
+        menu13.getItems().addAll(menu131, menu132);
+
+
+        // --- Menu 2
+        Menu menu2 = makeMenu("_Edit");
+        MenuItem menu21 = new MenuItem("_Undo");
+        menu21.setAccelerator(KeyCombination.keyCombination("shortcut+Z"));
+        menu21.setOnAction(actionHandler);
+        MenuItem menu22 = new MenuItem("_Redo");
+        menu22.setAccelerator(KeyCombination.keyCombination("shortcut+Y"));
+        menu22.setOnAction(actionHandler);
+        // menu separator
+        MenuItem menu23 = new MenuItem("_Disabled");
+        menu23.setDisable(true);
+        // menu separator
+        MenuItem menu24 = new MenuItem("Copy");
+        menu24.setAccelerator(KeyCombination.keyCombination("shortcut+C"));
+        menu24.setOnAction(actionHandler);
+        MenuItem menu25 = new MenuItem("Paste");
+        menu25.setAccelerator(KeyCombination.keyCombination("shortcut+V"));
+        menu25.setOnAction(actionHandler);
+        MenuItem menu26 = new MenuItem("Delete");
+        menu26.setAccelerator(KeyCombination.keyCombination("shortcut+D"));
+        MenuItem menu27 = new MenuItem("Help");
+        menu27.setAccelerator(new KeyCodeCombination(KeyCode.F1));
+        menu27.setOnAction(actionHandler);
+        menu27.setDisable(false);
+        menu2.getItems().addAll(menu21, menu22, new SeparatorMenuItem(), menu23,
+                 menu24, menu25, menu26, menu27);
+        
+
+        // --- Menu 3
+        Menu menu3 = makeMenu("_Radio/CheckBox");
+        CheckMenuItem checkMI1 = new CheckMenuItem("_1 CheckMenuItem - checked");
+        checkMI1.setSelected(true);
+        CheckMenuItem checkMI2 = new CheckMenuItem("_2 CheckMenuItem - not checked");
+
+        RadioMenuItem radioMI1 = new RadioMenuItem("_3 RadioMenuItem - selected");
+        radioMI1.setSelected(true);
+        RadioMenuItem radioMI2 = new RadioMenuItem("_4 RadioMenuItem - not selected");
+        ToggleGroup group = new ToggleGroup();
+        radioMI1.setToggleGroup(group);
+        radioMI2.setToggleGroup(group);
+
+        InvalidationListener selectedListener = new InvalidationListener() {
+            @Override public void invalidated(Observable valueModel) {
+                MenuItem mi = (MenuItem)((BooleanProperty)valueModel).getBean();
+                boolean selected = ((BooleanProperty)valueModel).get();
+                System.err.println(mi.getText() + " - " + selected);
+            }
+        };
+
+        checkMI1.selectedProperty().addListener(selectedListener);
+        checkMI2.selectedProperty().addListener(selectedListener);
+        radioMI1.selectedProperty().addListener(selectedListener);
+        radioMI2.selectedProperty().addListener(selectedListener);
+
+        menu3.getItems().addAll(checkMI1, checkMI2, radioMI1, radioMI2);
+//        ImageView im = new ImageView();
+//        im.setImage(new Image(imageURL));
+//        cmitem.setGraphic(im);
+
+        menuBar.getMenus().add(menu1);
+        menuBar.getMenus().add(menu2);
+        menuBar.getMenus().add(menu3);
+        
+        if (os != null && os.startsWith("Mac")) {
+            Menu systemMenuBarMenu = makeMenu("MenuBar _Options");
+
+            final CheckMenuItem useSystemMenuBarCB = new CheckMenuItem("Use _System Menu Bar");
+            useSystemMenuBarCB.setSelected(true);
+            menuBar.useSystemMenuBarProperty().bind(useSystemMenuBarCB.selectedProperty());
+            systemMenuBarMenu.getItems().add(useSystemMenuBarCB);
+
+            menuBar.getMenus().add(systemMenuBarMenu);
+        }
+
+        ((VBox)scene.getRoot()).getChildren().add(menuBar);
+        if (os != null && os.startsWith("Mac")) {
+            HBox hbox = new HBox();
+            hbox.setAlignment(Pos.CENTER);
+            sysMenuLabel.setStyle("-fx-font-size: 24");
+            hbox.getChildren().add(sysMenuLabel);
+            ((VBox)scene.getRoot()).getChildren().add(hbox);
+            sysMenuLabel.setVisible((menuBar.getHeight() == 0) ? true : false);
+            menuBar.heightProperty().addListener(new ChangeListener<Number>() {
+
+                public void changed(ObservableValue<? extends Number> ov, Number t, Number t1) {
+                    sysMenuLabel.setVisible((menuBar.getHeight() == 0) ? true : false);
+                }
+            });
+        }
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    private EventHandler showHideHandler = new EventHandler<Event>() {
+        public void handle(Event t) {
+            Menu menu = (Menu)t.getSource();
+            if (t.getEventType() == Menu.ON_SHOWING && 
+                    menu.getText().equals("_Submenu")) {
+                Date date = new Date();
+                String time = new SimpleDateFormat("HH:mm:ss").format(date);
+                menu.getItems().get(0).setText("The time is " + time);
+            }
+            if (showMessagesItem.isSelected()) {
+                System.out.println(((Menu)t.getSource()).getText() + " " + t.getEventType());
+            }
+        }
+    };
+
+    private Menu makeMenu(String text) {
+        return makeMenu(text, null);
+    }
+
+    private Menu makeMenu(String text, Node graphic) {
+        Menu menu = new Menu(text, graphic);
+        menu.setOnShowing(showHideHandler);
+        menu.setOnShown(showHideHandler);
+        menu.setOnHiding(showHideHandler);
+        menu.setOnHidden(showHideHandler);
+        return menu;
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+//        com.sun.javafx.Logging.getFocusLogger().setLevel(PlatformLogger.FINE);
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloMenuButton.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,280 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.beans.InvalidationListener;
+import javafx.beans.Observable;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.geometry.Side;
+import javafx.scene.Node;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.control.CheckBox;
+import javafx.scene.control.Label;
+import javafx.scene.control.MenuButton;
+import javafx.scene.control.MenuItem;
+import javafx.scene.control.RadioButton;
+import javafx.scene.control.SplitMenuButton;
+import javafx.scene.control.ToggleGroup;
+import javafx.scene.control.Tooltip;
+import javafx.scene.layout.HBox;
+import javafx.scene.layout.VBox;
+import javafx.scene.paint.Color;
+import javafx.stage.Stage;
+
+import static javafx.geometry.NodeOrientation.*;
+
+
+public class HelloMenuButton extends Application {
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        //com.sun.javafx.Logging.getFocusLogger().setLevel(PlatformLogger.FINE);
+        //com.sun.javafx.Logging.getInputLogger().setLevel(PlatformLogger.FINE);
+        //com.sun.javafx.scene.control.Logging.getControlsLogger().setLevel(PlatformLogger.FINEST);
+        Application.launch(args);
+    }
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello MenuButton");
+
+        VBox root = new VBox(20);
+        root.setStyle("-fx-padding: 30;");
+
+        Scene scene = new Scene(root);
+        scene.setFill(Color.CHOCOLATE);
+
+        final VBox vBox1 = new VBox(10);
+
+
+        /***************************************************************
+         *                                                             *
+         * Simple button for comparison with the others                *
+         *                                                             *
+         **************************************************************/
+
+        Button button = new Button("Simple Button");
+        button.setTooltip(new Tooltip("Tooltip for Simple Button"));
+        button.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                System.out.println("Simple Button");
+            }
+         });
+        vBox1.getChildren().add(button);
+
+
+        /***************************************************************
+         *                                                             *
+         * Simple menu button                                          *
+         *                                                             *
+         **************************************************************/
+
+        MenuButton mb = new MenuButton("MenuButton");
+        mb.setTooltip(new Tooltip("Tooltip for MenuButton"));
+
+        final MenuItem coke = new MenuItem("Coke");
+        coke.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                System.out.println(coke.getText());
+            }
+         });
+        mb.getItems().add(coke);
+
+        final MenuItem pepsi = new MenuItem("Pepsi");
+        pepsi.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                System.out.println(pepsi.getText());
+            }
+         });
+        mb.getItems().add(pepsi);
+        mb.getItems().addAll(new MenuItem("Foo"),
+                             new MenuItem("Foo"),
+                             new MenuItem("Foo"),
+                             new MenuItem("Foo"),
+                             new MenuItem("Foo"),
+                             new MenuItem("Foo"),
+                             new MenuItem("Foo"),
+                             new MenuItem("Foo"),
+                             new MenuItem("Foo"),
+                             new MenuItem("Foo"),
+                             new MenuItem("Foo"),
+                             new MenuItem("Foo"));
+        vBox1.getChildren().add(mb);
+
+
+
+
+        /***************************************************************
+         *                                                             *
+         * Split menu button                                           *
+         *                                                             *
+         **************************************************************/
+
+        SplitMenuButton smb = new SplitMenuButton();
+        smb.setText("SplitMenuButton1");
+        smb.setTooltip(new Tooltip("Tooltip for SplitMenuButton1"));
+        smb.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                System.out.println("SplitMenuButton1");
+            }
+        });
+
+        MenuItem mi = new MenuItem("Divide");
+        mi.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                System.out.println("Divide");
+            }
+         });
+        smb.getItems().add(mi);
+
+        mi = new MenuItem("Conquer");
+        mi.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                System.out.println("Conquer");
+            }
+         });
+        smb.getItems().add(mi);
+
+        vBox1.getChildren().add(smb);
+
+
+
+        /***************************************************************
+         *                                                             *
+         * Split menu button that                                      *
+         * gets label and action from selected item.                   *
+         *                                                             *
+         **************************************************************/
+
+        final SplitMenuButton smb3 = new SplitMenuButton();
+        smb3.setTooltip(new Tooltip("Tooltip for SplitMenuButton2"));
+        smb3.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                System.out.println("SplitMenuButton2");
+            }
+        });
+
+        {
+            final MenuItem menuItem = new MenuItem("Land");
+            menuItem.setOnAction(new EventHandler<ActionEvent>() {
+                @Override public void handle(ActionEvent e) {
+                    System.out.println("Land");
+                    smb3.setText(menuItem.getText());
+                    smb3.setOnAction(menuItem.getOnAction());
+                }
+             });
+            smb3.getItems().add(menuItem);
+        }
+
+        {
+            final MenuItem menuItem = new MenuItem("Sea");
+            menuItem.setOnAction(new EventHandler<ActionEvent>() {
+                @Override public void handle(ActionEvent e) {
+                    System.out.println("Sea");
+                    smb3.setText(menuItem.getText());
+                    smb3.setOnAction(menuItem.getOnAction());
+                }
+             });
+            smb3.getItems().add(menuItem);
+        }
+
+        smb3.setText(smb3.getItems().get(0).getText());
+        smb3.setOnAction(smb3.getItems().get(0).getOnAction());
+
+        vBox1.getChildren().add(smb3);
+
+
+        VBox vBox2 = new VBox(10);
+
+        {
+            HBox hBox = new HBox(14);
+            hBox.getChildren().add(new Label("Popup Side:"));
+
+            ToggleGroup toggleGroup = new ToggleGroup();
+            for (final Side side : Side.class.getEnumConstants()) {
+                final RadioButton rb = new RadioButton(side.toString());
+                rb.selectedProperty().addListener(new InvalidationListener() {
+                    @Override public void invalidated(Observable valueModel) {
+                        for (Node node : vBox1.getChildren()) {
+                            if (node instanceof MenuButton) {
+                                ((MenuButton)node).setPopupSide(side);
+                            }
+                        }
+                    }
+                });
+                rb.setToggleGroup(toggleGroup);
+                if (side == Side.BOTTOM) {
+                    rb.setSelected(true);
+                }
+                hBox.getChildren().add(rb);
+            }
+            vBox2.getChildren().add(hBox);
+        }
+
+        {
+            HBox hBox = new HBox(10);
+
+            {
+                final CheckBox cb = new CheckBox("Disable");
+                cb.selectedProperty().addListener(new InvalidationListener() {
+                    @Override public void invalidated(Observable valueModel) {
+                        boolean disabled = cb.isSelected();
+                        for (Node node : vBox1.getChildren()) {
+                            node.setDisable(disabled);
+                        }
+                    }
+                });
+                hBox.getChildren().addAll(cb);
+            }
+
+            {
+                final CheckBox cb = new CheckBox("RTL");
+                cb.selectedProperty().addListener(new InvalidationListener() {
+                    @Override public void invalidated(Observable valueModel) {
+                        boolean rtl = cb.isSelected();
+                        for (Node node : vBox1.getChildren()) {
+                            node.setNodeOrientation(rtl ? RIGHT_TO_LEFT : LEFT_TO_RIGHT);
+                        }
+                    }
+                });
+                cb.setSelected(scene.getEffectiveNodeOrientation() == RIGHT_TO_LEFT);
+                hBox.getChildren().addAll(cb);
+            }
+
+
+            vBox2.getChildren().add(hBox);
+        }
+
+        root.getChildren().addAll(vBox1, vBox2);
+
+        stage.setScene(scene);
+        stage.show();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloModality.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,212 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import java.io.File;
+
+import javafx.application.Application;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.control.CheckBox;
+import javafx.scene.control.RadioButton;
+import javafx.scene.control.ToggleGroup;
+import javafx.stage.FileChooser;
+import javafx.stage.Modality;
+import javafx.stage.Stage;
+import javafx.stage.StageStyle;
+
+public class HelloModality extends Application {
+
+    static final int offset = 25;
+    static int counter = 0;
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+    Scene createScene(final Stage stage) {
+
+        Group root = new Group();
+        int xyOffset = offset * counter++;
+        if (xyOffset > 200) xyOffset = 0;
+        Scene scene = new Scene(root, 600 - xyOffset, 450 - xyOffset);
+
+        // Setup Owner checker
+        final CheckBox checker = new CheckBox("Owner");
+        checker.setSelected(true);
+        checker.setLayoutX(25);
+        checker.setLayoutY(40);
+        root.getChildren().add(checker);
+        
+        // Setup Modality Selection
+        final ToggleGroup modalityGroup = new ToggleGroup();
+        final RadioButton noneButton = new RadioButton("NONE");
+        noneButton.setSelected(true);
+        noneButton.setLayoutX(155);
+        noneButton.setLayoutY(40);
+        noneButton.setToggleGroup(modalityGroup);
+        final RadioButton windowButton = new RadioButton("WINDOW_MODAL");
+        windowButton.setMnemonicParsing(false);
+        windowButton.setLayoutX(155);
+        windowButton.setLayoutY(60);
+        windowButton.setToggleGroup(modalityGroup);
+        final RadioButton applicationButton = new RadioButton("APPLICATION_MODAL");
+        applicationButton.setMnemonicParsing(false);
+        applicationButton.setLayoutX(155);
+        applicationButton.setLayoutY(80);
+        applicationButton.setToggleGroup(modalityGroup);
+        root.getChildren().add(noneButton);
+        root.getChildren().add(windowButton);
+        root.getChildren().add(applicationButton);
+
+        // Setup StageStyle Selection
+        final ToggleGroup styleGroup = new ToggleGroup();
+        final RadioButton sdButton = new RadioButton("DECORATED");
+        sdButton.setSelected(true);
+        sdButton.setLayoutX(325);
+        sdButton.setLayoutY(40);
+        sdButton.setToggleGroup(styleGroup);
+        final RadioButton sudButton = new RadioButton("UNDECORATED");
+        sudButton.setLayoutX(325);
+        sudButton.setLayoutY(60);
+        sudButton.setToggleGroup(styleGroup);
+        final RadioButton stButton = new RadioButton("TRANSPARENT");
+        stButton.setLayoutX(325);
+        stButton.setLayoutY(80);
+        stButton.setToggleGroup(styleGroup);
+        final RadioButton suButton = new RadioButton("UTILITY");
+        suButton.setLayoutX(325);
+        suButton.setLayoutY(100);
+        suButton.setToggleGroup(styleGroup);
+        root.getChildren().add(sdButton);
+        root.getChildren().add(sudButton);
+        root.getChildren().add(stButton);
+        root.getChildren().add(suButton);
+
+        Button button = new Button("Create Dialog");
+        button.setLayoutX(100);
+        button.setLayoutY(200);
+        button.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                final Stage dialog = new Stage();
+
+                boolean owned = checker.isSelected();
+                dialog.initOwner(owned ? stage : null);
+
+                Modality modality;
+                if (applicationButton.isSelected()) {
+                    modality = Modality.APPLICATION_MODAL;
+                } else if (windowButton.isSelected()) {
+                    modality = Modality.WINDOW_MODAL;
+                } else {
+                    // Default setting
+                    modality = Modality.NONE;
+                }
+                dialog.initModality(modality);
+
+                StageStyle stageStyle;
+                if (suButton.isSelected()) {
+                    stageStyle = StageStyle.UTILITY;
+                } else if (sudButton.isSelected()) {
+                    stageStyle = StageStyle.UNDECORATED;
+                } else if (stButton.isSelected()) {
+                    stageStyle = StageStyle.TRANSPARENT;
+                } else {
+                    // Default setting
+                    stageStyle = StageStyle.DECORATED;
+                }
+                dialog.initStyle(stageStyle);
+
+                dialog.initModality(modality);
+                dialog.setTitle("Owner: " + (owned ? stage : null) + " * Modality: "
+                        + modality.toString() + " * Style: " + stageStyle.toString());
+
+                Scene dialogScene = createScene(dialog);
+                Group dialogRoot = (Group) dialogScene.getRoot();
+
+                Button dialogButton = new Button("Dismiss");
+                dialogButton.setLayoutX(275);
+                dialogButton.setLayoutY(200);
+                dialogButton.setOnAction(new EventHandler<ActionEvent>() {
+                    @Override public void handle(ActionEvent e) {
+                        dialog.hide();
+                    }
+                });
+                dialogRoot.getChildren().add(dialogButton);
+
+
+                dialog.setScene(dialogScene);
+                dialog.show();
+            }
+        });
+        root.getChildren().add(button);
+
+        Button button2 = new Button("Click Me");
+        button2.setLayoutX(200);
+        button2.setLayoutY(200);
+        button2.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                System.out.println("Event: " + e);
+            }
+        });
+        root.getChildren().add(button2);
+
+        // Owned file dialog checkbox
+        final CheckBox ownedFileChooser = new CheckBox("Owned file chooser");
+        ownedFileChooser.setSelected(true);
+        ownedFileChooser.setLayoutX(25);
+        ownedFileChooser.setLayoutY(240);
+        root.getChildren().add(ownedFileChooser);
+        
+        Button button3 = new Button("File Chooser");
+        button3.setLayoutX(200);
+        button3.setLayoutY(240);
+        button3.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                FileChooser fc = new FileChooser();
+
+                File f = fc.showOpenDialog(ownedFileChooser.isSelected() ? stage : null);
+
+                System.err.println("Selected file: " + f);
+            }
+        });
+        root.getChildren().add(button3);
+
+        return scene;
+    }
+
+    @Override public void start(final Stage primaryStage) {
+        primaryStage.setTitle("HelloModality");
+        Scene scene = createScene(primaryStage);
+        primaryStage.setScene(scene);
+        primaryStage.show();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloPagination.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,213 @@
+/*
+ * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.scene.Scene;
+import javafx.scene.control.Pagination;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.scene.Node;
+import javafx.scene.control.Button;
+import javafx.scene.control.Label;
+import javafx.scene.layout.AnchorPane;
+import javafx.scene.layout.HBox;
+import javafx.scene.layout.VBox;
+import javafx.stage.Stage;
+import javafx.util.Callback;
+
+
+public class HelloPagination extends Application {
+    private Pagination pagination;
+
+    public static void main(String[] args) throws Exception {
+        launch(args);
+    }
+
+    public int itemsPerPage() {
+        return 10;
+    }
+
+    public VBox createPage(int pageIndex) {
+        VBox box = new VBox(5);
+        int page = pageIndex * itemsPerPage();
+        for (int i = page; i < page + itemsPerPage(); i++) {
+            Label l = new Label("PAGE INDEX " + pageIndex);
+            box.getChildren().add(l);
+        }
+        return box;
+    }
+
+    public VBox createPage2(int pageIndex) {
+        VBox box = new VBox(5);
+        int page = pageIndex * itemsPerPage();
+        for (int i = page; i < page + itemsPerPage(); i++) {
+            Label l = new Label("NEW PAGE INDEX " + pageIndex);
+            box.getChildren().add(l);
+        }
+        return box;
+    }
+
+    @Override
+    public void start(final Stage stage) throws Exception {
+        pagination = new Pagination(28, 0);
+        pagination.setStyle("-fx-border-color:red;");
+        pagination.setPageFactory(new Callback<Integer, Node>() {
+            @Override
+            public Node call(Integer pageIndex) {
+                return createPage(pageIndex);
+            }
+        });
+
+        VBox toolbar = new VBox(10);
+        Button setMaxPageIndicatorCount = new Button("setMaxPageIndicatorCount = 5");
+        setMaxPageIndicatorCount.setOnAction(new EventHandler<ActionEvent>() {
+            @Override
+            public void handle(ActionEvent t) {
+                System.out.println("setPageIndicatorCount = 5");
+                pagination.setMaxPageIndicatorCount(5);
+            }
+        });
+
+        Button getMaxPageIndicatorCount = new Button("getMaxPageIndicatorCount");
+        getMaxPageIndicatorCount.setOnAction(new EventHandler<ActionEvent>() {
+            @Override
+            public void handle(ActionEvent t) {
+                System.out.println("getPageIndicatorCount = " + pagination.getMaxPageIndicatorCount());
+            }
+        });
+
+        Button setCurrentPageIndex = new Button("setCurrentPageIndex = 19");
+        setCurrentPageIndex.setOnAction(new EventHandler<ActionEvent>() {
+            @Override
+            public void handle(ActionEvent t) {
+                System.out.println("setCurrentPageIndex = 19");
+                pagination.setCurrentPageIndex(19);
+            }
+        });
+
+        Button setCurrentPageIndex2 = new Button("setCurrentPageIndex = 0");
+        setCurrentPageIndex2.setOnAction(new EventHandler<ActionEvent>() {
+            @Override
+            public void handle(ActionEvent t) {
+                System.out.println("setCurrentPageIndex = 0");
+                pagination.setCurrentPageIndex(0);
+            }
+        });
+
+        Button setCurrentPageIndex3 = new Button("setCurrentPageIndex = 8");
+        setCurrentPageIndex3.setOnAction(new EventHandler<ActionEvent>() {
+            @Override
+            public void handle(ActionEvent t) {
+                System.out.println("setCurrentPageIndex = 8");
+                pagination.setCurrentPageIndex(8);
+            }
+        });
+
+        Button getCurrentPageIndex = new Button("getCurrentPageIndex");
+        getCurrentPageIndex.setOnAction(new EventHandler<ActionEvent>() {
+            @Override
+            public void handle(ActionEvent t) {
+                System.out.println("getCurrentPageIndex = " + pagination.getCurrentPageIndex());
+            }
+        });
+
+        Button setOldPageFactory = new Button("set OLD PageFactory");
+        setOldPageFactory.setOnAction(new EventHandler<ActionEvent>() {
+            @Override
+            public void handle(ActionEvent t) {
+                pagination.setPageFactory(new Callback<Integer, Node>() {
+                    @Override
+                    public Node call(Integer pageIndex) {
+                        return createPage(pageIndex);
+                    }
+                });
+            }
+        });
+
+        Button setNewPageFactory = new Button("set NEW PageFactory");
+        setNewPageFactory.setOnAction(new EventHandler<ActionEvent>() {
+            @Override
+            public void handle(ActionEvent t) {
+                pagination.setPageFactory(new Callback<Integer, Node>() {
+                    @Override
+                    public Node call(Integer pageIndex) {
+                        return createPage2(pageIndex);
+                    }
+                });
+            }
+        });
+
+        Button setPageCount = new Button("setPageCount = 8");
+        setPageCount.setOnAction(new EventHandler<ActionEvent>() {
+            @Override
+            public void handle(ActionEvent t) {
+                System.out.println("setPageCount = 8");
+                pagination.setPageCount(8);
+            }
+        });
+
+        Button setPageCount2 = new Button("setPageCount = 18");
+        setPageCount2.setOnAction(new EventHandler<ActionEvent>() {
+            @Override
+            public void handle(ActionEvent t) {
+                System.out.println("setPageCount = 18");
+                pagination.setPageCount(18);
+            }
+        });
+
+        Button setPageCount3 = new Button("setPageCount = INDETERMINATE");
+        setPageCount3.setOnAction(new EventHandler<ActionEvent>() {
+            @Override
+            public void handle(ActionEvent t) {
+                System.out.println("setPageCount = INDETERMINATE");
+                pagination.setPageCount(Pagination.INDETERMINATE);
+            }
+        });
+
+        toolbar.getChildren().addAll(
+                setMaxPageIndicatorCount,
+                setCurrentPageIndex, setCurrentPageIndex2, setCurrentPageIndex3,
+                setOldPageFactory, setNewPageFactory,
+                setPageCount, setPageCount2, setPageCount3,
+                getMaxPageIndicatorCount,
+                getCurrentPageIndex);
+
+        HBox box = new HBox(10);
+        box.getChildren().addAll(toolbar);
+        AnchorPane anchor = new AnchorPane();
+        AnchorPane.setTopAnchor(box, 10.0);
+        AnchorPane.setLeftAnchor(box, 10.0);
+        AnchorPane.setTopAnchor(pagination, 10.0);
+        AnchorPane.setRightAnchor(pagination, 10.0);
+        AnchorPane.setBottomAnchor(pagination, 10.0);
+        AnchorPane.setLeftAnchor(pagination, 250.0);
+        anchor.getChildren().addAll(box, pagination);
+        Scene scene = new Scene(anchor, 800, 600);
+        stage.setScene(scene);
+        stage.show();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloPieChart.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,65 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.collections.FXCollections;
+import javafx.collections.ObservableList;
+import javafx.scene.Scene;
+import javafx.scene.chart.PieChart;
+import javafx.stage.Stage;
+
+public class HelloPieChart extends Application {
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello PieChart");
+        final PieChart pc = new PieChart();
+         // setup chart
+        pc.setTitle("Pie Chart Example");
+        // add starting data
+        ObservableList<PieChart.Data> data = FXCollections.observableArrayList();
+//        for (int i=0; i<5; i++) data.add(new PieChart.Data("pie"+i, Math.random()*100));
+        data.add(new PieChart.Data("Sun", 20));
+         data.add(new PieChart.Data("IBM", 12));
+         data.add(new PieChart.Data("HP", 25));
+         data.add(new PieChart.Data("Dell", 22));
+         data.add(new PieChart.Data("Apple", 30));
+        pc.getData().addAll(data);
+
+      
+        Scene scene = new Scene(pc, 500, 500);
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloPopup.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,158 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import java.util.Iterator;
+
+import javafx.application.Application;
+import javafx.collections.ObservableList;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.scene.Group;
+import javafx.scene.Node;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.control.TextField;
+import javafx.scene.paint.Color;
+import javafx.scene.shape.Rectangle;
+import javafx.stage.Popup;
+import javafx.stage.Stage;
+import javafx.stage.Window;
+
+public class HelloPopup extends Application {
+    private static double WIDTH = 300;
+    private static double HEIGHT = 300;
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello Popup");
+        stage.setWidth(WIDTH);
+        stage.setHeight(HEIGHT);
+
+        stage.setScene(createScene(new PopupPlacement(0, 500)));
+        stage.show();
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+    private static Group createRootGroup(PopupPlacement popupPlacement) {
+        Group rootGroup = new Group();
+        ObservableList<Node> content = rootGroup.getChildren();
+
+        Rectangle rect = new Rectangle();
+        rect.setX(0);
+        rect.setY(0);
+        rect.setWidth(WIDTH);
+        rect.setHeight(HEIGHT);
+        rect.setFill(Color.GRAY);
+        rect.setStroke(Color.RED);
+        rect.setStrokeWidth(2);
+        content.add(rect);
+
+        final Button showButton = new Button("Popup");
+        showButton.setLayoutX(50);
+        showButton.setLayoutY(50);
+        showButton.setOnAction(new PopupActionHandler(popupPlacement,
+                                                      showButton));
+        content.add(showButton);
+
+        final TextField textbox = new TextField();
+//        textbox.setColumns(18);
+        textbox.setLayoutX(50);
+        textbox.setLayoutY(100);
+        content.add(textbox);
+
+        return rootGroup;
+    }
+
+    private static Scene createScene(PopupPlacement popupPlacement) {
+        Scene scene = new Scene(createRootGroup(popupPlacement));
+        return scene;
+    }
+
+    private static Popup createPopup(PopupPlacement popupPlacement) {
+        Popup popup = new Popup();
+
+        popup.getContent().add(createRootGroup(popupPlacement));
+        popup.setAutoHide(true);
+
+        return popup;
+    }
+
+    private static final class PopupActionHandler
+            implements EventHandler<ActionEvent> {
+        private final Node popupParent;
+        private final PopupPlacement popupPlacement;
+        private final int popupX;
+        private final int popupY;
+
+        private Popup nextPopup;
+
+        public PopupActionHandler(PopupPlacement popupPlacement, 
+                                  Node popupParent) {
+            this.popupPlacement = popupPlacement;
+            this.popupParent = popupParent;
+            this.popupX = popupPlacement.getNextX();
+            this.popupY = popupPlacement.getNextY();
+        }
+
+        public void handle(final ActionEvent t) {
+            if (nextPopup == null) {
+                nextPopup = createPopup(popupPlacement);
+            }
+
+            nextPopup.show(popupParent, popupX, popupY);
+            
+            Iterator<Window> windows = Window.impl_getWindows();
+            while (windows.hasNext()) {
+                System.out.println("W: " + windows.next().getClass().getName());
+            }
+        }
+    }
+
+    private static final class PopupPlacement {
+        private int x;
+        private int y;
+
+        public PopupPlacement(int x, int y) {
+            this.x = x;
+            this.y = y;
+        }
+
+        public int getNextX() {
+            int oldX = x;
+            x += WIDTH;
+            return oldX;
+        }
+
+        public int getNextY() {
+            return y;
+        }
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloPopupMenu.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,122 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.control.ContextMenu;
+import javafx.scene.control.MenuItem;
+import javafx.scene.paint.Color;
+import javafx.stage.Stage;
+import javafx.stage.WindowEvent;
+
+public class HelloPopupMenu extends Application {
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello PopupMenu");
+        stage.setWidth(500);
+        stage.setHeight(500);
+        Scene scene = createScene();
+        scene.setFill(Color.WHITE);
+
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    private Scene createScene() {
+        final Scene scene = new Scene(new Group());
+        final ContextMenu popupMenu = new ContextMenu();
+        popupMenu.setOnShowing(new EventHandler<WindowEvent>() {
+            @Override public void handle(WindowEvent t) {
+                System.out.println("showing");
+            }
+        });
+        popupMenu.setOnShown(new EventHandler<WindowEvent>() {
+            @Override public void handle(WindowEvent t) {
+                System.out.println("shown");
+            }
+        });
+        popupMenu.setOnHiding(new EventHandler<WindowEvent>() {
+            @Override public void handle(WindowEvent t) {
+                System.out.println("hiding");
+            }
+        });
+        popupMenu.setOnHidden(new EventHandler<WindowEvent>() {
+            @Override public void handle(WindowEvent t) {
+                System.out.println("hidden");
+            }
+        });
+        popupMenu.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent t) {
+                System.out.println("on Action: " + t.getTarget());
+            }
+        });
+
+        MenuItem item1 = new MenuItem("About");
+        item1.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                System.out.println("About");
+            }
+        });
+
+        MenuItem item2 = new MenuItem("Preferences");
+        item2.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                System.out.println("Preferences");
+            }
+        });
+
+        MenuItem item3 = new MenuItem("Templates");
+        item3.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                System.out.println("Templates");
+            }
+        });
+
+        popupMenu.getItems().add(item1);
+        popupMenu.getItems().add(item2);
+        popupMenu.getItems().add(item3);
+
+        final Button button = new Button("Click me");
+        button.setContextMenu(popupMenu);
+
+        Group root = (Group) scene.getRoot();
+        root.getChildren().clear();
+        root.getChildren().add(button);
+        return scene;
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloProgressBar.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,104 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.ProgressBar;
+import javafx.scene.paint.Color;
+import javafx.stage.Stage;
+
+public class HelloProgressBar extends Application {
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello ProgressBar");
+        Scene scene = new Scene(new Group(), 600, 450);
+        scene.setFill(Color.CHOCOLATE);
+
+        Group root = (Group)scene.getRoot();
+
+        double y = 15;
+        final double SPACING = 15;
+
+        ProgressBar pbar = new ProgressBar();
+        pbar.setLayoutX(15);
+        pbar.setLayoutY(y);
+        pbar.setVisible(true);
+        root.getChildren().add(pbar);
+
+        y += SPACING;
+        pbar = new ProgressBar();
+        pbar.setPrefWidth(150);
+        pbar.setLayoutX(15);
+        pbar.setLayoutY(y);
+        pbar.setVisible(true);
+        root.getChildren().add(pbar);
+
+        y += SPACING;
+        pbar = new ProgressBar();
+        pbar.setPrefWidth(200);
+        pbar.setLayoutX(15);
+        pbar.setLayoutY(y);
+        pbar.setVisible(true);
+        root.getChildren().add(pbar);
+
+        y = 15;
+        pbar = new ProgressBar();
+        pbar.setLayoutX(230);
+        pbar.setLayoutY(y);
+        pbar.setProgress(0.25);
+        pbar.setVisible(true);
+        root.getChildren().add(pbar);
+
+        y += SPACING;
+        pbar = new ProgressBar();
+        pbar.setPrefWidth(150);
+        pbar.setLayoutX(230);
+        pbar.setLayoutY(y);
+        pbar.setProgress(0.50);
+        pbar.setVisible(true);
+        root.getChildren().add(pbar);
+
+        y += SPACING;
+        pbar = new ProgressBar();
+        pbar.setPrefWidth(200);
+        pbar.setLayoutX(230);
+        pbar.setLayoutY(y);
+        pbar.setProgress(1);
+        root.getChildren().add(pbar);
+
+        stage.setScene(scene);
+        stage.show();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloProgressIndicator.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,201 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.animation.KeyFrame;
+import javafx.animation.KeyValue;
+import javafx.animation.Timeline;
+import javafx.application.Application;
+import javafx.beans.value.ChangeListener;
+import javafx.beans.value.ObservableValue;
+import javafx.event.ActionEvent;
+import javafx.event.EventHandler;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.ProgressIndicator;
+import javafx.scene.paint.Color;
+import javafx.scene.shape.Circle;
+import javafx.stage.Stage;
+import javafx.util.Duration;
+
+public class HelloProgressIndicator extends Application {
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello ProgressIndicator");
+        Scene scene = new Scene(new Group(), 600, 450);
+//        scene.setFill(Color.CHOCOLATE);
+
+        Group root = (Group)scene.getRoot();
+
+        ProgressIndicator pInd1 = new ProgressIndicator();
+        pInd1.setPrefSize(50, 50);
+        pInd1.setLayoutX(25);
+        pInd1.setLayoutY(40);
+        pInd1.setVisible(true);
+        root.getChildren().add(pInd1);
+
+        ProgressIndicator pInd1a = new ProgressIndicator();
+        pInd1a.setStyle("-fx-progress-color: red;");
+        pInd1a.setPrefSize(100, 100);
+        pInd1a.setLayoutX(75);
+        pInd1a.setLayoutY(40);
+        pInd1a.setVisible(true);
+        root.getChildren().add(pInd1a);
+
+        ProgressIndicator pInd2 = new ProgressIndicator();
+        pInd2.setPrefSize(150, 150);
+        pInd2.setLayoutX(200);
+        pInd2.setLayoutY(20);
+        pInd2.setProgress(0.25F);
+        pInd2.setVisible(true);
+        root.getChildren().add(pInd2);
+
+        ProgressIndicator pInd25 = new ProgressIndicator();
+        pInd25.setPrefSize(150, 150);
+        pInd25.setLayoutX(300);
+        pInd25.setLayoutY(20);
+        pInd25.setProgress(1);
+        pInd25.setVisible(true);
+        root.getChildren().add(pInd25);
+
+        ProgressIndicator pInd3 = new ProgressIndicator();
+        pInd3.setPrefSize(100, 100);
+        pInd3.setLayoutX(25);
+        pInd3.setLayoutY(150);
+        pInd3.setProgress(0.5F);
+        pInd3.setVisible(true);
+        root.getChildren().add(pInd3);
+
+        ProgressIndicator pInd4 = new ProgressIndicator();
+        pInd4.setPrefSize(40, 40);
+        pInd4.setLayoutX(200);
+        pInd4.setLayoutY(150);
+        pInd4.setProgress(1.0F);
+        pInd4.setVisible(true);
+        root.getChildren().add(pInd4);
+
+        ProgressIndicator pInd5 = new ProgressIndicator();
+        pInd5.setLayoutX(100);
+        pInd5.setLayoutY(250);
+        pInd5.setProgress(1.0F);
+        root.getChildren().add(pInd5);
+
+        ProgressIndicator pInd6 = new ProgressIndicator();
+        pInd6.setLayoutX(200);
+        pInd6.setLayoutY(250);
+        pInd6.setProgress(0.5);
+        root.getChildren().add(pInd6);
+
+        ProgressIndicator pInd7 = new ProgressIndicator();
+        pInd7.setLayoutX(300);
+        pInd7.setLayoutY(250);
+        pInd7.setProgress(-1);
+        pInd7.setStyle("-fx-spin-enabled:true;");
+        root.getChildren().add(pInd7);
+
+        ProgressIndicator pInd8 = new ProgressIndicator();
+        pInd8.setLayoutX(360);
+        pInd8.setLayoutY(250);
+        pInd8.setProgress(-1);
+        pInd8.setStyle("-fx-spin-enabled:false;");
+        root.getChildren().add(pInd8);
+
+        ProgressIndicator pInd9 = new ProgressIndicator();
+        pInd9.setLayoutX(450);
+        pInd9.setPrefSize(100, 100);
+        pInd9.setLayoutY(250);
+        pInd9.setProgress(-0.1);
+
+        final String styleRED = new String("-fx-progress-color: red;");
+        final String styleORANGE = new String("-fx-progress-color: orange;");
+        final String styleGREEN = new String("-fx-progress-color: green;");
+
+        pInd9.progressProperty().addListener(new ChangeListener<Number>() {
+           @Override public void changed(ObservableValue ov, Number oldVal, Number newVal) {
+               String currentStyle = pInd9.getStyle();
+               if (pInd9.getProgress() < 0.25) {
+                   if (!currentStyle.contains(styleRED)) {
+                       pInd9.setStyle(styleRED);
+                   }
+               }
+               else if (pInd9.getProgress() < 0.5) {
+                   if (!currentStyle.contains(styleORANGE)) {
+                       pInd9.setStyle(styleORANGE);
+                   }
+               }
+               else {
+                   if (!currentStyle.contains(styleGREEN)) {
+                       pInd9.setStyle(styleGREEN);
+                   }
+               }
+            }
+        });
+        root.getChildren().add(pInd9);
+
+        final Timeline timeline = new Timeline();
+        timeline.setCycleCount(Timeline.INDEFINITE);
+        timeline.setAutoReverse(true);
+        final KeyValue kv = new KeyValue(pInd9.progressProperty(), 1);
+        final KeyFrame kf1 = new KeyFrame(Duration.millis(3000), kv);
+        timeline.getKeyFrames().add(kf1);
+        timeline.play();
+
+
+        // Helper code to create CSS for dotted progress indicator.
+        Group g2 = new Group();
+        root.getChildren().add(0,g2);
+        double smallRadius = 1.5;
+        double bigRadius = 14-smallRadius;
+        String circles = "";
+        for(int angle=0, i=0; angle<360; angle += 30, i++) {
+            double centerX = bigRadius + smallRadius + Math.cos(Math.toRadians(angle)) * bigRadius;
+            double centerY = bigRadius + smallRadius + Math.sin(Math.toRadians(angle)) * bigRadius;
+            g2.getChildren().add(new Circle(centerX,centerY,smallRadius,Color.rgb(0,0,0,0.1)));
+            circles += writeCircle(centerX,centerY,smallRadius);
+            //System.out.println(".progress-indicator:indeterminate .segment"+i+" {\n" +
+            //   "    -fx-shape:\""+ writeCircle(centerX,centerY,smallRadius)+"\";\n" +
+            //   "}");
+        }
+        //System.out.println("<path d=\""+circles+"\" />");
+
+        stage.setScene(scene);
+        stage.show();
+    }
+
+
+    private String writeCircle(double  centerX,double centerY,double radius) {
+        centerX = ((int)(centerX*100))/100d;
+        centerY = ((int)(centerY*100))/100d;
+        return "M"+(centerX-radius)+" "+centerY+" a"+radius+","+radius+" 0 1,1 0,1 Z";
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloRadioButton.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,71 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import static javafx.scene.paint.Color.GHOSTWHITE;
+import javafx.application.Application;
+import javafx.collections.ObservableList;
+import javafx.scene.Group;
+import javafx.scene.Node;
+import javafx.scene.Scene;
+import javafx.scene.control.RadioButton;
+import javafx.scene.control.ToggleGroup;
+import javafx.stage.Stage;
+
+/**
+ * Demo for {@code RadioButton}.
+ */
+public class HelloRadioButton extends Application {
+
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello RadioButton");
+        stage.setWidth(600);
+        stage.setHeight(450);
+        Scene scene = newScene();
+        ToggleGroup group = new ToggleGroup();
+        RadioButton button1 = new RadioButton("Luke, *I* am your father");
+        button1.setToggleGroup(group);
+        RadioButton button2 = new RadioButton("Nooooooooo!");
+        button2.setLayoutY(40);
+        button2.setToggleGroup(group);
+        button1.setSelected(true);
+        ObservableList<Node> content = ((Group)scene.getRoot()).getChildren();
+        content.add(button1);
+        content.add(button2);
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    private static Scene newScene() {
+        Scene scene = new Scene(new Group());
+        scene.setFill(GHOSTWHITE);
+        return scene;
+    }
+}
--- a/apps/toys/Hello/src/main/java/hello/HelloRectangle.java	Sat Dec 28 08:05:35 2013 -0800
+++ b/apps/toys/Hello/src/main/java/hello/HelloRectangle.java	Thu Jan 02 10:58:15 2014 -0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -26,30 +26,37 @@
 package hello;
 
 import javafx.application.Application;
+import javafx.event.EventHandler;
 import javafx.scene.Group;
 import javafx.scene.Scene;
+import javafx.scene.input.MouseEvent;
 import javafx.scene.paint.Color;
 import javafx.scene.shape.Rectangle;
 import javafx.stage.Stage;
 
-/**
- */
 public class HelloRectangle extends Application {
+
     @Override public void start(Stage stage) {
         stage.setTitle("Hello Rectangle");
 
         Group root = new Group();
         Scene scene = new Scene(root, 600, 450);
+        scene.setFill(Color.LIGHTGREEN);
 
         Rectangle rect = new Rectangle();
         rect.setX(25);
         rect.setY(40);
-        rect.setWidth(300);
-        rect.setHeight(300);
+        rect.setWidth(100);
+        rect.setHeight(50);
         rect.setFill(Color.RED);
+        rect.setOnMousePressed(new EventHandler<MouseEvent>() {
+            @Override
+            public void handle(MouseEvent e) {
+                System.out.println("Mouse Pressed:" + e);
+            }
+        });
 
-        root.getChildren().addAll(rect);
-
+        root.getChildren().add(rect);
         stage.setScene(scene);
         stage.show();
     }
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloSanity.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,126 @@
+/*
+ * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.event.ActionEvent;
+import javafx.event.Event;
+import javafx.event.EventHandler;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.*;
+import javafx.scene.layout.VBox;
+import javafx.stage.Stage;
+import javafx.stage.Screen;
+import javafx.application.Application;
+import javafx.geometry.Pos;
+import javafx.geometry.Rectangle2D;
+import com.sun.glass.ui.Robot;
+
+/**
+ *  The application should be used by QA in order to test main
+ *  FX functionality
+ */
+public class HelloSanity extends Application {
+
+    public static void main(String[] args) {
+        launch(args);
+    }
+    
+    
+    //@Override
+    public void start(final Stage primaryStage) {
+
+        Screen screen = Screen.getPrimary();
+        Rectangle2D bounds = screen.getVisualBounds();
+
+        primaryStage.setX(0);
+        primaryStage.setY(0);
+        final VBox mainBox = new VBox(30);
+        mainBox.setAlignment(Pos.CENTER);
+        final Scene globalScene = new Scene(new Group(),bounds.getWidth(), bounds.getHeight());
+        final TestBuilder builder = TestBuilder.getInstance();
+
+        Label welcome = new Label("Welcome to Hello Sanity");
+
+        Button bControls = new Button("Controls");
+        bControls.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                builder.controlTest(globalScene, mainBox);
+            }
+        });
+
+        Button bTabs = new Button("Tabs and Menus");
+        bTabs.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                builder.menusTest(globalScene, mainBox, primaryStage);
+            }
+        });
+
+        Button bWins = new Button("Windows");
+        bWins.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                builder.windowsTest(globalScene, mainBox, primaryStage);
+            }
+        });
+
+        Button bAnim = new Button("Animation");
+        bAnim.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                builder.animationTest(globalScene, mainBox);
+            }
+        });
+
+        Button bEffs = new Button("Effects");
+        bEffs.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                builder.effectsTest(globalScene, mainBox);
+            }
+        });
+
+        Button bRobot = new Button("Robot");
+        bRobot.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                builder.robotTest(globalScene, mainBox, primaryStage);
+            }
+        });
+
+        Button bswipe = new Button("Swipe");
+        bswipe.setOnAction(new EventHandler<ActionEvent>() {
+            @Override public void handle(ActionEvent e) {
+                builder.swipeTest(globalScene, mainBox);
+            }
+        });
+        
+        mainBox.getChildren().addAll(welcome, bControls, bTabs, bWins, bRobot,  bAnim,
+                                                                        bEffs, bswipe);
+        globalScene.setRoot(mainBox);
+        globalScene.getStylesheets().add("hello/HelloSanityStyles.css");
+        primaryStage.setScene(globalScene);
+        primaryStage.show();
+    }   
+}
+
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloSanityStyles.css	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,64 @@
+    /*
+        Font configuration for HelloSanity sample
+    */
+    
+    .button {
+    -fx-font-size: 18px;
+    }
+
+    .label {
+    -fx-font-size: 18px;
+    }
+
+    .text-field {
+    -fx-font-size: 18px;
+    }
+
+    .radio-button {
+    -fx-font-size: 18px;
+    }
+
+    .check-box {
+    -fx-font-size: 18px;
+    }
+    
+    .slider {
+    -fx-font-size: 18px;
+    }
+
+    .scroll-pane {
+    -fx-font-size: 18px;
+    }
+
+    .list-view {
+    -fx-font-size: 18px;
+    }
+
+    .menu-bar {
+    -fx-font-size: 18px;
+    }
+
+    .menu {
+    -fx-font-size: 18px;
+    }
+
+    .combo-box {
+    -fx-font-size: 18px;
+    }
+
+    .menu-item {
+    -fx-font-size: 18px;
+    }
+
+    .menu-button {
+    -fx-font-size: 18px;
+    }
+
+    .split-menu-button {
+    -fx-font-size: 18px;
+    }
+
+
+
+
+    
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloScatterChart.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,72 @@
+/*
+ * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.collections.FXCollections;
+import javafx.collections.ObservableList;
+import javafx.scene.Scene;
+import javafx.scene.chart.Chart;
+import javafx.scene.chart.NumberAxis;
+import javafx.scene.chart.ScatterChart;
+import javafx.scene.chart.XYChart;
+import javafx.stage.Stage;
+
+public class HelloScatterChart extends Application {
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello ScatterChart");
+        Scene scene = new Scene(createScatterChart(), 500, 500);
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    private Chart createScatterChart() {
+
+        final NumberAxis xAxis = new NumberAxis();
+        final NumberAxis yAxis = new NumberAxis();
+        final ScatterChart<Number,Number> sc = new ScatterChart<Number,Number>(xAxis,yAxis);
+        // setup chart
+        sc.setTitle("Scatter Chart Example");
+        xAxis.setLabel("X Axis");
+        yAxis.setLabel("Y Axis");
+        // add starting data
+        ObservableList<XYChart.Data> data = FXCollections.observableArrayList();
+        XYChart.Series series = new XYChart.Series();
+        series.setName("Data Series 1");
+        for (int i=0; i<10; i++) series.getData().add(new XYChart.Data(Math.random()*100, Math.random()*100));
+        sc.getData().add(series);
+       
+        return sc;
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloScrollBar.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,150 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.geometry.Orientation;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.ScrollBar;
+import javafx.scene.paint.Color;
+import javafx.stage.Stage;
+
+public class HelloScrollBar extends Application {
+
+    /**
+     * TODO: once we get unit tests working for controls, this
+     * should become a unit test.
+     */
+    static void test() {
+        ScrollBar sb;
+
+        sb = new ScrollBar();
+        sb.setFocusTraversable(true);
+        sb.setMin(7000);
+        if (sb.getMin() != 7000) {
+            System.err.println("Could not set min to 7000");
+        }
+
+        sb = new ScrollBar();
+        sb.setFocusTraversable(true);
+        sb.setMax(-10);
+        if (sb.getMax() != -10) {
+            System.err.println("Could not set max to -10");
+        }
+
+        sb = new ScrollBar();
+        sb.setFocusTraversable(true);
+        sb.setMin(100);
+        if (sb.getMin() != 100) {
+            System.err.println("Could not set min to 100");
+        }
+
+        sb = new ScrollBar();
+        sb.setFocusTraversable(true);
+        sb.setMax(0);
+        if (sb.getMax() != 0) {
+            System.err.println("Could not set max to 0");
+        }
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+    @Override public void start(Stage stage) {
+        test();
+        stage.setTitle("Hello ScrollBar");
+        Scene scene = new Scene(new Group(), 600, 450);
+        scene.setFill(Color.CHOCOLATE);
+
+        Group root = (Group)scene.getRoot();
+        
+        ScrollBar sbarV1 = new ScrollBar();
+        sbarV1.setFocusTraversable(true);
+        sbarV1.setMax(100);
+        sbarV1.setOrientation(Orientation.VERTICAL);
+        sbarV1.setLayoutX(25);
+        sbarV1.setLayoutY(40);
+        sbarV1.setVisible(true);
+        root.getChildren().add(sbarV1);
+
+        ScrollBar sbarV2 = new ScrollBar();
+        sbarV2.setFocusTraversable(true);
+        sbarV2.setMax(100);
+        sbarV2.setPrefSize(25, 200);
+        sbarV2.setOrientation(Orientation.VERTICAL);
+        sbarV2.setLayoutX(55);
+        sbarV2.setLayoutY(40);
+        sbarV2.setVisible(true);
+        root.getChildren().add(sbarV2);
+
+        ScrollBar sbarV3 = new ScrollBar();
+        sbarV3.setFocusTraversable(true);
+        sbarV3.setMax(100);
+        sbarV3.setPrefSize(50, 300);
+        sbarV3.setOrientation(Orientation.VERTICAL);
+        sbarV3.setLayoutX(100);
+        sbarV3.setLayoutY(40);
+        sbarV3.setVisible(true);
+        root.getChildren().add(sbarV3);
+
+        ScrollBar sbarH1 = new ScrollBar();
+        sbarH1.setFocusTraversable(true);
+        sbarH1.setMax(100);
+        sbarH1.setOrientation(Orientation.HORIZONTAL);
+        sbarH1.setLayoutX(200);
+        sbarH1.setLayoutY(40);
+        sbarH1.setVisible(true);
+        root.getChildren().add(sbarH1);
+
+        ScrollBar sbarH2 = new ScrollBar();
+        sbarH2.setFocusTraversable(true);
+        sbarH2.setMax(100);
+        sbarH2.setPrefSize(200, 25);
+        sbarH2.setOrientation(Orientation.HORIZONTAL);
+        sbarH2.setLayoutX(200);
+        sbarH2.setLayoutY(80);
+        sbarH2.setVisible(true);
+        root.getChildren().add(sbarH2);
+
+        ScrollBar sbarH3 = new ScrollBar();
+        sbarH3.setFocusTraversable(true);
+        sbarH3.setMax(100);
+        sbarH3.setPrefSize(300, 50);
+        sbarH3.setOrientation(Orientation.HORIZONTAL);
+        sbarH3.setLayoutX(200);
+        sbarH3.setLayoutY(140);
+        sbarH3.setVisible(true);
+        root.getChildren().add(sbarH3);
+
+        stage.setScene(scene);
+        stage.show();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloScrollPane.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,107 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+
+import javafx.application.Application;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.ScrollPane;
+import javafx.scene.image.Image;
+import javafx.scene.image.ImageView;
+import javafx.scene.paint.Color;
+import javafx.stage.Stage;
+
+
+public class HelloScrollPane extends Application {
+
+    public static Image createImage(String filename, float width, float height) {
+        String file = HelloScrollPane.class.getResource(filename).toExternalForm();
+        return new Image(file, width, height, true, true, false);
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+    @Override public void start(Stage stage) {
+        Image image1 = createImage("duke.jpg", 200f, 200f);
+        ImageView imageView1 = new ImageView();
+        imageView1.setImage(image1);
+
+        Image image2 = createImage("duke.jpg", 200f, 200f);
+        ImageView imageView2 = new ImageView();
+        imageView2.setImage(image2);
+
+        Image image3 = createImage("duke.jpg", 200f, 200f);
+        ImageView imageView3 = new ImageView();
+        imageView3.setImage(image3);
+
+        stage.setTitle("Hello ScrollPane");
+        Scene scene = new Scene(new Group(), 600, 450);
+        scene.setFill(Color.CHOCOLATE);
+
+        Group root = (Group)scene.getRoot();
+
+
+        ScrollPane sView1 = new ScrollPane();
+        sView1.setContent(imageView1);
+        sView1.setPrefSize(150, 150);
+        sView1.setLayoutX(20);
+        sView1.setLayoutY(40);
+        sView1.setPannable(true);
+        sView1.setVisible(true);
+        root.getChildren().add(sView1);
+
+        ScrollPane sView2 = new ScrollPane();
+        sView2.setContent(imageView2);
+        sView2.setPrefSize(214, 150);
+        sView2.setLayoutX(200);
+        sView2.setLayoutY(40);
+        sView2.setPannable(true);
+        sView2.setVisible(true);
+        /*
+        **  set focus traversable to allow keyboard input.
+        */
+        sView2.setFocusTraversable(true);
+        root.getChildren().add(sView2);
+
+        ScrollPane sView3 = new ScrollPane();
+        sView3.setContent(imageView3);
+        sView3.setPrefSize(150, 214);
+        sView3.setLayoutX(430);
+        sView3.setLayoutY(40);
+        sView3.setPannable(true);
+        sView3.setVisible(true);
+        root.getChildren().add(sView3);
+
+        stage.setScene(scene);
+        stage.show();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloSeparator.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,87 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+
+import java.util.ArrayList;
+import java.util.List;
+
+import javafx.application.Application;
+import javafx.beans.InvalidationListener;
+import javafx.beans.Observable;
+import javafx.geometry.Orientation;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.Separator;
+import javafx.scene.control.ToggleButton;
+import javafx.stage.Stage;
+
+public class HelloSeparator extends Application {
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello Separator");
+
+        Scene scene = new Scene(new Group(), 200, 600);
+
+        int offsetX = 0;
+        int offsetY = 0;
+        final List<Separator> separators = new ArrayList<Separator>();
+        for(int i = 0; i < 10; i++) {
+            Separator s = new Separator();
+            separators.add(s);
+
+            s.setLayoutX(25 + offsetX);
+            s.setLayoutY(40 + offsetY);
+
+            offsetY += 45;
+            offsetX += 5;
+            
+            ((Group)scene.getRoot()).getChildren().add(s);
+        }
+
+        ToggleButton toggle = new ToggleButton("Horizontal Slider");
+        toggle.setSelected(true);
+        toggle.selectedProperty().addListener(new InvalidationListener() {
+            public void invalidated(Observable ov) {
+                for (Separator s : separators) {
+                    s.setOrientation(s.getOrientation() == Orientation.VERTICAL ?
+                            Orientation.HORIZONTAL : Orientation.VERTICAL);
+                }
+            }
+        });
+        ((Group)scene.getRoot()).getChildren().add(toggle);
+
+        stage.setScene(scene);
+        stage.show();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloSlider.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,92 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.scene.Scene;
+import javafx.scene.control.Slider;
+import javafx.scene.image.Image;
+import javafx.scene.image.ImageView;
+import javafx.scene.layout.VBox;
+import javafx.stage.Stage;
+
+public class HelloSlider extends Application {
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("Hello Slider");
+        
+        VBox vbox = new VBox(4);
+        Slider slider = new Slider();
+        vbox.getChildren().add(slider);
+        
+        slider = new Slider();
+        slider.setBlockIncrement(30);
+        vbox.getChildren().add(slider);
+        
+        slider = new Slider();
+        slider.setSnapToTicks(true);
+        vbox.getChildren().add(slider);
+        
+        slider = new Slider();
+        slider.setShowTickMarks(true);
+        vbox.getChildren().add(slider);
+
+         stage.setTitle("Hello Slider");
+
+        slider = new Slider(0, 1.0, 1.0);
+        slider.setBlockIncrement(0.2d);
+        slider.setMajorTickUnit(0.2d);
+        slider.setMinorTickCount(3);
+        slider.setSnapToTicks(true);
+        slider.setShowTickMarks(true);
+        slider.setShowTickLabels(true);
+
+        ImageView view = new ImageView(new Image("hello/duke_with_guitar.png"));
+        view.opacityProperty().bind(slider.valueProperty());
+        vbox.getChildren().add(view);
+        vbox.getChildren().add(slider);
+
+        slider = new Slider(0, 180.0, 0.0);
+        slider.setBlockIncrement(10d);
+        slider.setMajorTickUnit(30d);
+        slider.setMinorTickCount(10);
+        slider.setShowTickMarks(true);
+        slider.setShowTickLabels(true);
+        view.rotateProperty().bind(slider.valueProperty());
+        vbox.getChildren().add(slider);
+
+        Scene scene = new Scene(vbox);
+        stage.setScene(scene);
+        stage.show();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloSnapshot2.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,101 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.scene.Group;
+import javafx.scene.PerspectiveCamera;
+import javafx.scene.Scene;
+import javafx.scene.SnapshotParameters;
+import javafx.scene.SnapshotResult;
+import javafx.scene.image.Image;
+import javafx.scene.image.ImageView;
+import javafx.scene.layout.HBox;
+import javafx.scene.paint.Color;
+import javafx.scene.shape.Ellipse;
+import javafx.scene.transform.Transform;
+import javafx.stage.Stage;
+import javafx.util.Callback;
+
+public class HelloSnapshot2 extends Application {
+
+    @Override
+    public void start(Stage stage) {
+        stage.setTitle("HelloSnapshot2");
+
+        Group g = new Group();
+        Ellipse ellipse = new Ellipse(25, 20);
+        ellipse.setTranslateX(25);
+        ellipse.setTranslateY(25);
+        ellipse.setFill(Color.PALEGREEN);
+        g.getChildren().add(ellipse);
+        Group root = new Group(g);
+//        root.getTransforms().add(new Rotate(30));
+//        root.setRotate(30);
+
+        final Scene ellipseScene = new Scene(root);
+        ellipseScene.setFill(Color.DARKBLUE);
+        SnapshotParameters params = new SnapshotParameters();
+        params.setCamera(new PerspectiveCamera());
+        params.setFill(Color.DARKBLUE);
+        params.setTransform(Transform.rotate(30, 25, 25));
+//        params.setViewport(new Rectangle2D(20, 15, 100, 75));
+
+        final Image image2 = ellipse.snapshot(params, null);
+        final Image image1 = ellipseScene.snapshot(null);
+
+        Scene scene = new Scene(new Group(), 400, 300);
+        scene.setFill(Color.BROWN);
+
+        final HBox container = new HBox();
+        container.getChildren().add(new ImageView(image1));
+        container.getChildren().add(new ImageView(image2));
+
+        ellipse.snapshot(new Callback<SnapshotResult, Void>() {
+            public Void call(SnapshotResult r) {
+                System.err.println("callback: image = " + r.getImage()
+                        + "  source = " + r.getSource()
+                        + "  params = " + r.getSnapshotParameters());
+                container.getChildren().add(new ImageView(r.getImage()));
+                return null;
+            }
+        }, params, null);
+
+        params.setFill(Color.YELLOW);  // this should not affect the rendering
+        ellipse.setStroke(Color.RED); // this should
+        ellipse.setStrokeWidth(3);
+
+        scene.setRoot(container);
+        stage.setScene(scene);
+        stage.show();
+
+    }
+
+    public static void main(String[] args) {
+        javafx.application.Application.launch(args);
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloSplitPane.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,280 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.beans.InvalidationListener;
+import javafx.beans.Observable;
+import javafx.event.EventHandler;
+import javafx.geometry.Orientation;
+import javafx.geometry.Pos;
+import javafx.scene.Group;
+import javafx.scene.Scene;
+import javafx.scene.control.Button;
+import javafx.scene.control.Slider;
+import javafx.scene.control.SplitPane;
+import javafx.scene.input.MouseEvent;
+import javafx.scene.layout.HBox;
+import javafx.scene.layout.VBox;
+import javafx.scene.layout.VBoxBuilder;
+import javafx.scene.paint.Color;
+import javafx.stage.Stage;
+
+public class HelloSplitPane extends Application {
+
+    private final Slider horizSlider = new Slider();
+    private final SplitPane horizSplitPane = new SplitPane();
+    
+    private final Slider vertSlider = new Slider();
+    private final SplitPane vertSplitPane = new SplitPane();
+    private final SplitPane mailClient = new SplitPane();
+    private final SplitPane mailClient2 = new SplitPane();
+    private final SplitPane recursiveSplitPane = new SplitPane();
+
+    @Override public void init() {
+        horizSlider.setMin(0);
+        horizSlider.setMax(1);
+        horizSlider.setValue(0.5f);
+        horizSlider.setPrefWidth(horizSplitPane.prefWidth(-1));
+        horizSlider.valueProperty().addListener(new InvalidationListener() {
+            public void invalidated(Observable ov) {
+                horizSplitPane.setDividerPosition(0, horizSlider.getValue());
+            }
+        });
+
+        horizSplitPane.setPrefSize(200, 200);
+        final Button l = new Button("Left Button");
+        final Button r = new Button("Right Button");
+        horizSplitPane.getItems().addAll(
+            VBoxBuilder.create().children(l).alignment(Pos.CENTER).build(),
+            VBoxBuilder.create().children(r).alignment(Pos.CENTER).build());
+        horizSplitPane.getDividers().get(0).positionProperty().addListener(new InvalidationListener() {
+            public void invalidated(Observable ov) {
+                horizSlider.setValue(horizSplitPane.getDividers().get(0).getPosition());
+            }
+        });
+        horizSplitPane.widthProperty().addListener(new InvalidationListener() {
+            public void invalidated(Observable ov) {
+                horizSlider.setPrefWidth(horizSplitPane.prefWidth(-1));
+            }
+        });
+
+        vertSlider.setOrientation(Orientation.VERTICAL);
+        vertSlider.setMin(0);
+        vertSlider.setMax(1);
+        vertSlider.setValue(0.5f);
+        vertSlider.setPrefHeight(vertSplitPane.prefHeight(-1));
+        vertSlider.valueProperty().addListener(new InvalidationListener() {
+            public void invalidated(Observable ov) {                
+                vertSplitPane.setDividerPosition(0, 1 - vertSlider.getValue());
+            }
+        });
+
+        vertSplitPane.setPrefSize(200, 200);
+        vertSplitPane.setOrientation(Orientation.VERTICAL);
+        final Button t = new Button("Top Button");
+        final Button b = new Button("Bottom Button");
+        vertSplitPane.getItems().addAll(
+            VBoxBuilder.create().children(t).alignment(Pos.CENTER).build(),
+            VBoxBuilder.create().children(b).alignment(Pos.CENTER).build());
+        vertSplitPane.getDividers().get(0).positionProperty().addListener(new InvalidationListener() {
+            public void invalidated(Observable ov) {                
+                vertSlider.setValue(1 - vertSplitPane.getDividers().get(0).getPosition());
+            }
+        });
+        vertSplitPane.heightProperty().addListener(new InvalidationListener() {
+            public void invalidated(Observable ov) {
+                vertSlider.setPrefHeight(vertSplitPane.prefHeight(-1));
+            }
+        });
+
+        setupMailClient();
+        setupMailClient2();
+        setupRecursiveSplitPane();
+    }
+
+    private void setupMailClient() {
+        mailClient.setPrefSize(200, 200);
+        mailClient.setDividerPosition(0, 0.25f);
+        mailClient.setId("main-spt-pane");
+        Button lbtn = new Button("hello");
+        lbtn.setId("leftbtn");
+        mailClient.getItems().addAll(VBoxBuilder.create().children(lbtn).alignment(Pos.CENTER).build());
+        
+        SplitPane rsp = new SplitPane();
+        rsp.setId("right-spt-pane");
+        rsp.setDividerPosition(0, 0.6f);
+        rsp.setOrientation(Orientation.VERTICAL);
+        Button tbtn = new Button("hello");
+        tbtn.setId("right-topbtn");
+        rsp.getItems().addAll(VBoxBuilder.create().children(tbtn).alignment(Pos.CENTER).build());
+        Button bbtn = new Button("hello");
+        bbtn.setId("right-bottombtn");
+        rsp.getItems().addAll(VBoxBuilder.create().children(bbtn).alignment(Pos.CENTER).build());
+        mailClient.getItems().addAll(rsp);
+    }
+
+    private void setupMailClient2() {
+        mailClient2.setPrefSize(200, 200);
+        mailClient2.setDividerPosition(0, 0.25f);
+        mailClient2.setId("main-spt-pane");
+
+        SplitPane lsp = new SplitPane();
+        lsp.setOrientation(Orientation.HORIZONTAL);
+        SplitPane sp1 = new SplitPane();
+        sp1.setOrientation(Orientation.VERTICAL);
+        SplitPane sp2 = new SplitPane();
+        sp2.setOrientation(Orientation.VERTICAL);
+        lsp.getItems().addAll(sp1, sp2);
+        mailClient2.getItems().addAll(lsp);
+
+        SplitPane rsp = new SplitPane();
+        rsp.setId("right-spt-pane");
+        rsp.setDividerPosition(0, 0.6f);
+        rsp.setOrientation(Orientation.VERTICAL);
+        Button tbtn = new Button("hello");
+        tbtn.setId("right-topbtn");
+        rsp.getItems().addAll(VBoxBuilder.create().children(tbtn).alignment(Pos.CENTER).build());
+
+        Button bbtn = new Button("hello");
+        bbtn.setId("right-bottombtn");
+        rsp.getItems().addAll(VBoxBuilder.create().children(bbtn).alignment(Pos.CENTER).build());
+        mailClient2.getItems().addAll(rsp);
+    }
+
+    private void setupRecursiveSplitPane() {
+        recursiveSplitPane.setPrefSize(200, 200);
+        recursiveSplitPane.setDividerPosition(0, 0.6f);
+        recursiveSplitPane.setId("main-split-pane");
+
+        Button lbtn = new Button("hello");
+        lbtn.setId("left-btn");
+        recursiveSplitPane.getItems().addAll(VBoxBuilder.create().children(lbtn).alignment(Pos.CENTER).build());
+
+        SplitPane sp = new SplitPane();
+        sp.setId("right-split-pane");
+        sp.setDividerPosition(0, 0.6f);
+        sp.setOrientation(Orientation.VERTICAL);
+        Button rbtn = new Button("hello");
+        rbtn.setId("right-top-btn");
+        sp.getItems().addAll(VBoxBuilder.create().children(rbtn).alignment(Pos.CENTER).build());
+        SplitPane sv2 = new SplitPane();
+        sv2.setId("right-bottom-split-pane");
+        sp.getItems().addAll(sv2);
+        recursiveSplitPane.getItems().addAll(sp);
+    }
+
+    @Override public void start(Stage stage) {
+        stage.setTitle("SplitPane");
+        Scene scene = new Scene(new Group(), 1300, 400);
+        scene.setFill(Color.GHOSTWHITE);
+
+        VBox vbox = new VBox();
+        vbox.setSpacing(4);
+        vbox.getChildren().clear();
+        vbox.getChildren().add(horizSplitPane);
+        vbox.getChildren().add(horizSlider);
+
+        VBox vbox2 = new VBox();
+        vbox2.setSpacing(2);
+
+        Button b1 = new Button("0.0");
+        b1.setOnMouseClicked(new EventHandler<MouseEvent>() {
+            public void handle(MouseEvent me) {
+                horizSplitPane.setDividerPosition(0, 0);
+                vertSplitPane.setDividerPosition(0, 0);
+            }
+        });
+
+        Button b2 = new Button("0.25");
+        b2.setOnMouseClicked(new EventHandler<MouseEvent>() {
+            public void handle(MouseEvent me) {
+                horizSplitPane.setDividerPosition(0, 0.25f);
+                vertSplitPane.setDividerPosition(0, 0.25f);
+            }
+        });
+
+        Button b3 = new Button("0.50");
+        b3.setOnMouseClicked(new EventHandler<MouseEvent>() {
+            public void handle(MouseEvent me) {
+                horizSplitPane.setDividerPosition(0, 0.5f);
+                vertSplitPane.setDividerPosition(0, 0.5f);
+            }
+        });
+
+        Button b4 = new Button("0.75");
+        b4.setOnMouseClicked(new EventHandler<MouseEvent>() {
+            public void handle(MouseEvent me) {
+                horizSplitPane.setDividerPosition(0, 0.75f);
+                vertSplitPane.setDividerPosition(0, 0.75f);
+            }
+        });
+
+        Button b5 = new Button("1.0");
+        b5.setOnMouseClicked(new EventHandler<MouseEvent>() {
+            public void handle(MouseEvent me) {
+                horizSplitPane.setDividerPosition(0, 1.0f);
+                vertSplitPane.setDividerPosition(0, 1.0f);
+            }
+        });
+
+        vbox2.getChildren().clear();
+        vbox2.getChildren().add(b1);
+        vbox2.getChildren().add(b2);
+        vbox2.getChildren().add(b3);
+        vbox2.getChildren().add(b4);
+        vbox2.getChildren().add(b5);
+
+        HBox hbox2 = new HBox();
+        hbox2.setSpacing(4);
+        hbox2.getChildren().clear();
+        hbox2.getChildren().add(vertSplitPane);
+        hbox2.getChildren().add(vertSlider);
+
+        HBox hbox = new HBox();
+        hbox.setTranslateX(20);
+        hbox.setTranslateY(20);
+        hbox.setSpacing(20);
+        hbox.getChildren().clear();
+        hbox.getChildren().add(vbox);
+        hbox.getChildren().add(vbox2);
+        hbox.getChildren().add(hbox2);
+        hbox.getChildren().add(mailClient);
+        hbox.getChildren().add(mailClient2);
+        hbox.getChildren().add(recursiveSplitPane);
+
+        Group root = (Group)scene.getRoot();
+
+        root.getChildren().clear();
+        root.getChildren().add(hbox);
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloStackedAreaChart.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,95 @@
+/*
+ * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import javafx.application.Application;
+import javafx.collections.FXCollections;
+import javafx.collections.ObservableList;
+import javafx.scene.Scene;
+import javafx.scene.chart.NumberAxis;
+import javafx.scene.chart.StackedAreaChart;
+import javafx.scene.chart.XYChart;
+import javafx.scene.layout.VBox;
+import javafx.stage.Stage;
+
+
+public class HelloStackedAreaChart extends Application {
+
+    @Override public void start(Stage stage) {
+        // Set up Chart and axis
+        stage.setTitle("Hello AreaChart");
+        final NumberAxis xAxis = new NumberAxis();
+        final NumberAxis yAxis = new NumberAxis();
+        final StackedAreaChart<Number,Number> ac = new StackedAreaChart<Number,Number>(xAxis,yAxis);
+        xAxis.setLabel("X Axis");
+        yAxis.setLabel("Y Axis");
+        ac.setTitle("HelloStackedAreaChart");
+        
+        // Populate chart data.
+        ObservableList<XYChart.Data> data = FXCollections.observableArrayList();
+        final XYChart.Series<Number, Number> series1 = new XYChart.Series<Number, Number>();
+        final XYChart.Series<Number, Number> series2 = new XYChart.Series<Number, Number>();
+        final XYChart.Series<Number, Number> series3 = new XYChart.Series<Number, Number>();
+        series1.setName("Data Series 1");
+        series1.getData().add(new XYChart.Data(10d, 10d));
+        series1.getData().add(new XYChart.Data(25d, 20d));
+        series1.getData().add(new XYChart.Data(30d, 15d));
+        series1.getData().add(new XYChart.Data(50d, 15d));
+        series1.getData().add(new XYChart.Data(80d, 10d));
+        
+        series2.setName("Data Series 2");
+        series2.getData().add(new XYChart.Data(15d, 10d));
+        series2.getData().add(new XYChart.Data(20d, 5d));
+        series2.getData().add(new XYChart.Data(30d, 20d));
+        series2.getData().add(new XYChart.Data(60d, 5d));
+        series2.getData().add(new XYChart.Data(80d, 10d));
+        
+        series3.setName("Data Series 3");
+        series3.getData().add(new XYChart.Data(5d, 25d));
+        series3.getData().add(new XYChart.Data(20d, 10d));
+        series3.getData().add(new XYChart.Data(25d, 10d));
+        series3.getData().add(new XYChart.Data(30d, 15d));
+        series3.getData().add(new XYChart.Data(70d, 15d));
+        series3.getData().add(new XYChart.Data(80d, 15d));
+        
+        VBox box = new VBox(10);
+        ac.getData().addAll(series1, series2, series3);
+        box.getChildren().add(ac);
+        Scene scene  = new Scene(box,800,600);
+        
+        stage.setScene(scene);
+        stage.show();
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+}
+
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloStackedBarChart.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,99 @@
+/*
+ * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+import java.util.Arrays;
+import javafx.application.Application;
+import javafx.collections.FXCollections;
+import javafx.scene.Scene;
+import javafx.scene.chart.*;
+import javafx.scene.layout.VBox;
+import javafx.stage.Stage;
+
+public class HelloStackedBarChart extends Application {
+   
+    final String[] years = {"2007", "2008", "2009"};
+    
+    final CategoryAxis xAxis = new CategoryAxis();
+    final NumberAxis yAxis = new NumberAxis();
+    final StackedBarChart<String,Number> sbc = new StackedBarChart<String,Number>(xAxis,yAxis);
+    final XYChart.Series<String,Number> series1 = new XYChart.Series<String,Number>();
+    final XYChart.Series<String,Number> series2 = new XYChart.Series<String,Number>();
+    final XYChart.Series<String,Number> series3 = new XYChart.Series<String,Number>();
+    final XYChart.Series<String,Number> series4 = new XYChart.Series<String,Number>();
+    final XYChart.Series<String,Number> series5 = new XYChart.Series<String,Number>();
+        
+    
+    @Override
+    public void start(Stage stage) throws Exception {
+        stage.setTitle("Hello StackedBarChart");
+        populateChart();
+        VBox box = new VBox(10);
+       
+        box.getChildren().addAll(sbc);
+        Scene scene = new Scene(box, 500, 500);
+
+        stage.setScene(scene);
+        stage.show();
+        
+    }
+    
+    private void populateChart() {
+        
+        yAxis.setTickLabelFormatter(new NumberAxis.DefaultFormatter(yAxis,"$",null));
+        // setup chart
+        sbc.setTitle("Stacked Bar Chart");
+        xAxis.setLabel("Year");
+        xAxis.setCategories(FXCollections.<String>observableArrayList(Arrays.asList(years)));
+        yAxis.setLabel("Price");
+        // set series namges
+        series1.setName("Data Series 1");
+        series2.setName("Data Series 2");
+        series3.setName("Data Series 3");
+        // create sample data
+        series1.getData().add(new XYChart.Data<String,Number>(years[0], 567));
+        series1.getData().add(new XYChart.Data<String,Number>(years[1], 1292));
+        series1.getData().add(new XYChart.Data<String,Number>(years[2], 2180));
+        series2.getData().add(new XYChart.Data<String,Number>(years[0], 956));
+        series2.getData().add(new XYChart.Data<String,Number>(years[1], 1665));
+        series2.getData().add(new XYChart.Data<String,Number>(years[2], 2450));
+        series3.getData().add(new XYChart.Data<String,Number>(years[0], 800));
+        series3.getData().add(new XYChart.Data<String,Number>(years[1], 1000));
+        series3.getData().add(new XYChart.Data<String,Number>(years[2], 2800));
+        
+        sbc.getData().add(series1);
+        sbc.getData().add(series2);
+        sbc.getData().add(series3);
+    }
+
+    /**
+     * @param args the command line arguments
+     */
+    public static void main(String[] args) {
+        Application.launch(args);
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/toys/Hello/src/main/java/hello/HelloStyledPopups.java	Thu Jan 02 10:58:15 2014 -0800
@@ -0,0 +1,126 @@
+/*
+ * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package hello;
+
+
+import javafx.application.Application;
+import javafx.collections.FXCollections;
+import javafx.geometry.Insets;
+import javafx.geometry.Pos;
+import javafx.scene.Scene;
+import javafx.scene.control.*;
+import javafx.scene.layout.BorderPane;
+import javafx.scene.layout.HBox;
+import javafx.scene.layout.VBox;
+import javafx.stage.Stage;
+
+
+/*