changeset 4248:74160b530dfa

Merge
author Alexey Utkin <alexey.utkin@oracle.com>
date Wed, 10 Jul 2013 11:01:52 +0400
parents c0b912353269 9bbba7779511
children 4a0f90adb523
files .idea/ant.xml .idea/codeStyleSettings.xml .idea/copyright/OpenJFX_GPL.xml .idea/libraries/jfxrt_binary_stub.xml .idea/libraries/junit_4_8_2.xml idea/.idea/.name idea/.idea/compiler.xml idea/.idea/copyright/profiles_settings.xml idea/.idea/encodings.xml idea/.idea/gradle.xml idea/.idea/misc.xml idea/.idea/modules.xml idea/.idea/scopes/scope_settings.xml idea/.idea/uiDesigner.xml idea/.idea/vcs.xml idea/3DViewer.iml idea/Ensemble8.iml idea/Modena.iml idea/base.iml idea/buildSrc.iml idea/builders.iml idea/controls.iml idea/deploy.iml idea/designTime.iml idea/fxml.iml idea/fxpackager.iml idea/graphics.iml idea/media.iml idea/rt-closed.iml idea/rt.iml idea/swing.iml idea/swt.iml idea/web.iml modules/web/src/test/java/html/RT30835.html modules/web/src/test/java/html/RT9969.html modules/web/src/test/java/html/dom.html modules/web/src/test/java/html/guimark2-vector.html modules/web/src/test/java/html/h1.html modules/web/src/test/java/html/h2.html modules/web/src/test/java/html/h3.html modules/web/src/test/java/html/h4.html modules/web/src/test/java/html/ipsum.html
diffstat 145 files changed, 4405 insertions(+), 2530 deletions(-) [+]
line wrap: on
line diff
--- a/.hgignore	Tue Jul 09 18:33:45 2013 +0400
+++ b/.hgignore	Wed Jul 10 11:01:52 2013 +0400
@@ -6,11 +6,11 @@
 \.rej$
 \.conflict\~$
 ^\.ant-targets.*$
-\.idea/tasks.xml$
-\.idea/workspace.xml$
+^.idea/tasks.xml$
+^.idea/workspace.xml$
 ^\.gradle/
 ^buildSrc/\.gradle/
-^idea/out/
+^.idea/out/
 build/
 bin/
 dist/
@@ -24,6 +24,6 @@
 */Release/*
 */Debug/*
 *~
-webview/native/LayoutTests
-webview/native/WebKitBuild
-webview/native/WebKitLibraries/import
+modules/web/src/main/native/LayoutTests
+modules/web/src/main/native/WebKitBuild
+modules/web/src/main/native/WebKitLibraries/import
--- a/.hgtags	Tue Jul 09 18:33:45 2013 +0400
+++ b/.hgtags	Wed Jul 10 11:01:52 2013 +0400
@@ -85,3 +85,4 @@
 b1d681005b05e09d9af3aa476c590a478f0c0df4 8.0-b95
 dcb53a5d04ea339eb2d1c3fd3ca0a69b83eb69ed 8.0-b96
 d1f3dc25ac9f2ce239a95d50674681ee921b0d29 8-pre-gradle
+79c040d01c801c79fc4e784529fa325fccc18e58 8.0-b97
--- a/.idea/.name	Tue Jul 09 18:33:45 2013 +0400
+++ b/.idea/.name	Wed Jul 10 11:01:52 2013 +0400
@@ -1,1 +1,1 @@
-OpenJFX
\ No newline at end of file
+rt
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/3DViewer.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="EclipseModuleManager">
+    <libelement value="jar://$MODULE_DIR$/apps/experiments/3DViewer/build/libs/3DViewer.jar!/" />
+    <src_description expected_position="0">
+      <src_folder value="file://$MODULE_DIR$/apps/experiments/3DViewer/src/main/java" expected_position="0" />
+      <src_folder value="file://$MODULE_DIR$/apps/experiments/3DViewer/src/test/java" expected_position="1" />
+      <src_folder value="file://$MODULE_DIR$/apps/experiments/3DViewer/src/main/resources" expected_position="2" />
+      <src_folder value="file://$MODULE_DIR$/apps/experiments/3DViewer/src/test/resources" expected_position="3" />
+    </src_description>
+  </component>
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$/apps/experiments/3DViewer">
+      <sourceFolder url="file://$MODULE_DIR$/apps/experiments/3DViewer/src/main/java" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/apps/experiments/3DViewer/src/main/resources" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/apps/experiments/3DViewer/src/test/java" isTestSource="true" />
+      <sourceFolder url="file://$MODULE_DIR$/apps/experiments/3DViewer/src/test/resources" isTestSource="true" />
+      <excludeFolder url="file://$MODULE_DIR$/apps/experiments/3DViewer/build" />
+    </content>
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module-library">
+      <library name="3DViewer.jar">
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/apps/experiments/3DViewer/build/libs/3DViewer.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module" module-name="rt" />
+    <orderEntry type="inheritedJdk" />
+  </component>
+</module>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/Ensemble8.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,51 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="EclipseModuleManager">
+    <libelement value="jar://$MODULE_DIR$/apps/samples/Ensemble8/lib/lucene-core-3.2.0.jar!/" />
+    <libelement value="jar://$MODULE_DIR$/apps/samples/Ensemble8/lib/lucene-grouping-3.2.0.jar!/" />
+    <src_description expected_position="0">
+      <src_folder value="file://$MODULE_DIR$/apps/samples/Ensemble8/src/app/java" expected_position="0" />
+      <src_folder value="file://$MODULE_DIR$/apps/samples/Ensemble8/src/app/resources" expected_position="1" />
+      <src_folder value="file://$MODULE_DIR$/apps/samples/Ensemble8/src/samples/java" expected_position="2" />
+      <src_folder value="file://$MODULE_DIR$/apps/samples/Ensemble8/src/samples/resources" expected_position="3" />
+      <src_folder value="file://$MODULE_DIR$/apps/samples/Ensemble8/src/compiletime/java" expected_position="4" />
+      <src_folder value="file://$MODULE_DIR$/apps/samples/Ensemble8/src/generated/java" expected_position="5" />
+      <src_folder value="file://$MODULE_DIR$/apps/samples/Ensemble8/src/generated/resources" expected_position="6" />
+    </src_description>
+  </component>
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$/apps/samples/Ensemble8">
+      <sourceFolder url="file://$MODULE_DIR$/apps/samples/Ensemble8/src/app/java" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/apps/samples/Ensemble8/src/app/resources" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/apps/samples/Ensemble8/src/samples/java" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/apps/samples/Ensemble8/src/samples/resources" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/apps/samples/Ensemble8/src/compiletime/java" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/apps/samples/Ensemble8/src/generated/java" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/apps/samples/Ensemble8/src/generated/resources" isTestSource="false" />
+      <excludeFolder url="file://$MODULE_DIR$/apps/samples/Ensemble8/build" />
+    </content>
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module-library">
+      <library name="lucene-core-3.2.0.jar">
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/apps/samples/Ensemble8/lib/lucene-core-3.2.0.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library name="lucene-grouping-3.2.0.jar">
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/apps/samples/Ensemble8/lib/lucene-grouping-3.2.0.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module" module-name="rt" />
+    <orderEntry type="inheritedJdk" />
+  </component>
+</module>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/Modena.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$/apps/experiments/Modena">
+      <sourceFolder url="file://$MODULE_DIR$/apps/experiments/Modena/src/main/java" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/apps/experiments/Modena/src/main/resources" isTestSource="false" />
+      <excludeFolder url="file://$MODULE_DIR$/apps/experiments/Modena/build" />
+    </content>
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module" module-name="rt" />
+    <orderEntry type="inheritedJdk" />
+  </component>
+</module>
+
--- a/.idea/ant.xml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project version="4">
-  <component name="AntConfiguration">
-    <defaultAnt bundledAnt="true" />
-  </component>
-</project>
-
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/atlassian-ide-plugin.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,7 @@
+<atlassian-ide-plugin>
+  <project-configuration id="1">
+    <servers id="2" />
+    <default-crucible-server id="3">939232b1-9eb9-4c88-a44d-3abafd865a34</default-crucible-server>
+    <default-jira-server id="4">d42c85b0-998b-4a94-ad2b-02b0c042c35e</default-jira-server>
+  </project-configuration>
+</atlassian-ide-plugin>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/base.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$/modules/base">
+      <sourceFolder url="file://$MODULE_DIR$/modules/base/build/generated-src/version-info" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/base/src/main/java" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/base/src/main/resources" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/base/src/test/java" isTestSource="true" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/base/src/test/resources" isTestSource="true" />
+      <excludeFolder url="file://$MODULE_DIR$/modules/base/build/classes" />
+      <excludeFolder url="file://$MODULE_DIR$/modules/base/build/dependency-cache" />
+      <excludeFolder url="file://$MODULE_DIR$/modules/base/build/libs" />
+      <excludeFolder url="file://$MODULE_DIR$/modules/base/build/tmp" />
+    </content>
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module" module-name="buildSrc" exported="" />
+    <orderEntry type="inheritedJdk" />
+  </component>
+</module>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/buildSrc.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,88 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="EclipseModuleManager">
+    <libelement value="jar://$MODULE_DIR$/build/libs/ant-1.8.2.jar!/" />
+    <libelement value="jar://$MODULE_DIR$/build/libs/antlr-3.1.3.jar!/" />
+    <libelement value="jar://$MODULE_DIR$/build/libs/antlr-runtime-3.1.3.jar!/" />
+    <libelement value="jar://$MODULE_DIR$/build/libs/stringtemplate-3.2.jar!/" />
+    <libelement value="jar://$MODULE_DIR$/build/libs/swt-debug.jar!/" />
+    <src_description expected_position="0">
+      <src_folder value="file://$MODULE_DIR$/buildSrc/build/generated-src/antlr" expected_position="0" />
+      <src_folder value="file://$MODULE_DIR$/buildSrc/src/main/java" expected_position="1" />
+      <src_folder value="file://$MODULE_DIR$/buildSrc/src/test/java" expected_position="2" />
+    </src_description>
+  </component>
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$/buildSrc">
+      <sourceFolder url="file://$MODULE_DIR$/buildSrc/build/generated-src/antlr" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/buildSrc/src/main/java" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/buildSrc/src/test/java" isTestSource="true" />
+      <sourceFolder url="file://$MODULE_DIR$/buildSrc/src/test/resources" isTestSource="true" />
+      <excludeFolder url="file://$MODULE_DIR$/buildSrc/.gradle" />
+      <excludeFolder url="file://$MODULE_DIR$/buildSrc/build/classes" />
+      <excludeFolder url="file://$MODULE_DIR$/buildSrc/build/dependency-cache" />
+      <excludeFolder url="file://$MODULE_DIR$/buildSrc/build/libs" />
+      <excludeFolder url="file://$MODULE_DIR$/buildSrc/build/resources" />
+      <excludeFolder url="file://$MODULE_DIR$/buildSrc/build/test-results" />
+      <excludeFolder url="file://$MODULE_DIR$/buildSrc/build/tmp" />
+    </content>
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module-library" exported="">
+      <library name="ant-1.8.2.jar">
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/build/libs/ant-1.8.2.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library" exported="">
+      <library name="antlr-3.1.3.jar">
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/build/libs/antlr-3.1.3.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library" exported="">
+      <library name="antlr-runtime-3.1.3.jar">
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/build/libs/antlr-runtime-3.1.3.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library" exported="">
+      <library name="stringtemplate-3.2.jar">
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/build/libs/stringtemplate-3.2.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library" exported="">
+      <library name="swt-debug.jar">
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/build/libs/swt-debug.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library" exported="">
+      <library name="junit4">
+        <CLASSES>
+          <root url="jar://$APPLICATION_HOME_DIR$/lib/junit-4.10.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="inheritedJdk" />
+  </component>
+</module>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/builders.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="EclipseModuleManager">
+    <libelement value="jar://$MODULE_DIR$/modules/builders/build/libs/builders.jar!/" />
+    <src_description expected_position="1">
+      <src_folder value="file://$MODULE_DIR$/modules/builders/src/test/java" expected_position="1" />
+    </src_description>
+  </component>
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$/modules/builders">
+      <excludeFolder url="file://$MODULE_DIR$/modules/builders/build" />
+    </content>
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module-library" exported="">
+      <library name="builders.jar">
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/modules/builders/build/libs/builders.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES>
+          <root url="file://$MODULE_DIR$/modules/builders/src/main/java" />
+        </SOURCES>
+      </library>
+    </orderEntry>
+    <orderEntry type="inheritedJdk" />
+  </component>
+</module>
+
--- a/.idea/codeStyleSettings.xml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project version="4">
-  <component name="ProjectCodeStyleSettingsManager">
-    <option name="PER_PROJECT_SETTINGS">
-      <value>
-        <option name="LINE_SEPARATOR" value="&#10;" />
-        <option name="IMPORT_LAYOUT_TABLE">
-          <value>
-            <package name="java" withSubpackages="true" static="false" />
-            <package name="javax" withSubpackages="true" static="false" />
-            <package name="javafx.*" withSubpackages="true" static="false" />
-            <package name="" withSubpackages="true" static="false" />
-            <package name="" withSubpackages="true" static="true" />
-          </value>
-        </option>
-        <option name="RIGHT_MARGIN" value="80" />
-        <XML>
-          <option name="XML_LEGACY_SETTINGS_IMPORTED" value="true" />
-        </XML>
-        <codeStyleSettings language="JAVA">
-          <option name="SPACE_BEFORE_ARRAY_INITIALIZER_LBRACE" value="true" />
-        </codeStyleSettings>
-      </value>
-    </option>
-    <option name="USE_PER_PROJECT_SETTINGS" value="true" />
-  </component>
-</project>
-
--- a/.idea/compiler.xml	Tue Jul 09 18:33:45 2013 +0400
+++ b/.idea/compiler.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -2,20 +2,26 @@
 <project version="4">
   <component name="CompilerConfiguration">
     <option name="DEFAULT_COMPILER" value="Javac" />
+    <excludeFromCompile>
+      <file url="file://$PROJECT_DIR$/../../deploy/javafx-deploy-samples/src/helloworld/HelloFullscreen.java" />
+      <file url="file://$PROJECT_DIR$/../../deploy/javafx-deploy-samples/src/helloworld/HelloFullscreenToggle.java" />
+    </excludeFromCompile>
     <resourceExtensions />
     <wildcardResourcePatterns>
-      <entry name="?*.properties" />
-      <entry name="?*.xml" />
-      <entry name="?*.gif" />
-      <entry name="?*.png" />
-      <entry name="?*.jpeg" />
-      <entry name="?*.jpg" />
-      <entry name="?*.html" />
-      <entry name="?*.dtd" />
-      <entry name="?*.tld" />
-      <entry name="?*.ftl" />
+      <entry name="!?*.java" />
+      <entry name="!?*.form" />
+      <entry name="!?*.class" />
+      <entry name="!?*.groovy" />
+      <entry name="!?*.scala" />
+      <entry name="!?*.flex" />
+      <entry name="!?*.kt" />
+      <entry name="!?*.clj" />
     </wildcardResourcePatterns>
-    <annotationProcessing enabled="false" useClasspath="true" />
+    <annotationProcessing>
+      <profile default="true" name="Default" enabled="false">
+        <processorPath useClasspath="true" />
+      </profile>
+    </annotationProcessing>
   </component>
 </project>
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/controls.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$/modules/controls">
+      <sourceFolder url="file://$MODULE_DIR$/modules/controls/src/main/java" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/controls/src/main/resources" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/controls/src/test/java" isTestSource="true" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/controls/src/test/resources" isTestSource="true" />
+      <excludeFolder url="file://$MODULE_DIR$/modules/controls/build" />
+    </content>
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module" module-name="base" exported="" />
+    <orderEntry type="module" module-name="designTime" exported="" />
+    <orderEntry type="module" module-name="graphics" exported="" />
+    <orderEntry type="inheritedJdk" />
+  </component>
+</module>
+
--- a/.idea/copyright/OpenJFX_GPL.xml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,9 +0,0 @@
-<component name="CopyrightManager">
-  <copyright>
-    <option name="notice" value="Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.&#10;DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.&#10;&#10;This code is free software; you can redistribute it and/or modify it&#10;under the terms of the GNU General Public License version 2 only, as&#10;published by the Free Software Foundation.  Oracle designates this&#10;particular file as subject to the &quot;Classpath&quot; exception as provided&#10;by Oracle in the LICENSE file that accompanied this code.&#10;&#10;This code is distributed in the hope that it will be useful, but WITHOUT&#10;ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or&#10;FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License&#10;version 2 for more details (a copy is included in the LICENSE file that&#10;accompanied this code).&#10;&#10;You should have received a copy of the GNU General Public License version&#10;2 along with this work; if not, write to the Free Software Foundation,&#10;Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.&#10;&#10;Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA&#10;or visit www.oracle.com if you need additional information or have any&#10;questions." />
-    <option name="keyword" value="Copyright" />
-    <option name="allowReplaceKeyword" value="" />
-    <option name="myName" value="OpenJFX GPL" />
-    <option name="myLocal" value="true" />
-  </copyright>
-</component>
\ No newline at end of file
--- a/.idea/copyright/profiles_settings.xml	Tue Jul 09 18:33:45 2013 +0400
+++ b/.idea/copyright/profiles_settings.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -1,5 +1,5 @@
 <component name="CopyrightManager">
-  <settings default="OpenJFX GPL">
+  <settings default="">
     <module2copyright />
   </settings>
 </component>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/deploy.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="EclipseModuleManager">
+    <libelement value="jar://$MODULE_DIR$/../deploy/cache/plugin_exports.jar!/" />
+    <src_description expected_position="0">
+      <src_folder value="file://$MODULE_DIR$/../deploy/lib" expected_position="0" />
+      <src_folder value="file://$MODULE_DIR$/../deploy/javafx-deploy/src" expected_position="1" />
+      <src_folder value="file://$MODULE_DIR$/../deploy/javafx-deploy-samples/src" expected_position="2" />
+      <src_folder value="file://$MODULE_DIR$/../deploy/javafx-launcher-demoapp/src" expected_position="3" />
+    </src_description>
+  </component>
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$/../deploy">
+      <sourceFolder url="file://$MODULE_DIR$/../deploy/lib" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../deploy/javafx-deploy/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../deploy/javafx-deploy-samples/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../deploy/javafx-launcher-demoapp/src" isTestSource="false" />
+      <excludeFolder url="file://$MODULE_DIR$/../deploy/javafx-deploy-samples/src/helloworld" />
+    </content>
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module-library" exported="">
+      <library name="plugin_exports.jar">
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../deploy/cache/plugin_exports.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module" module-name="rt" exported="" />
+    <orderEntry type="inheritedJdk" />
+  </component>
+</module>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/designTime.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$/modules/designTime">
+      <sourceFolder url="file://$MODULE_DIR$/modules/designTime/src/main/java" isTestSource="false" />
+      <excludeFolder url="file://$MODULE_DIR$/modules/designTime/build" />
+    </content>
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module" module-name="graphics" exported="" />
+    <orderEntry type="inheritedJdk" />
+  </component>
+</module>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/fxml.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$/modules/fxml">
+      <sourceFolder url="file://$MODULE_DIR$/modules/fxml/src/main/java" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/fxml/src/main/resources" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/fxml/src/test/java" isTestSource="true" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/fxml/src/test/resources" isTestSource="true" />
+      <excludeFolder url="file://$MODULE_DIR$/modules/fxml/build" />
+    </content>
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module" module-name="base" exported="" />
+    <orderEntry type="module" module-name="controls" exported="" />
+    <orderEntry type="module" module-name="graphics" exported="" />
+    <orderEntry type="module" module-name="swing" exported="" />
+    <orderEntry type="module" module-name="swt" exported="" />
+    <orderEntry type="inheritedJdk" />
+  </component>
+</module>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/fxpackager.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$/modules/fxpackager">
+      <sourceFolder url="file://$MODULE_DIR$/modules/fxpackager/src/main/java" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/fxpackager/src/main/resources" isTestSource="false" />
+      <excludeFolder url="file://$MODULE_DIR$/modules/fxpackager/build" />
+    </content>
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module" module-name="graphics" exported="" />
+    <orderEntry type="inheritedJdk" />
+  </component>
+</module>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/gradle.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project version="4">
+  <component name="GradleSettings">
+    <option name="linkedProjectPath" value="" />
+    <option name="useAutoImport" value="false" />
+  </component>
+</project>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/graphics.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$/modules/graphics">
+      <sourceFolder url="file://$MODULE_DIR$/modules/graphics/src/main/java" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/graphics/src/main/resources" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/graphics/src/stub/java" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/graphics/src/stub/resources" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/graphics/build/generated-src/jsl-decora" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/graphics/build/generated-src/jsl-prism" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/graphics/build/resources/jsl-decora" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/graphics/build/resources/jsl-prism" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/graphics/src/test/java" isTestSource="true" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/graphics/src/test/resources" isTestSource="true" />
+      <excludeFolder url="file://$MODULE_DIR$/modules/graphics/build/classes" />
+      <excludeFolder url="file://$MODULE_DIR$/modules/graphics/build/dependency-cache" />
+      <excludeFolder url="file://$MODULE_DIR$/modules/graphics/build/libs" />
+      <excludeFolder url="file://$MODULE_DIR$/modules/graphics/build/resources" />
+      <excludeFolder url="file://$MODULE_DIR$/modules/graphics/build/tmp" />
+    </content>
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module" module-name="base" exported="" />
+    <orderEntry type="module" module-name="builders" exported="" />
+    <orderEntry type="inheritedJdk" />
+  </component>
+</module>
+
--- a/.idea/libraries/jfxrt_binary_stub.xml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,10 +0,0 @@
-<component name="libraryTable">
-  <library name="jfxrt-binary-stub">
-    <CLASSES>
-      <root url="jar://$PROJECT_DIR$/../artifacts/sdk/rt/lib/ext/jfxrt.jar!/" />
-      <root url="jar://$PROJECT_DIR$/../artifacts/sdk/lib/javafx-mx.jar!/" />
-    </CLASSES>
-    <JAVADOC />
-    <SOURCES />
-  </library>
-</component>
--- a/.idea/libraries/junit_4_8_2.xml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,9 +0,0 @@
-<component name="libraryTable">
-  <library name="junit-4.8.2">
-    <CLASSES>
-      <root url="jar://$PROJECT_DIR$/../import/junit-4.8.2/junit-4.8.2.jar!/" />
-    </CLASSES>
-    <JAVADOC />
-    <SOURCES />
-  </library>
-</component>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/media.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$/modules/media" />
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="inheritedJdk" />
+  </component>
+</module>
+
--- a/.idea/misc.xml	Tue Jul 09 18:33:45 2013 +0400
+++ b/.idea/misc.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -3,13 +3,9 @@
   <component name="EntryPointsManager">
     <entry_points version="2.0" />
   </component>
-  <component name="IdProvider" IDEtalkID="5A22F63458C80CE167DF63107CDD247D" />
-  <component name="ProjectResources">
-    <default-html-doctype>http://www.w3.org/1999/xhtml</default-html-doctype>
+  <component name="IdProvider" IDEtalkID="9BC0DE4049720C1246C2D3B835C6F7C3" />
+  <component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" assert-keyword="true" jdk-15="true" project-jdk-name="1.8" project-jdk-type="JavaSDK">
+    <output url="file://$PROJECT_DIR$/.idea/out" />
   </component>
-  <component name="ProjectRootManager" version="2" languageLevel="JDK_1_6" assert-keyword="true" jdk-15="true" project-jdk-name="1.7" project-jdk-type="JavaSDK">
-    <output url="file://$PROJECT_DIR$/build" />
-  </component>
-  <component name="WebServicesPlugin" addRequiredLibraries="true" />
 </project>
 
--- a/.idea/modules.xml	Tue Jul 09 18:33:45 2013 +0400
+++ b/.idea/modules.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -2,16 +2,24 @@
 <project version="4">
   <component name="ProjectModuleManager">
     <modules>
-      <module fileurl="file://$PROJECT_DIR$/javafx-beans-dt/javafx-beans-dt.iml" filepath="$PROJECT_DIR$/javafx-beans-dt/javafx-beans-dt.iml" group="Tools" />
-      <module fileurl="file://$PROJECT_DIR$/javafx-concurrent/javafx-concurrent.iml" filepath="$PROJECT_DIR$/javafx-concurrent/javafx-concurrent.iml" group="Concurrent" />
-      <module fileurl="file://$PROJECT_DIR$/javafx-designtime/javafx-designtime.iml" filepath="$PROJECT_DIR$/javafx-designtime/javafx-designtime.iml" group="Tools" />
-      <module fileurl="file://$PROJECT_DIR$/javafx-ui-charts/javafx-ui-charts.iml" filepath="$PROJECT_DIR$/javafx-ui-charts/javafx-ui-charts.iml" group="Controls" />
-      <module fileurl="file://$PROJECT_DIR$/javafx-ui-common/javafx-ui-common.iml" filepath="$PROJECT_DIR$/javafx-ui-common/javafx-ui-common.iml" group="Scene Graph" />
-      <module fileurl="file://$PROJECT_DIR$/javafx-ui-controls/javafx-ui-controls.iml" filepath="$PROJECT_DIR$/javafx-ui-controls/javafx-ui-controls.iml" group="Controls" />
-      <module fileurl="file://$PROJECT_DIR$/javafx-util-converter/javafx-util-converter.iml" filepath="$PROJECT_DIR$/javafx-util-converter/javafx-util-converter.iml" group="Core" />
-      <module fileurl="file://$PROJECT_DIR$/test-stub-toolkit/test-stub-toolkit.iml" filepath="$PROJECT_DIR$/test-stub-toolkit/test-stub-toolkit.iml" group="Tools" />
-      <module fileurl="file://$PROJECT_DIR$/javafx-embed-swing/javafx-embed-swing.iml" filepath="$PROJECT_DIR$/javafx-embed-swing/javafx-embed-swing.iml" />
-      <module fileurl="file://$PROJECT_DIR$/javafx-embed-swt/javafx-embed-swt.iml" filepath="$PROJECT_DIR$/javafx-embed-swt/javafx-embed-swt.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/3DViewer.iml" filepath="$PROJECT_DIR$/.idea/3DViewer.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/Ensemble8.iml" filepath="$PROJECT_DIR$/.idea/Ensemble8.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/Modena.iml" filepath="$PROJECT_DIR$/.idea/Modena.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/base.iml" filepath="$PROJECT_DIR$/.idea/base.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/buildSrc.iml" filepath="$PROJECT_DIR$/.idea/buildSrc.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/builders.iml" filepath="$PROJECT_DIR$/.idea/builders.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/controls.iml" filepath="$PROJECT_DIR$/.idea/controls.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/deploy.iml" filepath="$PROJECT_DIR$/.idea/deploy.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/designTime.iml" filepath="$PROJECT_DIR$/.idea/designTime.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/fxml.iml" filepath="$PROJECT_DIR$/.idea/fxml.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/fxpackager.iml" filepath="$PROJECT_DIR$/.idea/fxpackager.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/graphics.iml" filepath="$PROJECT_DIR$/.idea/graphics.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/media.iml" filepath="$PROJECT_DIR$/.idea/media.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/rt.iml" filepath="$PROJECT_DIR$/.idea/rt.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/rt-closed.iml" filepath="$PROJECT_DIR$/.idea/rt-closed.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/swing.iml" filepath="$PROJECT_DIR$/.idea/swing.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/swt.iml" filepath="$PROJECT_DIR$/.idea/swt.iml" />
+      <module fileurl="file://$PROJECT_DIR$/.idea/web.iml" filepath="$PROJECT_DIR$/.idea/web.iml" />
     </modules>
   </component>
 </project>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/rt-closed.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,119 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="EclipseModuleManager">
+    <libelement value="jar://$MODULE_DIR$/../caches/sdk/build/lib/desktop/jfxmedia.jar!/" />
+    <libelement value="file://../caches/sdk/build/lib/desktop/deploy.jar" />
+    <libelement value="jar://$MODULE_DIR$/../import/swt-3.7.1/swt-debug.jar!/" />
+    <src_description expected_position="0">
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/benchmark/VMPerformance/src" expected_position="0" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/glass/glass-test/test" expected_position="1" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/glass/UseCases/src" expected_position="2" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/javafx-android/webnode/src" expected_position="3" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/javafx-font-t2k/src" expected_position="4" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/javafx-ios/src" expected_position="5" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/javafx-mx-common/src" expected_position="6" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/javafx-mx-impl/src" expected_position="7" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/javafx-mx-impl/test/unit" expected_position="8" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/javafx-ui-desktop/src" expected_position="9" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/porting/src" expected_position="10" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/prism-bench/src" expected_position="11" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/tests/security/ES2NativeTest/test" expected_position="12" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/tests/security/GetWindowsTest/test" expected_position="13" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/tests/security/LoaderDisposeTest/test" expected_position="14" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/tests/security/MediaFuzzing/src" expected_position="15" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/tests/security/MediaFuzzing/test" expected_position="16" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/BlendTest/src" expected_position="17" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/CameraTests/src" expected_position="18" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/CanvasTest/src" expected_position="19" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/ColorCube/src" expected_position="20" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/CursorFXTest/src" expected_position="21" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/DirectoryBrowser/src" expected_position="22" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/DragDropColor/src" expected_position="23" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/DragDropText/src" expected_position="24" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/DragDropWithControls/src" expected_position="25" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/EarthCubeFX2/src" expected_position="26" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/EmbeddedSwing/src" expected_position="27" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/FX8-3DAPI/src" expected_position="28" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/GlassRobotTest/src" expected_position="29" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/Gradients/src" expected_position="30" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/GridExamples/src" expected_position="31" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/HelloFXCanvas/src" expected_position="32" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/HelloWorld/src" expected_position="33" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/LinuxInputTest/src" expected_position="34" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/LinuxInputTest/test" expected_position="35" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/NodeBlendTests/src" expected_position="36" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/PickTest3D/src" expected_position="37" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/SceneLeak/src" expected_position="38" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/ShapeT3DTest/src" expected_position="39" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/SwingBalls/src" expected_position="40" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/SwingBalls/css" expected_position="41" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/SwingNodeMark/src" expected_position="42" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/TextTest/src" expected_position="43" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/TouchSuite/src" expected_position="44" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/VideoCube/src" expected_position="45" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/Visual3DTest/src" expected_position="46" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/WebLauncher/src" expected_position="47" />
+      <src_folder value="file://$MODULE_DIR$/../rt-closed/toys/ZBufferTest/src" expected_position="48" />
+    </src_description>
+  </component>
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$/../rt-closed">
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/benchmark/VMPerformance/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/glass/glass-test/test" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/glass/UseCases/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/javafx-android/webnode/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/javafx-font-t2k/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/javafx-ios/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/javafx-mx-common/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/javafx-mx-impl/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/javafx-mx-impl/test/unit" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/javafx-ui-desktop/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/porting/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/prism-bench/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/tests/security/ES2NativeTest/test" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/tests/security/GetWindowsTest/test" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/tests/security/LoaderDisposeTest/test" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/tests/security/MediaFuzzing/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/tests/security/MediaFuzzing/test" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/BlendTest/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/CameraTests/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/CanvasTest/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/ColorCube/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/CursorFXTest/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/DirectoryBrowser/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/DragDropColor/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/DragDropText/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/DragDropWithControls/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/EarthCubeFX2/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/EmbeddedSwing/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/FX8-3DAPI/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/GlassRobotTest/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/Gradients/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/GridExamples/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/HelloFXCanvas/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/HelloWorld/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/LinuxInputTest/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/LinuxInputTest/test" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/NodeBlendTests/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/PickTest3D/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/SceneLeak/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/ShapeT3DTest/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/SwingBalls/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/SwingBalls/css" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/SwingNodeMark/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/TextTest/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/TouchSuite/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/VideoCube/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/Visual3DTest/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/WebLauncher/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/../rt-closed/toys/ZBufferTest/src" isTestSource="false" />
+      <excludeFolder url="file://$MODULE_DIR$/../rt-closed/javafx-android" />
+    </content>
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module" module-name="deploy" exported="" />
+    <orderEntry type="module" module-name="rt" exported="" />
+    <orderEntry type="inheritedJdk" />
+  </component>
+</module>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/rt.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$">
+      <excludeFolder url="file://$MODULE_DIR$/.gradle" />
+      <excludeFolder url="file://$MODULE_DIR$/build/libs" />
+    </content>
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module" module-name="fxml" exported="" />
+    <orderEntry type="module" module-name="fxpackager" exported="" />
+    <orderEntry type="module" module-name="swt" exported="" />
+    <orderEntry type="module" module-name="swing" exported="" />
+    <orderEntry type="module" module-name="media" exported="" />
+    <orderEntry type="module" module-name="web" exported="" />
+    <orderEntry type="inheritedJdk" />
+    <orderEntry type="library" name="gradle-1.4" level="application" />
+  </component>
+</module>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/swing.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$/modules/swing">
+      <sourceFolder url="file://$MODULE_DIR$/modules/swing/src/main/java" isTestSource="false" />
+      <excludeFolder url="file://$MODULE_DIR$/modules/swing/build" />
+    </content>
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module" module-name="base" exported="" />
+    <orderEntry type="module" module-name="graphics" exported="" />
+    <orderEntry type="inheritedJdk" />
+  </component>
+</module>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/swt.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$/modules/swt">
+      <sourceFolder url="file://$MODULE_DIR$/modules/swt/src/main/java" isTestSource="false" />
+      <excludeFolder url="file://$MODULE_DIR$/modules/swt/build" />
+    </content>
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module" module-name="base" exported="" />
+    <orderEntry type="module" module-name="graphics" exported="" />
+    <orderEntry type="inheritedJdk" />
+  </component>
+</module>
+
--- a/.idea/vcs.xml	Tue Jul 09 18:33:45 2013 +0400
+++ b/.idea/vcs.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -2,6 +2,8 @@
 <project version="4">
   <component name="VcsDirectoryMappings">
     <mapping directory="" vcs="" />
+    <mapping directory="$PROJECT_DIR$/../../deploy" vcs="hg4idea" />
+    <mapping directory="$PROJECT_DIR$/../../rt-closed" vcs="hg4idea" />
   </component>
 </project>
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.idea/web.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="NewModuleRootManager" inherit-compiler-output="true">
+    <exclude-output />
+    <content url="file://$MODULE_DIR$/modules/web">
+      <sourceFolder url="file://$MODULE_DIR$/modules/web/src/main/java" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/web/src/main/native/WebKitBuild/Release/WebCore/generated/java" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/modules/web/src/main/resources" isTestSource="false" />
+      <excludeFolder url="file://$MODULE_DIR$/modules/web/build" />
+    </content>
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module" module-name="graphics" exported="" />
+    <orderEntry type="module" module-name="controls" exported="" />
+    <orderEntry type="module" module-name="media" exported="" />
+    <orderEntry type="module-library" exported="">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../caches/sdk/rt/lib/ext/jfxrt.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="inheritedJdk" />
+  </component>
+</module>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/experiments/3DViewer/.idea/.name	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,1 @@
+3DViewer
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/experiments/3DViewer/.idea/compiler.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project version="4">
+  <component name="CompilerConfiguration">
+    <option name="DEFAULT_COMPILER" value="Javac" />
+    <resourceExtensions />
+    <wildcardResourcePatterns>
+      <entry name="!?*.java" />
+      <entry name="!?*.form" />
+      <entry name="!?*.class" />
+      <entry name="!?*.groovy" />
+      <entry name="!?*.scala" />
+      <entry name="!?*.flex" />
+      <entry name="!?*.kt" />
+      <entry name="!?*.clj" />
+    </wildcardResourcePatterns>
+    <annotationProcessing>
+      <profile default="true" name="Default" enabled="false">
+        <processorPath useClasspath="true" />
+      </profile>
+    </annotationProcessing>
+  </component>
+</project>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/experiments/3DViewer/.idea/copyright/profiles_settings.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,5 @@
+<component name="CopyrightManager">
+  <settings default="">
+    <module2copyright />
+  </settings>
+</component>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/experiments/3DViewer/.idea/encodings.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project version="4">
+  <component name="Encoding" useUTFGuessing="true" native2AsciiForPropertiesFiles="false" />
+</project>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/experiments/3DViewer/.idea/misc.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project version="4">
+  <component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" assert-keyword="true" jdk-15="true" project-jdk-name="1.8" project-jdk-type="JavaSDK">
+    <output url="file://$PROJECT_DIR$/out" />
+  </component>
+</project>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/experiments/3DViewer/.idea/modules.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project version="4">
+  <component name="ProjectModuleManager">
+    <modules>
+      <module fileurl="file://$PROJECT_DIR$/3DViewer.iml" filepath="$PROJECT_DIR$/3DViewer.iml" />
+    </modules>
+  </component>
+</project>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/experiments/3DViewer/.idea/runConfigurations/3DViewer.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,18 @@
+<component name="ProjectRunConfigurationManager">
+  <configuration default="false" name="3DViewer" type="Application" factoryName="Application">
+    <option name="MAIN_CLASS_NAME" value="com.javafx.experiments.jfx3dviewer.Jfx3dViewerApp" />
+    <option name="VM_PARAMETERS" value="-Dprism.verbose=true" />
+    <option name="PROGRAM_PARAMETERS" value="" />
+    <option name="WORKING_DIRECTORY" value="file://$PROJECT_DIR$" />
+    <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
+    <option name="ALTERNATIVE_JRE_PATH" value="" />
+    <option name="ENABLE_SWING_INSPECTOR" value="false" />
+    <option name="ENV_VARIABLES" />
+    <option name="PASS_PARENT_ENVS" value="true" />
+    <module name="3DViewer" />
+    <envs />
+    <RunnerSettings RunnerId="Run" />
+    <ConfigurationWrapper RunnerId="Run" />
+    <method />
+  </configuration>
+</component>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/experiments/3DViewer/.idea/scopes/scope_settings.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,5 @@
+<component name="DependencyValidationManager">
+  <state>
+    <option name="SKIP_IMPORT_STATEMENTS" value="false" />
+  </state>
+</component>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/experiments/3DViewer/.idea/vcs.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project version="4">
+  <component name="VcsDirectoryMappings">
+    <mapping directory="" vcs="hg4idea" />
+  </component>
+</project>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/experiments/3DViewer/3DViewer.iml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+  <component name="NewModuleRootManager" inherit-compiler-output="false">
+    <output url="file://$MODULE_DIR$/build/classes" />
+    <output-test url="file://$MODULE_DIR$/build/classes" />
+    <exclude-output />
+    <content url="file://$MODULE_DIR$">
+      <sourceFolder url="file://$MODULE_DIR$/src/main/java" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/src/main/resources" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/src/test/java" isTestSource="true" />
+      <sourceFolder url="file://$MODULE_DIR$/src/test/resources" isTestSource="true" />
+      <excludeFolder url="file://$MODULE_DIR$/.idea" />
+      <excludeFolder url="file://$MODULE_DIR$/nbproject" />
+    </content>
+    <orderEntry type="inheritedJdk" />
+    <orderEntry type="sourceFolder" forTests="false" />
+  </component>
+</module>
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/experiments/3DViewer/build.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,73 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- You may freely edit this file. See commented blocks below for -->
+<!-- some examples of how to customize the build. -->
+<!-- (If you delete it and reopen the project it will be recreated.) -->
+<!-- By default, only the Clean and Build commands use this build script. -->
+<!-- Commands such as Run, Debug, and Test only use this build script if -->
+<!-- the Compile on Save feature is turned off for the project. -->
+<!-- You can turn off the Compile on Save (or Deploy on Save) setting -->
+<!-- in the project's Project Properties dialog box.-->
+<project name="3DViewer" default="default" basedir=".">
+    <description>Builds, tests, and runs the project 3DViewer.</description>
+    <!--
+
+    There exist several targets which are by default empty and which can be 
+    used for execution of your tasks. These targets are usually executed 
+    before and after some main targets. They are: 
+
+      -pre-init:                 called before initialization of project properties
+      -post-init:                called after initialization of project properties
+      -pre-compile:              called before javac compilation
+      -post-compile:             called after javac compilation
+      -pre-compile-single:       called before javac compilation of single file
+      -post-compile-single:      called after javac compilation of single file
+      -pre-compile-test:         called before javac compilation of JUnit tests
+      -post-compile-test:        called after javac compilation of JUnit tests
+      -pre-compile-test-single:  called before javac compilation of single JUnit test
+      -post-compile-test-single: called after javac compilation of single JUunit test
+      -pre-jar:                  called before JAR building
+      -post-jar:                 called after JAR building
+      -post-clean:               called after cleaning build products
+
+    (Targets beginning with '-' are not intended to be called on their own.)
+
+    Example of inserting an obfuscator after compilation could look like this:
+
+        <target name="-post-compile">
+            <obfuscate>
+                <fileset dir="${build.classes.dir}"/>
+            </obfuscate>
+        </target>
+
+    For list of available properties check the imported 
+    nbproject/build-impl.xml file. 
+
+
+    Another way to customize the build is by overriding existing main targets.
+    The targets of interest are: 
+
+      -init-macrodef-javac:     defines macro for javac compilation
+      -init-macrodef-junit:     defines macro for junit execution
+      -init-macrodef-debug:     defines macro for class debugging
+      -init-macrodef-java:      defines macro for class execution
+      -do-jar-with-manifest:    JAR building (if you are using a manifest)
+      -do-jar-without-manifest: JAR building (if you are not using a manifest)
+      run:                      execution of project 
+      -javadoc-build:           Javadoc generation
+      test-report:              JUnit report generation
+
+    An example of overriding the target for project execution could look like this:
+
+        <target name="run" depends="3DViewer-impl.jar">
+            <exec dir="bin" executable="launcher.exe">
+                <arg file="${dist.jar}"/>
+            </exec>
+        </target>
+
+    Notice that the overridden target depends on the jar target and not only on 
+    the compile target as the regular run target does. Again, for a list of available 
+    properties which you can use, check the target you are overriding in the
+    nbproject/build-impl.xml file. 
+
+    -->
+</project>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/experiments/Modena/build.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,74 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- You may freely edit this file. See commented blocks below for -->
+<!-- some examples of how to customize the build. -->
+<!-- (If you delete it and reopen the project it will be recreated.) -->
+<!-- By default, only the Clean and Build commands use this build script. -->
+<!-- Commands such as Run, Debug, and Test only use this build script if -->
+<!-- the Compile on Save feature is turned off for the project. -->
+<!-- You can turn off the Compile on Save (or Deploy on Save) setting -->
+<!-- in the project's Project Properties dialog box.-->
+<project name="Modena" default="default" basedir=".">
+    <description>Builds, tests, and runs the project Modena.</description>
+    <import file="nbproject/build-impl.xml"/>
+    <!--
+
+    There exist several targets which are by default empty and which can be 
+    used for execution of your tasks. These targets are usually executed 
+    before and after some main targets. They are: 
+
+      -pre-init:                 called before initialization of project properties
+      -post-init:                called after initialization of project properties
+      -pre-compile:              called before javac compilation
+      -post-compile:             called after javac compilation
+      -pre-compile-single:       called before javac compilation of single file
+      -post-compile-single:      called after javac compilation of single file
+      -pre-compile-test:         called before javac compilation of JUnit tests
+      -post-compile-test:        called after javac compilation of JUnit tests
+      -pre-compile-test-single:  called before javac compilation of single JUnit test
+      -post-compile-test-single: called after javac compilation of single JUunit test
+      -pre-jar:                  called before JAR building
+      -post-jar:                 called after JAR building
+      -post-clean:               called after cleaning build products
+
+    (Targets beginning with '-' are not intended to be called on their own.)
+
+    Example of inserting an obfuscator after compilation could look like this:
+
+        <target name="-post-compile">
+            <obfuscate>
+                <fileset dir="${build.classes.dir}"/>
+            </obfuscate>
+        </target>
+
+    For list of available properties check the imported 
+    nbproject/build-impl.xml file. 
+
+
+    Another way to customize the build is by overriding existing main targets.
+    The targets of interest are: 
+
+      -init-macrodef-javac:     defines macro for javac compilation
+      -init-macrodef-junit:     defines macro for junit execution
+      -init-macrodef-debug:     defines macro for class debugging
+      -init-macrodef-java:      defines macro for class execution
+      -do-jar-with-manifest:    JAR building (if you are using a manifest)
+      -do-jar-without-manifest: JAR building (if you are not using a manifest)
+      run:                      execution of project 
+      -javadoc-build:           Javadoc generation
+      test-report:              JUnit report generation
+
+    An example of overriding the target for project execution could look like this:
+
+        <target name="run" depends="Modena-impl.jar">
+            <exec dir="bin" executable="launcher.exe">
+                <arg file="${dist.jar}"/>
+            </exec>
+        </target>
+
+    Notice that the overridden target depends on the jar target and not only on 
+    the compile target as the regular run target does. Again, for a list of available 
+    properties which you can use, check the target you are overriding in the
+    nbproject/build-impl.xml file. 
+
+    -->
+</project>
--- a/apps/experiments/Modena/nbproject/build-impl.xml	Tue Jul 09 18:33:45 2013 +0400
+++ b/apps/experiments/Modena/nbproject/build-impl.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -54,6 +54,43 @@
         <property file="nbproject/project.properties"/>
     </target>
     <target depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property" name="-do-init">
+        <j2seproject1:property name="platform.home" value="platforms.${platform.active}.home"/>
+        <j2seproject1:property name="platform.bootcp" value="platforms.${platform.active}.bootclasspath"/>
+        <j2seproject1:property name="platform.compiler" value="platforms.${platform.active}.compile"/>
+        <j2seproject1:property name="platform.javac.tmp" value="platforms.${platform.active}.javac"/>
+        <condition property="platform.javac" value="${platform.home}/bin/javac">
+            <equals arg1="${platform.javac.tmp}" arg2="$${platforms.${platform.active}.javac}"/>
+        </condition>
+        <property name="platform.javac" value="${platform.javac.tmp}"/>
+        <j2seproject1:property name="platform.java.tmp" value="platforms.${platform.active}.java"/>
+        <condition property="platform.java" value="${platform.home}/bin/java">
+            <equals arg1="${platform.java.tmp}" arg2="$${platforms.${platform.active}.java}"/>
+        </condition>
+        <property name="platform.java" value="${platform.java.tmp}"/>
+        <j2seproject1:property name="platform.javadoc.tmp" value="platforms.${platform.active}.javadoc"/>
+        <condition property="platform.javadoc" value="${platform.home}/bin/javadoc">
+            <equals arg1="${platform.javadoc.tmp}" arg2="$${platforms.${platform.active}.javadoc}"/>
+        </condition>
+        <property name="platform.javadoc" value="${platform.javadoc.tmp}"/>
+        <condition property="platform.invalid" value="true">
+            <or>
+                <contains string="${platform.javac}" substring="$${platforms."/>
+                <contains string="${platform.java}" substring="$${platforms."/>
+                <contains string="${platform.javadoc}" substring="$${platforms."/>
+            </or>
+        </condition>
+        <fail unless="platform.home">Must set platform.home</fail>
+        <fail unless="platform.bootcp">Must set platform.bootcp</fail>
+        <fail unless="platform.java">Must set platform.java</fail>
+        <fail unless="platform.javac">Must set platform.javac</fail>
+        <fail if="platform.invalid">
+ The J2SE Platform is not correctly set up.
+ Your active platform is: ${platform.active}, but the corresponding property "platforms.${platform.active}.home" is not found in the project's properties files. 
+ Either open the project in the IDE and setup the Platform with the same name or add it manually.
+ For example like this:
+     ant -Duser.properties.file=&lt;path_to_property_file&gt; jar (where you put the property "platforms.${platform.active}.home" in a .properties file)
+  or ant -Dplatforms.${platform.active}.home=&lt;path_to_JDK_home&gt; jar (where no properties file is used) 
+  </fail>
         <available file="${manifest.file}" property="manifest.available"/>
         <condition property="splashscreen.available">
             <and>
@@ -140,7 +177,11 @@
         </condition>
         <condition property="have.sources">
             <or>
+                <available file="${src.modena.dir}"/>
+                <available file="${src.modena2.dir}"/>
                 <available file="${src.dir}"/>
+                <available file="${src.java.dir}"/>
+                <available file="${src.resources.dir}"/>
             </or>
         </condition>
         <condition property="netbeans.home+have.tests">
@@ -188,15 +229,6 @@
         <condition else="" property="endorsed.classpath.cmd.line.arg" value="-Xbootclasspath/p:'${toString:endorsed.classpath.path}'">
             <length length="0" string="${endorsed.classpath}" when="greater"/>
         </condition>
-        <condition else="false" property="jdkBug6558476">
-            <and>
-                <matches pattern="1\.[56]" string="${java.specification.version}"/>
-                <not>
-                    <os family="unix"/>
-                </not>
-            </and>
-        </condition>
-        <property name="javac.fork" value="${jdkBug6558476}"/>
         <property name="jar.index" value="false"/>
         <property name="jar.index.metainf" value="${jar.index}"/>
         <property name="copylibs.rebase" value="true"/>
@@ -228,7 +260,11 @@
         <!-- You can override this target in the ../build.xml file. -->
     </target>
     <target depends="-pre-init,-init-private,-init-user,-init-project,-do-init" name="-init-check">
+        <fail unless="src.modena.dir">Must set src.modena.dir</fail>
+        <fail unless="src.modena2.dir">Must set src.modena2.dir</fail>
         <fail unless="src.dir">Must set src.dir</fail>
+        <fail unless="src.java.dir">Must set src.java.dir</fail>
+        <fail unless="src.resources.dir">Must set src.resources.dir</fail>
         <fail unless="test.src.dir">Must set test.src.dir</fail>
         <fail unless="build.dir">Must set build.dir</fail>
         <fail unless="dist.dir">Must set dist.dir</fail>
@@ -250,7 +286,7 @@
     </target>
     <target depends="-init-ap-cmdline-properties" if="ap.supported.internal" name="-init-macrodef-javac-with-processors">
         <macrodef name="javac" uri="http://www.netbeans.org/ns/j2se-project/3">
-            <attribute default="${src.dir}" name="srcdir"/>
+            <attribute default="${src.modena.dir}:${src.modena2.dir}:${src.dir}:${src.java.dir}:${src.resources.dir}" name="srcdir"/>
             <attribute default="${build.classes.dir}" name="destdir"/>
             <attribute default="${javac.classpath}" name="classpath"/>
             <attribute default="${javac.processorpath}" name="processorpath"/>
@@ -265,7 +301,7 @@
                 <property location="${build.dir}/empty" name="empty.dir"/>
                 <mkdir dir="${empty.dir}"/>
                 <mkdir dir="@{apgeneratedsrcdir}"/>
-                <javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" fork="${javac.fork}" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}" tempdir="${java.io.tmpdir}">
+                <javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" executable="${platform.javac}" fork="yes" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}" tempdir="${java.io.tmpdir}">
                     <src>
                         <dirset dir="@{gensrcdir}" erroronmissingdir="false">
                             <include name="*"/>
@@ -290,7 +326,7 @@
     </target>
     <target depends="-init-ap-cmdline-properties" name="-init-macrodef-javac-without-processors" unless="ap.supported.internal">
         <macrodef name="javac" uri="http://www.netbeans.org/ns/j2se-project/3">
-            <attribute default="${src.dir}" name="srcdir"/>
+            <attribute default="${src.modena.dir}:${src.modena2.dir}:${src.dir}:${src.java.dir}:${src.resources.dir}" name="srcdir"/>
             <attribute default="${build.classes.dir}" name="destdir"/>
             <attribute default="${javac.classpath}" name="classpath"/>
             <attribute default="${javac.processorpath}" name="processorpath"/>
@@ -304,7 +340,7 @@
             <sequential>
                 <property location="${build.dir}/empty" name="empty.dir"/>
                 <mkdir dir="${empty.dir}"/>
-                <javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" fork="${javac.fork}" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}" tempdir="${java.io.tmpdir}">
+                <javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" executable="${platform.javac}" fork="yes" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}" tempdir="${java.io.tmpdir}">
                     <src>
                         <dirset dir="@{gensrcdir}" erroronmissingdir="false">
                             <include name="*"/>
@@ -322,7 +358,7 @@
     </target>
     <target depends="-init-macrodef-javac-with-processors,-init-macrodef-javac-without-processors" name="-init-macrodef-javac">
         <macrodef name="depend" uri="http://www.netbeans.org/ns/j2se-project/3">
-            <attribute default="${src.dir}" name="srcdir"/>
+            <attribute default="${src.modena.dir}:${src.modena2.dir}:${src.dir}:${src.java.dir}:${src.resources.dir}" name="srcdir"/>
             <attribute default="${build.classes.dir}" name="destdir"/>
             <attribute default="${javac.classpath}" name="classpath"/>
             <sequential>
@@ -384,7 +420,7 @@
             <element name="customize" optional="true"/>
             <sequential>
                 <property name="junit.forkmode" value="perTest"/>
-                <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">
+                <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" jvm="${platform.java}" showoutput="true" tempdir="${build.dir}">
                     <test methods="@{testmethods}" name="@{testincludes}" todir="${build.test.results.dir}"/>
                     <syspropertyset>
                         <propertyref prefix="test-sys-prop."/>
@@ -407,7 +443,7 @@
             <element name="customize" optional="true"/>
             <sequential>
                 <property name="junit.forkmode" value="perTest"/>
-                <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">
+                <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" jvm="${platform.java}" showoutput="true" tempdir="${build.dir}">
                     <batchtest todir="${build.test.results.dir}">
                         <fileset dir="${test.src.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
                             <filename name="@{testincludes}"/>
@@ -446,7 +482,7 @@
                     </fileset>
                 </union>
                 <taskdef classname="org.testng.TestNGAntTask" classpath="${run.test.classpath}" name="testng"/>
-                <testng classfilesetref="test.set" failureProperty="tests.failed" methods="${testng.methods.arg}" mode="${testng.mode}" outputdir="${build.test.results.dir}" suitename="Modena" testname="TestNG tests" workingDir="${work.dir}">
+                <testng classfilesetref="test.set" failureProperty="tests.failed" jvm="${platform.java}" methods="${testng.methods.arg}" mode="${testng.mode}" outputdir="${build.test.results.dir}" suitename="Modena" testname="TestNG tests" workingDir="${work.dir}">
                     <xmlfileset dir="${build.test.classes.dir}" includes="@{testincludes}"/>
                     <propertyset>
                         <propertyref prefix="test-sys-prop."/>
@@ -526,7 +562,7 @@
             <element name="customize" optional="true"/>
             <sequential>
                 <property name="junit.forkmode" value="perTest"/>
-                <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">
+                <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" jvm="${platform.java}" showoutput="true" tempdir="${build.dir}">
                     <test methods="@{testmethods}" name="@{testincludes}" todir="${build.test.results.dir}"/>
                     <syspropertyset>
                         <propertyref prefix="test-sys-prop."/>
@@ -551,7 +587,7 @@
             <element name="customize" optional="true"/>
             <sequential>
                 <property name="junit.forkmode" value="perTest"/>
-                <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">
+                <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" jvm="${platform.java}" showoutput="true" tempdir="${build.dir}">
                     <batchtest todir="${build.test.results.dir}">
                         <fileset dir="${test.src.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
                             <filename name="@{testincludes}"/>
@@ -731,6 +767,9 @@
                     <classpath>
                         <path path="@{classpath}"/>
                     </classpath>
+                    <bootclasspath>
+                        <path path="${platform.bootcp}"/>
+                    </bootclasspath>
                 </nbjpdastart>
             </sequential>
         </macrodef>
@@ -746,7 +785,9 @@
         </macrodef>
     </target>
     <target name="-init-debug-args">
-        <property name="version-output" value="java version &quot;${ant.java.version}"/>
+        <exec executable="${platform.java}" outputproperty="version-output">
+            <arg value="-version"/>
+        </exec>
         <condition property="have-jdk-older-than-1.4">
             <or>
                 <contains string="${version-output}" substring="java version &quot;1.0"/>
@@ -771,7 +812,7 @@
             <attribute default="${debug.classpath}" name="classpath"/>
             <element name="customize" optional="true"/>
             <sequential>
-                <java classname="@{classname}" dir="${work.dir}" fork="true">
+                <java classname="@{classname}" dir="${work.dir}" fork="true" jvm="${platform.java}">
                     <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
                     <jvmarg line="${debug-args-line}"/>
                     <jvmarg value="-Xrunjdwp:transport=${debug-transport},address=${jpda.address}"/>
@@ -798,7 +839,7 @@
             <attribute default="jvm" name="jvm"/>
             <element name="customize" optional="true"/>
             <sequential>
-                <java classname="@{classname}" dir="${work.dir}" fork="true">
+                <java classname="@{classname}" dir="${work.dir}" fork="true" jvm="${platform.java}">
                     <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
                     <jvmarg value="-Dfile.encoding=${runtime.encoding}"/>
                     <redirector errorencoding="${runtime.encoding}" inputencoding="${runtime.encoding}" outputencoding="${runtime.encoding}"/>
@@ -920,12 +961,16 @@
                 <include name="*"/>
             </dirset>
         </pathconvert>
-        <j2seproject3:depend srcdir="${src.dir}:${build.generated.subdirs}"/>
+        <j2seproject3:depend srcdir="${src.modena.dir}:${src.modena2.dir}:${src.dir}:${src.java.dir}:${src.resources.dir}:${build.generated.subdirs}"/>
     </target>
     <target depends="init,deps-jar,-pre-pre-compile,-pre-compile, -copy-persistence-xml,-compile-depend" if="have.sources" name="-do-compile">
         <j2seproject3:javac gensrcdir="${build.generated.sources.dir}"/>
         <copy todir="${build.classes.dir}">
+            <fileset dir="${src.modena.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
+            <fileset dir="${src.modena2.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
+            <fileset dir="${src.java.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
+            <fileset dir="${src.resources.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
         </copy>
     </target>
     <target if="has.persistence.xml" name="-copy-persistence-xml">
@@ -946,7 +991,7 @@
     <target depends="init,deps-jar,-pre-pre-compile" name="-do-compile-single">
         <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
         <j2seproject3:force-recompile/>
-        <j2seproject3:javac excludes="" gensrcdir="${build.generated.sources.dir}" includes="${javac.includes}" sourcepath="${src.dir}"/>
+        <j2seproject3:javac excludes="" gensrcdir="${build.generated.sources.dir}" includes="${javac.includes}" sourcepath="${src.modena.dir}:${src.modena2.dir}:${src.dir}:${src.java.dir}:${src.resources.dir}"/>
     </target>
     <target name="-post-compile-single">
         <!-- Empty placeholder for easier customization. -->
@@ -985,7 +1030,7 @@
             <path path="${run.classpath}"/>
             <map from="${build.classes.dir.resolved}" to="${dist.jar.resolved}"/>
         </pathconvert>
-        <echo level="info">java -cp "${run.classpath.with.dist.jar}" ${main.class}</echo>
+        <echo level="info">${platform.java} -cp "${run.classpath.with.dist.jar}" ${main.class}</echo>
     </target>
     <target depends="init" if="do.archive" name="-do-jar-with-libraries-create-manifest" unless="manifest.available">
         <tempfile deleteonexit="true" destdir="${build.dir}" property="tmp.manifest.file"/>
@@ -1012,7 +1057,7 @@
         <j2seproject3:copylibs manifest="${tmp.manifest.file}"/>
         <echo level="info">To run this application from the command line without Ant, try:</echo>
         <property location="${dist.jar}" name="dist.jar.resolved"/>
-        <echo level="info">java -jar "${dist.jar.resolved}"</echo>
+        <echo level="info">${platform.java} -jar "${dist.jar.resolved}"</echo>
     </target>
     <target depends="-do-jar-with-libraries-pack" if="do.archive" name="-do-jar-with-libraries-delete-manifest">
         <delete>
@@ -1203,13 +1248,25 @@
                 </not>
             </and>
         </condition>
-        <javadoc additionalparam="${javadoc.additionalparam}" author="${javadoc.author}" charset="UTF-8" destdir="${dist.javadoc.dir}" docencoding="UTF-8" encoding="${javadoc.encoding.used}" failonerror="true" noindex="${javadoc.noindex}" nonavbar="${javadoc.nonavbar}" notree="${javadoc.notree}" private="${javadoc.private}" source="${javac.source}" splitindex="${javadoc.splitindex}" use="${javadoc.use}" useexternalfile="true" version="${javadoc.version}" windowtitle="${javadoc.windowtitle}">
+        <javadoc additionalparam="${javadoc.additionalparam}" author="${javadoc.author}" charset="UTF-8" destdir="${dist.javadoc.dir}" docencoding="UTF-8" encoding="${javadoc.encoding.used}" executable="${platform.javadoc}" failonerror="true" noindex="${javadoc.noindex}" nonavbar="${javadoc.nonavbar}" notree="${javadoc.notree}" private="${javadoc.private}" source="${javac.source}" splitindex="${javadoc.splitindex}" use="${javadoc.use}" useexternalfile="true" version="${javadoc.version}" windowtitle="${javadoc.windowtitle}">
             <classpath>
                 <path path="${javac.classpath}"/>
             </classpath>
+            <fileset dir="${src.modena.dir}" excludes="*.java,${excludes}" includes="${includes}">
+                <filename name="**/*.java"/>
+            </fileset>
+            <fileset dir="${src.modena2.dir}" excludes="*.java,${excludes}" includes="${includes}">
+                <filename name="**/*.java"/>
+            </fileset>
             <fileset dir="${src.dir}" excludes="*.java,${excludes}" includes="${includes}">
                 <filename name="**/*.java"/>
             </fileset>
+            <fileset dir="${src.java.dir}" excludes="*.java,${excludes}" includes="${includes}">
+                <filename name="**/*.java"/>
+            </fileset>
+            <fileset dir="${src.resources.dir}" excludes="*.java,${excludes}" includes="${includes}">
+                <filename name="**/*.java"/>
+            </fileset>
             <fileset dir="${build.generated.sources.dir}" erroronmissingdir="false">
                 <include name="**/*.java"/>
                 <exclude name="*.java"/>
@@ -1217,9 +1274,21 @@
             <arg line="${javadoc.endorsed.classpath.cmd.line.arg}"/>
         </javadoc>
         <copy todir="${dist.javadoc.dir}">
+            <fileset dir="${src.modena.dir}" excludes="${excludes}" includes="${includes}">
+                <filename name="**/doc-files/**"/>
+            </fileset>
+            <fileset dir="${src.modena2.dir}" excludes="${excludes}" includes="${includes}">
+                <filename name="**/doc-files/**"/>
+            </fileset>
             <fileset dir="${src.dir}" excludes="${excludes}" includes="${includes}">
                 <filename name="**/doc-files/**"/>
             </fileset>
+            <fileset dir="${src.java.dir}" excludes="${excludes}" includes="${includes}">
+                <filename name="**/doc-files/**"/>
+            </fileset>
+            <fileset dir="${src.resources.dir}" excludes="${excludes}" includes="${includes}">
+                <filename name="**/doc-files/**"/>
+            </fileset>
             <fileset dir="${build.generated.sources.dir}" erroronmissingdir="false">
                 <include name="**/doc-files/**"/>
             </fileset>
--- a/apps/experiments/Modena/nbproject/genfiles.properties	Tue Jul 09 18:33:45 2013 +0400
+++ b/apps/experiments/Modena/nbproject/genfiles.properties	Wed Jul 10 11:01:52 2013 +0400
@@ -1,8 +1,8 @@
-build.xml.data.CRC32=83fefa80
+build.xml.data.CRC32=404da80d
 build.xml.script.CRC32=dcafbe5a
 build.xml.stylesheet.CRC32=28e38971@1.56.1.46
 # This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
 # Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
-nbproject/build-impl.xml.data.CRC32=83fefa80
-nbproject/build-impl.xml.script.CRC32=2fd1e588
+nbproject/build-impl.xml.data.CRC32=404da80d
+nbproject/build-impl.xml.script.CRC32=4573e166
 nbproject/build-impl.xml.stylesheet.CRC32=c6d2a60f@1.56.1.46
--- a/apps/experiments/Modena/nbproject/project.properties	Tue Jul 09 18:33:45 2013 +0400
+++ b/apps/experiments/Modena/nbproject/project.properties	Wed Jul 10 11:01:52 2013 +0400
@@ -59,7 +59,7 @@
 manifest.file=manifest.mf
 meta.inf.dir=${src.dir}/META-INF
 mkdist.disabled=false
-platform.active=default_platform
+platform.active=JDK_1.8
 run.classpath=\
     ${javac.classpath}:\
     ${build.classes.dir}
@@ -72,4 +72,8 @@
     ${build.test.classes.dir}
 source.encoding=UTF-8
 src.dir=src
+src.java.dir=src/main/java
+src.modena.dir=src/main/java/modena
+src.modena2.dir=src/main/resources/modena
+src.resources.dir=src/main/resources
 test.src.dir=test
--- a/apps/experiments/Modena/nbproject/project.xml	Tue Jul 09 18:33:45 2013 +0400
+++ b/apps/experiments/Modena/nbproject/project.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -4,8 +4,13 @@
     <configuration>
         <data xmlns="http://www.netbeans.org/ns/j2se-project/3">
             <name>Modena</name>
+            <explicit-platform explicit-source-supported="true"/>
             <source-roots>
+                <root id="src.modena.dir"/>
+                <root id="src.modena2.dir"/>
                 <root id="src.dir"/>
+                <root id="src.java.dir"/>
+                <root id="src.resources.dir"/>
             </source-roots>
             <test-roots>
                 <root id="test.src.dir"/>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/apps/samples/Ensemble8/build.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,138 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- You may freely edit this file. See commented blocks below for -->
+<!-- some examples of how to customize the build. -->
+<!-- (If you delete it and reopen the project it will be recreated.) -->
+<!-- By default, only the Clean and Build commands use this build script. -->
+<!-- Commands such as Run, Debug, and Test only use this build script if -->
+<!-- the Compile on Save feature is turned off for the project. -->
+<!-- You can turn off the Compile on Save (or Deploy on Save) setting -->
+<!-- in the project's Project Properties dialog box.-->
+<project name="Ensemble8" default="default" basedir="." xmlns:fx="javafx:com.sun.javafx.tools.ant">
+    <description>Builds, tests, and runs the project Ensemble8.</description>
+    <import file="nbproject/build-impl.xml"/>
+    <!--
+
+    There exist several targets which are by default empty and which can be 
+    used for execution of your tasks. These targets are usually executed 
+    before and after some main targets. They are: 
+
+      -pre-init:                 called before initialization of project properties
+      -post-init:                called after initialization of project properties
+      -pre-compile:              called before javac compilation
+      -post-compile:             called after javac compilation
+      -pre-compile-single:       called before javac compilation of single file
+      -post-compile-single:      called after javac compilation of single file
+      -pre-compile-test:         called before javac compilation of JUnit tests
+      -post-compile-test:        called after javac compilation of JUnit tests
+      -pre-compile-test-single:  called before javac compilation of single JUnit test
+      -post-compile-test-single: called after javac compilation of single JUunit test
+      -pre-jar:                  called before JAR building
+      -post-jar:                 called after JAR building
+      -post-clean:               called after cleaning build products
+
+    (Targets beginning with '-' are not intended to be called on their own.)
+
+    Example of inserting an obfuscator after compilation could look like this:
+
+        <target name="-post-compile">
+            <obfuscate>
+                <fileset dir="${build.classes.dir}"/>
+            </obfuscate>
+        </target>
+
+    For list of available properties check the imported 
+    nbproject/build-impl.xml file. 
+
+
+    Another way to customize the build is by overriding existing main targets.
+    The targets of interest are: 
+
+      -init-macrodef-javac:     defines macro for javac compilation
+      -init-macrodef-junit:     defines macro for junit execution
+      -init-macrodef-debug:     defines macro for class debugging
+      -init-macrodef-java:      defines macro for class execution
+      -do-jar-with-manifest:    JAR building (if you are using a manifest)
+      -do-jar-without-manifest: JAR building (if you are not using a manifest)
+      run:                      execution of project 
+      -javadoc-build:           Javadoc generation
+      test-report:              JUnit report generation
+
+    An example of overriding the target for project execution could look like this:
+
+        <target name="run" depends="Ensemble8-impl.jar">
+            <exec dir="bin" executable="launcher.exe">
+                <arg file="${dist.jar}"/>
+            </exec>
+        </target>
+
+    Notice that the overridden target depends on the jar target and not only on 
+    the compile target as the regular run target does. Again, for a list of available 
+    properties which you can use, check the target you are overriding in the
+    nbproject/build-impl.xml file. 
+
+    -->
+    
+    <!-- COPY SAMPLE SRC TO BUILD DIR -->
+    <target name="-pre-compile">
+        <echo>Copying all sample source files to build dir</echo>
+         <copy todir="${build.classes.dir}">
+            <fileset dir="${basedir}/src/samples">
+                <include name="**/samples/**/*.java"/>
+                <include name="**/*.js"/> <!-- include javascript files -->
+                <include name="**/*.wav"/> <!-- include wav files -->
+                <include name="**/*.css"/> <!-- include css files -->
+            </fileset>
+        </copy>
+    </target>
+    
+    <!-- DON'T INCLUDE COMPILE TIME CODE IN APP JAR -->
+    <target name="-pre-jar">
+        <delete dir="${build.classes.dir}/ensemble/compiletime"/>
+    </target>
+    
+    <!-- COPY LIBS INTO JAR FILE: so that we have a simple single jar application -->
+    <target name="-post-jar" depends="jfx-deployment">
+        <zip destfile="${dist.jar}" update="true">
+            <zipfileset src="${file.reference.lucene-core-3.2.0.jar}"/>
+            <zipfileset src="${file.reference.lucene-grouping-3.2.0.jar}"/>
+        </zip>
+    </target>
+    
+    <target name="ensemble-generate-samples-class" depends="init,compile" description="Ensemble: Generate source for all samples data class.">
+       <java classname="ensemble.compiletime.EnsembleCompiletimeMain" dir="${basedir}">
+         <arg value="samples"/>
+         <classpath>
+           <pathelement location="${build.classes.dir}"/>
+           <pathelement path="${javac.classpath}"/>
+         </classpath>
+       </java>
+    </target>
+    
+    <target name="ensemble-generate-search-index" depends="init,compile" description="Ensemble: Generate search index.">
+       <delete dir="${basedir}/src/generated/ensemble/search/index"/>
+       <java classname="ensemble.compiletime.EnsembleCompiletimeMain" dir="${basedir}">
+         <arg value="index"/>
+         <classpath>
+           <pathelement location="${build.classes.dir}"/>
+           <pathelement path="${javac.classpath}"/>
+         </classpath>
+       </java>
+    </target>
+    
+    <target name="jfx-deployment">
+        <!-- Delete the Ensemble8.jar build by netbeans as we will build one with JavaFX packager -->
+        <delete file="${dist.jar}"/>  
+        <fx:application id="ensemble8"
+                        name="${application.title}"
+                        mainClass="ensemble.EnsembleApp"/>
+        <fx:jar destfile="${dist.jar}">
+            <fx:application refId="ensemble8"/>
+            <fileset dir="${build.classes.dir}"/>
+            <manifest>
+                <attribute name="Implementation-Vendor" value="${application.vendor}"/>
+                <attribute name="Implementation-Title" value="${application.title}"/>
+                <attribute name="Implementation-Version" value="1.0"/>
+            </manifest>
+        </fx:jar>
+    </target>    
+</project>
--- a/apps/samples/Ensemble8/nbproject/build-impl.xml	Tue Jul 09 18:33:45 2013 +0400
+++ b/apps/samples/Ensemble8/nbproject/build-impl.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -54,6 +54,43 @@
         <property file="nbproject/project.properties"/>
     </target>
     <target depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property" name="-do-init">
+        <j2seproject1:property name="platform.home" value="platforms.${platform.active}.home"/>
+        <j2seproject1:property name="platform.bootcp" value="platforms.${platform.active}.bootclasspath"/>
+        <j2seproject1:property name="platform.compiler" value="platforms.${platform.active}.compile"/>
+        <j2seproject1:property name="platform.javac.tmp" value="platforms.${platform.active}.javac"/>
+        <condition property="platform.javac" value="${platform.home}/bin/javac">
+            <equals arg1="${platform.javac.tmp}" arg2="$${platforms.${platform.active}.javac}"/>
+        </condition>
+        <property name="platform.javac" value="${platform.javac.tmp}"/>
+        <j2seproject1:property name="platform.java.tmp" value="platforms.${platform.active}.java"/>
+        <condition property="platform.java" value="${platform.home}/bin/java">
+            <equals arg1="${platform.java.tmp}" arg2="$${platforms.${platform.active}.java}"/>
+        </condition>
+        <property name="platform.java" value="${platform.java.tmp}"/>
+        <j2seproject1:property name="platform.javadoc.tmp" value="platforms.${platform.active}.javadoc"/>
+        <condition property="platform.javadoc" value="${platform.home}/bin/javadoc">
+            <equals arg1="${platform.javadoc.tmp}" arg2="$${platforms.${platform.active}.javadoc}"/>
+        </condition>
+        <property name="platform.javadoc" value="${platform.javadoc.tmp}"/>
+        <condition property="platform.invalid" value="true">
+            <or>
+                <contains string="${platform.javac}" substring="$${platforms."/>
+                <contains string="${platform.java}" substring="$${platforms."/>
+                <contains string="${platform.javadoc}" substring="$${platforms."/>
+            </or>
+        </condition>
+        <fail unless="platform.home">Must set platform.home</fail>
+        <fail unless="platform.bootcp">Must set platform.bootcp</fail>
+        <fail unless="platform.java">Must set platform.java</fail>
+        <fail unless="platform.javac">Must set platform.javac</fail>
+        <fail if="platform.invalid">
+ The J2SE Platform is not correctly set up.
+ Your active platform is: ${platform.active}, but the corresponding property "platforms.${platform.active}.home" is not found in the project's properties files. 
+ Either open the project in the IDE and setup the Platform with the same name or add it manually.
+ For example like this:
+     ant -Duser.properties.file=&lt;path_to_property_file&gt; jar (where you put the property "platforms.${platform.active}.home" in a .properties file)
+  or ant -Dplatforms.${platform.active}.home=&lt;path_to_JDK_home&gt; jar (where no properties file is used) 
+  </fail>
         <available file="${manifest.file}" property="manifest.available"/>
         <condition property="splashscreen.available">
             <and>
@@ -138,10 +175,13 @@
         </condition>
         <condition property="have.sources">
             <or>
-                <available file="${src.compiletime.dir}"/>
-                <available file="${src.generated.dir}"/>
-                <available file="${src.app.dir}"/>
-                <available file="${src.samples.dir}"/>
+                <available file="${src.java.dir}"/>
+                <available file="${src.resources.dir}"/>
+                <available file="${src.java2.dir}"/>
+                <available file="${src.resources2.dir}"/>
+                <available file="${src.java3.dir}"/>
+                <available file="${src.java4.dir}"/>
+                <available file="${src.resources3.dir}"/>
             </or>
         </condition>
         <condition property="netbeans.home+have.tests">
@@ -189,15 +229,6 @@
         <condition else="" property="endorsed.classpath.cmd.line.arg" value="-Xbootclasspath/p:'${toString:endorsed.classpath.path}'">
             <length length="0" string="${endorsed.classpath}" when="greater"/>
         </condition>
-        <condition else="false" property="jdkBug6558476">
-            <and>
-                <matches pattern="1\.[56]" string="${java.specification.version}"/>
-                <not>
-                    <os family="unix"/>
-                </not>
-            </and>
-        </condition>
-        <property name="javac.fork" value="${jdkBug6558476}"/>
         <property name="jar.index" value="false"/>
         <property name="jar.index.metainf" value="${jar.index}"/>
         <property name="copylibs.rebase" value="true"/>
@@ -229,10 +260,13 @@
         <!-- You can override this target in the ../build.xml file. -->
     </target>
     <target depends="-pre-init,-init-private,-init-user,-init-project,-do-init" name="-init-check">
-        <fail unless="src.compiletime.dir">Must set src.compiletime.dir</fail>
-        <fail unless="src.generated.dir">Must set src.generated.dir</fail>
-        <fail unless="src.app.dir">Must set src.app.dir</fail>
-        <fail unless="src.samples.dir">Must set src.samples.dir</fail>
+        <fail unless="src.java.dir">Must set src.java.dir</fail>
+        <fail unless="src.resources.dir">Must set src.resources.dir</fail>
+        <fail unless="src.java2.dir">Must set src.java2.dir</fail>
+        <fail unless="src.resources2.dir">Must set src.resources2.dir</fail>
+        <fail unless="src.java3.dir">Must set src.java3.dir</fail>
+        <fail unless="src.java4.dir">Must set src.java4.dir</fail>
+        <fail unless="src.resources3.dir">Must set src.resources3.dir</fail>
         <fail unless="build.dir">Must set build.dir</fail>
         <fail unless="dist.dir">Must set dist.dir</fail>
         <fail unless="build.classes.dir">Must set build.classes.dir</fail>
@@ -253,7 +287,7 @@
     </target>
     <target depends="-init-ap-cmdline-properties" if="ap.supported.internal" name="-init-macrodef-javac-with-processors">
         <macrodef name="javac" uri="http://www.netbeans.org/ns/j2se-project/3">
-            <attribute default="${src.compiletime.dir}:${src.generated.dir}:${src.app.dir}:${src.samples.dir}" name="srcdir"/>
+            <attribute default="${src.java.dir}:${src.resources.dir}:${src.java2.dir}:${src.resources2.dir}:${src.java3.dir}:${src.java4.dir}:${src.resources3.dir}" name="srcdir"/>
             <attribute default="${build.classes.dir}" name="destdir"/>
             <attribute default="${javac.classpath}" name="classpath"/>
             <attribute default="${javac.processorpath}" name="processorpath"/>
@@ -268,7 +302,7 @@
                 <property location="${build.dir}/empty" name="empty.dir"/>
                 <mkdir dir="${empty.dir}"/>
                 <mkdir dir="@{apgeneratedsrcdir}"/>
-                <javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" fork="${javac.fork}" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}" tempdir="${java.io.tmpdir}">
+                <javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" executable="${platform.javac}" fork="yes" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}" tempdir="${java.io.tmpdir}">
                     <src>
                         <dirset dir="@{gensrcdir}" erroronmissingdir="false">
                             <include name="*"/>
@@ -293,7 +327,7 @@
     </target>
     <target depends="-init-ap-cmdline-properties" name="-init-macrodef-javac-without-processors" unless="ap.supported.internal">
         <macrodef name="javac" uri="http://www.netbeans.org/ns/j2se-project/3">
-            <attribute default="${src.compiletime.dir}:${src.generated.dir}:${src.app.dir}:${src.samples.dir}" name="srcdir"/>
+            <attribute default="${src.java.dir}:${src.resources.dir}:${src.java2.dir}:${src.resources2.dir}:${src.java3.dir}:${src.java4.dir}:${src.resources3.dir}" name="srcdir"/>
             <attribute default="${build.classes.dir}" name="destdir"/>
             <attribute default="${javac.classpath}" name="classpath"/>
             <attribute default="${javac.processorpath}" name="processorpath"/>
@@ -307,7 +341,7 @@
             <sequential>
                 <property location="${build.dir}/empty" name="empty.dir"/>
                 <mkdir dir="${empty.dir}"/>
-                <javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" fork="${javac.fork}" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}" tempdir="${java.io.tmpdir}">
+                <javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" executable="${platform.javac}" fork="yes" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}" tempdir="${java.io.tmpdir}">
                     <src>
                         <dirset dir="@{gensrcdir}" erroronmissingdir="false">
                             <include name="*"/>
@@ -325,7 +359,7 @@
     </target>
     <target depends="-init-macrodef-javac-with-processors,-init-macrodef-javac-without-processors" name="-init-macrodef-javac">
         <macrodef name="depend" uri="http://www.netbeans.org/ns/j2se-project/3">
-            <attribute default="${src.compiletime.dir}:${src.generated.dir}:${src.app.dir}:${src.samples.dir}" name="srcdir"/>
+            <attribute default="${src.java.dir}:${src.resources.dir}:${src.java2.dir}:${src.resources2.dir}:${src.java3.dir}:${src.java4.dir}:${src.resources3.dir}" name="srcdir"/>
             <attribute default="${build.classes.dir}" name="destdir"/>
             <attribute default="${javac.classpath}" name="classpath"/>
             <sequential>
@@ -387,7 +421,7 @@
             <element name="customize" optional="true"/>
             <sequential>
                 <property name="junit.forkmode" value="perTest"/>
-                <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">
+                <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" jvm="${platform.java}" showoutput="true" tempdir="${build.dir}">
                     <test methods="@{testmethods}" name="@{testincludes}" todir="${build.test.results.dir}"/>
                     <syspropertyset>
                         <propertyref prefix="test-sys-prop."/>
@@ -410,7 +444,7 @@
             <element name="customize" optional="true"/>
             <sequential>
                 <property name="junit.forkmode" value="perTest"/>
-                <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">
+                <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" jvm="${platform.java}" showoutput="true" tempdir="${build.dir}">
                     <batchtest todir="${build.test.results.dir}">
                         <fileset dir="${build.test.classes.dir}" excludes="@{excludes},${excludes},${test.binaryexcludes}" includes="${test.binaryincludes}">
                             <filename name="${test.binarytestincludes}"/>
@@ -442,7 +476,7 @@
                 </condition>
                 <union id="test.set"/>
                 <taskdef classname="org.testng.TestNGAntTask" classpath="${run.test.classpath}" name="testng"/>
-                <testng classfilesetref="test.set" failureProperty="tests.failed" methods="${testng.methods.arg}" mode="${testng.mode}" outputdir="${build.test.results.dir}" suitename="Ensemble8" testname="TestNG tests" workingDir="${work.dir}">
+                <testng classfilesetref="test.set" failureProperty="tests.failed" jvm="${platform.java}" methods="${testng.methods.arg}" mode="${testng.mode}" outputdir="${build.test.results.dir}" suitename="Ensemble8" testname="TestNG tests" workingDir="${work.dir}">
                     <xmlfileset dir="${build.test.classes.dir}" includes="@{testincludes}"/>
                     <propertyset>
                         <propertyref prefix="test-sys-prop."/>
@@ -522,7 +556,7 @@
             <element name="customize" optional="true"/>
             <sequential>
                 <property name="junit.forkmode" value="perTest"/>
-                <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">
+                <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" jvm="${platform.java}" showoutput="true" tempdir="${build.dir}">
                     <test methods="@{testmethods}" name="@{testincludes}" todir="${build.test.results.dir}"/>
                     <syspropertyset>
                         <propertyref prefix="test-sys-prop."/>
@@ -547,7 +581,7 @@
             <element name="customize" optional="true"/>
             <sequential>
                 <property name="junit.forkmode" value="perTest"/>
-                <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">
+                <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" jvm="${platform.java}" showoutput="true" tempdir="${build.dir}">
                     <batchtest todir="${build.test.results.dir}">
                         <fileset dir="${build.test.classes.dir}" excludes="@{excludes},${excludes},${test.binaryexcludes}" includes="${test.binaryincludes}">
                             <filename name="${test.binarytestincludes}"/>
@@ -724,6 +758,9 @@
                     <classpath>
                         <path path="@{classpath}"/>
                     </classpath>
+                    <bootclasspath>
+                        <path path="${platform.bootcp}"/>
+                    </bootclasspath>
                 </nbjpdastart>
             </sequential>
         </macrodef>
@@ -739,7 +776,9 @@
         </macrodef>
     </target>
     <target name="-init-debug-args">
-        <property name="version-output" value="java version &quot;${ant.java.version}"/>
+        <exec executable="${platform.java}" outputproperty="version-output">
+            <arg value="-version"/>
+        </exec>
         <condition property="have-jdk-older-than-1.4">
             <or>
                 <contains string="${version-output}" substring="java version &quot;1.0"/>
@@ -764,7 +803,7 @@
             <attribute default="${debug.classpath}" name="classpath"/>
             <element name="customize" optional="true"/>
             <sequential>
-                <java classname="@{classname}" dir="${work.dir}" fork="true">
+                <java classname="@{classname}" dir="${work.dir}" fork="true" jvm="${platform.java}">
                     <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
                     <jvmarg line="${debug-args-line}"/>
                     <jvmarg value="-Xrunjdwp:transport=${debug-transport},address=${jpda.address}"/>
@@ -791,7 +830,7 @@
             <attribute default="jvm" name="jvm"/>
             <element name="customize" optional="true"/>
             <sequential>
-                <java classname="@{classname}" dir="${work.dir}" fork="true">
+                <java classname="@{classname}" dir="${work.dir}" fork="true" jvm="${platform.java}">
                     <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
                     <jvmarg value="-Dfile.encoding=${runtime.encoding}"/>
                     <redirector errorencoding="${runtime.encoding}" inputencoding="${runtime.encoding}" outputencoding="${runtime.encoding}"/>
@@ -913,15 +952,18 @@
                 <include name="*"/>
             </dirset>
         </pathconvert>
-        <j2seproject3:depend srcdir="${src.compiletime.dir}:${src.generated.dir}:${src.app.dir}:${src.samples.dir}:${build.generated.subdirs}"/>
+        <j2seproject3:depend srcdir="${src.java.dir}:${src.resources.dir}:${src.java2.dir}:${src.resources2.dir}:${src.java3.dir}:${src.java4.dir}:${src.resources3.dir}:${build.generated.subdirs}"/>
     </target>
     <target depends="init,deps-jar,-pre-pre-compile,-pre-compile, -copy-persistence-xml,-compile-depend" if="have.sources" name="-do-compile">
         <j2seproject3:javac gensrcdir="${build.generated.sources.dir}"/>
         <copy todir="${build.classes.dir}">
-            <fileset dir="${src.compiletime.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
-            <fileset dir="${src.generated.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
-            <fileset dir="${src.app.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
-            <fileset dir="${src.samples.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
+            <fileset dir="${src.java.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
+            <fileset dir="${src.resources.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
+            <fileset dir="${src.java2.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
+            <fileset dir="${src.resources2.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
+            <fileset dir="${src.java3.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
+            <fileset dir="${src.java4.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
+            <fileset dir="${src.resources3.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
         </copy>
     </target>
     <target if="has.persistence.xml" name="-copy-persistence-xml">
@@ -942,7 +984,7 @@
     <target depends="init,deps-jar,-pre-pre-compile" name="-do-compile-single">
         <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
         <j2seproject3:force-recompile/>
-        <j2seproject3:javac excludes="" gensrcdir="${build.generated.sources.dir}" includes="${javac.includes}" sourcepath="${src.compiletime.dir}:${src.generated.dir}:${src.app.dir}:${src.samples.dir}"/>
+        <j2seproject3:javac excludes="" gensrcdir="${build.generated.sources.dir}" includes="${javac.includes}" sourcepath="${src.java.dir}:${src.resources.dir}:${src.java2.dir}:${src.resources2.dir}:${src.java3.dir}:${src.java4.dir}:${src.resources3.dir}"/>
     </target>
     <target name="-post-compile-single">
         <!-- Empty placeholder for easier customization. -->
@@ -981,7 +1023,7 @@
             <path path="${run.classpath}"/>
             <map from="${build.classes.dir.resolved}" to="${dist.jar.resolved}"/>
         </pathconvert>
-        <echo level="info">java -cp "${run.classpath.with.dist.jar}" ${main.class}</echo>
+        <echo level="info">${platform.java} -cp "${run.classpath.with.dist.jar}" ${main.class}</echo>
     </target>
     <target depends="init" if="do.archive" name="-do-jar-with-libraries-create-manifest" unless="manifest.available">
         <tempfile deleteonexit="true" destdir="${build.dir}" property="tmp.manifest.file"/>
@@ -1008,7 +1050,7 @@
         <j2seproject3:copylibs manifest="${tmp.manifest.file}"/>
         <echo level="info">To run this application from the command line without Ant, try:</echo>
         <property location="${dist.jar}" name="dist.jar.resolved"/>
-        <echo level="info">java -jar "${dist.jar.resolved}"</echo>
+        <echo level="info">${platform.java} -jar "${dist.jar.resolved}"</echo>
     </target>
     <target depends="-do-jar-with-libraries-pack" if="do.archive" name="-do-jar-with-libraries-delete-manifest">
         <delete>
@@ -1199,20 +1241,29 @@
                 </not>
             </and>
         </condition>
-        <javadoc additionalparam="${javadoc.additionalparam}" author="${javadoc.author}" charset="UTF-8" destdir="${dist.javadoc.dir}" docencoding="UTF-8" encoding="${javadoc.encoding.used}" failonerror="true" noindex="${javadoc.noindex}" nonavbar="${javadoc.nonavbar}" notree="${javadoc.notree}" private="${javadoc.private}" source="${javac.source}" splitindex="${javadoc.splitindex}" use="${javadoc.use}" useexternalfile="true" version="${javadoc.version}" windowtitle="${javadoc.windowtitle}">
+        <javadoc additionalparam="${javadoc.additionalparam}" author="${javadoc.author}" charset="UTF-8" destdir="${dist.javadoc.dir}" docencoding="UTF-8" encoding="${javadoc.encoding.used}" executable="${platform.javadoc}" failonerror="true" noindex="${javadoc.noindex}" nonavbar="${javadoc.nonavbar}" notree="${javadoc.notree}" private="${javadoc.private}" source="${javac.source}" splitindex="${javadoc.splitindex}" use="${javadoc.use}" useexternalfile="true" version="${javadoc.version}" windowtitle="${javadoc.windowtitle}">
             <classpath>
                 <path path="${javac.classpath}"/>
             </classpath>
-            <fileset dir="${src.compiletime.dir}" excludes="*.java,${excludes}" includes="${includes}">
+            <fileset dir="${src.java.dir}" excludes="*.java,${excludes}" includes="${includes}">
                 <filename name="**/*.java"/>
             </fileset>
-            <fileset dir="${src.generated.dir}" excludes="*.java,${excludes}" includes="${includes}">
+            <fileset dir="${src.resources.dir}" excludes="*.java,${excludes}" includes="${includes}">
                 <filename name="**/*.java"/>
             </fileset>
-            <fileset dir="${src.app.dir}" excludes="*.java,${excludes}" includes="${includes}">
+            <fileset dir="${src.java2.dir}" excludes="*.java,${excludes}" includes="${includes}">
                 <filename name="**/*.java"/>
             </fileset>
-            <fileset dir="${src.samples.dir}" excludes="*.java,${excludes}" includes="${includes}">
+            <fileset dir="${src.resources2.dir}" excludes="*.java,${excludes}" includes="${includes}">
+                <filename name="**/*.java"/>
+            </fileset>
+            <fileset dir="${src.java3.dir}" excludes="*.java,${excludes}" includes="${includes}">
+                <filename name="**/*.java"/>
+            </fileset>
+            <fileset dir="${src.java4.dir}" excludes="*.java,${excludes}" includes="${includes}">
+                <filename name="**/*.java"/>
+            </fileset>
+            <fileset dir="${src.resources3.dir}" excludes="*.java,${excludes}" includes="${includes}">
                 <filename name="**/*.java"/>
             </fileset>
             <fileset dir="${build.generated.sources.dir}" erroronmissingdir="false">
@@ -1222,16 +1273,25 @@
             <arg line="${javadoc.endorsed.classpath.cmd.line.arg}"/>
         </javadoc>
         <copy todir="${dist.javadoc.dir}">
-            <fileset dir="${src.compiletime.dir}" excludes="${excludes}" includes="${includes}">
+            <fileset dir="${src.java.dir}" excludes="${excludes}" includes="${includes}">
                 <filename name="**/doc-files/**"/>
             </fileset>
-            <fileset dir="${src.generated.dir}" excludes="${excludes}" includes="${includes}">
+            <fileset dir="${src.resources.dir}" excludes="${excludes}" includes="${includes}">
                 <filename name="**/doc-files/**"/>
             </fileset>
-            <fileset dir="${src.app.dir}" excludes="${excludes}" includes="${includes}">
+            <fileset dir="${src.java2.dir}" excludes="${excludes}" includes="${includes}">
                 <filename name="**/doc-files/**"/>
             </fileset>
-            <fileset dir="${src.samples.dir}" excludes="${excludes}" includes="${includes}">
+            <fileset dir="${src.resources2.dir}" excludes="${excludes}" includes="${includes}">
+                <filename name="**/doc-files/**"/>
+            </fileset>
+            <fileset dir="${src.java3.dir}" excludes="${excludes}" includes="${includes}">
+                <filename name="**/doc-files/**"/>
+            </fileset>
+            <fileset dir="${src.java4.dir}" excludes="${excludes}" includes="${includes}">
+                <filename name="**/doc-files/**"/>
+            </fileset>
+            <fileset dir="${src.resources3.dir}" excludes="${excludes}" includes="${includes}">
                 <filename name="**/doc-files/**"/>
             </fileset>
             <fileset dir="${build.generated.sources.dir}" erroronmissingdir="false">
--- a/apps/samples/Ensemble8/nbproject/genfiles.properties	Tue Jul 09 18:33:45 2013 +0400
+++ b/apps/samples/Ensemble8/nbproject/genfiles.properties	Wed Jul 10 11:01:52 2013 +0400
@@ -3,6 +3,6 @@
 build.xml.stylesheet.CRC32=28e38971@1.56.1.46
 # This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
 # Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
-nbproject/build-impl.xml.data.CRC32=134533ca
-nbproject/build-impl.xml.script.CRC32=aa7c6be7
+nbproject/build-impl.xml.data.CRC32=8d0eded5
+nbproject/build-impl.xml.script.CRC32=67848eb1
 nbproject/build-impl.xml.stylesheet.CRC32=c6d2a60f@1.56.1.46
--- a/apps/samples/Ensemble8/nbproject/project.properties	Tue Jul 09 18:33:45 2013 +0400
+++ b/apps/samples/Ensemble8/nbproject/project.properties	Wed Jul 10 11:01:52 2013 +0400
@@ -27,6 +27,7 @@
 dist.javadoc.dir=${dist.dir}/javadoc
 endorsed.classpath=
 excludes=
+file.reference.ant-javafx.jar=/Users/debram/projects/jdk8b96/jdk1.8.0.jdk/Contents/Home/lib/ant-javafx.jar
 file.reference.jfxrt.jar=../../../../artifacts/sdk/rt/lib/ext/jfxrt.jar
 file.reference.lucene-core-3.2.0.jar=lib/lucene-core-3.2.0.jar
 file.reference.lucene-grouping-3.2.0.jar=lib/lucene-grouping-3.2.0.jar
@@ -35,6 +36,7 @@
 jar.compress=true
 jar.index=${jnlp.enabled}
 javac.classpath=\
+    .:\
     ${file.reference.lucene-core-3.2.0.jar}:\
     ${file.reference.lucene-grouping-3.2.0.jar}:\
     ${file.reference.jfxrt.jar}
@@ -42,7 +44,8 @@
 javac.compilerargs=
 javac.deprecation=false
 javac.processorpath=\
-    ${javac.classpath}
+    ${javac.classpath}:\
+    ${file.reference.ant-javafx.jar}
 javac.source=1.7
 javac.target=1.7
 javac.test.classpath=\
@@ -61,6 +64,9 @@
 javadoc.use=true
 javadoc.version=false
 javadoc.windowtitle=
+jnlp.applet.class=ensemble.samples.swing.swinginterop.SwingInterop
+jnlp.applet.height=300
+jnlp.applet.width=300
 jnlp.codebase.type=no.codebase
 jnlp.descriptor=application
 jnlp.enabled=false
@@ -74,7 +80,7 @@
 manifest.file=manifest.mf
 meta.inf.dir=${src.dir}/META-INF
 mkdist.disabled=true
-platform.active=default_platform
+platform.active=JDK_1.8
 run.classpath=\
     ${javac.classpath}:\
     ${build.classes.dir}
@@ -86,7 +92,10 @@
     ${javac.test.classpath}:\
     ${build.test.classes.dir}
 source.encoding=UTF-8
-src.app.dir=src/app
-src.compiletime.dir=src/compiletime
-src.generated.dir=src/generated
-src.samples.dir=src/samples
+src.java.dir=src/app/java
+src.java2.dir=src/generated/java
+src.java3.dir=src/compiletime/java
+src.java4.dir=src/samples/java
+src.resources.dir=src/app/resources
+src.resources2.dir=src/generated/resources
+src.resources3.dir=src/samples/resources
--- a/apps/samples/Ensemble8/nbproject/project.xml	Tue Jul 09 18:33:45 2013 +0400
+++ b/apps/samples/Ensemble8/nbproject/project.xml	Wed Jul 10 11:01:52 2013 +0400
@@ -4,11 +4,15 @@
     <configuration>
         <data xmlns="http://www.netbeans.org/ns/j2se-project/3">
             <name>Ensemble8</name>
+            <explicit-platform explicit-source-supported="true"/>
             <source-roots>
-                <root id="src.compiletime.dir"/>
-                <root id="src.generated.dir"/>
-                <root id="src.app.dir"/>
-                <root id="src.samples.dir"/>
+                <root id="src.java.dir"/>
+                <root id="src.resources.dir"/>
+                <root id="src.java2.dir"/>
+                <root id="src.resources2.dir"/>
+                <root id="src.java3.dir"/>
+                <root id="src.java4.dir"/>
+                <root id="src.resources3.dir"/>
             </source-roots>
             <test-roots/>
         </data>
--- a/build.gradle	Tue Jul 09 18:33:45 2013 +0400
+++ b/build.gradle	Wed Jul 10 11:01:52 2013 +0400
@@ -688,6 +688,16 @@
                 linkTask.dependsOn rcTask;
             }
         }
+
+        def useLipo = targetProperties.containsKey('useLipo') ? targetProperties.useLipo : false
+        if (useLipo) {
+            def lipoTask = project.task("lipo${t.capital}$capitalName", type: LipoTask, dependsOn: javahTask, group: "Build") {
+                description = "Creates native fat library for $name for ${t.name}"
+                libDir = file("$libRootDir/${t.name}")
+                lib = file("$libRootDir/${t.name}/${library(properties.lib)}")
+            }
+            nativeTask.dependsOn(lipoTask)
+        }
     }
 }
 
@@ -748,6 +758,47 @@
 *        Project definitions (dependencies, etc)                             *
 *****************************************************************************/
 
+void addJCov(p, test) {
+    test.doFirst {
+        def jcovJVMArgument =
+                "include=javafx," +
+                "include=com.sun.javafx," +
+                "include=com.sun.glass," +
+                "include=com.sun.openpisces," +
+                "include=com.sun.pisces," +
+                "include=com.sun.prism," +
+                "include=com.sun.scenario," +
+                "include=com.sun.webkit," +
+                "exclude=com," +
+                "exclude=java," +
+                "exclude=javax," +
+                "exclude=\"**.test\"," +
+                "exclude=\"**.*Test\"," +
+                "file=build/reports/jcov/report.xml," +
+                "merge=merge";
+        test.jvmArgs("-javaagent:${p.configurations.testCompile.files.find { it.name.startsWith('jcov') }}=$jcovJVMArgument");
+        p.mkdir p.file("build/reports/jcov")
+    }
+    test.doLast {
+        def reportFile = p.file("build/reports/jcov/report.xml")
+        if (reportFile.exists()) {
+            p.javaexec {
+                workingDir = p.file("build/reports/jcov")
+                classpath = p.files(p.configurations.testCompile.files.find { it.name.startsWith('jcov') })
+                main = "com.sun.tdk.jcov.Helper"
+                args = [
+                        "RepGen",
+                        "-exclude", "\"**.test\"",
+                        "-exclude", "\"**.*Test\"",
+                        "-output", ".",
+                        "-source", p.sourceSets.main.java.srcDirs.collect{p.file(it)}.join(":"),
+                        "report.xml"
+                ]
+            }
+        }
+    }
+}
+
 allprojects {
     // We want to configure all projects as java projects and use the same compile settings
     // etc, except for the root project which we just want to ignore (and for now media)
@@ -783,7 +834,8 @@
     // By default all of our projects require junit for testing so we can just
     // setup this dependency here.
     dependencies {
-        testCompile(group: "junit", name: "junit", version: "4.8.2");
+        testCompile group: "junit", name: "junit", version: "4.8.2"
+        if (BUILD_CLOSED) testCompile name: "jcov"
     }
 
     // At the moment the ASM library shipped with Gradle that is used to
@@ -802,6 +854,9 @@
         include("**/*Test.*");
         exclude("**/DepthTest.*");
         exclude("**/*Abstract*.*");
+        if (BUILD_CLOSED) {
+            addJCov(project, test)
+        }
     }
 
     // Exclude any non-public-API classes from having javadoc generated. This block is used
@@ -1119,6 +1174,9 @@
         test.scanForTestClasses = false
         test.include "**/*Test.*"
         test.exclude "**/*Abstract*.*"
+        if (BUILD_CLOSED) {
+            addJCov(project, test)
+        }
     }
     test.dependsOn testWithoutStub, testWithStub
 
@@ -1665,11 +1723,12 @@
              "modules/graphics/build/resources/jsl-prism");
         if (COMPILE_SWING) from ("modules/swing/build/classes/main", "modules/swing/build/resources/main")
         if (COMPILE_SWT) from ("modules/swt/build/classes/main", "modules/swt/build/resources/main")
-        ///if (COMPILE_WEBKIT)
-        if (t.name != 'android') {
+        if (t.name == 'android') {
+            from ("modules/web/build/classes/android", "modules/web/build/resources/android")
+        } else if (t.name == 'ios') {
+            from ("modules/web/build/classes/ios", "modules/web/build/resources/ios")
+        } else {
             from ("modules/web/build/classes/main", "modules/web/build/resources/main")
-        } else {
-            from ("modules/web/build/classes/android", "modules/web/build/resources/android")
         }
         exclude("js/**/*", // er...
                 "PrismLoaderBackend*", // More decora stuff
@@ -1692,9 +1751,10 @@
             // TODO instead of using copy everywhere, I probably want to use "sync" instead?
             // Copy all of the .dll / .so / .dylib native libraries into build/sdk/rt/lib/
             copy {
+                def useLipo = targetProperties.containsKey('useLipo') ? targetProperties.useLipo : false
                 from("modules/graphics/build/libs/jsl-decora/${t.name}/${library(targetProperties.decora.lib)}")
                 ['font', 'prism', 'prismSW', 'prismES2', 'glass', 'iio'].each { lib ->
-                    def variants = targetProperties[lib].containsKey('variants') ? targetProperties[lib].variants : [null]
+                    def variants = targetProperties[lib].containsKey('variants') && !useLipo ? targetProperties[lib].variants : [null]
                     variants.each { variant ->
                         def variantProperties = variant ? targetProperties[lib][variant] : targetProperties[lib]
                         println "modules/graphics/build/libs/$lib/$t.name/${library(variantProperties.lib)}"
@@ -1710,7 +1770,7 @@
                         from ("modules/web/src/main/native/WebKitLibraries/import/runtime")
                     }
                 } else {
-                    if (IS_MAC) from ("$LIBRARY_STUB/libjfxwebkit.dylib")
+                    if (IS_MAC && COMPILE_TARGETS != "ios") from ("$LIBRARY_STUB/libjfxwebkit.dylib")
                     else if (IS_WINDOWS) {
                         from ("$LIBRARY_STUB/jfxwebkit.dll")
                         from ("$LIBRARY_STUB/libxml2.dll")
@@ -1773,6 +1833,18 @@
         dependsOn(jfxrtTask)
         dependsOn(javadoc)
     }
+
+    def generateSymbols = targetProperties.containsKey('generateSymbols') ? targetProperties.generateSymbols : false
+    if (generateSymbols) {
+        def exportedSymbolsTask = project.task("exportedSymbols${t.capital}", type: ExportedSymbolsTask, dependsOn: sdkTask, group: "Build") {
+            description = "Generates exported symbols file for iOS build (from .a libraries)"
+            def libDirName = "build/${t.name}-sdk/rt/$targetProperties.libDest"
+            libDir = file("$libDirName")
+            outputFile = file("$libDirName/exported.symbols")
+        }
+        sdk.dependsOn(exportedSymbolsTask)
+    }
+
     sdk.dependsOn(sdkTask)
 }
 
@@ -1783,448 +1855,6 @@
     //    dependsOn subprojects.collect { project -> project.getTasksByName("check", true)}
     //}
 
-/******************************************************************************
- *                                                                            *
- *                 Generation of NetBeans Project Files                       *
- *                                                                            *
- *  This next section is responsible for setting up the work for generation   *
- *  of NetBeans project files. The developer needs to invoke                  *
- *                                                                            *
- *      gradle netbeans                                                       *
- *                                                                            *
- *  and all necessary project files will be generated. Note that unlike       *
- *  Eclipse and IDEA, NetBeans natively understands Gradle build files so     *
- *  the project files generated for NetBeans is limited to just shared        *
- *  configuration files. Make sure you have the latest stable release of      *
- *                                                                            *
- *  http://plugins.netbeans.org/plugin/44510/gradle-support                   *
- *                                                                            *
- *  for your version of the IDE.                                              *
- *                                                                            *
- *****************************************************************************/
-
-/*
-  <built-in-tasks>
-    <task>
-      <display-name>build</display-name>
-      <non-blocking>yes</non-blocking>
-      <task-names>
-        <name must-exist="no">build</name>
-      </task-names>
-      <task-jvm-args/>
-    </task>
-  </built-in-tasks>
-  <common-tasks>
-    <task>
-      <display-name>sdk</display-name>
-      <non-blocking>no</non-blocking>
-      <task-names>
-        <name must-exist="yes">tasks</name>
-      </task-names>
-      <task-jvm-args/>
-    </task>
-  </common-tasks>
-
- */
-
-task netBeans() {
-    description = "Creates the NetBeans project files for JavaFX"
-    group = "IDE"
-
-    doLast {
-        File nbGradleProperties = file(".nb-gradle-properties")
-        if (nbGradleProperties.exists()) nbGradleProperties.delete()
-        nbGradleProperties.createNewFile()
-        nbGradleProperties <<
-"""<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<gradle-project-properties>
-  <!--DO NOT EDIT THIS FILE! - Used by the Gradle plugin of NetBeans.-->
-  <source-encoding>UTF-8</source-encoding>
-  <target-platform-name>j2se</target-platform-name>
-  <target-platform>1.7</target-platform>
-  <source-level>1.7</source-level>
-  <script-platform>
-    <spec-name>j2se</spec-name>
-    <spec-version>1.7</spec-version>
-  </script-platform>
-  <gradle-home>?VER=1.4</gradle-home>
-  <license-header>
-    <name>OpenJFX</name>
-    <template>.nb-openjfx-template-license</template>
-    <property name="organization">OpenJFX</property>
-  </license-header>
-</gradle-project-properties>"""
-
-        File nbGradleTemplate = file(".nb-openjfx-template-license")
-        if (nbGradleTemplate.exists()) nbGradleTemplate.delete()
-        nbGradleTemplate.createNewFile()
-        nbGradleTemplate <<
-"""My License will reign supreme!"""
-    }
-}
-
-task cleanNetBeans() {
-    description = "Deletes generated NetBeans files"
-    group = "IDE"
-    doLast {
-        file(".nb-gradle-properties").delete()
-    }
-}
-
-/******************************************************************************
- *                                                                            *
- *                   Generation of IDEA Project Files                         *
- *                                                                            *
- *  This next section is responsible for setting up the work for generation   *
- *  of IntelliJ IDEA project files. The developer needs to invoke             *
- *                                                                            *
- *      gradle idea                                                           *
- *                                                                            *
- *  and all necessary project files will be generated.                        *
- *                                                                            *
- *****************************************************************************/
-
-allprojects {
-    apply plugin: 'idea'
-    if (project == rootProject || project.name == "media") return
-
-    // Also need to un-exclude the build-dir since we put stuff in it, and then re-exclude other stuff
-    if (rootProject.BINARY_STUB != null) {
-        configurations {
-          binaryStub
-          binaryStub.extendsFrom(compile)
-        }
-
-        dependencies {
-          binaryStub rootProject.BINARY_STUB
-        }
-    }
-
-    idea {
-        module {
-            inheritOutputDirs = true;
-            excludeDirs -= buildDir;
-            excludeDirs += [
-                    new File(buildDir, "classes"),
-                    new File(buildDir, "dependency-cache"),
-                    new File(buildDir, "libs"),
-                    new File(buildDir, "resources"),
-                    new File(buildDir, "tmp")];
-
-            if (rootProject.BINARY_STUB != null) {
-                scopes.COMPILE.plus += configurations.binaryStub
-
-                // Some hackery. I have to make sure the binary stub is the VERY LAST entry
-                // in the class path or things will be somewhat unpredictable
-                iml {
-                    withXml { xmlProvider ->
-                        def root = xmlProvider.asNode();
-                        // Find the <root url=".../jfxrt.jar!/" />. Walk up 3 steps to <orderEntry>
-                        def orderEntry = root.depthFirst().find { it.name() == "root" }.parent().parent().parent(); // && it.@url.contains(rootProject.files(rootProject.BINARY_STUB))
-                        if (orderEntry.name() != "orderEntry") throw new Exception("Couldn't find the order entry");
-                        // Move that <orderEntry> to be the last child of its parent.
-                        def parent = orderEntry.parent();
-                        parent.remove(orderEntry);
-                        parent.append(orderEntry);
-                    }
-                }
-            }
-        }
-    }
-}
-
-/**
- * I want to keep all the project files and out directory and such all hidden from the filesystem
- * for the most part, so we don't have a lot of .iml files strewn about. So what we will do is
- * to redirect all of the .iml files into a .idea directory on the root project level, and stash the
- * out/ for all the projects there as well as the project module definition files.
- */
-idea {
-    project {
-        jdkName = "JavaFX 1.7"
-        languageLevel = "1.7"
-        wildcards += ["?*.css", "?*.bss", "?*.glsl", "?*.frag", "?*.ttf", "?*.txt", "?*.fxml"]
-        ipr {
-            withXml { xmlProvider ->
-                def root = xmlProvider.asNode();
-                def doc = root.depthFirst();
-
-                // Set the copyright
-                def copyrightManager = doc.find { it.name() == "component" && it.@name == "CopyrightManager" };
-                copyrightManager.@default="OpenJFX";
-                def module2copyright = copyrightManager.get("module2copyright");
-                module2copyright.replaceNode {
-                    copyright {
-                        option(name: "notice", value:
-"""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.""");
-                        option(name: "keyword", value: "Copyright");
-                        option(name: "allowReplaceKeyword", value: "");
-                        option(name: "myName", value: "OpenJFX");
-                        option(name: "myLocal", value: "true");
-                    }
-                }
-
-                // Remove some setting and change the project output directory
-                def projectRootManager = doc.find { it.name() == "component" && it.@name == "ProjectRootManager" };
-                projectRootManager.attributes.remove("assert-jdk-15");
-                projectRootManager.children()[0].@url = "file://\$PROJECT_DIR\$/.idea-out";
-
-                // Add in some custom dictionary stuff so that people get fewer green-squigglies
-                // in their code. Nothing like a green squiggly to ruin my day.
-                copyrightManager.plus {
-                    component(name: "ProjectDictionaryState") {
-                        dictionary(name: "javafx") {
-                            words {
-                                w (text: "backoff")
-                                w (text: "blhr")
-                                w (text: "blvr")
-                                w (text: "brhr")
-                                w (text: "brvr")
-                                w (text: "gradle")
-                                w (text: "gzip")
-                                w (text: "halignment")
-                                w (text: "interpolator")
-                                w (text: "jfxrt")
-                                w (text: "multithreaded")
-                                w (text: "redoable")
-                                w (text: "resized")
-                                w (text: "squigglies")
-                                w (text: "subclassing")
-                                w (text: "timeline")
-                                w (text: "timeline's")
-                                w (text: "tlhr")
-                                w (text: "tlvr")
-                                w (text: "trhr")
-                                w (text: "trvr")
-                                w (text: "unmanaged")
-                                w (text: "unselect")
-                                w (text: "urlencoded")
-                                w (text: "valignment")
-                            }
-                        }
-                    }
-                }
-
-                // Setup some common project settings like tabs vs. spaces
-                copyrightManager.plus {
-                    component(name: "CodeStyleSettingsManager") {
-                        option(name: "PER_PROJECT_SETTINGS") {
-                            value {
-                                ADDITIONAL_INDENT_OPTIONS(fileType: "java") {
-                                    option (name: "IDENT_SIZE", value: "4")
-                                    option (name: "CONTINUATION_INDENT_SIZE", value: "8")
-                                    option (name: "TAB_SIZE", value: "4")
-                                    option (name: "USE_TAB_CHARACTER", value: "false")
-                                    option (name: "SMART_TABS", value: "false")
-                                    option (name: "LABEL_INDENT_SIZE", value: "0")
-                                    option (name: "LABEL_INDENT_ABSOLUTE", value: "false")
-                                    option (name: "USE_RELATIVE_INDENTS", value: "false")
-                                }
-                                ADDITIONAL_INDENT_OPTIONS(fileType: "xml") {
-                                    option (name: "IDENT_SIZE", value: "4")
-                                    option (name: "CONTINUATION_INDENT_SIZE", value: "8")
-                                    option (name: "TAB_SIZE", value: "4")
-                                    option (name: "USE_TAB_CHARACTER", value: "false")
-                                    option (name: "SMART_TABS", value: "false")
-                                    option (name: "LABEL_INDENT_SIZE", value: "0")
-                                    option (name: "LABEL_INDENT_ABSOLUTE", value: "false")
-                                    option (name: "USE_RELATIVE_INDENTS", value: "false")
-                                }
-                            }
-                        }
-                    }
-                }
-            }
-        }
-    }
-}
-
-//project("buildSrc") {
-//    // Add antlr to the sources for IDEA
-//    idea {
-//        module {
-//            sourceDirs += file("$buildDir/generated-src/antlr")
-//        }
-//    }
-//}
-
-project(":base") {
-    // Add in the version-info generated sources for IDEA projects
-    idea {
-        module {
-            sourceDirs += file("$buildDir/generated-src/version-info")
-        }
-    }
-}
-
-// TODO need to do the iOS stuff (ios package of prism-es2-native, ios package of javafx-iio-native javafx-font-native)
-
-project(":graphics") {
-    idea {
-        module {
-            sourceDirs += [file("$buildDir/generated-src/headers"),
-                    file("src/main/native-decora"),
-                    file("src/main/native-glass/gtk"),
-                    file("src/main/native-glass/ios"),
-                    file("src/main/native-glass/lens"),
-                    file("src/main/native-glass/mac"),
-                    file("src/main/native-glass/win"),
-                    file("src/main/native-prism"),
-                    file("src/main/native-prism-sw")]
-            // TODO generated JSL directories need to be added
-//            sourceDirs += file("$buildDir/generated-src/jsl")
-//            sourceDirs += file("$buildDir/generated-src/jsl")
-            excludeDirs += new File(buildDir, "native");
-            testSourceDirs += [file("src/stub/java"), file("src/stub/resources")];
-        }
-    }
-}
-
-project(":controls") {
-    idea {
-        module {
-            sourceDirs += file("src/main/dt");
-        }
-    }
-}
-
-cleanIdeaWorkspace.group = "IDE"
-cleanIdeaWorkspace.description = "Deletes the javafx.ipw file"
-
-
-/******************************************************************************
- *                                                                            *
- *                   Generation of Eclipse Project Files                      *
- *                                                                            *
- *  This next section is responsible for setting up the work for generation   *
- *  of Eclipse project files. The developer needs to get the Gradle IDE from  *
- *  the SpringSource update site:                                             *
- *                                                                            *
- *      http://dist.springsource.com/release/TOOLS/gradle                     *
- *                                                                            *
- *  and all project files will be generated when javafx is imported into the  *
- *  workspace.  Note that 'gradle eclipse' does not generate good results at  *
- *  this time so the Eclipse plugin is recommended.                           *
- *                                                                            *
- *****************************************************************************/
-
-//TODO - default setting for Eclipse IDE (spaces vs. tabs etc.)
-allprojects {
-    apply plugin: "eclipse"
-    task afterEclipseImport {
-        ext.srcFile = file('.classpath')
-        inputs.file srcFile
-        outputs.dir srcFile
-        onlyIf { srcFile.exists() }
-        doLast {
-            def classpath = new XmlParser().parse(srcFile)
-
-            // Temporary code:  Until full support for JDK8 is released for Eclipse, some expressions
-            // involving generics won't compile.  Builders inclues some exmaples of this.  The fix is
-            // to use the jar that was compiled by the JDK rather than source from Eclipse
-            if (project.name == 'builders') {
-                Node source = classpath.classpathentry.find {it.@path == 'src/main/java'}
-                if (source) {
-                    source.@kind="lib"
-                    source.@exported="true"
-                    source.@path="build/libs/builders.jar"
-                    source.@sourcepath="src/main/java"
-                }
-            }
-
-            // Add an optional reference to the closed runtime repository and the generated source to graphics
-            if (project.name == "graphics") {
-                classpath.appendNode('classpathentry', [kind: 'src', exported: 'true', path: '/builders'])
-                classpath.appendNode('classpathentry', [kind: 'src', exported: 'true', path: 'build/generated-src/jsl-decora'])
-                classpath.appendNode('classpathentry', [kind: 'src', exported: 'true', path: 'build/generated-src/jsl-prism'])
-                classpath
-                    .appendNode('classpathentry', [kind: 'src', exported: 'true', path: '/rt-closed'])
-                    .appendNode('attributes')
-                    .appendNode('attribute', [name: 'optional', value: 'true'])
-            }
-
-            // Add an optional reference to the closed media repository
-            if (project.name == 'media') {
-                //TODO - remove rt when legacy build goes away
-                def list = ['jfxmedia/src', 'test/demos/JavaTestApps/src', 'test/perf/JFXMediaSystemTestApp/src', '/rt', '/rt-closed']
-                for (string in list) {
-                    Node node = classpath.classpathentry.find {it.@path == string}
-                    if (!node) {
-                        classpath
-                            .appendNode('classpathentry', [kind: 'src', exported: 'true', path: string])
-                            .appendNode('attributes')
-                            .appendNode('attribute', [name: 'optional', value: 'true'])
-                    }
-                }
-            }
-
-            // Temporary code: The Eclipse gradle plugin fails when BUILD_CLOSED = true.  This means
-            // that projects must be imported into Eclipse in two passes, first with BUILD_CLOSED = false, 
-            // then with BUILD_CLOSED = true.  The classpath to media and web need to be fixed up during
-            // the second pass when these projects are imported 
-            if (project.name == 'builders') {
-                Node node = classpath.classpathentry.find {it.@path == '/web'}
-                if (!node) {
-                    classpath
-                        .appendNode('classpathentry', [kind: 'src', exported: 'true', path: '/web'])
-                        .appendNode('attributes')
-                        .appendNode('attribute', [name: 'optional', value: 'true'])
-                }
-            }
-            if (project.name == 'media') {
-                Node node = classpath.classpathentry.find {it.@path == '/controls'}
-                if (!node) {
-                    classpath
-                        .appendNode('classpathentry', [kind: 'src', exported: 'true', path: '/controls'])
-                        .appendNode('attributes')
-                        .appendNode('attribute', [name: 'optional', value: 'true'])
-                }
-            }
-            if (project.name == 'web') {
-                def list = ['src/main/java', '/controls', '/media']
-                for (string in list) {
-                    Node node = classpath.classpathentry.find {it.@path == string}
-                    if (!node) {
-                        classpath
-                            .appendNode('classpathentry', [kind: 'src', exported: 'true', path: string])
-                            .appendNode('attributes')
-                            .appendNode('attribute', [name: 'optional', value: 'true'])
-                    }
-                }
-            }
-            
-            // Add the standard Eclipse JUnit class path entry
-            Node node = classpath.classpathentry.find {it.@path == 'org.eclipse.jdt.junit.JUNIT_CONTAINER/4'}
-            if (!node) {
-                classpath.appendNode('classpathentry', [kind: 'con', path: 'org.eclipse.jdt.junit.JUNIT_CONTAINER/4'])
-            }
-            def writer = new FileWriter(srcFile)
-            new XmlNodePrinter(new PrintWriter(writer)).print(classpath)
-         }
-    }
-}
-
 /*
  * This clause changes the way we handle a build.gradle within ./apps
  * It does a few things:
@@ -2312,6 +1942,7 @@
         }
     }
 
+    compileJava.enabled = COMPILE_WEBKIT
     if (BUILD_CLOSED && COMPILE_GSTREAMER) {
         compileJava.dependsOn compileMediaJava
         compileJava.classpath += files(
@@ -2320,7 +1951,14 @@
     }
     compileJava.exclude "com/sun/javafx/webkit/drt/**/*"
 
-    test.enabled = false
+    test {
+        classpath += files("../../../artifacts/sdk/rt/lib/ext/jfxrt.jar")
+        doFirst {
+            classpath.each { p ->
+                print "Test CLASSPATH: ${p.getPath()}\n"
+            }
+        }
+    }
     
     task generateHeaders(dependsOn: compileJava) {
         doLast {
@@ -2474,9 +2112,20 @@
         }
     }
 
-    if (COMPILE_WEBKIT) {
-        jar.dependsOn compileGenerated
+    task copyClassesFromBinaryStub << {
+        copy {
+            from zipTree(BINARY_STUB.getSingleFile())
+            into "build/classes/main"
+            include("javafx/scene/web/**",
+                "com/sun/javafx/scene/web/**",
+                "com/sun/webkit/**",
+                "com/sun/javafx/webkit/**",
+                "netscape/javascript/**",
+                "com/sun/javafx/sg/prism/NGWebView*")
+        }
     }
+
+    jar.dependsOn (COMPILE_WEBKIT ? compileGenerated : copyClassesFromBinaryStub)
     
     clean << {
         project.delete(
--- a/build.properties	Tue Jul 09 18:33:45 2013 +0400
+++ b/build.properties	Wed Jul 10 11:01:52 2013 +0400
@@ -52,5 +52,5 @@
 ##############################################################################
 
 jfx.build.jdk.version=1.8.0
-jfx.build.jdk.buildnum=95
+jfx.build.jdk.buildnum=97
 jfx.build.jdk.buildnum.min=91
--- a/buildSrc/android.gradle	Tue Jul 09 18:33:45 2013 +0400
+++ b/buildSrc/android.gradle	Wed Jul 10 11:01:52 2013 +0400
@@ -145,6 +145,10 @@
     }
 
     afterEvaluate {
+        if (!BUILD_CLOSED) {
+            logger.warn("OpenJFX build. Skipping webkit build on Android.")
+            return
+        }
         def compileWebJavaAndroid = task("compileWebJavaAndroid",
             type: JavaCompile, group: "Build") {
             
--- a/buildSrc/ios.gradle	Tue Jul 09 18:33:45 2013 +0400
+++ b/buildSrc/ios.gradle	Wed Jul 10 11:01:52 2013 +0400
@@ -29,11 +29,20 @@
 IOS.canBuild = IS_MAC
 if (!IOS.canBuild) return;
 
+IOS.artifactsName = "ios"
+
 IOS.compileSwing = false;
 IOS.compileSWT = false;
 IOS.compileFXPackager = false;
 IOS.compileDesignTime = false;
 
+defineProperty("USE_LIPO", "false")
+defineProperty("GENERATE_SYMBOLS", "false")
+if (USE_LIPO instanceof String) IOS.useLipo = Boolean.parseBoolean(USE_LIPO)
+if (GENERATE_SYMBOLS instanceof String) IOS.generateSymbols = Boolean.parseBoolean(GENERATE_SYMBOLS)
+
+defineProperty("IOS_VERSION", "6.1")
+
 // Lambda for naming the generated libs
 IOS.library = { name -> return "lib${name}.a" as String }
 
@@ -73,19 +82,20 @@
 def iPhoneSim = "iPhoneSimulator"
 
 String sdkPath(String platform) {
-    return "/Applications/Xcode.app/Contents/Developer/Platforms/${platform}.platform/Developer/SDKs/${platform}6.1.sdk";
+    return "/Applications/Xcode.app/Contents/Developer/Platforms/${platform}.platform/Developer/SDKs/${platform}${IOS_VERSION}.sdk";
 }
 
 def linkFlags = [
     "-static",
     "-framework", "Foundation",
     "-framework", "CoreGraphics",
+    "-framework", "CoreText",
     "-framework", "UIKit",
     "-framework", "QuartzCore",
     "-framework", "OpenGLES"].flatten()
 
 def ccFlags = [
-    "-miphoneos-version-min=6.1", "-fmessage-length=0", "-std=c99", "-fno-common",
+    "-miphoneos-version-min=6.0", "-fmessage-length=0", "-std=c99", "-fno-common",
     "-Wall", "-fno-strict-aliasing", "-fwrapv", "-fpascal-strings", "-fobjc-abi-version=2", "-fobjc-legacy-dispatch",
     "-I$JDK_HOME/include", "-I$JDK_HOME/include/darwin", "-c",
     IS_DEBUG ? "-DDEBUG" : ["-O3", "-DNDEBUG"]].flatten()
@@ -125,6 +135,7 @@
 IOS.decora.lib = "decora-sse-${archArm}"
 
 IOS.prism = [:]
+IOS.prism.lib = "prism-common"
 IOS.prism.javahInclude = ["com/sun/prism/impl/**/*", "com/sun/prism/PresentableState*"]
 IOS.prism.variants = ["arm", "x86"];
 
@@ -145,6 +156,7 @@
 IOS.prism.x86.lib = "prism-common-${archX86}"
 
 IOS.prismSW = [:]
+IOS.prismSW.lib = "prism-sw"
 IOS.prismSW.javahInclude = ["com/sun/pisces/**/*"]
 IOS.prismSW.variants = ["arm", "x86"];
 
@@ -165,6 +177,7 @@
 IOS.prismSW.x86.lib = "prism-sw-${archX86}"
 
 IOS.iio = [:]
+IOS.iio.lib = "javafx-iio"
 IOS.iio.javahInclude = ["com/sun/javafx/iio/**/*"]
 IOS.iio.variants = ["arm", "x86"];
 
@@ -188,6 +201,7 @@
 IOS.iio.x86.lib = "javafx-iio-${archX86}"
 
 IOS.prismES2 = [:]
+IOS.prismES2.lib = "prism-es2"
 IOS.prismES2.javahInclude = ["com/sun/prism/es2/**/*"]
 IOS.prismES2.variants = ["arm", "x86"];
 
@@ -213,6 +227,7 @@
 
 def closedDir = file("$projectDir/../rt-closed")
 IOS.font = [:]
+IOS.font.lib = "javafx-font"
 IOS.font.javahInclude = [
         "com/sun/javafx/font/**/*",
         "com/sun/javafx/text/**/*"]
@@ -235,6 +250,7 @@
 IOS.font.x86.lib = "javafx-font-${archX86}"
 
 IOS.fontT2K = [:]
+IOS.fontT2K.lib = "javafx-font-t2k"
 IOS.fontT2K.javahInclude = ["com/sun/javafx/font/t2k/**/*"]
 IOS.fontT2K.variants = ["arm", "x86"];
 
@@ -256,3 +272,79 @@
 IOS.fontT2K.x86.linker = linker
 IOS.fontT2K.x86.linkFlags = ["-arch_only", archX86, "-syslibroot", sdkPath(iPhoneSim), linkFlags].flatten()
 IOS.fontT2K.x86.lib = "javafx-font-t2k-${archX86}"
+
+IOS.webview = [:]
+IOS.webview.lib = "javafx-ios-webnode"
+IOS.webview.javahInclude = ["javafx/scene/web/*"]
+IOS.webview.variants = ["arm", "x86"];
+
+IOS.webview.arm = [:]
+IOS.webview.arm.nativeSource = file("$closedDir/javafx-ios-webnode/native")
+IOS.webview.arm.compiler = compiler
+IOS.webview.arm.ccFlags = [ccFlags, "-arch", archArm, "-isysroot", sdkPath(iPhoneOS)].flatten()
+IOS.webview.arm.linker = linker
+IOS.webview.arm.linkFlags = ["-arch_only", archArm, "-syslibroot", sdkPath(iPhoneOS), linkFlags].flatten()
+IOS.webview.arm.lib = "javafx-ios-webnode-${archArm}"
+
+IOS.webview.x86 = [:]
+IOS.webview.x86.nativeSource = [IOS.webview.arm.nativeSource].flatten()
+IOS.webview.x86.compiler = compiler
+IOS.webview.x86.ccFlags = [ccFlags, "-arch", archX86, "-isysroot", sdkPath(iPhoneSim)].flatten()
+IOS.webview.x86.linker = linker
+IOS.webview.x86.linkFlags = ["-arch_only", archX86, "-syslibroot", sdkPath(iPhoneSim), linkFlags].flatten()
+IOS.webview.x86.lib = "javafx-ios-webnode-${archX86}"
+
+project(":web") {
+    if (BUILD_CLOSED) {
+        apply plugin: 'java'
+
+        compileJava {
+            enabled = false
+        }
+
+        afterEvaluate {
+            def compileWebJavaIos = task("compileWebJavaIos",
+                type: JavaCompile, group: "Build") {
+
+                dependsOn(project(":graphics").classes, project(":base").classes)
+                description = "Task compiles web component for iOS."
+                classpath = files(
+                    project(":controls").sourceSets.main.output.classesDir,
+                    project(":graphics").sourceSets.main.output.classesDir,
+                    project(":base").sourceSets.main.output.classesDir
+                )
+                destinationDir = file("modules/web/build/classes/ios")
+                dependencyCacheDir = file("modules/web/build/dependency-cache")
+                source file("$closedDir/javafx-ios-webnode/src")
+            }
+
+            def jarWebJavaIos = task("jarWebJavaIos",
+                type: Jar, group: "Build") {
+                description = "Creates web.jar for iOS."
+                dependsOn(compileWebJavaIos)
+                archiveName = "web.jar"
+                includeEmptyDirs = false
+                destinationDir = project.file("build/libs/ios")
+                from("build/classes/ios")
+            }
+
+            addNative(project, "webview")
+            javahIosWebview.dependsOn(compileWebJavaIos)
+
+            jfxrtIos {
+                from "modules/web/build/classes/ios"
+            }
+
+            sdkIos  {
+                dependsOn(jarWebJavaIos)
+                doLast {
+                    def props = project.ext["IOS"]
+                    copy {
+                        from ("modules/web/build/libs/webview/ios/${props.library(props.webview.lib)}")
+                        into ("build/ios-sdk/rt/${props.libDest}")
+                    }
+                }
+            }
+        }
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/buildSrc/src/main/groovy/com/sun/javafx/gradle/ExportedSymbolsTask.groovy	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,73 @@
+/*
+ * 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.
+ */
+
+import org.gradle.api.DefaultTask
+import org.gradle.api.tasks.InputDirectory
+import org.gradle.api.tasks.OutputFile
+import org.gradle.api.tasks.TaskAction
+
+class ExportedSymbolsTask extends DefaultTask {
+    @OutputFile File outputFile;
+    @InputDirectory File libDir;
+
+
+    @TaskAction void generateExportedSymbols() {
+        // Get symbols only from .a libraries
+        List<String> libNames = [];
+        List<File> files = libDir.listFiles();
+        files.each { file ->
+            if (!file.isDirectory() && file.getName().endsWith(".a")) {
+                libNames.add(file.getAbsolutePath())
+            }
+        }
+
+        def baos = new ByteArrayOutputStream();
+
+        // Execute nm on .a libraries
+        project.exec({
+            commandLine("nm", "-jg");
+            args(libNames);
+            setStandardOutput(baos);
+        });
+
+        def bais = new ByteArrayInputStream(baos.toByteArray());
+
+        outputFile.withWriter { out ->
+            bais.eachLine { line ->
+                // Remove unnecessary lines
+                line = (line =~ /^(?!(_Java|_JNI_)).*$/).replaceFirst("");
+                line = (line =~ /^(_Java|_JNI_).*(.eh)$/).replaceFirst("");
+
+                if (!line.isEmpty()) {
+                    out.writeLine(line);
+                }
+            }
+        }
+
+        baos.close();
+        bais.close();
+    }
+}
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/buildSrc/src/main/groovy/com/sun/javafx/gradle/LipoTask.groovy	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,52 @@
+/*
+ * 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.
+ */
+
+import org.gradle.api.DefaultTask
+import org.gradle.api.tasks.InputDirectory
+import org.gradle.api.tasks.OutputFile
+import org.gradle.api.tasks.TaskAction
+
+
+class LipoTask extends DefaultTask {
+    @InputDirectory File libDir;
+    @OutputFile File lib;
+    @TaskAction void compile() {
+        List<String> libNames = [];
+        List<File> files = libDir.listFiles();
+        files.each { file ->
+            String fileName = file.getName();
+            // process only thin libraries
+            if (!file.isDirectory() && (fileName.indexOf("armv7") != -1 || fileName.indexOf("i386") != -1)) {
+                libNames.add(file.getAbsolutePath())
+            }
+        }
+        // Create a fat library (.a)
+        project.exec({
+            commandLine("lipo", "-create", "-output", "$lib");
+            args(libNames);
+        });
+    }
+}
+
--- a/buildSrc/win.gradle	Tue Jul 09 18:33:45 2013 +0400
+++ b/buildSrc/win.gradle	Wed Jul 10 11:01:52 2013 +0400
@@ -59,7 +59,7 @@
 ]
 
 def ccFlags = ["/nologo", "/W3", "/EHsc", "/c",
-        "/D_STATIC_CPP_LIB", "/D_DISABLE_DEPRECATE_STATIC_CPPLIB", "/DINLINE=__inline",
+        "/D_STATIC_CPPLIB", "/D_DISABLE_DEPRECATE_STATIC_CPPLIB", "/DINLINE=__inline",
         "/DUNICODE", "/D_UNICODE", "/DWIN32", "/DIAL", "/D_LITTLE_ENDIAN", "/DWIN32_LEAN_AND_MEAN",
         "/I$JDK_HOME/include", "/I$JDK_HOME/include/win32", "/arch:SSE", "/fp:fast",
         IS_DEBUG ? ["/MDd", "/Od", "/Zi", "/DDEBUG"] : ["/O2", "/MD"]].flatten();
--- a/idea/.idea/.name	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,1 +0,0 @@
-rt
\ No newline at end of file
--- a/idea/.idea/compiler.xml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project version="4">
-  <component name="CompilerConfiguration">
-    <option name="DEFAULT_COMPILER" value="Javac" />
-    <excludeFromCompile>
-      <file url="file://$PROJECT_DIR$/../../../deploy/javafx-deploy-samples/src/helloworld/HelloFullscreen.java" />
-      <file url="file://$PROJECT_DIR$/../../../deploy/javafx-deploy-samples/src/helloworld/HelloFullscreenToggle.java" />
-    </excludeFromCompile>
-    <resourceExtensions />
-    <wildcardResourcePatterns>
-      <entry name="!?*.java" />
-      <entry name="!?*.form" />
-      <entry name="!?*.class" />
-      <entry name="!?*.groovy" />
-      <entry name="!?*.scala" />
-      <entry name="!?*.flex" />
-      <entry name="!?*.kt" />
-      <entry name="!?*.clj" />
-    </wildcardResourcePatterns>
-    <annotationProcessing>
-      <profile default="true" name="Default" enabled="false">
-        <processorPath useClasspath="true" />
-      </profile>
-    </annotationProcessing>
-  </component>
-</project>
-
--- a/idea/.idea/copyright/profiles_settings.xml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,5 +0,0 @@
-<component name="CopyrightManager">
-  <settings default="">
-    <module2copyright />
-  </settings>
-</component>
\ No newline at end of file
--- a/idea/.idea/encodings.xml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project version="4">
-  <component name="Encoding" useUTFGuessing="true" native2AsciiForPropertiesFiles="false" />
-</project>
-
--- a/idea/.idea/gradle.xml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project version="4">
-  <component name="GradleSettings">
-    <option name="linkedProjectPath" value="" />
-    <option name="useAutoImport" value="false" />
-  </component>
-</project>
-
--- a/idea/.idea/misc.xml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project version="4">
-  <component name="EntryPointsManager">
-    <entry_points version="2.0" />
-  </component>
-  <component name="IdProvider" IDEtalkID="9BC0DE4049720C1246C2D3B835C6F7C3" />
-  <component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" assert-keyword="true" jdk-15="true" project-jdk-name="1.8" project-jdk-type="JavaSDK">
-    <output url="file://$PROJECT_DIR$/out" />
-  </component>
-</project>
-
--- a/idea/.idea/modules.xml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project version="4">
-  <component name="ProjectModuleManager">
-    <modules>
-      <module fileurl="file://$PROJECT_DIR$/3DViewer.iml" filepath="$PROJECT_DIR$/3DViewer.iml" />
-      <module fileurl="file://$PROJECT_DIR$/Ensemble8.iml" filepath="$PROJECT_DIR$/Ensemble8.iml" />
-      <module fileurl="file://$PROJECT_DIR$/Modena.iml" filepath="$PROJECT_DIR$/Modena.iml" />
-      <module fileurl="file://$PROJECT_DIR$/base.iml" filepath="$PROJECT_DIR$/base.iml" />
-      <module fileurl="file://$PROJECT_DIR$/buildSrc.iml" filepath="$PROJECT_DIR$/buildSrc.iml" />
-      <module fileurl="file://$PROJECT_DIR$/builders.iml" filepath="$PROJECT_DIR$/builders.iml" />
-      <module fileurl="file://$PROJECT_DIR$/controls.iml" filepath="$PROJECT_DIR$/controls.iml" />
-      <module fileurl="file://$PROJECT_DIR$/deploy.iml" filepath="$PROJECT_DIR$/deploy.iml" />
-      <module fileurl="file://$PROJECT_DIR$/designTime.iml" filepath="$PROJECT_DIR$/designTime.iml" />
-      <module fileurl="file://$PROJECT_DIR$/fxml.iml" filepath="$PROJECT_DIR$/fxml.iml" />
-      <module fileurl="file://$PROJECT_DIR$/fxpackager.iml" filepath="$PROJECT_DIR$/fxpackager.iml" />
-      <module fileurl="file://$PROJECT_DIR$/graphics.iml" filepath="$PROJECT_DIR$/graphics.iml" />
-      <module fileurl="file://$PROJECT_DIR$/media.iml" filepath="$PROJECT_DIR$/media.iml" />
-      <module fileurl="file://$PROJECT_DIR$/rt.iml" filepath="$PROJECT_DIR$/rt.iml" />
-      <module fileurl="file://$PROJECT_DIR$/rt-closed.iml" filepath="$PROJECT_DIR$/rt-closed.iml" />
-      <module fileurl="file://$PROJECT_DIR$/swing.iml" filepath="$PROJECT_DIR$/swing.iml" />
-      <module fileurl="file://$PROJECT_DIR$/swt.iml" filepath="$PROJECT_DIR$/swt.iml" />
-      <module fileurl="file://$PROJECT_DIR$/web.iml" filepath="$PROJECT_DIR$/web.iml" />
-    </modules>
-  </component>
-</project>
-
--- a/idea/.idea/scopes/scope_settings.xml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,5 +0,0 @@
-<component name="DependencyValidationManager">
-  <state>
-    <option name="SKIP_IMPORT_STATEMENTS" value="false" />
-  </state>
-</component>
\ No newline at end of file
--- a/idea/.idea/uiDesigner.xml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,125 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project version="4">
-  <component name="Palette2">
-    <group name="Swing">
-      <item class="com.intellij.uiDesigner.HSpacer" tooltip-text="Horizontal Spacer" icon="/com/intellij/uiDesigner/icons/hspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="1" hsize-policy="6" anchor="0" fill="1" />
-      </item>
-      <item class="com.intellij.uiDesigner.VSpacer" tooltip-text="Vertical Spacer" icon="/com/intellij/uiDesigner/icons/vspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="1" anchor="0" fill="2" />
-      </item>
-      <item class="javax.swing.JPanel" icon="/com/intellij/uiDesigner/icons/panel.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3" />
-      </item>
-      <item class="javax.swing.JScrollPane" icon="/com/intellij/uiDesigner/icons/scrollPane.png" removable="false" auto-create-binding="false" can-attach-label="true">
-        <default-constraints vsize-policy="7" hsize-policy="7" anchor="0" fill="3" />
-      </item>
-      <item class="javax.swing.JButton" icon="/com/intellij/uiDesigner/icons/button.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="3" anchor="0" fill="1" />
-        <initial-values>
-          <property name="text" value="Button" />
-        </initial-values>
-      </item>
-      <item class="javax.swing.JRadioButton" icon="/com/intellij/uiDesigner/icons/radioButton.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
-        <initial-values>
-          <property name="text" value="RadioButton" />
-        </initial-values>
-      </item>
-      <item class="javax.swing.JCheckBox" icon="/com/intellij/uiDesigner/icons/checkBox.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
-        <initial-values>
-          <property name="text" value="CheckBox" />
-        </initial-values>
-      </item>
-      <item class="javax.swing.JLabel" icon="/com/intellij/uiDesigner/icons/label.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="0" anchor="8" fill="0" />
-        <initial-values>
-          <property name="text" value="Label" />
-        </initial-values>
-      </item>
-      <item class="javax.swing.JTextField" icon="/com/intellij/uiDesigner/icons/textField.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
-          <preferred-size width="150" height="-1" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JPasswordField" icon="/com/intellij/uiDesigner/icons/passwordField.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
-          <preferred-size width="150" height="-1" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JFormattedTextField" icon="/com/intellij/uiDesigner/icons/formattedTextField.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
-          <preferred-size width="150" height="-1" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JTextArea" icon="/com/intellij/uiDesigner/icons/textArea.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JTextPane" icon="/com/intellij/uiDesigner/icons/textPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JEditorPane" icon="/com/intellij/uiDesigner/icons/editorPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JComboBox" icon="/com/intellij/uiDesigner/icons/comboBox.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="2" anchor="8" fill="1" />
-      </item>
-      <item class="javax.swing.JTable" icon="/com/intellij/uiDesigner/icons/table.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JList" icon="/com/intellij/uiDesigner/icons/list.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="2" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JTree" icon="/com/intellij/uiDesigner/icons/tree.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JTabbedPane" icon="/com/intellij/uiDesigner/icons/tabbedPane.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
-          <preferred-size width="200" height="200" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JSplitPane" icon="/com/intellij/uiDesigner/icons/splitPane.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
-          <preferred-size width="200" height="200" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JSpinner" icon="/com/intellij/uiDesigner/icons/spinner.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
-      </item>
-      <item class="javax.swing.JSlider" icon="/com/intellij/uiDesigner/icons/slider.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
-      </item>
-      <item class="javax.swing.JSeparator" icon="/com/intellij/uiDesigner/icons/separator.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3" />
-      </item>
-      <item class="javax.swing.JProgressBar" icon="/com/intellij/uiDesigner/icons/progressbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1" />
-      </item>
-      <item class="javax.swing.JToolBar" icon="/com/intellij/uiDesigner/icons/toolbar.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1">
-          <preferred-size width="-1" height="20" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JToolBar$Separator" icon="/com/intellij/uiDesigner/icons/toolbarSeparator.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="0" anchor="0" fill="1" />
-      </item>
-      <item class="javax.swing.JScrollBar" icon="/com/intellij/uiDesigner/icons/scrollbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="0" anchor="0" fill="2" />
-      </item>
-    </group>
-  </component>
-</project>
-
--- a/idea/.idea/vcs.xml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project version="4">
-  <component name="VcsDirectoryMappings">
-    <mapping directory="" vcs="" />
-    <mapping directory="$PROJECT_DIR$/../../../deploy" vcs="hg4idea" />
-    <mapping directory="$PROJECT_DIR$/../../../rt-closed" vcs="hg4idea" />
-  </component>
-</project>
-
--- a/idea/3DViewer.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="EclipseModuleManager">
-    <libelement value="jar://$MODULE_DIR$/../apps/experiments/3DViewer/build/libs/3DViewer.jar!/" />
-    <src_description expected_position="0">
-      <src_folder value="file://$MODULE_DIR$/../apps/experiments/3DViewer/src/main/java" expected_position="0" />
-      <src_folder value="file://$MODULE_DIR$/../apps/experiments/3DViewer/src/test/java" expected_position="1" />
-      <src_folder value="file://$MODULE_DIR$/../apps/experiments/3DViewer/src/main/resources" expected_position="2" />
-      <src_folder value="file://$MODULE_DIR$/../apps/experiments/3DViewer/src/test/resources" expected_position="3" />
-    </src_description>
-  </component>
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../apps/experiments/3DViewer">
-      <sourceFolder url="file://$MODULE_DIR$/../apps/experiments/3DViewer/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../apps/experiments/3DViewer/src/main/resources" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../apps/experiments/3DViewer/src/test/java" isTestSource="true" />
-      <sourceFolder url="file://$MODULE_DIR$/../apps/experiments/3DViewer/src/test/resources" isTestSource="true" />
-      <excludeFolder url="file://$MODULE_DIR$/../apps/experiments/3DViewer/build" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module-library">
-      <library name="3DViewer.jar">
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../apps/experiments/3DViewer/build/libs/3DViewer.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module" module-name="rt" />
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/idea/Ensemble8.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,51 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="EclipseModuleManager">
-    <libelement value="jar://$MODULE_DIR$/../apps/samples/Ensemble8/lib/lucene-core-3.2.0.jar!/" />
-    <libelement value="jar://$MODULE_DIR$/../apps/samples/Ensemble8/lib/lucene-grouping-3.2.0.jar!/" />
-    <src_description expected_position="0">
-      <src_folder value="file://$MODULE_DIR$/../apps/samples/Ensemble8/src/app/java" expected_position="0" />
-      <src_folder value="file://$MODULE_DIR$/../apps/samples/Ensemble8/src/app/resources" expected_position="1" />
-      <src_folder value="file://$MODULE_DIR$/../apps/samples/Ensemble8/src/samples/java" expected_position="2" />
-      <src_folder value="file://$MODULE_DIR$/../apps/samples/Ensemble8/src/samples/resources" expected_position="3" />
-      <src_folder value="file://$MODULE_DIR$/../apps/samples/Ensemble8/src/compiletime/java" expected_position="4" />
-      <src_folder value="file://$MODULE_DIR$/../apps/samples/Ensemble8/src/generated/java" expected_position="5" />
-      <src_folder value="file://$MODULE_DIR$/../apps/samples/Ensemble8/src/generated/resources" expected_position="6" />
-    </src_description>
-  </component>
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../apps/samples/Ensemble8">
-      <sourceFolder url="file://$MODULE_DIR$/../apps/samples/Ensemble8/src/app/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../apps/samples/Ensemble8/src/app/resources" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../apps/samples/Ensemble8/src/samples/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../apps/samples/Ensemble8/src/samples/resources" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../apps/samples/Ensemble8/src/compiletime/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../apps/samples/Ensemble8/src/generated/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../apps/samples/Ensemble8/src/generated/resources" isTestSource="false" />
-      <excludeFolder url="file://$MODULE_DIR$/../apps/samples/Ensemble8/build" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module-library">
-      <library name="lucene-core-3.2.0.jar">
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../apps/samples/Ensemble8/lib/lucene-core-3.2.0.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library name="lucene-grouping-3.2.0.jar">
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../apps/samples/Ensemble8/lib/lucene-grouping-3.2.0.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module" module-name="rt" />
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/idea/Modena.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,15 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../apps/experiments/Modena">
-      <sourceFolder url="file://$MODULE_DIR$/../apps/experiments/Modena/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../apps/experiments/Modena/src/main/resources" isTestSource="false" />
-      <excludeFolder url="file://$MODULE_DIR$/../apps/experiments/Modena/build" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module" module-name="rt" />
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/idea/base.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../modules/base">
-      <sourceFolder url="file://$MODULE_DIR$/../modules/base/build/generated-src/version-info" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/base/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/base/src/main/resources" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/base/src/test/java" isTestSource="true" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/base/src/test/resources" isTestSource="true" />
-      <excludeFolder url="file://$MODULE_DIR$/../modules/base/build/classes" />
-      <excludeFolder url="file://$MODULE_DIR$/../modules/base/build/dependency-cache" />
-      <excludeFolder url="file://$MODULE_DIR$/../modules/base/build/libs" />
-      <excludeFolder url="file://$MODULE_DIR$/../modules/base/build/tmp" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module" module-name="buildSrc" exported="" />
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/idea/buildSrc.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,88 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="EclipseModuleManager">
-    <libelement value="jar://$MODULE_DIR$/../build/libs/ant-1.8.2.jar!/" />
-    <libelement value="jar://$MODULE_DIR$/../build/libs/antlr-3.1.3.jar!/" />
-    <libelement value="jar://$MODULE_DIR$/../build/libs/antlr-runtime-3.1.3.jar!/" />
-    <libelement value="jar://$MODULE_DIR$/../build/libs/stringtemplate-3.2.jar!/" />
-    <libelement value="jar://$MODULE_DIR$/../build/libs/swt-debug.jar!/" />
-    <src_description expected_position="0">
-      <src_folder value="file://$MODULE_DIR$/../buildSrc/build/generated-src/antlr" expected_position="0" />
-      <src_folder value="file://$MODULE_DIR$/../buildSrc/src/main/java" expected_position="1" />
-      <src_folder value="file://$MODULE_DIR$/../buildSrc/src/test/java" expected_position="2" />
-    </src_description>
-  </component>
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../buildSrc">
-      <sourceFolder url="file://$MODULE_DIR$/../buildSrc/build/generated-src/antlr" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../buildSrc/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../buildSrc/src/test/java" isTestSource="true" />
-      <sourceFolder url="file://$MODULE_DIR$/../buildSrc/src/test/resources" isTestSource="true" />
-      <excludeFolder url="file://$MODULE_DIR$/../buildSrc/.gradle" />
-      <excludeFolder url="file://$MODULE_DIR$/../buildSrc/build/classes" />
-      <excludeFolder url="file://$MODULE_DIR$/../buildSrc/build/dependency-cache" />
-      <excludeFolder url="file://$MODULE_DIR$/../buildSrc/build/libs" />
-      <excludeFolder url="file://$MODULE_DIR$/../buildSrc/build/resources" />
-      <excludeFolder url="file://$MODULE_DIR$/../buildSrc/build/test-results" />
-      <excludeFolder url="file://$MODULE_DIR$/../buildSrc/build/tmp" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module-library" exported="">
-      <library name="ant-1.8.2.jar">
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../build/libs/ant-1.8.2.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library" exported="">
-      <library name="antlr-3.1.3.jar">
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../build/libs/antlr-3.1.3.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library" exported="">
-      <library name="antlr-runtime-3.1.3.jar">
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../build/libs/antlr-runtime-3.1.3.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library" exported="">
-      <library name="stringtemplate-3.2.jar">
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../build/libs/stringtemplate-3.2.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library" exported="">
-      <library name="swt-debug.jar">
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../build/libs/swt-debug.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library" exported="">
-      <library name="junit4">
-        <CLASSES>
-          <root url="jar://$APPLICATION_HOME_DIR$/lib/junit-4.10.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/idea/builders.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,29 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="EclipseModuleManager">
-    <libelement value="jar://$MODULE_DIR$/../modules/builders/build/libs/builders.jar!/" />
-    <src_description expected_position="1">
-      <src_folder value="file://$MODULE_DIR$/../modules/builders/src/test/java" expected_position="1" />
-    </src_description>
-  </component>
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../modules/builders">
-      <excludeFolder url="file://$MODULE_DIR$/../modules/builders/build" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module-library" exported="">
-      <library name="builders.jar">
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../modules/builders/build/libs/builders.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES>
-          <root url="file://$MODULE_DIR$/../modules/builders/src/main/java" />
-        </SOURCES>
-      </library>
-    </orderEntry>
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/idea/controls.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../modules/controls">
-      <sourceFolder url="file://$MODULE_DIR$/../modules/controls/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/controls/src/main/resources" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/controls/src/test/java" isTestSource="true" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/controls/src/test/resources" isTestSource="true" />
-      <excludeFolder url="file://$MODULE_DIR$/../modules/controls/build" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module" module-name="base" exported="" />
-    <orderEntry type="module" module-name="designTime" exported="" />
-    <orderEntry type="module" module-name="graphics" exported="" />
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/idea/deploy.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,35 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="EclipseModuleManager">
-    <libelement value="jar://$MODULE_DIR$/../../deploy/cache/plugin_exports.jar!/" />
-    <src_description expected_position="0">
-      <src_folder value="file://$MODULE_DIR$/../../deploy/lib" expected_position="0" />
-      <src_folder value="file://$MODULE_DIR$/../../deploy/javafx-deploy/src" expected_position="1" />
-      <src_folder value="file://$MODULE_DIR$/../../deploy/javafx-deploy-samples/src" expected_position="2" />
-      <src_folder value="file://$MODULE_DIR$/../../deploy/javafx-launcher-demoapp/src" expected_position="3" />
-    </src_description>
-  </component>
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../../deploy">
-      <sourceFolder url="file://$MODULE_DIR$/../../deploy/lib" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../deploy/javafx-deploy/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../deploy/javafx-deploy-samples/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../deploy/javafx-launcher-demoapp/src" isTestSource="false" />
-      <excludeFolder url="file://$MODULE_DIR$/../../deploy/javafx-deploy-samples/src/helloworld" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module-library" exported="">
-      <library name="plugin_exports.jar">
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../deploy/cache/plugin_exports.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module" module-name="rt" exported="" />
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/idea/designTime.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,14 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../modules/designTime">
-      <sourceFolder url="file://$MODULE_DIR$/../modules/designTime/src/main/java" isTestSource="false" />
-      <excludeFolder url="file://$MODULE_DIR$/../modules/designTime/build" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module" module-name="graphics" exported="" />
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/idea/fxml.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../modules/fxml">
-      <sourceFolder url="file://$MODULE_DIR$/../modules/fxml/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/fxml/src/main/resources" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/fxml/src/test/java" isTestSource="true" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/fxml/src/test/resources" isTestSource="true" />
-      <excludeFolder url="file://$MODULE_DIR$/../modules/fxml/build" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module" module-name="base" exported="" />
-    <orderEntry type="module" module-name="controls" exported="" />
-    <orderEntry type="module" module-name="graphics" exported="" />
-    <orderEntry type="module" module-name="swing" exported="" />
-    <orderEntry type="module" module-name="swt" exported="" />
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/idea/fxpackager.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,15 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../modules/fxpackager">
-      <sourceFolder url="file://$MODULE_DIR$/../modules/fxpackager/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/fxpackager/src/main/resources" isTestSource="false" />
-      <excludeFolder url="file://$MODULE_DIR$/../modules/fxpackager/build" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module" module-name="graphics" exported="" />
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/idea/graphics.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../modules/graphics">
-      <sourceFolder url="file://$MODULE_DIR$/../modules/graphics/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/graphics/src/main/resources" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/graphics/src/stub/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/graphics/src/stub/resources" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/graphics/build/generated-src/jsl-decora" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/graphics/build/generated-src/jsl-prism" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/graphics/build/resources/jsl-decora" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/graphics/build/resources/jsl-prism" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/graphics/src/test/java" isTestSource="true" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/graphics/src/test/resources" isTestSource="true" />
-      <excludeFolder url="file://$MODULE_DIR$/../modules/graphics/build/classes" />
-      <excludeFolder url="file://$MODULE_DIR$/../modules/graphics/build/dependency-cache" />
-      <excludeFolder url="file://$MODULE_DIR$/../modules/graphics/build/libs" />
-      <excludeFolder url="file://$MODULE_DIR$/../modules/graphics/build/resources" />
-      <excludeFolder url="file://$MODULE_DIR$/../modules/graphics/build/tmp" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module" module-name="base" exported="" />
-    <orderEntry type="module" module-name="builders" exported="" />
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/idea/media.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../modules/media" />
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/idea/rt-closed.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,119 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="EclipseModuleManager">
-    <libelement value="jar://$MODULE_DIR$/../../caches/sdk/build/lib/desktop/jfxmedia.jar!/" />
-    <libelement value="file://../caches/sdk/build/lib/desktop/deploy.jar" />
-    <libelement value="jar://$MODULE_DIR$/../../import/swt-3.7.1/swt-debug.jar!/" />
-    <src_description expected_position="0">
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/benchmark/VMPerformance/src" expected_position="0" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/glass/glass-test/test" expected_position="1" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/glass/UseCases/src" expected_position="2" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/javafx-android/webnode/src" expected_position="3" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/javafx-font-t2k/src" expected_position="4" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/javafx-ios/src" expected_position="5" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/javafx-mx-common/src" expected_position="6" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/javafx-mx-impl/src" expected_position="7" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/javafx-mx-impl/test/unit" expected_position="8" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/javafx-ui-desktop/src" expected_position="9" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/porting/src" expected_position="10" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/prism-bench/src" expected_position="11" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/tests/security/ES2NativeTest/test" expected_position="12" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/tests/security/GetWindowsTest/test" expected_position="13" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/tests/security/LoaderDisposeTest/test" expected_position="14" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/tests/security/MediaFuzzing/src" expected_position="15" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/tests/security/MediaFuzzing/test" expected_position="16" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/BlendTest/src" expected_position="17" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/CameraTests/src" expected_position="18" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/CanvasTest/src" expected_position="19" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/ColorCube/src" expected_position="20" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/CursorFXTest/src" expected_position="21" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/DirectoryBrowser/src" expected_position="22" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/DragDropColor/src" expected_position="23" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/DragDropText/src" expected_position="24" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/DragDropWithControls/src" expected_position="25" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/EarthCubeFX2/src" expected_position="26" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/EmbeddedSwing/src" expected_position="27" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/FX8-3DAPI/src" expected_position="28" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/GlassRobotTest/src" expected_position="29" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/Gradients/src" expected_position="30" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/GridExamples/src" expected_position="31" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/HelloFXCanvas/src" expected_position="32" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/HelloWorld/src" expected_position="33" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/LinuxInputTest/src" expected_position="34" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/LinuxInputTest/test" expected_position="35" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/NodeBlendTests/src" expected_position="36" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/PickTest3D/src" expected_position="37" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/SceneLeak/src" expected_position="38" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/ShapeT3DTest/src" expected_position="39" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/SwingBalls/src" expected_position="40" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/SwingBalls/css" expected_position="41" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/SwingNodeMark/src" expected_position="42" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/TextTest/src" expected_position="43" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/TouchSuite/src" expected_position="44" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/VideoCube/src" expected_position="45" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/Visual3DTest/src" expected_position="46" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/WebLauncher/src" expected_position="47" />
-      <src_folder value="file://$MODULE_DIR$/../../rt-closed/toys/ZBufferTest/src" expected_position="48" />
-    </src_description>
-  </component>
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../../rt-closed">
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/benchmark/VMPerformance/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/glass/glass-test/test" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/glass/UseCases/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/javafx-android/webnode/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/javafx-font-t2k/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/javafx-ios/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/javafx-mx-common/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/javafx-mx-impl/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/javafx-mx-impl/test/unit" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/javafx-ui-desktop/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/porting/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/prism-bench/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/tests/security/ES2NativeTest/test" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/tests/security/GetWindowsTest/test" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/tests/security/LoaderDisposeTest/test" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/tests/security/MediaFuzzing/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/tests/security/MediaFuzzing/test" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/BlendTest/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/CameraTests/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/CanvasTest/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/ColorCube/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/CursorFXTest/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/DirectoryBrowser/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/DragDropColor/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/DragDropText/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/DragDropWithControls/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/EarthCubeFX2/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/EmbeddedSwing/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/FX8-3DAPI/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/GlassRobotTest/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/Gradients/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/GridExamples/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/HelloFXCanvas/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/HelloWorld/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/LinuxInputTest/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/LinuxInputTest/test" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/NodeBlendTests/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/PickTest3D/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/SceneLeak/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/ShapeT3DTest/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/SwingBalls/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/SwingBalls/css" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/SwingNodeMark/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/TextTest/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/TouchSuite/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/VideoCube/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/Visual3DTest/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/WebLauncher/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../../rt-closed/toys/ZBufferTest/src" isTestSource="false" />
-      <excludeFolder url="file://$MODULE_DIR$/../../rt-closed/javafx-android" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module" module-name="deploy" exported="" />
-    <orderEntry type="module" module-name="rt" exported="" />
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/idea/rt.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/..">
-      <excludeFolder url="file://$MODULE_DIR$/../.gradle" />
-      <excludeFolder url="file://$MODULE_DIR$/../build/libs" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module" module-name="fxml" exported="" />
-    <orderEntry type="module" module-name="fxpackager" exported="" />
-    <orderEntry type="module" module-name="swt" exported="" />
-    <orderEntry type="module" module-name="swing" exported="" />
-    <orderEntry type="module" module-name="media" exported="" />
-    <orderEntry type="module" module-name="web" exported="" />
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/idea/swing.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,15 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../modules/swing">
-      <sourceFolder url="file://$MODULE_DIR$/../modules/swing/src/main/java" isTestSource="false" />
-      <excludeFolder url="file://$MODULE_DIR$/../modules/swing/build" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module" module-name="base" exported="" />
-    <orderEntry type="module" module-name="graphics" exported="" />
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/idea/swt.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,15 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../modules/swt">
-      <sourceFolder url="file://$MODULE_DIR$/../modules/swt/src/main/java" isTestSource="false" />
-      <excludeFolder url="file://$MODULE_DIR$/../modules/swt/build" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module" module-name="base" exported="" />
-    <orderEntry type="module" module-name="graphics" exported="" />
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/idea/web.iml	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module type="JAVA_MODULE" version="4">
-  <component name="NewModuleRootManager" inherit-compiler-output="true">
-    <exclude-output />
-    <content url="file://$MODULE_DIR$/../modules/web">
-      <sourceFolder url="file://$MODULE_DIR$/../modules/web/src/main/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/web/src/main/native/WebKitBuild/Release/WebCore/generated/java" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/../modules/web/src/main/resources" isTestSource="false" />
-      <excludeFolder url="file://$MODULE_DIR$/../modules/web/build" />
-    </content>
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module" module-name="graphics" exported="" />
-    <orderEntry type="module" module-name="controls" exported="" />
-    <orderEntry type="module" module-name="media" exported="" />
-    <orderEntry type="module-library" exported="">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../caches/sdk/rt/lib/ext/jfxrt.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="inheritedJdk" />
-  </component>
-</module>
-
--- a/modules/fxpackager/src/main/native/launcher/win/WinLauncher.cpp	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/fxpackager/src/main/native/launcher/win/WinLauncher.cpp	Wed Jul 10 11:01:52 2013 +0400
@@ -845,6 +845,9 @@
     // Parse command line arguments to see if /Debug is there
     szArgList = CommandLineToArgvW(GetCommandLine(), &argCount);
 
+    // [RT-31061] otherwise UI can be left in back of other windows
+    AllowSetForegroundWindow(ASFW_ANY);
+
     enableDebugIfNeeded(argCount, szArgList);
 
     if (isDebug) {
--- a/modules/graphics/src/main/java/com/sun/glass/ui/mac/MacSystemClipboard.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/graphics/src/main/java/com/sun/glass/ui/mac/MacSystemClipboard.java	Wed Jul 10 11:01:52 2013 +0400
@@ -30,11 +30,11 @@
 import java.net.URL;
 import java.nio.ByteBuffer;
 import java.nio.IntBuffer;
+import java.nio.file.FileSystems;
 import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
-import java.util.Set;
 import com.sun.glass.ui.Application;
 import com.sun.glass.ui.Clipboard;
 import com.sun.glass.ui.Pixels;
@@ -48,7 +48,7 @@
     
     // if true we'll synthesize a file list
     static final boolean SUPPORT_10_5_API = true;
-    
+
     // if true we'll force the synthesized file list into 1st item as Plain text,
     // regardless of whether such attribute already exists or not
     static final boolean SUPPORT_10_5_API_FORCE = false;
@@ -101,32 +101,10 @@
                 switch (mime) {
                     case URI_TYPE:
                     {
-                        // synthesize list of urls as seperate pasteboard items (Mac OS 10.6 style)
-                        String split[] = ((String) object).split("\n");
-                        int count = 0;
-                        for (String string : split) {
-                            if (!string.startsWith("#")) {
-                                // exclude comments: http://www.ietf.org/rfc/rfc2483.txt
-                                count++;
-                            }
-                        }
-                        if (count > 0) {
-                            itemList = new HashMap[count];
-                            count = 0;
-                            for (String file : split) {
-                                if (!file.startsWith("#")) {
-                                    // exclude comments: http://www.ietf.org/rfc/rfc2483.txt
-                                    URI uri = createUri(file, MacSystemClipboard.BAD_URI_MSG);
-                                    String utf = MacPasteboard.UtfUrl;
-                                    if (uri.getScheme() == null) {
-                                        utf = MacPasteboard.UtfFileUrl;
-                                        uri = createUri(MacSystemClipboard.FILE_SCHEME, uri.getPath(), MacSystemClipboard.BAD_URI_MSG);
-                                    }
-                                    itemList[count] = new HashMap<>();
-                                    itemList[count].put(utf, uri.toASCIIString());
-                                    count++;
-                                }
-                            }
+                        List<HashMap<String, Object>> items = putToItemList(((String) object).split("\n"), true);
+                        if (!items.isEmpty()) {
+                            itemList = new HashMap[items.size()];
+                            items.toArray(itemList);
                         }
                         break;
                     }
@@ -189,17 +167,10 @@
                         String files[] = (String[]) object;
                         if (data.get(URI_TYPE) == null) {
                             // special case no explicit urls found - synthesize urls (Mac OS 10.6 style)
-                            itemList = new HashMap[files.length];
-                            for (int i = 0; i < files.length; i++) {
-                                String file = files[i];
-                                URI uri = createUri(file, MacSystemClipboard.BAD_URI_MSG);
-                                String utf = MacPasteboard.UtfUrl;
-                                if (uri.getScheme() == null) {
-                                    utf = MacPasteboard.UtfFileUrl;
-                                    uri = createUri(MacSystemClipboard.FILE_SCHEME, uri.getPath(), MacSystemClipboard.BAD_URI_MSG);
-                                }
-                                itemList[i] = new HashMap<>();
-                                itemList[i].put(utf, uri.toASCIIString());
+                            List<HashMap<String, Object>> items = putToItemList(files, true);
+                            if (!items.isEmpty()) {
+                                itemList = new HashMap[items.size()];
+                                items.toArray(itemList);
                             }
                         } else if (MacSystemClipboard.SUPPORT_10_5_API) {
                             // special case urls already exist - synthesize file list (Mac OS 10.5 API compatible)
@@ -209,11 +180,11 @@
                             StringBuilder string = null;
                             for (int i = 0; i < files.length; i++) {
                                 String file = files[i];
-                                URI uri = createUri(file, MacSystemClipboard.BAD_URI_MSG);
+                                String path = FileSystems.getDefault().getPath(file).toUri().toASCIIString();
                                 if (string == null) {
                                     string = new StringBuilder();
                                 }
-                                string.append(uri.getPath());
+                                string.append(path);
                                 if (i < (files.length - 1)) {
                                     string.append("\n");
                                 }
@@ -254,7 +225,7 @@
             this.seed = this.pasteboard.putItems(itemList, supportedActions);
         }
     }
-    
+
     @Override
     protected Object popFromSystem(String mime) {
         String[][] utfs = this.pasteboard.getUTFs();
@@ -302,8 +273,7 @@
                 for (int i = 0; i < utfs.length; i++) {
                     String file = this.pasteboard.getItemStringForUTF(i, MacPasteboard.UtfFileUrl); // explicitly ask for urls
                     if (file != null) {
-                        URL url = createUrl(file, MacSystemClipboard.BAD_URL_MSG);
-                        list.add(url.getPath());
+                        list.add(_convertFileReferencePath(file));
                     }
                 }
                 String[] object = null;
@@ -343,7 +313,7 @@
         }
         return null;
     }
-    
+
     @Override
     protected String[] mimesFromSystem() {
         String[][] all = this.pasteboard.getUTFs();
@@ -425,7 +395,7 @@
         private static native String _convertMIMEtoUTI(String mime);
         private static native String _convertUTItoMIME(String uti);
     }
-    
+
     private URI createUri(String path, String message) {
         URI uri = null;
         try {
@@ -436,27 +406,45 @@
         }
         return uri;
     }
-    
-    private URI createUri(String scheme, String path, String message) {
-        URI uri = null;
-        try {
-            uri = new URI(scheme, null, path, null);
-        } catch (URISyntaxException ex) {
-            System.err.println(message+path);
-            Thread.dumpStack();
+
+    private HashMap<String, Object> getItemFromURIString(String string) {
+        String utf;
+        String path = null;
+        if (string.indexOf(':') == -1) {
+            // Treat a URI without a scheme as a file name
+            utf = MacPasteboard.UtfFileUrl;
+            path = FileSystems.getDefault().getPath(string).toUri().toASCIIString();
+        } else {
+            // Mac OS X file names cannot contain ":", so this means we are dealing with a URI
+            // Only fully-qualified URIs are supported, so semicolon must exist as a scheme separator
+            utf = MacPasteboard.UtfUrl;
+            URI uri = createUri(string, MacSystemClipboard.BAD_URI_MSG);
+            if (uri != null) {
+                path = uri.toASCIIString();
+            } // no else, the error is already reported by createURI
         }
-        return uri;
+        if (path != null) {
+            HashMap<String, Object> item = new HashMap<>();
+            item.put(utf, path);
+            return item;
+        } else {
+            return null;
+        }
     }
-    
-    private URL createUrl(String path, String message) {
-        URL url = null;
-        try {
-            url = new URL(_convertFileReferencePath(path));
-        } catch (MalformedURLException ex) {
-            System.err.println(message+path);
-            Thread.dumpStack();
+
+    private List<HashMap<String, Object>> putToItemList(String[] items, boolean excludeComments) {
+        // synthesize list of urls as seperate pasteboard items (Mac OS 10.6 style)
+        List<HashMap<String, Object>> uriList = new ArrayList<>();
+        for (String file : items) {
+            if (!(excludeComments && file.startsWith("#"))) {
+                // exclude comments: http://www.ietf.org/rfc/rfc2483.txt
+                HashMap<String, Object> entry = getItemFromURIString(file);
+                if (entry != null) {
+                    uriList.add(entry);
+                }
+            }
         }
-        return url;
+        return  uriList;
     }
 
     private static native String _convertFileReferencePath(String path);
--- a/modules/graphics/src/main/java/com/sun/javafx/font/PrismFontFactory.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/PrismFontFactory.java	Wed Jul 10 11:01:52 2013 +0400
@@ -203,10 +203,10 @@
     }
 
     PrismFontFile createFontResource(String name, String filename,
-                                          boolean register,
-                                          boolean embedded,
-                                          boolean copy,
-                                          boolean tracked) {
+                                     boolean register,
+                                     boolean embedded,
+                                     boolean copy,
+                                     boolean tracked) {
         if (filename == null) {
             return null;
         } else {
@@ -228,8 +228,8 @@
                             }
                         } else {
                             fr = createFontFile(name, filename, index,
-                                                embedded,
-                                                register, copy, tracked);
+                                                register, embedded,
+                                                copy, tracked);
                         }
                     } catch (Exception e) {
                         if (PrismFontFactory.debugFonts) {
@@ -1467,7 +1467,7 @@
          * know to reference the file directly.
          */
         PrismFontFile fr = createFontResource(name, path, register,
-                                            true, copy, tracked);
+                                              true, copy, tracked);
         if (fr == null) {
             return null; // yes, this means the caller needs to handle null.
         }
--- a/modules/graphics/src/main/java/com/sun/javafx/font/coretext/CTGlyph.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/coretext/CTGlyph.java	Wed Jul 10 11:01:52 2013 +0400
@@ -143,7 +143,7 @@
     private synchronized byte[] getImage(double x, double y, int w, int h,
                                          double subPixelX, double subPixelY) {
 
-        if (w == 0 || h == 0) return null;
+        if (w == 0 || h == 0) return new byte[0];
 
         long fontRef = strike.getFontRef();
         boolean lcd = isLCDGlyph();
--- a/modules/graphics/src/main/java/com/sun/javafx/font/coretext/CTGlyphLayout.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/coretext/CTGlyphLayout.java	Wed Jul 10 11:01:52 2013 +0400
@@ -27,308 +27,108 @@
 
 import com.sun.javafx.font.CompositeFontResource;
 import com.sun.javafx.font.CompositeStrike;
-import com.sun.javafx.font.FontResource;
 import com.sun.javafx.font.FontStrike;
 import com.sun.javafx.font.PGFont;
 import com.sun.javafx.font.PrismFontFactory;
 import com.sun.javafx.geom.transform.BaseTransform;
 import com.sun.javafx.scene.text.TextSpan;
 import com.sun.javafx.text.GlyphLayout;
-import com.sun.javafx.text.ScriptMapper;
 import com.sun.javafx.text.PrismTextLayout;
 import com.sun.javafx.text.TextRun;
 
-import java.text.Bidi;
 import java.util.Arrays;
 
-import static com.sun.javafx.scene.text.TextLayout.FLAGS_ANALYSIS_VALID;
-import static com.sun.javafx.scene.text.TextLayout.FLAGS_HAS_COMPLEX;
-import static com.sun.javafx.scene.text.TextLayout.FLAGS_HAS_BIDI;
-import static com.sun.javafx.scene.text.TextLayout.FLAGS_HAS_TABS;
-import static com.sun.javafx.scene.text.TextLayout.FLAGS_HAS_EMBEDDED;
-import static com.sun.javafx.scene.text.TextLayout.FLAGS_RTL_BASE;
-
 class CTGlyphLayout extends GlyphLayout {
 
-    private TextRun addTextRun(PrismTextLayout layout, char[] chars, int start, int length,
-                               PGFont font, TextSpan span, byte level, boolean complex) {
+    protected TextRun addTextRun(PrismTextLayout layout, char[] chars, int start,
+                                 int length, PGFont font, TextSpan span, byte level) {
 
         TextRun textRun = null;
-        if (complex) {
-            /* Use CoreText to analize the run */
-            long alloc = OS.kCFAllocatorDefault();
-            long textRef = OS.CFStringCreateWithCharacters(alloc, chars, start, length);
 
-            FontStrike fontStrike = font.getStrike(BaseTransform.IDENTITY_TRANSFORM);
-            boolean composite = fontStrike instanceof CompositeStrike;
-            if (composite) {
-                fontStrike = ((CompositeStrike)fontStrike).getStrikeSlot(0);
+        /* Use CoreText to analize the run */
+        long alloc = OS.kCFAllocatorDefault();
+        long textRef = OS.CFStringCreateWithCharacters(alloc, chars, start, length);
+
+        FontStrike fontStrike = font.getStrike(BaseTransform.IDENTITY_TRANSFORM);
+        boolean composite = fontStrike instanceof CompositeStrike;
+        if (composite) {
+            fontStrike = ((CompositeStrike)fontStrike).getStrikeSlot(0);
+        }
+        CTFontStrike strike = (CTFontStrike)fontStrike;
+        long fontRef = strike.getFontRef();
+
+        long attributes = OS.CFDictionaryCreateMutable(alloc, 4, OS.kCFTypeDictionaryKeyCallBacks(), OS.kCFTypeDictionaryValueCallBacks());
+        OS.CFDictionaryAddValue(attributes, OS.kCTFontAttributeName(), fontRef);
+        /* Note that by default CoreText will apply kerning depending on the font*/
+        long attString = OS.CFAttributedStringCreate(alloc, textRef, attributes);
+        long lineRef = OS.CTLineCreateWithAttributedString(attString);
+        OS.CFRelease(attributes);
+        OS.CFRelease(attString);
+        OS.CFRelease(textRef);
+
+        long runs = OS.CTLineGetGlyphRuns(lineRef);
+        long runCount = OS.CFArrayGetCount(runs);
+
+        /*
+         * Need to undo the bidi reordering done by CoreText as it will be
+         * done again in text layout after wrapping.
+         */
+        boolean bidi = (level & 1) != 0;
+        int i = bidi ? (int)runCount - 1 : 0;
+        int step = bidi ? -1 : 1;
+        for (; 0 <= i && i < runCount; i += step) {
+            long run = OS.CFArrayGetValueAtIndex(runs, i);
+            int status = OS.CTRunGetStatus(run);
+            boolean runBidi = (status & OS.kCTRunStatusRightToLeft) != 0;
+            if (bidi != runBidi) {
+                if (PrismFontFactory.debugFonts) {
+                    System.err.println("[CoreText] not expecing bidi level to differ.");
+                }
             }
-            CTFontStrike strike = (CTFontStrike)fontStrike;
-            long fontRef = strike.getFontRef();
-
-            long attributes = OS.CFDictionaryCreateMutable(alloc, 4, OS.kCFTypeDictionaryKeyCallBacks(), OS.kCFTypeDictionaryValueCallBacks());
-            OS.CFDictionaryAddValue(attributes, OS.kCTFontAttributeName(), fontRef);
-            /* Note that by default CoreText will apply kerning depending on the font*/
-            long attString = OS.CFAttributedStringCreate(alloc, textRef, attributes);
-            long lineRef = OS.CTLineCreateWithAttributedString(attString);
-            OS.CFRelease(attributes);
-            OS.CFRelease(attString);
-            OS.CFRelease(textRef);
-
-            long runs = OS.CTLineGetGlyphRuns(lineRef);
-            long runCount = OS.CFArrayGetCount(runs);
+            CFRange range = OS.CTRunGetStringRange(run);
+            int glyphCount = (int)OS.CTRunGetGlyphCount(run);
+            int[] glyphs = OS.CTRunGetGlyphsPtr(run);
 
             /*
-             * Need to undo the bidi reordering done by CoreText as it will be
-             * done again in text layout after wrapping.
+             * The positions and indices returned by core text are
+             * relative to the line, the following native methods
+             * are custom to return values relative to the run.
              */
-            boolean bidi = (level & 1) != 0;
-            int i = bidi ? (int)runCount - 1 : 0;
-            int step = bidi ? -1 : 1;
-            for (; 0 <= i && i < runCount; i += step) {
-                long run = OS.CFArrayGetValueAtIndex(runs, i);
-                int status = OS.CTRunGetStatus(run);
-                boolean runBidi = (status & OS.kCTRunStatusRightToLeft) != 0;
-                if (bidi != runBidi) {
+            float[] positions = OS.CTRunGetPositionsPtr(run);
+            int[] indices = OS.CTRunGetStringIndicesPtr(run);
+
+            if (PrismFontFactory.debugFonts) {
+                System.err.println("Run " + i + " range " + (start+range.location) + ", " + range.length);
+                System.err.println("\tText=[" + new String(chars, start + (int)range.location, (int)range.length) + "]");
+                System.err.println("\tFont=" +strike.getFontResource());
+                System.err.println("\tStatus="+status);
+                System.err.println("\tGlyphs="+Arrays.toString(glyphs));
+                System.err.println("\tPositions="+Arrays.toString(positions));
+                System.err.println("\tIndices="+Arrays.toString(indices));
+            }
+            if (composite) {
+                long runAttrs = OS.CTRunGetAttributes(run);
+                long actualFont = OS.CFDictionaryGetValue(runAttrs, OS.kCTFontAttributeName());
+                String fontName = OS.CTFontCopyDisplayName(actualFont);
+                if (!fontName.equalsIgnoreCase(strike.getFontResource().getFullName())) {
+                    CompositeFontResource fr = (CompositeFontResource)font.getFontResource();
+                    int slot = fr.getSlotForFont(fontName) << 24;
                     if (PrismFontFactory.debugFonts) {
-                        System.err.println("[CoreText] not expecing bidi level to differ.");
+                        System.err.println("\tFallback front= "+ fontName + " slot=" + (slot>>24));
+                    }
+                    for (int j = 0; j < glyphs.length; j++) {
+                        glyphs[j] |= slot;
                     }
                 }
-                CFRange range = OS.CTRunGetStringRange(run);
-                int glyphCount = (int)OS.CTRunGetGlyphCount(run);
-                int[] glyphs = OS.CTRunGetGlyphsPtr(run);
-
-                /*
-                 * The positions and indices returned by core text are
-                 * relative to the line, the following native methods
-                 * are custom to return values relative to the run.
-                 */
-                float[] positions = OS.CTRunGetPositionsPtr(run);
-                int[] indices = OS.CTRunGetStringIndicesPtr(run);
-
-                if (PrismFontFactory.debugFonts) {
-                    System.err.println("Run " + i + " range " + (start+range.location) + ", " + range.length);
-                    System.err.println("\tText=[" + new String(chars, start + (int)range.location, (int)range.length) + "]");
-                    System.err.println("\tFont=" +strike.getFontResource());
-                    System.err.println("\tStatus="+status);
-                    System.err.println("\tGlyphs="+Arrays.toString(glyphs));
-                    System.err.println("\tPositions="+Arrays.toString(positions));
-                    System.err.println("\tIndices="+Arrays.toString(indices));
-                }
-                if (composite) {
-                    long runAttrs = OS.CTRunGetAttributes(run);
-                    long actualFont = OS.CFDictionaryGetValue(runAttrs, OS.kCTFontAttributeName());
-                    String fontName = OS.CTFontCopyDisplayName(actualFont);
-                    if (!fontName.equalsIgnoreCase(strike.getFontResource().getFullName())) {
-                        CompositeFontResource fr = (CompositeFontResource)font.getFontResource();
-                        int slot = fr.getSlotForFont(fontName) << 24;
-                        if (PrismFontFactory.debugFonts) {
-                            System.err.println("\tFallback front= "+ fontName + " slot=" + (slot>>24));
-                        }
-                        for (int j = 0; j < glyphs.length; j++) {
-                            glyphs[j] |= slot;
-                        }
-                    }
-                }
-                textRun = new TextRun(start + (int)range.location, (int)range.length, level, true, 0, span, 0, false);
-                textRun.shape(glyphCount, glyphs, positions, indices);
-                layout.addTextRun(textRun);
             }
-            OS.CFRelease(lineRef);
-        } else {
-            textRun = new TextRun(start, length, level, false, 0, span, 0, false);
+            textRun = new TextRun(start + (int)range.location, (int)range.length, level, true, 0, span, 0, false);
+            textRun.shape(glyphCount, glyphs, positions, indices);
             layout.addTextRun(textRun);
         }
+        OS.CFRelease(lineRef);
         return textRun;
     }
 
-    public int breakRuns(PrismTextLayout layout, char[] chars, int flags) {
-        int length = chars.length;
-        boolean complexRun = false;
-        boolean complex = false;
-        boolean feature = false;
-
-        boolean checkComplex = true;
-        boolean checkBidi = true;
-        if ((flags & FLAGS_ANALYSIS_VALID) != 0) {
-            /* Avoid work when it is known neither complex
-             * text nor bidi are not present. */
-            checkComplex = (flags & FLAGS_HAS_COMPLEX) != 0;
-            checkBidi = (flags & FLAGS_HAS_BIDI) != 0;
-        }
-
-        TextRun run = null;
-        Bidi bidi = null;
-        byte bidiLevel = 0;
-        int bidiEnd = length;
-        int bidiIndex = 0;
-        int spanIndex = 0;
-        TextSpan span = null;
-        int spanEnd = length;
-        PGFont font = null;
-        TextSpan[] spans = layout.getTextSpans();
-        if (spans != null) {
-            if (spans.length > 0) {
-                span = spans[spanIndex];
-                spanEnd = span.getText().length();
-                font = (PGFont)span.getFont();
-                if (font == null) {
-                    flags |= FLAGS_HAS_EMBEDDED;
-                }
-            }
-        } else {
-            font = layout.getFont();
-        }
-        if (font != null) {
-            FontResource fr = font.getFontResource();
-            int requestedFeatures = font.getFeatures();
-            int supportedFeatures = fr.getFeatures();
-            feature = (requestedFeatures & supportedFeatures) != 0;
-        }
-        if (checkBidi && length > 0) {
-            int direction = layout.getDirection();
-            bidi = new Bidi(chars, 0, null, 0, length, direction);
-            /* Temporary Code: See RT-26997 */
-//            bidiLevel = (byte)bidi.getRunLevel(bidiIndex);
-            bidiLevel = (byte)bidi.getLevelAt(bidi.getRunStart(bidiIndex));
-            bidiEnd = bidi.getRunLimit(bidiIndex);
-            if ((bidiLevel & 1) != 0) {
-                flags |= FLAGS_HAS_BIDI;
-            }
-        }
-
-        int start = 0;
-        int i = 0;
-        while (i < length) {
-            char ch = chars[i];
-            int codePoint = ch;
-
-            boolean delimiterChanged = ch == '\t' || ch == '\n' || ch == '\r';
-            boolean spanChanged = i >= spanEnd;
-            boolean levelChanged = i >= bidiEnd;
-            boolean complexChanged = false;
-
-            if (checkComplex) {
-                if (Character.isHighSurrogate(ch)) {
-                    /* Only merge surrogate when the pair is in the same span. */
-                    if (i + 1 < spanEnd && Character.isLowSurrogate(chars[i + 1])) {
-                        codePoint = Character.toCodePoint(ch, chars[++i]);
-                    }
-                }
-                if (Character.isWhitespace(codePoint)) {
-                    complex = feature || complexRun;
-                } else {
-                    complex = feature || ScriptMapper.isComplexCharCode(codePoint);
-                }
-                complexChanged = complex != complexRun;
-            }
-
-            if (delimiterChanged || spanChanged || levelChanged || complexChanged) {
-
-                /* Create text run */
-                if (i != start) {
-                    run = addTextRun(layout, chars, start, i - start,
-                                     font, span, bidiLevel, complexRun);
-                    if (complexRun) {
-                        flags |= FLAGS_HAS_COMPLEX;
-                    }
-                    start = i;
-                }
-
-                if (delimiterChanged) {
-                    i++;
-                    /* Only merge \r\n when the are in the same text span */
-                    if (ch == '\r' && i < spanEnd && chars[i] == '\n') {
-                        i++;
-                    }
-
-                    /* Create delimiter run */
-                    run = new TextRun(start, i - start, bidiLevel, false,
-                                      ScriptMapper.COMMON, span, 0, false);
-                    if (ch == '\t') {
-                        run.setTab();
-                        flags |= FLAGS_HAS_TABS;
-                    } else {
-                        run.setLinebreak();
-                    }
-                    layout.addTextRun(run);
-
-                    start = i;
-                    if (i == length) break;
-                    spanChanged = i >= spanEnd;
-                    levelChanged = i >= bidiEnd;
-                }
-                if (spanChanged) {
-                    /* Only true for rich text (spans != null) */
-                    span = spans[++spanIndex];
-                    spanEnd += span.getText().length();
-                    font = (PGFont)span.getFont();
-                    if (font == null) {
-                        flags |= FLAGS_HAS_EMBEDDED;
-                    } else {
-                        FontResource fr = font.getFontResource();
-                        int requestedFeatures = font.getFeatures();
-                        int supportedFeatures = fr.getFeatures();
-                        feature = (requestedFeatures & supportedFeatures) != 0;
-                    }
-                }
-                if (levelChanged) {
-                    bidiIndex++;
-                    /* Temporary Code: See RT-26997 */
-//                    bidiLevel = (byte)bidi.getRunLevel(bidiIndex);
-                    bidiLevel = (byte)bidi.getLevelAt(bidi.getRunStart(bidiIndex));
-                    bidiEnd = bidi.getRunLimit(bidiIndex);
-                    if ((bidiLevel & 1) != 0) {
-                        flags |= FLAGS_HAS_BIDI;
-                    }
-                }
-
-                if (complexChanged) {
-                    if (delimiterChanged) {
-                        ch = chars[i]; /* update ch because of delimiterChanged */
-                        if (Character.isHighSurrogate(ch)) {
-                            /* Only merge surrogate when the pair is in the same span */
-                            if (i + 1 < spanEnd && Character.isLowSurrogate(chars[i + 1])) {
-                                codePoint = Character.toCodePoint(ch, chars[++i]);
-                            }
-                        }
-                        if (Character.isWhitespace(codePoint)) {
-                            complex = feature || complexRun;
-                        } else {
-                            complex = feature || ScriptMapper.isComplexCharCode(codePoint);
-                        }
-                    }
-                    complexRun = complex;
-                }
-            }
-            if (!delimiterChanged) i++;
-        }
-
-        /* Create final text run */
-        if (start < length) {
-            addTextRun(layout, chars, start, length - start,
-                       font, span, bidiLevel, complexRun);
-            if (complexRun) {
-                flags |= FLAGS_HAS_COMPLEX;
-            }
-        } else {
-            /* Ensure every lines has at least one run */
-            if (run == null || run.isLinebreak()) {
-                run = new TextRun(start, 0, (byte)0, false,
-                                  ScriptMapper.COMMON, span, 0, false);
-                layout.addTextRun(run);
-            }
-        }
-        if (bidi != null) {
-            if (!bidi.baseIsLeftToRight()) {
-                flags |= FLAGS_RTL_BASE;
-            }
-        }
-        flags |= FLAGS_ANALYSIS_VALID;
-        return flags;
-    }
-
     public void layout(TextRun run, PGFont font, FontStrike strike, char[] text) {
         // Nothing - complex run are analyzed by CoreText during break run
     }
--- a/modules/graphics/src/main/java/com/sun/javafx/font/directwrite/DWGlyph.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/directwrite/DWGlyph.java	Wed Jul 10 11:01:52 2013 +0400
@@ -101,6 +101,10 @@
         int textureType = OS.DWRITE_TEXTURE_CLEARTYPE_3x1;
         IDWriteGlyphRunAnalysis runAnalysis = createAnalysis(subPixelX, subPixelY);
         rect = runAnalysis.GetAlphaTextureBounds(textureType);
+        if ((rect.right - rect.left == 0) ||
+            (rect.bottom - rect.top == 0)) {
+            return new byte[0];
+        }
         byte[] buffer = runAnalysis.CreateAlphaTexture(textureType, rect);
         runAnalysis.Release();
         return buffer;
--- a/modules/graphics/src/main/java/com/sun/javafx/font/directwrite/DWGlyphLayout.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/directwrite/DWGlyphLayout.java	Wed Jul 10 11:01:52 2013 +0400
@@ -25,7 +25,6 @@
 
 package com.sun.javafx.font.directwrite;
 
-import java.text.Bidi;
 import com.sun.javafx.font.CompositeFontResource;
 import com.sun.javafx.font.FontResource;
 import com.sun.javafx.font.FontStrike;
@@ -34,43 +33,36 @@
 import com.sun.javafx.scene.text.TextSpan;
 import com.sun.javafx.text.GlyphLayout;
 import com.sun.javafx.text.PrismTextLayout;
-import com.sun.javafx.text.ScriptMapper;
 import com.sun.javafx.text.TextRun;
-import static com.sun.javafx.scene.text.TextLayout.*;
 
 public class DWGlyphLayout extends GlyphLayout {
 
     private static final String LOCALE = "en-us";
 
-    private TextRun addTextRun(PrismTextLayout layout, char[] chars, int start, int length,
-                               PGFont font, TextSpan span, byte level, boolean complex) {
+    protected TextRun addTextRun(PrismTextLayout layout, char[] chars, int start,
+                                 int length, PGFont font, TextSpan span, byte level) {
         TextRun textRun = null;
-        if (complex) {
-            int dir = (level & 1) != 0 ? OS.DWRITE_READING_DIRECTION_RIGHT_TO_LEFT :
-                                         OS.DWRITE_READING_DIRECTION_LEFT_TO_RIGHT;
-            JFXTextAnalysisSink sink = OS.NewJFXTextAnalysisSink(chars, start, length, LOCALE, dir);
-            sink.AddRef();
+        int dir = (level & 1) != 0 ? OS.DWRITE_READING_DIRECTION_RIGHT_TO_LEFT :
+                                     OS.DWRITE_READING_DIRECTION_LEFT_TO_RIGHT;
+        JFXTextAnalysisSink sink = OS.NewJFXTextAnalysisSink(chars, start, length, LOCALE, dir);
+        sink.AddRef();
 
-            IDWriteFactory factory = DWFactory.getDWriteFactory();
-            IDWriteTextAnalyzer analyzer = factory.CreateTextAnalyzer();
-            analyzer.AnalyzeScript(sink, 0, length, sink);
+        IDWriteFactory factory = DWFactory.getDWriteFactory();
+        IDWriteTextAnalyzer analyzer = factory.CreateTextAnalyzer();
+        analyzer.AnalyzeScript(sink, 0, length, sink);
 
-            while (sink.Next()) {
-                int runStart = sink.GetStart();
-                int runLength = sink.GetLength();
-                DWRITE_SCRIPT_ANALYSIS analysis = sink.GetAnalysis();
-                textRun = new TextRun(start + runStart, runLength, level, true,
-                                      analysis.script, span,
-                                      analysis.shapes, false);
-                layout.addTextRun(textRun) ;
-            }
+        while (sink.Next()) {
+            int runStart = sink.GetStart();
+            int runLength = sink.GetLength();
+            DWRITE_SCRIPT_ANALYSIS analysis = sink.GetAnalysis();
+            textRun = new TextRun(start + runStart, runLength, level, true,
+                                  analysis.script, span,
+                                  analysis.shapes, false);
+            layout.addTextRun(textRun) ;
+        }
 
-            analyzer.Release();
-            sink.Release();
-        } else {
-            textRun = new TextRun(start, length, level, false, 0, span, 0, false);
-            layout.addTextRun(textRun);
-        }
+        analyzer.Release();
+        sink.Release();
         return textRun;
     }
 
@@ -279,198 +271,4 @@
         }
         run.shape(totalGlyphCount, glyphs, pos, clusterMap);
     }
-
-    /*
-    * Ideally DirectWrite could be used to do the entire job.
-    * Still need to verify if JFX handling of non-complex is indeed faster
-    * than DirectWrite.
-    *
-    * (this method was copied from the CoreText implementation).
-    */
-    public int breakRuns(PrismTextLayout layout, char[] chars, int flags) {
-        int length = chars.length;
-        boolean complexRun = false;
-        boolean complex = false;
-        boolean feature = false;
-
-        boolean checkComplex = true;
-        boolean checkBidi = true;
-        if ((flags & FLAGS_ANALYSIS_VALID) != 0) {
-            /* Avoid work when it is known neither complex
-             * text nor bidi are not present. */
-            checkComplex = (flags & FLAGS_HAS_COMPLEX) != 0;
-            checkBidi = (flags & FLAGS_HAS_BIDI) != 0;
-        }
-
-        TextRun run = null;
-        Bidi bidi = null;
-        byte bidiLevel = 0;
-        int bidiEnd = length;
-        int bidiIndex = 0;
-        int spanIndex = 0;
-        TextSpan span = null;
-        int spanEnd = length;
-        PGFont font = null;
-        TextSpan[] spans = layout.getTextSpans();
-        if (spans != null) {
-            if (spans.length > 0) {
-                span = spans[spanIndex];
-                spanEnd = span.getText().length();
-                font = (PGFont)span.getFont();
-                if (font == null) {
-                    flags |= FLAGS_HAS_EMBEDDED;
-                }
-            }
-        } else {
-            font = layout.getFont();
-        }
-        if (font != null) {
-            FontResource fr = font.getFontResource();
-            int requestedFeatures = font.getFeatures();
-            int supportedFeatures = fr.getFeatures();
-            feature = (requestedFeatures & supportedFeatures) != 0;
-        }
-        if (checkBidi && length > 0) {
-            int direction = layout.getDirection();
-            bidi = new Bidi(chars, 0, null, 0, length, direction);
-            /* Temporary Code: See RT-26997 */
-//            bidiLevel = (byte)bidi.getRunLevel(bidiIndex);
-            bidiLevel = (byte)bidi.getLevelAt(bidi.getRunStart(bidiIndex));
-            bidiEnd = bidi.getRunLimit(bidiIndex);
-            if ((bidiLevel & 1) != 0) {
-                flags |= FLAGS_HAS_BIDI;
-            }
-        }
-
-        int start = 0;
-        int i = 0;
-        while (i < length) {
-            char ch = chars[i];
-            int codePoint = ch;
-
-            boolean delimiterChanged = ch == '\t' || ch == '\n' || ch == '\r';
-            boolean spanChanged = i >= spanEnd;
-            boolean levelChanged = i >= bidiEnd;
-            boolean complexChanged = false;
-
-            if (checkComplex) {
-                if (Character.isHighSurrogate(ch)) {
-                    /* Only merge surrogate when the pair is in the same span. */
-                    if (i + 1 < spanEnd && Character.isLowSurrogate(chars[i + 1])) {
-                        codePoint = Character.toCodePoint(ch, chars[++i]);
-                    }
-                }
-                if (Character.isWhitespace(codePoint)) {
-                    complex = feature || complexRun;
-                } else {
-                    complex = feature || ScriptMapper.isComplexCharCode(codePoint);
-                }
-                complexChanged = complex != complexRun;
-            }
-
-            if (delimiterChanged || spanChanged || levelChanged || complexChanged) {
-
-                /* Create text run */
-                if (i != start) {
-                    run = addTextRun(layout, chars, start, i - start,
-                                     font, span, bidiLevel, complexRun);
-                    if (complexRun) {
-                        flags |= FLAGS_HAS_COMPLEX;
-                    }
-                    start = i;
-                }
-
-                if (delimiterChanged) {
-                    i++;
-                    /* Only merge \r\n when the are in the same text span */
-                    if (ch == '\r' && i < spanEnd && chars[i] == '\n') {
-                        i++;
-                    }
-
-                    /* Create delimiter run */
-                    run = new TextRun(start, i - start, bidiLevel, false,
-                                      ScriptMapper.COMMON, span, 0, false);
-                    if (ch == '\t') {
-                        run.setTab();
-                        flags |= FLAGS_HAS_TABS;
-                    } else {
-                        run.setLinebreak();
-                    }
-                    layout.addTextRun(run);
-
-                    start = i;
-                    if (i == length) break;
-                    spanChanged = i >= spanEnd;
-                    levelChanged = i >= bidiEnd;
-                }
-                if (spanChanged) {
-                    /* Only true for rich text (spans != null) */
-                    span = spans[++spanIndex];
-                    spanEnd += span.getText().length();
-                    font = (PGFont)span.getFont();
-                    if (font == null) {
-                        flags |= FLAGS_HAS_EMBEDDED;
-                    } else {
-                        FontResource fr = font.getFontResource();
-                        int requestedFeatures = font.getFeatures();
-                        int supportedFeatures = fr.getFeatures();
-                        feature = (requestedFeatures & supportedFeatures) != 0;
-                    }
-                }
-                if (levelChanged) {
-                    bidiIndex++;
-                    /* Temporary Code: See RT-26997 */
-//                    bidiLevel = (byte)bidi.getRunLevel(bidiIndex);
-                    bidiLevel = (byte)bidi.getLevelAt(bidi.getRunStart(bidiIndex));
-                    bidiEnd = bidi.getRunLimit(bidiIndex);
-                    if ((bidiLevel & 1) != 0) {
-                        flags |= FLAGS_HAS_BIDI;
-                    }
-                }
-
-                if (complexChanged) {
-                    if (delimiterChanged) {
-                        ch = chars[i]; /* update ch because of delimiterChanged */
-                        if (Character.isHighSurrogate(ch)) {
-                            /* Only merge surrogate when the pair is in the same span */
-                            if (i + 1 < spanEnd && Character.isLowSurrogate(chars[i + 1])) {
-                                codePoint = Character.toCodePoint(ch, chars[++i]);
-                            }
-                        }
-                        if (Character.isWhitespace(codePoint)) {
-                            complex = feature || complexRun;
-                        } else {
-                            complex = feature || ScriptMapper.isComplexCharCode(codePoint);
-                        }
-                    }
-                    complexRun = complex;
-                }
-            }
-            if (!delimiterChanged) i++;
-        }
-
-        /* Create final text run */
-        if (start < length) {
-            addTextRun(layout, chars, start, length - start,
-                       font, span, bidiLevel, complexRun);
-            if (complexRun) {
-                flags |= FLAGS_HAS_COMPLEX;
-            }
-        } else {
-            /* Ensure every lines has at least one run */
-            if (run == null || run.isLinebreak()) {
-                run = new TextRun(start, 0, (byte)0, false,
-                                  ScriptMapper.COMMON, span, 0, false);
-                layout.addTextRun(run);
-            }
-        }
-        if (bidi != null) {
-            if (!bidi.baseIsLeftToRight()) {
-                flags |= FLAGS_RTL_BASE;
-            }
-        }
-        flags |= FLAGS_ANALYSIS_VALID;
-        return flags;
-    }
-
 }
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/pango/FTDisposer.java	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,56 @@
+/*
+ * 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 com.sun.javafx.font.pango;
+
+import com.sun.javafx.font.DisposerRecord;
+import com.sun.javafx.font.PrismFontFactory;
+
+class FTDisposer implements DisposerRecord  {
+    long library;
+    long face;
+
+    FTDisposer(long library, long face) {
+        this.library = library;
+        this.face = face;
+    }
+
+    public synchronized void dispose() {
+        if (face != 0) {
+            OS.FT_Done_Face(face);
+            if (PrismFontFactory.debugFonts) {
+                System.err.println("Done Face=" + face);
+            }
+            face = 0;
+        }
+        if (library != 0) {
+            OS.FT_Done_FreeType(library);
+            if (PrismFontFactory.debugFonts) {
+                System.err.println("Done Library=" + library);
+            }
+            library = 0;
+        }
+    }
+}
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/pango/FTFontFile.java	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,208 @@
+/*
+ * 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 com.sun.javafx.font.pango;
+
+import com.sun.javafx.font.Disposer;
+import com.sun.javafx.font.FontResource;
+import com.sun.javafx.font.FontStrikeDesc;
+import com.sun.javafx.font.PrismFontFactory;
+import com.sun.javafx.font.PrismFontFile;
+import com.sun.javafx.font.PrismFontStrike;
+import com.sun.javafx.geom.Path2D;
+import com.sun.javafx.geom.transform.BaseTransform;
+
+class FTFontFile extends PrismFontFile {
+    /*
+     * Font files can be accessed by several threads. In general this are the
+     * JFX thread (measuring) and the Prism thread (rendering). But, if a Text
+     * node is no connected a Scene it can be used in any user thread, thus a
+     * font resource can be accessed from any thread.
+     *
+     * Freetype resources are not thread safe. In this implementation each font
+     * resources has its own FT_Face and FT_Library, and while it permits these
+     * resources be used by different threads it does not allow concurrent access.
+     * This is enforced by converging all operation (from FTFontStrike and
+     * FTGlyph) to this object and synchronizing the access to the native
+     * resources using the same lock.
+     */
+    private long library;
+    private long face;
+    private FTDisposer disposer;
+
+    FTFontFile(String name, String filename, int fIndex, boolean register,
+               boolean embedded, boolean copy, boolean tracked) throws Exception {
+        super(name, filename, fIndex, register, embedded, copy, tracked);
+        init();
+    }
+
+    private synchronized void init() throws Exception {
+        long[] ptr = new long[1];
+        int error = OS.FT_Init_FreeType(ptr);
+        if (error != 0) {
+            throw new Exception("FT_Init_FreeType Failed error " + error);
+        }
+        library = ptr[0];
+        if (PangoFactory.LCD_SUPPORT) {
+            OS.FT_Library_SetLcdFilter(library, OS.FT_LCD_FILTER_DEFAULT);
+        }
+
+        String file = getFileName();
+        int fontIndex = getFontIndex();
+        /* Freetype expects 'a standard C string' */
+        byte[] buffer = (file+"\0").getBytes();
+        error = OS.FT_New_Face(library, buffer, fontIndex, ptr);
+        if (error != 0) {
+            throw new Exception("FT_New_Face Failed error " + error +
+                                " Font File " + file +
+                                " Font Index " + fontIndex);
+        }
+        face = ptr[0];
+
+        if (!isRegistered()) {
+            disposer = new FTDisposer(library, face);
+            Disposer.addRecord(this, disposer);
+        }
+    }
+
+    /* This is called only for fonts where a temp file was created */
+    @Override
+    protected synchronized void disposeOnShutdown() {
+        if (face != 0) {
+            OS.FT_Done_Face(face);
+            if (PrismFontFactory.debugFonts) {
+                System.err.println("Done Face=" + face);
+            }
+            face = 0;
+        }
+        if (library != 0) {
+            OS.FT_Done_FreeType(library);
+            if (PrismFontFactory.debugFonts) {
+                System.err.println("Done Library=" + library);
+            }
+            library = 0;
+        }
+        if (disposer != null) {
+            disposer.library = 0;
+            disposer.face = 0;
+            disposer = null;
+        }
+    }
+
+    @Override
+    protected PrismFontStrike<?> createStrike(float size, BaseTransform transform,
+                                              int aaMode, FontStrikeDesc desc) {
+        return new FTFontStrike(this, size, transform, aaMode, desc);
+    }
+
+    @Override
+    protected synchronized int[] createGlyphBoundingBox(int gc) {
+        int flags = OS.FT_LOAD_NO_SCALE;
+        OS.FT_Load_Glyph(face, gc, flags);
+        FT_GlyphSlotRec glyphRec = OS.getGlyphSlot(face);
+        FT_Glyph_Metrics gm = glyphRec.metrics;
+        int[] bbox = new int[4];
+        bbox[0] = (int)gm.horiBearingX;
+        bbox[1] = (int)(gm.horiBearingY - gm.height);
+        bbox[2] = (int)(gm.horiBearingX + gm.width);
+        bbox[3] = (int)gm.horiBearingY;
+        return bbox;
+    }
+
+    synchronized Path2D createGlyphOutline(int gc, float size) {
+        int size26dot6 = (int)(size * 64);
+        OS.FT_Set_Char_Size(face, 0, size26dot6, 72, 72);
+        int flags = OS.FT_LOAD_NO_HINTING | OS.FT_LOAD_NO_BITMAP | OS.FT_LOAD_IGNORE_TRANSFORM;
+        OS.FT_Load_Glyph(face, gc, flags);
+        return OS.FT_Outline_Decompose(face);
+    }
+
+    synchronized void initGlyph(FTGlyph glyph, FTFontStrike strike) {
+        int size26dot6 = (int)(strike.getSize() * 64);
+        OS.FT_Set_Char_Size(face, 0, size26dot6, 72, 72);
+
+        boolean lcd = strike.getAAMode() == FontResource.AA_LCD &&
+                      PangoFactory.LCD_SUPPORT;
+
+        int flags = OS.FT_LOAD_RENDER | OS.FT_LOAD_NO_HINTING;
+        FT_Matrix matrix = strike.matrix;
+        if (matrix != null) {
+            OS.FT_Set_Transform(face, matrix, 0, 0);
+        } else {
+            flags |= OS.FT_LOAD_IGNORE_TRANSFORM;
+        }
+        if (lcd) {
+            flags |= OS.FT_LOAD_TARGET_LCD;
+        } else {
+            flags |= OS.FT_LOAD_TARGET_NORMAL;
+        }
+
+        int glyphCode = glyph.getGlyphCode();
+        int error = OS.FT_Load_Glyph(face, glyphCode, flags);
+        if (error != 0) {
+            if (PrismFontFactory.debugFonts) {
+                System.err.println("FT_Load_Glyph failed " + error +
+                                   " glyph code " + glyphCode +
+                                   " load falgs " + flags);
+            }
+            return;
+        }
+
+        FT_GlyphSlotRec glyphRec = OS.getGlyphSlot(face);
+        FT_Bitmap bitmap = glyphRec.bitmap;
+        int width = bitmap.width;
+        int height = bitmap.rows;
+        int pitch = bitmap.pitch;
+        byte[] buffer;
+        if (width != 0 && height != 0) {
+            buffer = OS.getBitmapData(face);
+            if (pitch != width) {
+                /* Common for LCD glyphs */
+                byte[] newBuffer = new byte[width * height];
+                int src = 0, dst = 0;
+                for (int y = 0; y < height; y++) {
+                    for (int x = 0; x < width; x++) {
+                        newBuffer[dst + x] = buffer[src + x];
+                    }
+                    dst += width;
+                    src += pitch;
+                }
+                buffer = newBuffer;
+            }
+        } else {
+            /* white space */
+            buffer = new byte[0];
+        }
+
+        glyph.buffer = buffer;
+        glyph.bitmap = bitmap;
+        glyph.bitmap_left = glyphRec.bitmap_left;
+        glyph.bitmap_top = glyphRec.bitmap_top;
+        glyph.advanceX = glyphRec.advance_x / 64f;    /* Fixed 26.6*/
+        glyph.advanceY = glyphRec.advance_y / 64f;
+        glyph.userAdvance = glyphRec.linearHoriAdvance / 65536.0f; /* Fixed 16.16 */
+        glyph.lcd = lcd;
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/pango/FTFontStrike.java	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,90 @@
+/*
+ * 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 com.sun.javafx.font.pango;
+
+import com.sun.javafx.font.DisposerRecord;
+import com.sun.javafx.font.FontStrikeDesc;
+import com.sun.javafx.font.Glyph;
+import com.sun.javafx.font.PrismFontStrike;
+import com.sun.javafx.geom.Path2D;
+import com.sun.javafx.geom.transform.BaseTransform;
+
+class FTFontStrike extends PrismFontStrike<FTFontFile> {
+    FT_Matrix matrix;
+
+    protected FTFontStrike(FTFontFile fontResource, float size,
+                              BaseTransform tx, int aaMode,
+                              FontStrikeDesc desc) {
+        super(fontResource, size, tx, aaMode, desc);
+        float maxDim = 80f;
+        if (tx.isTranslateOrIdentity()) {
+            drawShapes = size > maxDim;
+        } else {
+            BaseTransform tx2d = getTransform();
+            matrix = new FT_Matrix();
+            /* Fixed 16.16 to int */
+            matrix.xx = (int)( tx2d.getMxx() * 65536.0f);
+            matrix.yx = (int)(-tx2d.getMyx() * 65536.0f); /*Inverted coordinates system */
+            matrix.xy = (int)(-tx2d.getMxy() * 65536.0f); /*Inverted coordinates system */
+            matrix.yy = (int)( tx2d.getMyy() * 65536.0f);
+
+            if (Math.abs(tx2d.getMxx() * size) > maxDim ||
+                Math.abs(tx2d.getMyx() * size) > maxDim ||
+                Math.abs(tx2d.getMxy() * size) > maxDim ||
+                Math.abs(tx2d.getMyy() * size) > maxDim)
+            {
+                drawShapes = true;
+            }
+        }
+    }
+
+    @Override
+    public boolean isSubPixelGlyph() {
+        return false;
+    }
+
+    @Override
+    protected DisposerRecord createDisposer(FontStrikeDesc desc) {
+        return null;
+    }
+
+    @Override
+    protected Glyph createGlyph(int glyphCode) {
+        return new FTGlyph(this, glyphCode, drawShapes);
+    }
+
+    @Override
+    protected Path2D createGlyphOutline(int glyphCode) {
+        FTFontFile fontResource = getFontResource();
+        return fontResource.createGlyphOutline(glyphCode, getSize());
+    }
+
+    void initGlyph(FTGlyph glyph) {
+        FTFontFile fontResource = getFontResource();
+        fontResource.initGlyph(glyph, this);
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/pango/FTGlyph.java	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,132 @@
+/*
+ * 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 com.sun.javafx.font.pango;
+
+import com.sun.javafx.font.Glyph;
+import com.sun.javafx.geom.RectBounds;
+import com.sun.javafx.geom.Shape;
+
+class FTGlyph implements Glyph {
+    FTFontStrike strike;
+    int glyphCode;
+    byte[] buffer;
+    FT_Bitmap bitmap;
+    int bitmap_left;
+    int bitmap_top;
+    float advanceX;
+    float advanceY;
+    float userAdvance;
+    boolean lcd;
+
+    FTGlyph(FTFontStrike strike, int glyphCode, boolean drawAsShape) {
+        this.strike = strike;
+        this.glyphCode = glyphCode;
+    }
+
+    @Override
+    public int getGlyphCode() {
+        return glyphCode;
+    }
+
+    private void init() {
+        if (bitmap != null) return;
+        strike.initGlyph(this);
+    }
+
+    @Override
+    public RectBounds getBBox() {
+        float[] bb = new float[4];
+        FTFontFile fontResource = strike.getFontResource();
+        fontResource.getGlyphBoundingBox(glyphCode, strike.getSize(), bb);
+        return new RectBounds(bb[0], bb[1], bb[2], bb[3]);
+    }
+
+    @Override
+    public float getAdvance() {
+        init();
+        return userAdvance;
+    }
+
+    @Override
+    public Shape getShape() {
+        return strike.createGlyphOutline(glyphCode);
+    }
+
+    @Override
+    public byte[] getPixelData() {
+        init();
+        return buffer;
+    }
+
+    @Override
+    public byte[] getPixelData(float x, float y) {
+        init();
+        return buffer;
+    }
+
+    @Override
+    public float getPixelXAdvance() {
+        init();
+        return advanceX;
+    }
+
+    @Override
+    public float getPixelYAdvance() {
+        init();
+        return advanceY;
+    }
+
+    @Override
+    public int getWidth() {
+        init();
+        /* Note: In Freetype the width is byte based */
+        return bitmap.width;
+    }
+
+    @Override
+    public int getHeight() {
+        init();
+        return bitmap.rows;
+    }
+
+    @Override
+    public int getOriginX() {
+        init();
+        return bitmap_left;
+    }
+
+    @Override
+    public int getOriginY() {
+        init();
+        return -bitmap_top; /*Inverted coordinates system */
+    }
+
+    @Override
+    public boolean isLCDGlyph() {
+        return lcd;
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/pango/FT_Bitmap.java	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,37 @@
+/*
+ * 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 com.sun.javafx.font.pango;
+
+class FT_Bitmap {
+    int rows;
+    int width;
+    int pitch;
+    long buffer;
+    short num_grays;
+    byte pixel_mode;
+    char palette_mode;
+    long palette;
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/pango/FT_GlyphSlotRec.java	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,38 @@
+/*
+ * 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 com.sun.javafx.font.pango;
+
+class FT_GlyphSlotRec {
+    FT_Glyph_Metrics metrics = new FT_Glyph_Metrics();
+    long linearHoriAdvance;
+    long linearVertAdvance;
+    long advance_x;
+    long advance_y;
+    int format;
+    FT_Bitmap bitmap = new FT_Bitmap();
+    int bitmap_left;
+    int bitmap_top;
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/pango/FT_Glyph_Metrics.java	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,37 @@
+/*
+ * 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 com.sun.javafx.font.pango;
+
+class FT_Glyph_Metrics {
+    long width;
+    long height;
+    long horiBearingX;
+    long horiBearingY;
+    long horiAdvance;
+    long vertBearingX;
+    long vertBearingY;
+    long vertAdvance;
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/pango/FT_Matrix.java	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,33 @@
+/*
+ * 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 com.sun.javafx.font.pango;
+
+class FT_Matrix {
+    long xx;
+    long xy;
+    long yx;
+    long yy;
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/pango/OS.java	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,163 @@
+/*
+ * 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 com.sun.javafx.font.pango;
+
+import java.nio.ByteBuffer;
+import java.security.AccessController;
+import java.security.PrivilegedAction;
+import com.sun.glass.utils.NativeLibLoader;
+import com.sun.javafx.geom.Path2D;
+
+class OS {
+
+    static {
+        AccessController.doPrivileged(new PrivilegedAction<Void>() {
+           public Void run() {
+               NativeLibLoader.loadLibrary("javafx-font-pango");
+               return null;
+           }
+        });
+    }
+
+    /* Pango */
+    static final int PANGO_SCALE = 1024;
+    static final int PANGO_STRETCH_ULTRA_CONDENSED = 0x0;
+    static final int PANGO_STRETCH_EXTRA_CONDENSED = 0x1;
+    static final int PANGO_STRETCH_CONDENSED = 0x2;
+    static final int PANGO_STRETCH_SEMI_CONDENSED = 0x3;
+    static final int PANGO_STRETCH_NORMAL = 0x4;
+    static final int PANGO_STRETCH_SEMI_EXPANDED = 0x5;
+    static final int PANGO_STRETCH_EXPANDED = 0x6;
+    static final int PANGO_STRETCH_EXTRA_EXPANDED = 0x7;
+    static final int PANGO_STRETCH_ULTRA_EXPANDED = 0x8;
+    static final int PANGO_STYLE_ITALIC = 0x2;
+    static final int PANGO_STYLE_NORMAL = 0x0;
+    static final int PANGO_STYLE_OBLIQUE = 0x1;
+    static final int PANGO_WEIGHT_BOLD = 0x2bc;
+    static final int PANGO_WEIGHT_NORMAL = 0x190;
+
+    static final native long pango_ft2_font_map_new();
+    static final native long pango_font_map_create_context(long fontmap);
+    static final native long pango_font_describe(long font);
+    static final native long pango_font_description_new();
+    static final native void pango_font_description_free(long desc);
+    static final native String pango_font_description_get_family(long desc);
+    static final native int pango_font_description_get_stretch(long desc);
+    static final native int pango_font_description_get_style(long desc);
+    static final native int pango_font_description_get_weight(long desc);
+    static final native void pango_font_description_set_family(long desc, String family);
+    static final native void pango_font_description_set_absolute_size(long desc, double size);
+    static final native void pango_font_description_set_stretch(long desc, int stretch);
+    static final native void pango_font_description_set_style(long desc, int style);
+    static final native void pango_font_description_set_weight(long desc, int weight);
+    static final native long pango_attr_list_new();
+    static final native long pango_attr_font_desc_new(long desc);
+    static final native long pango_attr_fallback_new(boolean enable_fallback);
+    static final native void pango_attr_list_unref(long list);
+    static final native void pango_attr_list_insert(long list, long attr);
+    static final native long pango_itemize(long context, ByteBuffer text, int start_index, int length, long attrs, long cached_iter);
+    static final native PangoGlyphString pango_shape(ByteBuffer text, long pangoItem);
+    static final native void pango_item_free(long item);
+
+    /* Miscellaneous (glib, fontconfig) */
+    static final native int g_list_length(long list);
+    static final native long g_list_nth_data(long list, int n);
+    static final native void g_list_free(long list);
+    static final native void g_object_unref(long object);
+    static final native boolean FcConfigAppFontAddFile(long config, String file);
+
+    /* Freetype */
+    static final int FT_FACE_FLAG_SCALABLE          = 1 <<  0;
+    static final int FT_FACE_FLAG_FIXED_SIZES       = 1 <<  1;
+    static final int FT_FACE_FLAG_FIXED_WIDTH       = 1 <<  2;
+    static final int FT_FACE_FLAG_SFNT              = 1 <<  3;
+    static final int FT_FACE_FLAG_HORIZONTAL        = 1 <<  4;
+    static final int FT_FACE_FLAG_VERTICAL          = 1 <<  5;
+    static final int FT_FACE_FLAG_KERNING           = 1 <<  6;
+    static final int FT_FACE_FLAG_FAST_GLYPHS       = 1 <<  7;
+    static final int FT_FACE_FLAG_MULTIPLE_MASTERS  = 1 <<  8;
+    static final int FT_FACE_FLAG_GLYPH_NAMES       = 1 <<  9;
+    static final int FT_FACE_FLAG_EXTERNAL_STREAM   = 1 << 10;
+    static final int FT_FACE_FLAG_HINTER            = 1 << 11;
+    static final int FT_FACE_FLAG_CID_KEYED         = 1 << 12;
+    static final int FT_FACE_FLAG_TRICKY            = 1 << 13;
+    static final int FT_STYLE_FLAG_ITALIC  = 1 << 0;
+    static final int FT_STYLE_FLAG_BOLD    = 1 << 1;
+    static final int FT_RENDER_MODE_NORMAL = 0;
+    static final int FT_RENDER_MODE_LIGHT = 1;
+    static final int FT_RENDER_MODE_MONO = 2;
+    static final int FT_RENDER_MODE_LCD = 3;
+    static final int FT_RENDER_MODE_LCD_V = 4;
+    static final int FT_PIXEL_MODE_NONE = 0;
+    static final int FT_PIXEL_MODE_MONO = 1;
+    static final int FT_PIXEL_MODE_GRAY = 2;
+    static final int FT_PIXEL_MODE_GRAY2 = 3;
+    static final int FT_PIXEL_MODE_GRAY4 = 4;
+    static final int FT_PIXEL_MODE_LCD = 5;
+    static final int FT_PIXEL_MODE_LCD_V = 6;
+    static final int FT_LOAD_DEFAULT                      = 0x0;
+    static final int FT_LOAD_NO_SCALE                     = 1 << 0;
+    static final int FT_LOAD_NO_HINTING                   = 1 << 1;
+    static final int FT_LOAD_RENDER                       = 1 << 2;
+    static final int FT_LOAD_NO_BITMAP                    = 1 << 3;
+    static final int FT_LOAD_VERTICAL_LAYOUT              = 1 << 4;
+    static final int FT_LOAD_FORCE_AUTOHINT               = 1 << 5;
+    static final int FT_LOAD_CROP_BITMAP                  = 1 << 6;
+    static final int FT_LOAD_PEDANTIC                     = 1 << 7;
+    static final int FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH  = 1 << 9;
+    static final int FT_LOAD_NO_RECURSE                   = 1 << 10;
+    static final int FT_LOAD_IGNORE_TRANSFORM             = 1 << 11;
+    static final int FT_LOAD_MONOCHROME                   = 1 << 12;
+    static final int FT_LOAD_LINEAR_DESIGN                = 1 << 13;
+    static final int FT_LOAD_NO_AUTOHINT                  = 1 << 15;
+    static final int FT_LOAD_TARGET_NORMAL  = (FT_RENDER_MODE_NORMAL & 15 ) << 16;
+    static final int FT_LOAD_TARGET_LIGHT   = (FT_RENDER_MODE_LIGHT  & 15 ) << 16;
+    static final int FT_LOAD_TARGET_MONO    = (FT_RENDER_MODE_MONO   & 15 ) << 16;
+    static final int FT_LOAD_TARGET_LCD     = (FT_RENDER_MODE_LCD    & 15 ) << 16;
+    static final int FT_LOAD_TARGET_LCD_V   = (FT_RENDER_MODE_LCD_V  & 15 ) << 16;
+    static final int FT_LCD_FILTER_NONE    = 0;
+    static final int FT_LCD_FILTER_DEFAULT = 1;
+    static final int FT_LCD_FILTER_LIGHT   = 2;
+    static final int FT_LCD_FILTER_LEGACY  = 16;
+
+    static final int FT_LOAD_TARGET_MODE(int x) {
+        return (x >> 16 ) & 15;
+    }
+
+    static final native Path2D FT_Outline_Decompose(long face);
+    static final native int FT_Init_FreeType(long[] alibrary);
+    static final native int FT_Done_FreeType(long library);
+    static final native void FT_Library_Version(long library, int[] amajor, int[] aminor, int[] apatch);
+    static final native int FT_Library_SetLcdFilter(long library, int filter);
+    static final native int FT_New_Face(long library, byte[] filepathname, long face_index, long[] aface);
+    static final native int FT_Done_Face(long face);
+    static final native int FT_Get_Char_Index(long face, long charcode);
+    static final native int FT_Set_Char_Size(long face, long char_width, long char_height, int horz_resolution, int vert_resolution);
+    static final native int FT_Load_Glyph(long face, int glyph_index, int load_flags);
+    static final native void FT_Set_Transform(long face, FT_Matrix matrix, long delta_x, long delta_y);
+    static final native FT_GlyphSlotRec getGlyphSlot(long face);
+    static final native byte[] getBitmapData(long face);
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/pango/PangoFactory.java	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,113 @@
+/*
+ * 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 com.sun.javafx.font.pango;
+
+import com.sun.javafx.font.PrismFontFactory;
+import com.sun.javafx.font.PrismFontFile;
+import com.sun.javafx.text.GlyphLayout;
+
+public class PangoFactory extends PrismFontFactory {
+
+    static boolean LCD_SUPPORT;
+
+    public static PrismFontFactory getFactory() {
+        PrismFontFactory factory = null;
+        long[] ptr = new long[1];
+        int error = OS.FT_Init_FreeType(ptr);
+        long library = ptr[0];
+        int[] major = new int[1], minor = new int[1], patch = new int[1];
+        if (error == 0) {
+            factory = new PangoFactory();
+            OS.FT_Library_Version(library, major, minor, patch);
+
+            /* This implementation only supports LDC if freetype has support. */
+            error = OS.FT_Library_SetLcdFilter(library, OS.FT_LCD_FILTER_DEFAULT);
+            LCD_SUPPORT = error == 0;
+            OS.FT_Done_FreeType(library);
+        }
+        if (PrismFontFactory.debugFonts) {
+            if (factory != null) {
+                String version = major[0] + "." + minor[0] + "." + patch[0];
+                System.err.println("Freetype2 Loaded (version " + version + ")");
+                String lcdSupport = LCD_SUPPORT ? "Enabled" : "Disabled";
+                System.err.println("LCD support " + lcdSupport);
+            } else {
+                System.err.println("Freetype2 Failed (error " + error + ")");
+            }
+        }
+        return factory;
+    }
+
+    private PangoFactory() {
+    }
+
+    @Override
+    protected PrismFontFile createFontFile(String name, String filename,
+            int fIndex, boolean register, boolean embedded, boolean copy,
+            boolean tracked) throws Exception {
+        return new FTFontFile(name, filename, fIndex, register,
+                                 embedded, copy, tracked);
+    }
+
+    @Override
+    public GlyphLayout createGlyphLayout() {
+        /* Implementing a HarfbuzzGlyphLayout would needed in order to support
+         * font features and non-hinted glyph advances.  */
+        return new PangoGlyphLayout();
+    }
+
+    @Override
+    protected boolean registerEmbeddedFont(String path) {
+        boolean result = false;
+
+        /* Test if freetype supports the file */
+        long[] ptr = new long[1];
+        int error = OS.FT_Init_FreeType(ptr);
+        if (error == 0) {
+            long library = ptr[0];
+            byte[] buffer = (path+"\0").getBytes();
+            error = OS.FT_New_Face(library, buffer, 0, ptr);
+            if (error == 0) {
+                result = true;
+                OS.FT_Done_Face(ptr[0]);
+            }
+            OS.FT_Done_FreeType(library);
+        }
+        /* Test if fontconfig supports the file  */
+        if (result) {
+            /* Adding the file to fontconfig so it can be used by pango */
+            result = OS.FcConfigAppFontAddFile(0, path);
+        }
+        if (debugFonts) {
+            if (result) {
+                System.err.println("[PANGO] Font registration succeeded:" + path);
+            } else {
+                System.err.println("[PANGO] Font registration failed:" + path);
+            }
+        }
+        return result;
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/pango/PangoGlyphInfo.java	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,34 @@
+/*
+ * 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 com.sun.javafx.font.pango;
+
+class PangoGlyphInfo {
+    int glyph;
+    /* Inline PangoGlyphGeometry */
+    int width;
+    int x_offset;
+    int y_offset;
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/pango/PangoGlyphLayout.java	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,157 @@
+/*
+ * 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 com.sun.javafx.font.pango;
+
+import java.nio.ByteBuffer;
+import java.nio.CharBuffer;
+import java.nio.charset.Charset;
+import java.nio.charset.CharsetEncoder;
+import java.nio.charset.CoderResult;
+import java.nio.charset.StandardCharsets;
+import com.sun.javafx.font.CompositeFontResource;
+import com.sun.javafx.font.FontResource;
+import com.sun.javafx.font.FontStrike;
+import com.sun.javafx.font.PGFont;
+import com.sun.javafx.font.PrismFontFactory;
+import com.sun.javafx.scene.text.TextSpan;
+import com.sun.javafx.text.GlyphLayout;
+import com.sun.javafx.text.PrismTextLayout;
+import com.sun.javafx.text.TextRun;
+
+class PangoGlyphLayout extends GlyphLayout {
+
+    private int getSlot(PGFont font, PangoGlyphString glyphString) {
+        CompositeFontResource fr = (CompositeFontResource)font.getFontResource();
+        long fallbackFont = glyphString.font;
+        long fallbackFd = OS.pango_font_describe(fallbackFont);
+        String fallbackFamily = OS.pango_font_description_get_family(fallbackFd);
+        int fallbackStyle = OS.pango_font_description_get_style(fallbackFd);
+        int fallbackWeight = OS.pango_font_description_get_weight(fallbackFd);
+        OS.pango_font_description_free(fallbackFd);
+        boolean bold = fallbackWeight == OS.PANGO_WEIGHT_BOLD;
+        boolean italic = fallbackStyle != OS.PANGO_STYLE_NORMAL;
+
+        PrismFontFactory prismFactory = PrismFontFactory.getFontFactory();
+        PGFont fallbackPGFont = prismFactory.createFont(fallbackFamily, bold,
+                                                        italic, font.getSize());
+        String fallbackFullname =  fallbackPGFont.getFullName();
+        String primaryFullname = fr.getSlotResource(0).getFullName();
+
+        int slot = 0;
+        if (!fallbackFullname.equalsIgnoreCase(primaryFullname)) {
+            slot = fr.getSlotForFont(fallbackFullname) << 24;
+            if (PrismFontFactory.debugFonts) {
+                System.err.println("\tFallback front= "+ fallbackFullname + " slot=" + (slot>>24));
+            }
+        }
+        return slot;
+    }
+
+    protected TextRun addTextRun(PrismTextLayout layout, char[] chars, int start,
+                                 int length, PGFont font, TextSpan span, byte level) {
+
+        TextRun textRun = null;
+        Charset utf8 = StandardCharsets.UTF_8;
+        CharsetEncoder encoder = utf8.newEncoder();
+        CharBuffer in = CharBuffer.wrap(chars, start, length);
+        int capacity = (int)(length * (double)encoder.averageBytesPerChar());
+        ByteBuffer out = ByteBuffer.allocateDirect(capacity);
+        CoderResult result = encoder.encode(in, out, true);
+        if (result.isOverflow()) {
+            capacity = (int)(length * (double)encoder.maxBytesPerChar());
+            in.rewind();
+            out = ByteBuffer.allocateDirect(capacity);
+            encoder.encode(in, out, true);
+            if (PrismFontFactory.debugFonts) {
+                System.err.println("[PANGO] ByteBuffer capacity increased " + out);
+            }
+        }
+
+        FontResource fr = font.getFontResource();
+        boolean composite = fr instanceof CompositeFontResource;
+        if (composite) {
+            fr = ((CompositeFontResource)fr).getSlotResource(0);
+        }
+
+        long fontmap = OS.pango_ft2_font_map_new();
+        long context = OS.pango_font_map_create_context(fontmap);
+        float size = font.getSize();
+        int style = fr.isItalic() ? OS.PANGO_STYLE_ITALIC : OS.PANGO_STYLE_NORMAL;
+        int weight = fr.isBold() ? OS.PANGO_WEIGHT_BOLD : OS.PANGO_WEIGHT_NORMAL;
+        long desc = OS.pango_font_description_new();
+        OS.pango_font_description_set_family(desc, fr.getFamilyName());
+        OS.pango_font_description_set_absolute_size(desc, size * OS.PANGO_SCALE);
+        OS.pango_font_description_set_stretch(desc, OS.PANGO_STRETCH_NORMAL);
+        OS.pango_font_description_set_style(desc, style);
+        OS.pango_font_description_set_weight(desc, weight);
+        long attrList = OS.pango_attr_list_new();
+        long attr = OS.pango_attr_font_desc_new(desc);
+        OS.pango_attr_list_insert(attrList, attr);
+        if (!composite) {
+            attr = OS.pango_attr_fallback_new(false);
+            OS.pango_attr_list_insert(attrList, attr);
+        }
+        long runs = OS.pango_itemize(context, out, 0, out.position(), attrList, 0);
+        int runsCount = OS.g_list_length(runs);
+        int runStart = start;
+        for (int i = 0; i < runsCount; i++) {
+            long pangoItem = OS.g_list_nth_data(runs, i);
+            PangoGlyphString glyphString = OS.pango_shape(out, pangoItem);
+            OS.pango_item_free(pangoItem);
+            int slot = composite ? getSlot(font, glyphString) : 0;
+            int glyphCount = glyphString.num_glyphs;
+            int[] glyphs = new int[glyphCount];
+            float[] pos = new float[glyphCount*2+2];
+            PangoGlyphInfo info = null;
+            int k = 2;
+            int width = 0;
+            for (int j = 0; j < glyphCount; j++) {
+                info = glyphString.glyphs[j];
+                glyphs[j] = slot | info.glyph;
+                width += info.width;
+                pos[k] = ((float)width) / OS.PANGO_SCALE;
+                k += 2;
+            }
+
+            int runLength = glyphString.num_chars;
+            textRun = new TextRun(runStart, runLength, level, true, 0, span, 0, false);
+            textRun.shape(glyphCount, glyphs, pos, glyphString.log_clusters);
+            layout.addTextRun(textRun);
+            runStart += runLength;
+        }
+        OS.g_list_free(runs);
+        /* pango_attr_list_unref() also frees the attributes it contains */
+        OS.pango_attr_list_unref(attrList);
+        OS.pango_font_description_free(desc);
+        OS.g_object_unref(context);
+        OS.g_object_unref(fontmap);
+        return textRun;
+    }
+
+    public void layout(TextRun run, PGFont font, FontStrike strike, char[] text) {
+        // Nothing - complex run are analyzed by Pango during break run
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/modules/graphics/src/main/java/com/sun/javafx/font/pango/PangoGlyphString.java	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,38 @@
+/*
+ * 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 com.sun.javafx.font.pango;
+
+class PangoGlyphString {
+    /* Fields from PangoItem */
+    int offset;
+    int length;
+    int num_chars;
+    /* pangoItem->analysis->font*/
+    long font;
+    int num_glyphs;
+    PangoGlyphInfo[] glyphs;
+    int[] log_clusters;
+}
--- a/modules/graphics/src/main/java/com/sun/javafx/text/GlyphLayout.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/graphics/src/main/java/com/sun/javafx/text/GlyphLayout.java	Wed Jul 10 11:01:52 2013 +0400
@@ -56,9 +56,20 @@
  */
 package com.sun.javafx.text;
 
+import static com.sun.javafx.scene.text.TextLayout.FLAGS_ANALYSIS_VALID;
+import static com.sun.javafx.scene.text.TextLayout.FLAGS_HAS_BIDI;
+import static com.sun.javafx.scene.text.TextLayout.FLAGS_HAS_COMPLEX;
+import static com.sun.javafx.scene.text.TextLayout.FLAGS_HAS_EMBEDDED;
+import static com.sun.javafx.scene.text.TextLayout.FLAGS_HAS_TABS;
+import static com.sun.javafx.scene.text.TextLayout.FLAGS_RTL_BASE;
+
+import java.text.Bidi;
+
+import com.sun.javafx.font.FontResource;
 import com.sun.javafx.font.FontStrike;
 import com.sun.javafx.font.PGFont;
 import com.sun.javafx.font.PrismFontFactory;
+import com.sun.javafx.scene.text.TextSpan;
 
 public abstract class GlyphLayout {
 
@@ -84,7 +95,211 @@
 
     public static final int HINTING = 1 << 4;
 
-    public abstract int breakRuns(PrismTextLayout layout, char[] text, int flags);
+    protected TextRun addTextRun(PrismTextLayout layout, char[] chars,
+                                 int start, int length,
+                                 PGFont font, TextSpan span, byte level) {
+        /* subclass can overwrite this method in order to handle complex text */
+        TextRun run = new TextRun(start, length, level, false, 0, span, 0, false);
+        layout.addTextRun(run);
+        return run;
+    }
+
+    private TextRun addTextRun(PrismTextLayout layout, char[] chars,
+                               int start, int length, PGFont font,
+                               TextSpan span, byte level, boolean complex) {
+        if (complex) {
+            return addTextRun(layout, chars, start, length, font, span, level);
+        }
+        TextRun run = new TextRun(start, length, level, false, 0, span, 0, false);
+        layout.addTextRun(run);
+        return run;
+    }
+
+    public int breakRuns(PrismTextLayout layout, char[] chars, int flags) {
+        int length = chars.length;
+        boolean complexRun = false;
+        boolean complex = false;
+        boolean feature = false;
+
+        boolean checkComplex = true;
+        boolean checkBidi = true;
+        if ((flags & FLAGS_ANALYSIS_VALID) != 0) {
+            /* Avoid work when it is known neither complex
+             * text nor bidi are not present. */
+            checkComplex = (flags & FLAGS_HAS_COMPLEX) != 0;
+            checkBidi = (flags & FLAGS_HAS_BIDI) != 0;
+        }
+
+        TextRun run = null;
+        Bidi bidi = null;
+        byte bidiLevel = 0;
+        int bidiEnd = length;
+        int bidiIndex = 0;
+        int spanIndex = 0;
+        TextSpan span = null;
+        int spanEnd = length;
+        PGFont font = null;
+        TextSpan[] spans = layout.getTextSpans();
+        if (spans != null) {
+            if (spans.length > 0) {
+                span = spans[spanIndex];
+                spanEnd = span.getText().length();
+                font = (PGFont)span.getFont();
+                if (font == null) {
+                    flags |= FLAGS_HAS_EMBEDDED;
+                }
+            }
+        } else {
+            font = layout.getFont();
+        }
+        if (font != null) {
+            FontResource fr = font.getFontResource();
+            int requestedFeatures = font.getFeatures();
+            int supportedFeatures = fr.getFeatures();
+            feature = (requestedFeatures & supportedFeatures) != 0;
+        }
+        if (checkBidi && length > 0) {
+            int direction = layout.getDirection();
+            bidi = new Bidi(chars, 0, null, 0, length, direction);
+            /* Temporary Code: See RT-26997 */
+//            bidiLevel = (byte)bidi.getRunLevel(bidiIndex);
+            bidiLevel = (byte)bidi.getLevelAt(bidi.getRunStart(bidiIndex));
+            bidiEnd = bidi.getRunLimit(bidiIndex);
+            if ((bidiLevel & 1) != 0) {
+                flags |= FLAGS_HAS_BIDI;
+            }
+        }
+
+        int start = 0;
+        int i = 0;
+        while (i < length) {
+            char ch = chars[i];
+            int codePoint = ch;
+
+            boolean delimiterChanged = ch == '\t' || ch == '\n' || ch == '\r';
+            boolean spanChanged = i >= spanEnd;
+            boolean levelChanged = i >= bidiEnd;
+            boolean complexChanged = false;
+
+            if (checkComplex) {
+                if (Character.isHighSurrogate(ch)) {
+                    /* Only merge surrogate when the pair is in the same span. */
+                    if (i + 1 < spanEnd && Character.isLowSurrogate(chars[i + 1])) {
+                        codePoint = Character.toCodePoint(ch, chars[++i]);
+                    }
+                }
+                if (Character.isWhitespace(codePoint)) {
+                    complex = feature || complexRun;
+                } else {
+                    complex = feature || ScriptMapper.isComplexCharCode(codePoint);
+                }
+                complexChanged = complex != complexRun;
+            }
+
+            if (delimiterChanged || spanChanged || levelChanged || complexChanged) {
+
+                /* Create text run */
+                if (i != start) {
+                    run = addTextRun(layout, chars, start, i - start,
+                                     font, span, bidiLevel, complexRun);
+                    if (complexRun) {
+                        flags |= FLAGS_HAS_COMPLEX;
+                    }
+                    start = i;
+                }
+
+                if (delimiterChanged) {
+                    i++;
+                    /* Only merge \r\n when the are in the same text span */
+                    if (ch == '\r' && i < spanEnd && chars[i] == '\n') {
+                        i++;
+                    }
+
+                    /* Create delimiter run */
+                    run = new TextRun(start, i - start, bidiLevel, false,
+                                      ScriptMapper.COMMON, span, 0, false);
+                    if (ch == '\t') {
+                        run.setTab();
+                        flags |= FLAGS_HAS_TABS;
+                    } else {
+                        run.setLinebreak();
+                    }
+                    layout.addTextRun(run);
+
+                    start = i;
+                    if (i == length) break;
+                    spanChanged = i >= spanEnd;
+                    levelChanged = i >= bidiEnd;
+                }
+                if (spanChanged) {
+                    /* Only true for rich text (spans != null) */
+                    span = spans[++spanIndex];
+                    spanEnd += span.getText().length();
+                    font = (PGFont)span.getFont();
+                    if (font == null) {
+                        flags |= FLAGS_HAS_EMBEDDED;
+                    } else {
+                        FontResource fr = font.getFontResource();
+                        int requestedFeatures = font.getFeatures();
+                        int supportedFeatures = fr.getFeatures();
+                        feature = (requestedFeatures & supportedFeatures) != 0;
+                    }
+                }
+                if (levelChanged) {
+                    bidiIndex++;
+                    /* Temporary Code: See RT-26997 */
+//                    bidiLevel = (byte)bidi.getRunLevel(bidiIndex);
+                    bidiLevel = (byte)bidi.getLevelAt(bidi.getRunStart(bidiIndex));
+                    bidiEnd = bidi.getRunLimit(bidiIndex);
+                    if ((bidiLevel & 1) != 0) {
+                        flags |= FLAGS_HAS_BIDI;
+                    }
+                }
+
+                if (complexChanged) {
+                    if (delimiterChanged) {
+                        ch = chars[i]; /* update ch because of delimiterChanged */
+                        if (Character.isHighSurrogate(ch)) {
+                            /* Only merge surrogate when the pair is in the same span */
+                            if (i + 1 < spanEnd && Character.isLowSurrogate(chars[i + 1])) {
+                                codePoint = Character.toCodePoint(ch, chars[++i]);
+                            }
+                        }
+                        if (Character.isWhitespace(codePoint)) {
+                            complex = feature || complexRun;
+                        } else {
+                            complex = feature || ScriptMapper.isComplexCharCode(codePoint);
+                        }
+                    }
+                    complexRun = complex;
+                }
+            }
+            if (!delimiterChanged) i++;
+        }
+
+        /* Create final text run */
+        if (start < length) {
+            addTextRun(layout, chars, start, length - start,
+                       font, span, bidiLevel, complexRun);
+            if (complexRun) {
+                flags |= FLAGS_HAS_COMPLEX;
+            }
+        } else {
+            /* Ensure every lines has at least one run */
+            if (run == null || run.isLinebreak()) {
+                run = new TextRun(start, 0, (byte)0, false,
+                                  ScriptMapper.COMMON, span, 0, false);
+                layout.addTextRun(run);
+            }
+        }
+        if (bidi != null) {
+            if (!bidi.baseIsLeftToRight()) {
+                flags |= FLAGS_RTL_BASE;
+            }
+        }
+        flags |= FLAGS_ANALYSIS_VALID;
+        return flags;
+    }
 
     public abstract void layout(TextRun run, PGFont font,
                                 FontStrike strike, char[] text);
--- a/modules/graphics/src/main/java/javafx/stage/FileChooser.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/graphics/src/main/java/javafx/stage/FileChooser.java	Wed Jul 10 11:01:52 2013 +0400
@@ -251,7 +251,7 @@
      * file open dialogs.
      * </p>
      *
-     * @since JavaFX 8.0
+     * @since JavaFX 2.2.40
      */
     private ObjectProperty<String> initialFileName;
 
--- a/modules/graphics/src/main/native-font/coretext.c	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/graphics/src/main/native-font/coretext.c	Wed Jul 10 11:01:52 2013 +0400
@@ -26,13 +26,20 @@
 #ifdef __APPLE__
 #include <TargetConditionals.h>
 
-#if TARGET_OS_MAC && !(TARGET_OS_IPHONE)
+#if TARGET_OS_MAC
 
 #include <jni.h>
 #include <com_sun_javafx_font_coretext_OS.h>
 
 #import <CoreFoundation/CoreFoundation.h>
+
+#if TARGET_OS_IPHONE
+#import <CoreGraphics/CoreGraphics.h>
+#import <CoreText/CoreText.h>
+#else
 #import <ApplicationServices/ApplicationServices.h>
+#endif
+
 
 #define OS_NATIVE(func) Java_com_sun_javafx_font_coretext_OS_##func
 
@@ -788,21 +795,22 @@
     if (tableData == NULL) return FALSE;
     length = CFDataGetLength(tableData);
     UInt32 offset1 = 0, offset2 = 0;
+    UInt32 index = arg2 & 0xFFFF;
     if (indexToLocFormat) {
         const UInt32 * loca = (const UInt32 *)CFDataGetBytePtr(tableData);
         if (loca != NULL && length / 4 > arg2) {
-            offset1 = CFSwapInt32BigToHost(loca[arg2]);
-            offset2 = CFSwapInt32BigToHost(loca[arg2 + 1]);
+            offset1 = CFSwapInt32BigToHost(loca[index]);
+            offset2 = CFSwapInt32BigToHost(loca[index + 1]);
         }
     } else {
         const UInt16 * loca = (const UInt16 *)CFDataGetBytePtr(tableData);
         if (loca != NULL && length / 2 > arg2) {
-            offset1 = CFSwapInt16BigToHost(loca[arg2]) << 1;
-            offset2 = CFSwapInt16BigToHost(loca[arg2 + 1]) << 1;
+            offset1 = CFSwapInt16BigToHost(loca[index]) << 1;
+            offset2 = CFSwapInt16BigToHost(loca[index + 1]) << 1;
         }
     }
     CFRelease(tableData);
-
+    jboolean result = FALSE;
     if (offset2 > offset1 && (offset2 - offset1) >= 10) {
         tableData = CTFontCopyTable(fontRef, kCTFontTableGlyf, options);
         if (tableData == NULL) return FALSE;
@@ -821,10 +829,11 @@
                 (SInt16)CFSwapInt16BigToHost(glyf[4]),
             };
             (*env)->SetIntArrayRegion(env, arg4, 0, 4, data);
+            result = TRUE;
         }
         CFRelease(tableData);
     }
-    return TRUE;
+    return result;
 }
 
 JNIEXPORT jdouble JNICALL OS_NATIVE(CTFontGetAdvancesForGlyphs)
--- a/modules/graphics/src/main/native-font/dfontdecoder.c	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/graphics/src/main/native-font/dfontdecoder.c	Wed Jul 10 11:01:52 2013 +0400
@@ -26,13 +26,19 @@
 #ifdef __APPLE__
 #include <TargetConditionals.h>
 
-#if TARGET_OS_MAC && !(TARGET_OS_IPHONE)
+#if TARGET_OS_MAC
 
 #include <jni.h>
 #include <com_sun_javafx_font_DFontDecoder.h>
 
 #import <CoreFoundation/CoreFoundation.h>
+
+#if TARGET_OS_IPHONE
+#import <CoreGraphics/CoreGraphics.h>
+#import <CoreText/CoreText.h>
+#else
 #import <ApplicationServices/ApplicationServices.h>
+#endif
 
 
 JNIEXPORT jlong JNICALL Java_com_sun_javafx_font_DFontDecoder_createCTFont
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/modules/graphics/src/main/native-font/freetype.c	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,474 @@
+/*
+ * 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.
+ */
+
+#if defined __linux__
+#if defined _ENABLE_PANGO
+
+#include <jni.h>
+#include <com_sun_javafx_font_pango_OS.h>
+#include <dlfcn.h>
+#include <ft2build.h>
+#include FT_FREETYPE_H
+#include FT_OUTLINE_H
+#include FT_LCD_FILTER_H
+
+#define OS_NATIVE(func) Java_com_sun_javafx_font_pango_OS_##func
+
+/**************************************************************************/
+/*                                                                        */
+/*                            Structs                                     */
+/*                                                                        */
+/**************************************************************************/
+
+typedef struct FT_Matrix_FID_CACHE {
+    int cached;
+    jfieldID xx, xy, yx, yy;
+} FT_Matrix_FID_CACHE;
+
+FT_Matrix_FID_CACHE FT_MatrixFc;
+
+void cacheFT_MatrixFields(JNIEnv *env, jobject lpObject)
+{
+    if (FT_MatrixFc.cached) return;
+    jclass clazz = (*env)->GetObjectClass(env, lpObject);
+    FT_MatrixFc.xx = (*env)->GetFieldID(env, clazz, "xx", "J");
+    FT_MatrixFc.xy = (*env)->GetFieldID(env, clazz, "xy", "J");
+    FT_MatrixFc.yx = (*env)->GetFieldID(env, clazz, "yx", "J");
+    FT_MatrixFc.yy = (*env)->GetFieldID(env, clazz, "yy", "J");
+    FT_MatrixFc.cached = 1;
+}
+
+FT_Matrix *getFT_MatrixFields(JNIEnv *env, jobject lpObject, FT_Matrix *lpStruct)
+{
+    if (!FT_MatrixFc.cached) cacheFT_MatrixFields(env, lpObject);
+    lpStruct->xx = (FT_Fixed)(*env)->GetLongField(env, lpObject, FT_MatrixFc.xx);
+    lpStruct->xy = (FT_Fixed)(*env)->GetLongField(env, lpObject, FT_MatrixFc.xy);
+    lpStruct->yx = (FT_Fixed)(*env)->GetLongField(env, lpObject, FT_MatrixFc.yx);
+    lpStruct->yy = (FT_Fixed)(*env)->GetLongField(env, lpObject, FT_MatrixFc.yy);
+    return lpStruct;
+}
+
+typedef struct FT_Bitmap_FID_CACHE {
+    int cached;
+    jfieldID rows, width, pitch, buffer, num_grays, pixel_mode, palette_mode, palette;
+} FT_Bitmap_FID_CACHE;
+
+FT_Bitmap_FID_CACHE FT_BitmapFc;
+
+void cacheFT_BitmapFields(JNIEnv *env, jobject lpObject)
+{
+    if (FT_BitmapFc.cached) return;
+    jclass clazz = (*env)->GetObjectClass(env, lpObject);
+    FT_BitmapFc.rows = (*env)->GetFieldID(env, clazz, "rows", "I");
+    FT_BitmapFc.width = (*env)->GetFieldID(env, clazz, "width", "I");
+    FT_BitmapFc.pitch = (*env)->GetFieldID(env, clazz, "pitch", "I");
+    FT_BitmapFc.buffer = (*env)->GetFieldID(env, clazz, "buffer", "J");
+    FT_BitmapFc.num_grays = (*env)->GetFieldID(env, clazz, "num_grays", "S");
+    FT_BitmapFc.pixel_mode = (*env)->GetFieldID(env, clazz, "pixel_mode", "B");
+    FT_BitmapFc.palette_mode = (*env)->GetFieldID(env, clazz, "palette_mode", "C");
+    FT_BitmapFc.palette = (*env)->GetFieldID(env, clazz, "palette", "J");
+    FT_BitmapFc.cached = 1;
+}
+
+void setFT_BitmapFields(JNIEnv *env, jobject lpObject, FT_Bitmap *lpStruct)
+{
+    if (!FT_BitmapFc.cached) cacheFT_BitmapFields(env, lpObject);
+    (*env)->SetIntField(env, lpObject, FT_BitmapFc.rows, (jint)lpStruct->rows);
+    (*env)->SetIntField(env, lpObject, FT_BitmapFc.width, (jint)lpStruct->width);
+    (*env)->SetIntField(env, lpObject, FT_BitmapFc.pitch, (jint)lpStruct->pitch);
+    (*env)->SetLongField(env, lpObject, FT_BitmapFc.buffer, (jlong)lpStruct->buffer);
+    (*env)->SetShortField(env, lpObject, FT_BitmapFc.num_grays, (jshort)lpStruct->num_grays);
+    (*env)->SetByteField(env, lpObject, FT_BitmapFc.pixel_mode, (jbyte)lpStruct->pixel_mode);
+    (*env)->SetCharField(env, lpObject, FT_BitmapFc.palette_mode, (jchar)lpStruct->palette_mode);
+    (*env)->SetLongField(env, lpObject, FT_BitmapFc.palette, (jlong)lpStruct->palette);
+}
+
+typedef struct FT_Glyph_Metrics_FID_CACHE {
+    int cached;
+    jfieldID width, height, horiBearingX, horiBearingY, horiAdvance, vertBearingX, vertBearingY, vertAdvance;
+} FT_Glyph_Metrics_FID_CACHE;
+
+FT_Glyph_Metrics_FID_CACHE FT_Glyph_MetricsFc;
+
+void cacheFT_Glyph_MetricsFields(JNIEnv *env, jobject lpObject)
+{
+    if (FT_Glyph_MetricsFc.cached) return;
+    jclass clazz = (*env)->GetObjectClass(env, lpObject);
+    FT_Glyph_MetricsFc.width = (*env)->GetFieldID(env, clazz, "width", "J");
+    FT_Glyph_MetricsFc.height = (*env)->GetFieldID(env, clazz, "height", "J");
+    FT_Glyph_MetricsFc.horiBearingX = (*env)->GetFieldID(env, clazz, "horiBearingX", "J");
+    FT_Glyph_MetricsFc.horiBearingY = (*env)->GetFieldID(env, clazz, "horiBearingY", "J");
+    FT_Glyph_MetricsFc.horiAdvance = (*env)->GetFieldID(env, clazz, "horiAdvance", "J");
+    FT_Glyph_MetricsFc.vertBearingX = (*env)->GetFieldID(env, clazz, "vertBearingX", "J");
+    FT_Glyph_MetricsFc.vertBearingY = (*env)->GetFieldID(env, clazz, "vertBearingY", "J");
+    FT_Glyph_MetricsFc.vertAdvance = (*env)->GetFieldID(env, clazz, "vertAdvance", "J");
+    FT_Glyph_MetricsFc.cached = 1;
+}
+
+void setFT_Glyph_MetricsFields(JNIEnv *env, jobject lpObject, FT_Glyph_Metrics *lpStruct)
+{
+    if (!FT_Glyph_MetricsFc.cached) cacheFT_Glyph_MetricsFields(env, lpObject);
+    (*env)->SetLongField(env, lpObject, FT_Glyph_MetricsFc.width, (jlong)lpStruct->width);
+    (*env)->SetLongField(env, lpObject, FT_Glyph_MetricsFc.height, (jlong)lpStruct->height);
+    (*env)->SetLongField(env, lpObject, FT_Glyph_MetricsFc.horiBearingX, (jlong)lpStruct->horiBearingX);
+    (*env)->SetLongField(env, lpObject, FT_Glyph_MetricsFc.horiBearingY, (jlong)lpStruct->horiBearingY);
+    (*env)->SetLongField(env, lpObject, FT_Glyph_MetricsFc.horiAdvance, (jlong)lpStruct->horiAdvance);
+    (*env)->SetLongField(env, lpObject, FT_Glyph_MetricsFc.vertBearingX, (jlong)lpStruct->vertBearingX);
+    (*env)->SetLongField(env, lpObject, FT_Glyph_MetricsFc.vertBearingY, (jlong)lpStruct->vertBearingY);
+    (*env)->SetLongField(env, lpObject, FT_Glyph_MetricsFc.vertAdvance, (jlong)lpStruct->vertAdvance);
+}
+
+typedef struct FT_GlyphSlotRec_FID_CACHE {
+    int cached;
+    jclass clazz;
+    jfieldID metrics, linearHoriAdvance, linearVertAdvance, advance_x, advance_y, format, bitmap, bitmap_left, bitmap_top;
+    jmethodID init;
+} FT_GlyphSlotRec_FID_CACHE;
+
+FT_GlyphSlotRec_FID_CACHE FT_GlyphSlotRecFc;
+
+void cacheFT_GlyphSlotRecFields(JNIEnv *env)
+{
+    if (FT_GlyphSlotRecFc.cached) return;
+    jclass tmpClass = (*env)->FindClass(env, "com/sun/javafx/font/pango/FT_GlyphSlotRec");
+    FT_GlyphSlotRecFc.clazz =  (jclass)(*env)->NewGlobalRef(env, tmpClass);
+    FT_GlyphSlotRecFc.metrics = (*env)->GetFieldID(env, FT_GlyphSlotRecFc.clazz, "metrics", "Lcom/sun/javafx/font/pango/FT_Glyph_Metrics;");
+    FT_GlyphSlotRecFc.linearHoriAdvance = (*env)->GetFieldID(env, FT_GlyphSlotRecFc.clazz, "linearHoriAdvance", "J");
+    FT_GlyphSlotRecFc.linearVertAdvance = (*env)->GetFieldID(env, FT_GlyphSlotRecFc.clazz, "linearVertAdvance", "J");
+    FT_GlyphSlotRecFc.advance_x = (*env)->GetFieldID(env, FT_GlyphSlotRecFc.clazz, "advance_x", "J");
+    FT_GlyphSlotRecFc.advance_y = (*env)->GetFieldID(env, FT_GlyphSlotRecFc.clazz, "advance_y", "J");
+    FT_GlyphSlotRecFc.format = (*env)->GetFieldID(env, FT_GlyphSlotRecFc.clazz, "format", "I");
+    FT_GlyphSlotRecFc.bitmap = (*env)->GetFieldID(env, FT_GlyphSlotRecFc.clazz, "bitmap", "Lcom/sun/javafx/font/pango/FT_Bitmap;");
+    FT_GlyphSlotRecFc.bitmap_left = (*env)->GetFieldID(env, FT_GlyphSlotRecFc.clazz, "bitmap_left", "I");
+    FT_GlyphSlotRecFc.bitmap_top = (*env)->GetFieldID(env, FT_GlyphSlotRecFc.clazz, "bitmap_top", "I");
+    FT_GlyphSlotRecFc.init = (*env)->GetMethodID(env, FT_GlyphSlotRecFc.clazz, "<init>", "()V");
+    FT_GlyphSlotRecFc.cached = 1;
+}
+
+void setFT_GlyphSlotRecFields(JNIEnv *env, jobject lpObject, FT_GlyphSlotRec *lpStruct)
+{
+    if (!FT_GlyphSlotRecFc.cached) cacheFT_GlyphSlotRecFields(env);
+    {
+    jobject lpObject1 = (*env)->GetObjectField(env, lpObject, FT_GlyphSlotRecFc.metrics);
+    if (lpObject1 != NULL) setFT_Glyph_MetricsFields(env, lpObject1, &lpStruct->metrics);
+    }
+    (*env)->SetLongField(env, lpObject, FT_GlyphSlotRecFc.linearHoriAdvance, (jlong)lpStruct->linearHoriAdvance);
+    (*env)->SetLongField(env, lpObject, FT_GlyphSlotRecFc.linearVertAdvance, (jlong)lpStruct->linearVertAdvance);
+    (*env)->SetLongField(env, lpObject, FT_GlyphSlotRecFc.advance_x, (jlong)lpStruct->advance.x);
+    (*env)->SetLongField(env, lpObject, FT_GlyphSlotRecFc.advance_y, (jlong)lpStruct->advance.y);
+    (*env)->SetIntField(env, lpObject, FT_GlyphSlotRecFc.format, (jint)lpStruct->format);
+    {
+    jobject lpObject1 = (*env)->GetObjectField(env, lpObject, FT_GlyphSlotRecFc.bitmap);
+    if (lpObject1 != NULL) setFT_BitmapFields(env, lpObject1, &lpStruct->bitmap);
+    }
+    (*env)->SetIntField(env, lpObject, FT_GlyphSlotRecFc.bitmap_left, (jint)lpStruct->bitmap_left);
+    (*env)->SetIntField(env, lpObject, FT_GlyphSlotRecFc.bitmap_top, (jint)lpStruct->bitmap_top);
+}
+
+jobject newFT_GlyphSlotRec(JNIEnv *env, FT_GlyphSlotRec *lpStruct)
+{
+    jobject lpObject = NULL;
+    if (!FT_GlyphSlotRecFc.cached) cacheFT_GlyphSlotRecFields(env);
+    lpObject = (*env)->NewObject(env, FT_GlyphSlotRecFc.clazz, FT_GlyphSlotRecFc.init);
+    if (lpObject && lpStruct) setFT_GlyphSlotRecFields(env, lpObject, lpStruct);
+    return lpObject;
+}
+
+/**************************************************************************/
+/*                                                                        */
+/*                           Functions                                    */
+/*                                                                        */
+/**************************************************************************/
+
+JNIEXPORT jobject JNICALL OS_NATIVE(getGlyphSlot)(JNIEnv *env, jclass that, jlong facePtr)
+{
+    jobject result = NULL;
+    if (facePtr) {
+        FT_Face face = (FT_Face)facePtr;
+        FT_GlyphSlot slot = face->glyph;
+        if (slot) {
+            result = newFT_GlyphSlotRec(env, slot);
+        }
+    }
+    return result;
+}
+
+JNIEXPORT jbyteArray JNICALL OS_NATIVE(getBitmapData)(JNIEnv *env, jclass that, jlong facePtr)
+{
+    if (!facePtr) return NULL;
+    FT_Face face = (FT_Face)facePtr;
+    FT_GlyphSlot slot = face->glyph;
+    if (!slot) return NULL;
+    FT_Bitmap bitmap = slot->bitmap;
+    unsigned char* src = bitmap.buffer;
+    if (!src) return NULL;
+    size_t size = bitmap.pitch * bitmap.rows;
+    jbyteArray result = (*env)->NewByteArray(env, size);
+    if (result) {
+        unsigned char* dst = (*env)->GetPrimitiveArrayCritical(env, result, NULL);
+        if (dst) {
+            memcpy(dst, src, size);
+            (*env)->ReleasePrimitiveArrayCritical(env, result, dst, 0);
+        }
+    }
+    return result;
+}
+
+JNIEXPORT void JNICALL OS_NATIVE(FT_1Set_1Transform)
+    (JNIEnv *env, jclass that, jlong arg0, jobject arg1, jlong arg2, jlong arg3)
+{
+    FT_Vector *lpDelta = NULL;
+    if (arg2 || arg3) {
+        FT_Vector vec = {arg2, arg3};
+        lpDelta = &vec;
+    }
+    if (arg1) {
+        FT_Matrix matrix, *lpMatrix = NULL;
+        lpMatrix = getFT_MatrixFields(env, arg1, &matrix);
+        if (lpMatrix) {
+            FT_Set_Transform((FT_Face)arg0, lpMatrix, lpDelta);
+        }
+    }
+}
+
+#define LIB_FREETYPE "libfreetype.so"
+JNIEXPORT jint JNICALL OS_NATIVE(FT_1Library_1SetLcdFilter)
+    (JNIEnv *env, jclass that, jlong arg0, jint arg1)
+{
+//  return (jint)FT_Library_SetLcdFilter((FT_Library)arg0, (FT_LcdFilter)arg1);
+    static void *fp = NULL;
+    if (!fp) {
+        void* handle = dlopen(LIB_FREETYPE, RTLD_LAZY);
+        if (handle) fp = dlsym(handle, "FT_Library_SetLcdFilter");
+    }
+    jint rc = 0;
+    if (fp) {
+        rc = (jint)((jint (*)(jlong, jint))fp)(arg0, arg1);
+    }
+    return rc;
+}
+
+JNIEXPORT jint JNICALL OS_NATIVE(FT_1Done_1Face)
+    (JNIEnv *env, jclass that, jlong arg0)
+{
+    return (jint)FT_Done_Face((FT_Face)arg0);
+}
+
+JNIEXPORT void JNICALL OS_NATIVE(FT_1Library_1Version)
+    (JNIEnv *env, jclass that, jlong arg0, jintArray arg1, jintArray arg2, jintArray arg3)
+{
+    jint *lparg1=NULL;
+    jint *lparg2=NULL;
+    jint *lparg3=NULL;
+    if (arg1) if ((lparg1 = (*env)->GetIntArrayElements(env, arg1, NULL)) == NULL) goto fail;
+    if (arg2) if ((lparg2 = (*env)->GetIntArrayElements(env, arg2, NULL)) == NULL) goto fail;
+    if (arg3) if ((lparg3 = (*env)->GetIntArrayElements(env, arg3, NULL)) == NULL) goto fail;
+    FT_Library_Version((FT_Library)arg0, lparg1, lparg2, lparg3);
+fail:
+    if (arg3 && lparg3) (*env)->ReleaseIntArrayElements(env, arg3, lparg3, 0);
+    if (arg2 && lparg2) (*env)->ReleaseIntArrayElements(env, arg2, lparg2, 0);
+    if (arg1 && lparg1) (*env)->ReleaseIntArrayElements(env, arg1, lparg1, 0);
+}
+
+JNIEXPORT jint JNICALL OS_NATIVE(FT_1Done_1FreeType)
+    (JNIEnv *env, jclass that, jlong arg0)
+{
+    return (jint)FT_Done_FreeType((FT_Library)arg0);
+}
+
+JNIEXPORT jint JNICALL OS_NATIVE(FT_1Init_1FreeType)
+    (JNIEnv *env, jclass that, jlongArray arg0)
+{
+    jlong *lparg0=NULL;
+    jint rc = 0;
+    if (arg0) if ((lparg0 = (*env)->GetLongArrayElements(env, arg0, NULL)) == NULL) goto fail;
+    rc = (jint)FT_Init_FreeType((FT_Library  *)lparg0);
+fail:
+    if (arg0 && lparg0) (*env)->ReleaseLongArrayElements(env, arg0, lparg0, 0);
+    return rc;
+}
+
+JNIEXPORT jint JNICALL OS_NATIVE(FT_1Load_1Glyph)
+    (JNIEnv *env, jclass that, jlong arg0, jint arg1, jint arg2)
+{
+    return (jint)FT_Load_Glyph((FT_Face)arg0, (FT_UInt)arg1, (FT_Int32)arg2);
+}
+
+JNIEXPORT jint JNICALL OS_NATIVE(FT_1New_1Face)
+    (JNIEnv *env, jclass that, jlong arg0, jbyteArray arg1, jlong arg2, jlongArray arg3)
+{
+    jbyte *lparg1=NULL;
+    jlong *lparg3=NULL;
+    jint rc = 0;
+    if (arg1) if ((lparg1 = (*env)->GetByteArrayElements(env, arg1, NULL)) == NULL) goto fail;
+    if (arg3) if ((lparg3 = (*env)->GetLongArrayElements(env, arg3, NULL)) == NULL) goto fail;
+    rc = (jint)FT_New_Face((FT_Library)arg0, (const char*)lparg1, (FT_Long)arg2, (FT_Face  *)lparg3);
+fail:
+    if (arg3 && lparg3) (*env)->ReleaseLongArrayElements(env, arg3, lparg3, 0);
+    if (arg1 && lparg1) (*env)->ReleaseByteArrayElements(env, arg1, lparg1, 0);
+    return rc;
+}
+
+JNIEXPORT jint JNICALL OS_NATIVE(FT_1Set_1Char_1Size)
+    (JNIEnv *env, jclass that, jlong arg0, jlong arg1, jlong arg2, jint arg3, jint arg4)
+{
+    return (jint)FT_Set_Char_Size((FT_Face)arg0, (FT_F26Dot6)arg1, (FT_F26Dot6)arg2, (FT_UInt)arg3, (FT_UInt)arg4);
+}
+
+/***********************************************/
+/*                Glyph Outline                */
+/***********************************************/
+
+#define F26DOT6TOFLOAT(n) (float)n/64.0;
+static const int DEFAULT_LEN_TYPES = 10;
+static const int DEFAULT_LEN_COORDS = 50;
+typedef struct _PathData {
+    jbyte* pointTypes;
+    int numTypes;
+    int lenTypes;
+    jfloat* pointCoords;
+    int numCoords;
+    int lenCoords;
+} PathData;
+
+static PathData* checkSize(void* user, int coordCount)
+{
+    PathData* info = (PathData *)user;
+    if (info->numTypes == info->lenTypes) {
+        info->lenTypes += DEFAULT_LEN_TYPES;
+        info->pointTypes = (jbyte*)realloc(info->pointTypes, info->lenTypes * sizeof(jbyte));
+    }
+    if (info->numCoords + (coordCount * 2) > info->lenCoords) {
+        info->lenCoords += DEFAULT_LEN_COORDS;
+        info->pointCoords = (jfloat*)realloc(info->pointCoords, info->lenCoords * sizeof(jfloat));
+    }
+    return info;
+}
+
+static int JFX_Outline_MoveToFunc(const FT_Vector*   to,
+                                  void*              user)
+{
+    PathData *info = checkSize(user, 1);
+    info->pointTypes[info->numTypes++] = 0;
+    info->pointCoords[info->numCoords++] = F26DOT6TOFLOAT(to->x);
+    info->pointCoords[info->numCoords++] = -F26DOT6TOFLOAT(to->y);
+    return 0;
+}
+
+static int JFX_Outline_LineToFunc(const FT_Vector*   to,
+                                  void* user)
+{
+    PathData *info =  checkSize(user, 1);
+    info->pointTypes[info->numTypes++] = 1;
+    info->pointCoords[info->numCoords++] = F26DOT6TOFLOAT(to->x);
+    info->pointCoords[info->numCoords++] = -F26DOT6TOFLOAT(to->y);
+    return 0;
+}
+
+static int JFX_Outline_ConicToFunc(const FT_Vector*  control,
+                                   const FT_Vector*  to,
+                                   void*             user )
+{
+    PathData *info = checkSize(user, 2);
+    info->pointTypes[info->numTypes++] = 2;
+    info->pointCoords[info->numCoords++] = F26DOT6TOFLOAT(control->x);
+    info->pointCoords[info->numCoords++] = -F26DOT6TOFLOAT(control->y);
+    info->pointCoords[info->numCoords++] = F26DOT6TOFLOAT(to->x);
+    info->pointCoords[info->numCoords++] = -F26DOT6TOFLOAT(to->y);
+    return 0;
+}
+
+static int JFX_Outline_CubicToFunc(const FT_Vector*  control1,
+                                   const FT_Vector*  control2,
+                                   const FT_Vector*  to,
+                                   void*             user)
+{
+    PathData *info = checkSize(user, 3);
+    info->pointTypes[info->numTypes++] = 3;
+    info->pointCoords[info->numCoords++] = F26DOT6TOFLOAT(control1->x);
+    info->pointCoords[info->numCoords++] = -F26DOT6TOFLOAT(control1->y);
+    info->pointCoords[info->numCoords++] = F26DOT6TOFLOAT(control2->x);
+    info->pointCoords[info->numCoords++] = -F26DOT6TOFLOAT(control2->y);
+    info->pointCoords[info->numCoords++] = F26DOT6TOFLOAT(to->x);
+    info->pointCoords[info->numCoords++] = -F26DOT6TOFLOAT(to->y);
+    return 0;
+}
+
+static const  FT_Outline_Funcs JFX_Outline_Funcs =
+{
+    JFX_Outline_MoveToFunc,
+    JFX_Outline_LineToFunc,
+    JFX_Outline_ConicToFunc,
+    JFX_Outline_CubicToFunc,
+    0, 0
+};
+
+JNIEXPORT jobject JNICALL OS_NATIVE(FT_1Outline_1Decompose)
+    (JNIEnv *env, jclass that, jlong arg0)
+{
+    FT_Face face = (FT_Face)arg0;
+    if (face == NULL) return NULL;
+    FT_GlyphSlot slot = face->glyph;
+    if (slot == NULL) return NULL;
+    FT_Outline* outline = &slot->outline;
+    if (outline == NULL) return NULL;
+
+    jobject path2D = NULL;
+    PathData data;
+    data.pointTypes = (jbyte*)malloc(sizeof(jbyte) * DEFAULT_LEN_TYPES);
+    data.numTypes = 0;
+    data.lenTypes = DEFAULT_LEN_TYPES;
+    data.pointCoords = (jfloat*)malloc(sizeof(jfloat) * DEFAULT_LEN_COORDS);
+    data.numCoords = 0;
+    data.lenCoords = DEFAULT_LEN_COORDS;
+
+    /* Decompose outline */
+    FT_Outline_Decompose(outline, &JFX_Outline_Funcs, &data);
+
+    static jclass path2DClass = NULL;
+    static jmethodID path2DCtr = NULL;
+    if (path2DClass == NULL) {
+        jclass tmpClass = (*env)->FindClass(env, "com/sun/javafx/geom/Path2D");
+        path2DClass = (jclass)(*env)->NewGlobalRef(env, tmpClass);
+        path2DCtr = (*env)->GetMethodID(env, path2DClass, "<init>", "(I[BI[FI)V");
+    }
+
+    jbyteArray types = (*env)->NewByteArray(env, data.numTypes);
+    jfloatArray coords = (*env)->NewFloatArray(env, data.numCoords);
+    if (types && coords) {
+        (*env)->SetByteArrayRegion(env, types, 0, data.numTypes, data.pointTypes);
+        (*env)->SetFloatArrayRegion(env, coords, 0, data.numCoords, data.pointCoords);
+        path2D = (*env)->NewObject(env, path2DClass, path2DCtr,
+                                   0 /*winding rule*/,
+                                   types, data.numTypes,
+                                   coords, data.numCoords);
+    }
+    free(data.pointTypes);
+    free(data.pointCoords);
+    return path2D;
+}
+
+#endif /* ENABLE_PANGO */
+#endif /* __linux__ */
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/modules/graphics/src/main/native-font/pango.c	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,352 @@
+/*
+ * 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.
+ */
+
+#if defined __linux__
+#if defined _ENABLE_PANGO
+
+#include <jni.h>
+#include <com_sun_javafx_font_pango_OS.h>
+#include <pango/pango.h>
+#include <pango/pangoft2.h>
+#include <dlfcn.h>
+
+#define OS_NATIVE(func) Java_com_sun_javafx_font_pango_OS_##func
+
+/**************************************************************************/
+/*                                                                        */
+/*                            Structs                                     */
+/*                                                                        */
+/**************************************************************************/
+
+typedef struct PangoGlyphInfo_FID_CACHE {
+    int cached;
+    jclass clazz;
+    jfieldID glyph, width, x_offset, y_offset;
+    jmethodID init;
+} PangoGlyphInfo_FID_CACHE;
+
+PangoGlyphInfo_FID_CACHE PangoGlyphInfoFc;
+
+void cachePangoGlyphInfoFields(JNIEnv *env)
+{
+    if (PangoGlyphInfoFc.cached) return;
+    jclass tmpClass = (*env)->FindClass(env, "com/sun/javafx/font/pango/PangoGlyphInfo");
+    PangoGlyphInfoFc.clazz =  (jclass)(*env)->NewGlobalRef(env, tmpClass);
+    PangoGlyphInfoFc.glyph = (*env)->GetFieldID(env, PangoGlyphInfoFc.clazz, "glyph", "I");
+    PangoGlyphInfoFc.width = (*env)->GetFieldID(env, PangoGlyphInfoFc.clazz, "width", "I");
+    PangoGlyphInfoFc.x_offset = (*env)->GetFieldID(env, PangoGlyphInfoFc.clazz, "x_offset", "I");
+    PangoGlyphInfoFc.y_offset = (*env)->GetFieldID(env, PangoGlyphInfoFc.clazz, "y_offset", "I");
+    PangoGlyphInfoFc.init = (*env)->GetMethodID(env, PangoGlyphInfoFc.clazz, "<init>", "()V");
+    PangoGlyphInfoFc.cached = 1;
+}
+
+void setPangoGlyphInfoFields(JNIEnv *env, jobject lpObject, PangoGlyphInfo *lpStruct)
+{
+    if (!PangoGlyphInfoFc.cached) cachePangoGlyphInfoFields(env);
+    (*env)->SetIntField(env, lpObject, PangoGlyphInfoFc.glyph, (jint)lpStruct->glyph);
+    (*env)->SetIntField(env, lpObject, PangoGlyphInfoFc.width, (jint)lpStruct->geometry.width);
+    (*env)->SetIntField(env, lpObject, PangoGlyphInfoFc.x_offset, (jint)lpStruct->geometry.x_offset);
+    (*env)->SetIntField(env, lpObject, PangoGlyphInfoFc.y_offset, (jint)lpStruct->geometry.y_offset);
+}
+
+jobject newPangoGlyphInfo(JNIEnv *env, PangoGlyphInfo *lpStruct)
+{
+    jobject lpObject = NULL;
+    if (!PangoGlyphInfoFc.cached) cachePangoGlyphInfoFields(env);
+    lpObject = (*env)->NewObject(env, PangoGlyphInfoFc.clazz, PangoGlyphInfoFc.init);
+    if (lpObject && lpStruct) setPangoGlyphInfoFields(env, lpObject, lpStruct);
+    return lpObject;
+}
+
+typedef struct PangoGlyphString_FID_CACHE {
+    int cached;
+    jclass clazz;
+    jfieldID num_glyphs, glyphs, log_clusters, offset, length, num_chars, font;
+    jmethodID init;
+} PangoGlyphString_FID_CACHE;
+
+PangoGlyphString_FID_CACHE PangoGlyphStringFc;
+
+void cachePangoGlyphStringFields(JNIEnv *env)
+{
+    if (PangoGlyphStringFc.cached) return;
+    jclass tmpClass = (*env)->FindClass(env, "com/sun/javafx/font/pango/PangoGlyphString");
+    PangoGlyphStringFc.clazz =  (jclass)(*env)->NewGlobalRef(env, tmpClass);
+    PangoGlyphStringFc.num_glyphs = (*env)->GetFieldID(env, PangoGlyphStringFc.clazz, "num_glyphs", "I");
+    PangoGlyphStringFc.glyphs = (*env)->GetFieldID(env, PangoGlyphStringFc.clazz, "glyphs", "[Lcom/sun/javafx/font/pango/PangoGlyphInfo;");
+    PangoGlyphStringFc.log_clusters = (*env)->GetFieldID(env, PangoGlyphStringFc.clazz, "log_clusters", "[I");
+    PangoGlyphStringFc.offset = (*env)->GetFieldID(env, PangoGlyphStringFc.clazz, "offset", "I");
+    PangoGlyphStringFc.length = (*env)->GetFieldID(env, PangoGlyphStringFc.clazz, "length", "I");
+    PangoGlyphStringFc.num_chars = (*env)->GetFieldID(env, PangoGlyphStringFc.clazz, "num_chars", "I");
+    PangoGlyphStringFc.font = (*env)->GetFieldID(env, PangoGlyphStringFc.clazz, "font", "J");
+    PangoGlyphStringFc.init = (*env)->GetMethodID(env, PangoGlyphStringFc.clazz, "<init>", "()V");
+    PangoGlyphStringFc.cached = 1;
+}
+
+/**************************************************************************/
+/*                                                                        */
+/*                           Functions                                    */
+/*                                                                        */
+/**************************************************************************/
+
+/** Custom **/
+JNIEXPORT jlong JNICALL OS_NATIVE(pango_1itemize)
+    (JNIEnv *env, jclass that, jlong arg0, jobject arg1, jint arg2, jint arg3, jlong arg4, jlong arg5)
+{
+    jbyte *lparg1=NULL;
+    jlong rc = 0;
+    if (arg1) lparg1 = (*env)->GetDirectBufferAddress(env, arg1);
+    if (lparg1) {
+        rc = (jlong)pango_itemize((PangoContext *)arg0, (const char *)lparg1, arg2, arg3, (PangoAttrList *)arg4, (PangoAttrIterator *)arg5);
+    }
+    return rc;
+}
+
+
+JNIEXPORT jobject JNICALL OS_NATIVE(pango_1shape)
+    (JNIEnv *env, jclass that, jobject nioBuffer, jlong pangoItem)
+{
+    if (!pangoItem) return NULL;
+    if (!nioBuffer) return NULL;
+    void *bytePtr = (*env)->GetDirectBufferAddress(env, nioBuffer);
+    if (!bytePtr) return NULL;
+    PangoItem *item = (PangoItem *)pangoItem;
+    PangoAnalysis analysis = item->analysis;
+    const gchar *text= bytePtr + item->offset;
+    PangoGlyphString *glyphs = pango_glyph_string_new();
+
+    pango_shape(text, item->length, &analysis, glyphs);
+    int count = glyphs->num_glyphs;
+    if(count == 0) return NULL;
+
+    if (!PangoGlyphInfoFc.cached) cachePangoGlyphInfoFields(env);
+    jobjectArray infoArray = (*env)->NewObjectArray(env, count, PangoGlyphInfoFc.clazz, NULL);
+    jintArray clusterArray = (*env)->NewIntArray(env, count);
+    jobject result = NULL;
+    if (infoArray && clusterArray) {
+        jint cluster[count];
+        int i;
+        for (i = 0; i < count; i++) {
+            jobject info = newPangoGlyphInfo(env, &glyphs->glyphs[i]);
+            (*env)->SetObjectArrayElement(env, infoArray, i, info);
+            /* translate byte index to char index */
+            cluster[i] = (jint)g_utf8_pointer_to_offset(text, text + glyphs->log_clusters[i]);
+        }
+        (*env)->SetIntArrayRegion(env, clusterArray, 0, count, cluster);
+        if (!PangoGlyphStringFc.cached) cachePangoGlyphStringFields(env);
+        result = (*env)->NewObject(env, PangoGlyphStringFc.clazz, PangoGlyphStringFc.init);
+        if (result) {
+            (*env)->SetIntField(env, result, PangoGlyphStringFc.num_glyphs, count);
+
+            /* Set custom fields */
+            (*env)->SetObjectField(env, result, PangoGlyphStringFc.glyphs, infoArray);
+            (*env)->SetObjectField(env, result, PangoGlyphStringFc.log_clusters, clusterArray);
+            (*env)->SetIntField(env, result, PangoGlyphStringFc.offset, item->offset);
+            (*env)->SetIntField(env, result, PangoGlyphStringFc.length, item->length);
+            (*env)->SetIntField(env, result, PangoGlyphStringFc.num_chars, item->num_chars);
+            (*env)->SetLongField(env, result, PangoGlyphStringFc.font, (jlong)analysis.font);
+        }
+    }
+    pango_glyph_string_free(glyphs);
+    return result;
+}
+
+JNIEXPORT jstring JNICALL OS_NATIVE(pango_1font_1description_1get_1family)
+    (JNIEnv *env, jclass that, jlong arg0)
+{
+    const char *family = pango_font_description_get_family((PangoFontDescription *)arg0);
+    return (*env)->NewStringUTF(env, family);
+}
+
+JNIEXPORT void JNICALL OS_NATIVE(pango_1font_1description_1set_1family)
+    (JNIEnv *env, jclass that, jlong arg0, jstring arg1)
+{
+    if (arg1) {
+        const char *text = (*env)->GetStringUTFChars(env, arg1, NULL);
+        if (text) {
+            pango_font_description_set_family((PangoFontDescription *)arg0, text);
+            (*env)->ReleaseStringUTFChars(env, arg1, text);
+        }
+    }
+}
+
+#define LIB_FONTCONFIG "libfontconfig.so.1"
+JNIEXPORT jboolean JNICALL OS_NATIVE(FcConfigAppFontAddFile)
+    (JNIEnv *env, jclass that, jlong arg0, jstring arg1)
+{
+    static void *fp = NULL;
+    if (!fp) {
+        void* handle = dlopen(LIB_FONTCONFIG, RTLD_LAZY);
+        if (handle) fp = dlsym(handle, "FcConfigAppFontAddFile");
+    }
+    jboolean rc = 0;
+    if (arg1) {
+        const char *text = (*env)->GetStringUTFChars(env, arg1, NULL);
+        if (text) {
+//            rc = (jboolean)FcConfigAppFontAddFile(arg0, text);
+            if (fp) {
+                rc = (jboolean)((jboolean (*)(jlong, const char *))fp)(arg0, text);
+            }
+            (*env)->ReleaseStringUTFChars(env, arg1, text);
+        }
+    }
+    return rc;
+}
+
+/** one to one **/
+JNIEXPORT jlong JNICALL OS_NATIVE(pango_1font_1describe)
+    (JNIEnv *env, jclass that, jlong arg0)
+{
+    return (jlong)pango_font_describe((PangoFont *)arg0);
+}
+
+JNIEXPORT jlong JNICALL OS_NATIVE(pango_1attr_1fallback_1new)
+    (JNIEnv *env, jclass that, jboolean arg0)
+{
+    return (jlong)pango_attr_fallback_new(arg0);
+}
+
+JNIEXPORT jint JNICALL OS_NATIVE(pango_1font_1description_1get_1stretch)
+    (JNIEnv *env, jclass that, jlong arg0)
+{
+    return (jint)pango_font_description_get_stretch((PangoFontDescription *)arg0);
+}
+
+JNIEXPORT jint JNICALL OS_NATIVE(pango_1font_1description_1get_1style)
+    (JNIEnv *env, jclass that, jlong arg0)
+{
+    return (jint)pango_font_description_get_style((PangoFontDescription *)arg0);
+}
+
+JNIEXPORT jint JNICALL OS_NATIVE(pango_1font_1description_1get_1weight)
+    (JNIEnv *env, jclass that, jlong arg0)
+{
+    return (jint)pango_font_description_get_weight((PangoFontDescription *)arg0);
+}
+
+JNIEXPORT jlong JNICALL OS_NATIVE(pango_1ft2_1font_1map_1new)
+    (JNIEnv *env, jclass that)
+{
+    return (jlong)pango_ft2_font_map_new();
+}
+
+JNIEXPORT jlong JNICALL OS_NATIVE(pango_1font_1map_1create_1context)
+    (JNIEnv *env, jclass that, jlong arg0)
+{
+    return (jlong)pango_font_map_create_context((PangoFontMap *)arg0);
+}
+
+JNIEXPORT void JNICALL OS_NATIVE(g_1object_1unref)
+    (JNIEnv *env, jclass that, jlong arg0)
+{
+    g_object_unref((gpointer)arg0);
+}
+
+JNIEXPORT jlong JNICALL OS_NATIVE(pango_1font_1description_1new)
+    (JNIEnv *env, jclass that)
+{
+    return (jlong)pango_font_description_new();
+}
+
+JNIEXPORT void JNICALL OS_NATIVE(pango_1font_1description_1set_1absolute_1size)
+    (JNIEnv *env, jclass that, jlong arg0, jdouble arg1)
+{
+    pango_font_description_set_absolute_size((PangoFontDescription *)arg0, arg1);
+}
+
+JNIEXPORT void JNICALL OS_NATIVE(pango_1font_1description_1set_1stretch)
+    (JNIEnv *env, jclass that, jlong arg0, jint arg1)
+{
+    pango_font_description_set_stretch((PangoFontDescription *)arg0, (PangoStretch)arg1);
+}
+
+JNIEXPORT void JNICALL OS_NATIVE(pango_1font_1description_1set_1style)
+    (JNIEnv *env, jclass that, jlong arg0, jint arg1)
+{
+    pango_font_description_set_style((PangoFontDescription *)arg0, (PangoStyle)arg1);
+}
+
+JNIEXPORT void JNICALL OS_NATIVE(pango_1font_1description_1set_1weight)
+    (JNIEnv *env, jclass that, jlong arg0, jint arg1)
+{
+    pango_font_description_set_weight((PangoFontDescription *)arg0, (PangoWeight)arg1);
+}
+
+JNIEXPORT jlong JNICALL OS_NATIVE(pango_1attr_1list_1new)
+    (JNIEnv *env, jclass that)
+{
+    return (jlong)pango_attr_list_new();
+}
+
+JNIEXPORT jlong JNICALL OS_NATIVE(pango_1attr_1font_1desc_1new)
+    (JNIEnv *env, jclass that, jlong arg0)
+{
+    return (jlong)pango_attr_font_desc_new((const PangoFontDescription *)arg0);
+}
+
+JNIEXPORT void JNICALL OS_NATIVE(pango_1attr_1list_1insert)
+    (JNIEnv *env, jclass that, jlong arg0, jlong arg1)
+{
+    pango_attr_list_insert((PangoAttrList *)arg0, (PangoAttribute *)arg1);
+}
+
+JNIEXPORT jint JNICALL OS_NATIVE(g_1list_1length)
+    (JNIEnv *env, jclass that, jlong arg0)
+{
+    return (jint)g_list_length((GList *)arg0);
+}
+
+JNIEXPORT jlong JNICALL OS_NATIVE(g_1list_1nth_1data)
+    (JNIEnv *env, jclass that, jlong arg0, jint arg1)
+{
+    return (jlong)g_list_nth_data((GList *)arg0, (guint)arg1);
+}
+
+JNIEXPORT void JNICALL OS_NATIVE(pango_1item_1free)
+    (JNIEnv *env, jclass that, jlong arg0)
+{
+    pango_item_free((PangoItem *)arg0);
+}
+
+JNIEXPORT void JNICALL OS_NATIVE(g_1list_1free)
+    (JNIEnv *env, jclass that, jlong arg0)
+{
+    g_list_free((GList *)arg0);
+}
+
+JNIEXPORT void JNICALL OS_NATIVE(pango_1attr_1list_1unref)
+    (JNIEnv *env, jclass that, jlong arg0)
+{
+    pango_attr_list_unref((PangoAttrList *)arg0);
+}
+
+JNIEXPORT void JNICALL OS_NATIVE(pango_1font_1description_1free)
+    (JNIEnv *env, jclass that, jlong arg0)
+{
+    pango_font_description_free((PangoFontDescription *)arg0);
+}
+
+#endif /* ENABLE_PANGO */
+#endif /* __linux__ */
--- a/modules/graphics/src/main/native-glass/mac/GlassSystemClipboard.m	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/graphics/src/main/native-glass/mac/GlassSystemClipboard.m	Wed Jul 10 11:01:52 2013 +0400
@@ -93,7 +93,7 @@
         if (url != nil) {
             url = [url filePathURL];
             if (url != nil) {
-                path = [url absoluteString];
+                path = [url path];
             }
         }
         result = (*env) -> NewStringUTF(env, [path UTF8String]);
--- a/modules/graphics/src/main/native-prism-sw/PiscesPaint.c	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/graphics/src/main/native-prism-sw/PiscesPaint.c	Wed Jul 10 11:01:52 2013 +0400
@@ -357,6 +357,22 @@
     pts[2] = (isXin) ? data[sidx2 + 1] : pts[0];
 }
 
+static INLINE void getPointsToInterpolateRepeat(jint *pts, jint *data, jint sidx, jint stride, jint p00,
+    jint tx, jint txMin, jint txMax, jint ty, jint tyMin, jint tyMax)
+{
+    jint txn = tx+1;
+    jint tyn = ty+1;
+    if (txn > txMax) {
+        txn = txMin;
+    }
+    if (tyn > tyMax) {
+        tyn = tyMin;
+    }
+    pts[0] = data[MAX(tyMin, ty) * stride + txn];
+    pts[1] = data[tyn * stride + MAX(txMin, tx)];
+    pts[2] = data[tyn * stride + txn];
+}
+
 void
 genTexturePaintTarget(Renderer *rdr, jint *paint, jint height) {
     jint j;
@@ -454,8 +470,13 @@
                         jint sidx = MAX(tyMin, ty) * rdr->_texture_stride + MAX(txMin, tx);
                         jint p00 = txtData[sidx];
                         if (rdr->_texture_interpolate) {
-                            getPointsToInterpolate(pts, txtData, sidx, rdr->_texture_stride, p00,
-                                tx, txMin, txMax, ty, tyMin, tyMax);
+                            if (rdr->_texture_repeat) {
+                                getPointsToInterpolateRepeat(pts, txtData, sidx, rdr->_texture_stride, p00,
+                                    tx, txMin, txMax, ty, tyMin, tyMax);
+                            } else {
+                                getPointsToInterpolate(pts, txtData, sidx, rdr->_texture_stride, p00,
+                                    tx, txMin, txMax, ty, tyMin, tyMax);
+                            }
 
                             if (hfrac && vfrac) {
                                 cval = interpolate4points(p00, pts[0], pts[1], pts[2], hfrac, vfrac);
@@ -513,8 +534,13 @@
                         jint sidx = MAX(tyMin, ty) * rdr->_texture_stride + MAX(txMin, tx);
                         jint p00 = txtData[sidx];
                         if (rdr->_texture_interpolate) {
-                            getPointsToInterpolate(pts, txtData, sidx, rdr->_texture_stride, p00,
-                                tx, txMin, txMax, ty, tyMin, tyMax);
+                            if (rdr->_texture_repeat) {
+                                getPointsToInterpolateRepeat(pts, txtData, sidx, rdr->_texture_stride, p00,
+                                    tx, txMin, txMax, ty, tyMin, tyMax);
+                            } else {
+                                getPointsToInterpolate(pts, txtData, sidx, rdr->_texture_stride, p00,
+                                    tx, txMin, txMax, ty, tyMin, tyMax);
+                            }
 
                             if (hfrac && vfrac) {
                                 cval = interpolate4pointsNoAlpha(p00, pts[0], pts[1], pts[2], hfrac, vfrac);
@@ -586,8 +612,13 @@
                         jint sidx = MAX(tyMin, ty) * rdr->_texture_stride + MAX(txMin, tx);
                         jint p00 = txtData[sidx];
                         if (rdr->_texture_interpolate) {
-                            getPointsToInterpolate(pts, txtData, sidx, rdr->_texture_stride, p00,
-                                tx, txMin, txMax, ty, tyMin, tyMax);
+                            if (rdr->_texture_repeat) {
+                                getPointsToInterpolateRepeat(pts, txtData, sidx, rdr->_texture_stride, p00,
+                                    tx, txMin, txMax, ty, tyMin, tyMax);
+                            } else {
+                                getPointsToInterpolate(pts, txtData, sidx, rdr->_texture_stride, p00,
+                                    tx, txMin, txMax, ty, tyMin, tyMax);
+                            }
 
                             if (hfrac && vfrac) {
                                 cval = interpolate4points(p00, pts[0], pts[1], pts[2], hfrac, vfrac);
@@ -651,8 +682,13 @@
                         jint sidx = MAX(tyMin, ty) * rdr->_texture_stride + MAX(txMin, tx);
                         jint p00 = txtData[sidx];
                         if (rdr->_texture_interpolate) {
-                            getPointsToInterpolate(pts, txtData, sidx, rdr->_texture_stride, p00,
-                                tx, txMin, txMax, ty, tyMin, tyMax);
+                            if (rdr->_texture_repeat) {
+                                getPointsToInterpolateRepeat(pts, txtData, sidx, rdr->_texture_stride, p00,
+                                    tx, txMin, txMax, ty, tyMin, tyMax);
+                            } else {
+                                getPointsToInterpolate(pts, txtData, sidx, rdr->_texture_stride, p00,
+                                    tx, txMin, txMax, ty, tyMin, tyMax);
+                            }
 
                             if (hfrac && vfrac) {
                                 cval = interpolate4pointsNoAlpha(p00, pts[0], pts[1], pts[2], hfrac, vfrac);
--- a/modules/swing/src/main/java/javafx/embed/swing/SwingNode.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/swing/src/main/java/javafx/embed/swing/SwingNode.java	Wed Jul 10 11:01:52 2013 +0400
@@ -535,7 +535,10 @@
             Platform.runLater(new Runnable() {
                 @Override
                 public void run() {
-                    if (getScene() != null && getScene().getWindow() != null) {
+                    if (getScene() != null &&
+                        getScene().getWindow() != null &&
+                        getScene().getWindow().impl_getPeer() != null)
+                    {
                         getScene().getWindow().impl_getPeer().grabFocus();
                         grabbed = true;
                     }
@@ -555,7 +558,9 @@
 
     private void ungrabFocus(boolean postUngrabEvent) {
         if (grabbed &&
-            getScene() != null && getScene().getWindow() != null)
+            getScene() != null &&
+            getScene().getWindow() != null &&
+            getScene().getWindow().impl_getPeer() != null)
         {
             skipBackwardUnrgabNotification = !postUngrabEvent;
             getScene().getWindow().impl_getPeer().ungrabFocus();
@@ -585,6 +590,10 @@
             {
                 SwingNode.this.requestFocus();
             }
+            JLightweightFrame frame = lwFrame;
+            if (frame == null) {
+                return;
+            }
             int swingID = SwingEvents.fxMouseEventTypeToMouseID(event);
             if (swingID < 0) {
                 return;
@@ -596,7 +605,7 @@
             long swingWhen = System.currentTimeMillis();
             java.awt.event.MouseEvent mouseEvent =
                     new java.awt.event.MouseEvent(
-                        lwFrame, swingID, swingWhen, swingModifiers,
+                        frame, swingID, swingWhen, swingModifiers,
                         (int)event.getX(), (int)event.getY(), (int)event.getScreenX(), (int)event.getSceneY(),
                         event.getClickCount(), swingPopupTrigger, swingButton);
             AccessController.doPrivileged(new PostEventAction(mouseEvent));
@@ -606,16 +615,14 @@
     private class SwingKeyEventHandler implements EventHandler<KeyEvent> {
         @Override
         public void handle(KeyEvent event) {
+            JLightweightFrame frame = lwFrame;
+            if (frame == null) {
+                return;
+            }
             if (event.getCharacter().isEmpty()) {
                 // TODO: should we post an "empty" character?
                 return;
             }
-            // Let Ctrl+Tab, Shift+Strl+Tab traverse focus out.
-            if (event.getCode() == KeyCode.TAB && event.isControlDown()) {
-                Direction d = event.isShiftDown() ? Direction.PREVIOUS : Direction.NEXT;
-                getParent().getImpl_traversalEngine().trav(SwingNode.this, d);
-                return;
-            }
             // Don't let Arrows, Tab, Shift+Tab traverse focus out.
             if (event.getCode() == KeyCode.LEFT  ||
                 event.getCode() == KeyCode.RIGHT ||
@@ -633,7 +640,7 @@
             char swingChar = event.getCharacter().charAt(0);
             long swingWhen = System.currentTimeMillis();
             java.awt.event.KeyEvent keyEvent = new java.awt.event.KeyEvent(
-                    lwFrame, swingID, swingWhen, swingModifiers,
+                    frame, swingID, swingWhen, swingModifiers,
                     swingKeyCode, swingChar);
             AccessController.doPrivileged(new PostEventAction(keyEvent));
         }
--- a/modules/web/src/main/java/com/sun/javafx/webkit/prism/WCGraphicsPrismContext.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/web/src/main/java/com/sun/javafx/webkit/prism/WCGraphicsPrismContext.java	Wed Jul 10 11:01:52 2013 +0400
@@ -937,8 +937,12 @@
     }
 
     @Override
-    public void drawWidget(RenderTheme theme, Ref widget, int x, int y) {
-        theme.drawWidget(this, widget, x, y);
+    public void drawWidget(final RenderTheme theme, final Ref widget, final int x, final int y) {
+        new Composite() {
+            @Override void doPaint(Graphics g) {
+                theme.drawWidget(WCGraphicsPrismContext.this, widget, x, y);
+            }
+        }.paint();
     }
 
     @Override
--- a/modules/web/src/main/java/com/sun/webkit/network/SocketStreamHandle.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/web/src/main/java/com/sun/webkit/network/SocketStreamHandle.java	Wed Jul 10 11:01:52 2013 +0400
@@ -251,53 +251,20 @@
     }
 
     private void connect(Proxy proxy) throws IOException {
-        if (proxy.type() == Proxy.Type.HTTP) {
-            synchronized (this) {
-                if (state != State.ACTIVE) {
-                    throw new SocketException("Close requested");
-                }
-                socket = new Socket(Proxy.NO_PROXY);
+        synchronized (this) {
+            if (state != State.ACTIVE) {
+                throw new SocketException("Close requested");
             }
-            if (logger.isLoggable(Level.FINEST)) {
-                logger.log(Level.FINEST, format("%s connecting to proxy: [%s]",
-                        this, proxy));
-            }
-            final InetSocketAddress address =
-                    (InetSocketAddress) proxy.address();
-            try {
-                AccessController.doPrivileged(
-                    new PrivilegedExceptionAction<Void>() {
-                        @Override public Void run() throws IOException {
-                            socket.connect(new InetSocketAddress(
-                                    address.getHostName(),
-                                    address.getPort()));
-                            return null;
-                        }
-                    });
-            } catch (PrivilegedActionException ex) {
-                throw (IOException) ex.getException();
-            }
-            if (logger.isLoggable(Level.FINEST)) {
-                logger.log(Level.FINEST, format("%s connected to proxy: [%s]",
-                        this, proxy));
-            }
-            setupProxyTunnel();
-        } else { // DIRECT or SOCKS
-            synchronized (this) {
-                if (state != State.ACTIVE) {
-                    throw new SocketException("Close requested");
-                }
-                socket = new Socket(proxy);
-            }
-            if (logger.isLoggable(Level.FINEST)) {
-                logger.log(Level.FINEST, format("%s connecting to: [%s:%d]",
-                        this, host, port));
-            }
-            socket.connect(new InetSocketAddress(host, port));
-            if (logger.isLoggable(Level.FINEST)) {
-                logger.log(Level.FINEST, format("%s connected to: [%s:%d]",
-                        this, host, port));
-            }
+            socket = new Socket(proxy);
+        }
+        if (logger.isLoggable(Level.FINEST)) {
+            logger.log(Level.FINEST, format("%s connecting to: [%s:%d]",
+                    this, host, port));
+        }
+        socket.connect(new InetSocketAddress(host, port));
+        if (logger.isLoggable(Level.FINEST)) {
+            logger.log(Level.FINEST, format("%s connected to: [%s:%d]",
+                    this, host, port));
         }
         if (ssl) {
             synchronized (this) {
@@ -312,80 +279,6 @@
         }
     }
 
-    private void setupProxyTunnel() throws IOException {
-        logger.log(Level.FINEST, "{0} setting up proxy tunnel", this);
-
-        String request =
-                "CONNECT " + host + ":" + port + " HTTP/1.1\r\n"
-                + "Host: " + host + "\r\n"
-                + "Proxy-Connection: keep-alive\r\n"
-                + "\r\n";
-        if (logger.isLoggable(Level.FINEST)) {
-            logger.log(Level.FINEST, format("%s sending:%n%s",
-                    this, request.replaceAll("(?m)^", "    ")));
-        }
-        OutputStreamWriter w =
-                new OutputStreamWriter(socket.getOutputStream(), "US-ASCII");
-        w.write(request);
-        w.flush();
-
-        String firstLine = null;
-        StringBuilder line = new StringBuilder();
-        InputStreamReader r =
-                new InputStreamReader(socket.getInputStream(), "UTF-8");
-        while (true) {
-            int c = r.read();
-            if (c < 0) {
-                if (logger.isLoggable(Level.FINEST)) {
-                    logger.log(Level.FINEST, format("%s received: [%s]",
-                            this, line));
-                }
-                throw new SocketException("Connection closed by proxy "
-                        + "during tunnel setup");
-            } else if (c == '\n') {
-                if (line.length() > 0
-                        && line.charAt(line.length() - 1) == '\r')
-                {
-                    line.deleteCharAt(line.length() - 1);
-                }
-                if (logger.isLoggable(Level.FINEST)) {
-                    logger.log(Level.FINEST, format("%s received: [%s]",
-                            this, line));
-                }
-                if (line.length() == 0) {
-                    break; // empty line indicates end of headers
-                } else {
-                    if (firstLine == null) {
-                        firstLine = line.toString();
-                    }
-                    line.setLength(0);
-                }
-            } else {
-                line.append((char) c);
-            }
-        }
-
-        if (firstLine == null) {
-            throw new SocketException("Empty response from proxy "
-                    + "during tunnel setup");
-        }
-
-        Matcher matcher = FIRST_LINE_PATTERN.matcher(firstLine);
-        if (!matcher.matches()) {
-            throw new SocketException("Unexpected response from proxy during "
-                    + "tunnel setup: [" + firstLine + "]");
-        }
-
-        int responseCode = Integer.parseInt(matcher.group(1));
-        if (responseCode != 200) {
-            // TODO: handle proxy authentication RT-25644
-            throw new SocketException("Error setting up proxy tunnel: "
-                    + "[" + firstLine + "]");
-        }
-
-        logger.log(Level.FINEST, "{0} proxy tunnel set up successfully", this);
-    }
-
     private int fwkSend(byte[] buffer) {
         if (logger.isLoggable(Level.FINEST)) {
             logger.log(Level.FINEST, format("%s sending len: [%d], data:%s",
--- a/modules/web/src/test/java/html/RT30835.html	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,8 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta http-equiv="Refresh" content="100; URL=ipsum.html" />
-</head>
-<body>
-</body>
-</html>
--- a/modules/web/src/test/java/html/dom.html	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,49 +0,0 @@
-<!doctype html>
-<html>
-<head>
-    <title>DOM Tests</title>
-    <style media="screen">
-        @import url('imported-styles.css');
-
-        body {background-color: red}
-
-        @media screen
-        {
-            p.test {font-family:verdana,sans-serif;font-size:14px;}
-        }
-        @media print
-        {
-            p.test {font-family:times,serif;font-size:10px;}
-        }
-        @media screen,print
-        {
-            p.test {font-weight:bold;}
-        }
-    </style>
-    <link rel="stylesheet" type="text/css" href="imported-styles.css">
-</head>
-<body onclick="document.body.className='testClass';" style="background-color: blue" class="bodyClass">
-
-<!-- used by testEmptyTextContent -->
-<p id="empty-paragraph" align="left"></p>
-
-<!-- used by insert/append/remove/replace tests -->
-<p id="p1">Things <b>do</b> change</p>
-<p id="p2">Again <i>and</i> again</p>
-
-<!-- used by testNodeTypes -->
-<p id="showcase-paragraph">
-text<!--comment--><span class="spanclass">spantext</span></p>
-<img src="file:///C:/test.png" alt="test image">
-
-<label for="unittype">Select unit type:</label>
-<select id="unittype" name="unittype">
-    <option value="1"> Miner </option>
-    <option value="2"> Puffer </option>
-    <option value="3" selected> Snipey </option>
-    <option value="4"> Max </option>
-    <option value="5"> Firebot </option>
-</select>
-
-</body>
-</html>
--- a/modules/web/src/test/java/html/guimark2-vector.html	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,231 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<title>GUIMark 2 - HTML5 Vector Test</title>
-<meta http-equiv="content-type" content="text/html; charset=UTF-8">
-<script type="text/javascript">
-var meter;
-var fps;
-var results;
-var draw;
-
-var chartWidth = 1200;
-var chartHeight = 600;
-var highestStock = 200;
-var totalMinutes = 480;
-var chartXSpread;
-var chartYSpread;
-var a = new Array();
-var b = new Array();
-var c = new Array();
-var d = new Array();
-var e = new Array();
-
-function init(){
-	var canvas = document.getElementById('canvas');
-	draw = canvas.getContext('2d');
-	chartXSpread = chartWidth/totalMinutes;
-	chartYSpread = chartHeight/highestStock;
-	meter = new FPSMeter();
-	fps = document.getElementById("current");
-	results = document.getElementById("results");
-	setInterval("processFrame()", 17);
-}
-
-function processFrame(){
-	draw.clearRect(0,0,chartWidth,chartHeight);
-	draw.beginPath();
-	draw.lineWidth = 1;
-	draw.strokeStyle = "#666666";
-
-	var xCoord;
-	var yCoord;
-	for(var x=0; x<=totalMinutes; x+=40){
-		xCoord = x*chartXSpread+0.5;
-		draw.moveTo(xCoord, 0);
-		draw.lineTo(xCoord, chartHeight);
-	}
-	for(var y=0; y<=highestStock; y+=20){
-		yCoord = y*chartYSpread+0.5;
-		draw.moveTo(0, yCoord);
-		draw.lineTo(chartWidth, yCoord);
-	}
-	draw.stroke();
-	draw.closePath();
-
-	fillStockData(a, 180);
-	fillStockData(b, 140);
-	fillStockData(c, 100);
-	fillStockData(d, 60);
-	fillStockData(e, 20);
-
-	graphStockData(a, b, "#FF00FF", "rgba(255, 176, 255, 0.6)");
-	graphStockData(b, c, "#FF0000", "rgba(255, 176, 176, 0.6)");
-	graphStockData(c, d, "#FF6600", "rgba(255, 216, 176, 0.6)");
-	graphStockData(d, e, "#0000FF", "rgba(176, 176, 255, 0.6)");
-	graphStockData(e, null, "#00FF00", "rgba(176, 255, 176, 0.6)");
-	
-	updatePerformance();
-}
-
-function fillStockData(data, region){
-	var diff = 15;
-	var low = region-(diff/2);
-	var i = 0;
-	var stock;
-	
-	if(data.length == 0){
-		while(i <= totalMinutes){
-			stock = new StockVO(i, Math.random()*diff+low);
-			data.push(stock);
-			i++;
-		}
-	}else{
-		while(i <= totalMinutes){
-			stock = data[i];
-			stock.minute--;
-			i++;
-		}
-		stock = data.shift();
-		stock.minute = totalMinutes;
-		stock.value = Math.random()*diff+low;
-		data.push(stock);
-	}
-}
-
-function graphStockData(topData, bottomData, line, fill){
-	var stock;
-	var xCoord;
-	var yCoord;
-	var i = 0;
-	
-	draw.beginPath();
-	draw.strokeStyle = line;
-	draw.lineWidth = 2;
-	draw.lineCap = "round";
-	draw.lineJoin = "round";
-	draw.fillStyle = fill;
-
-	stock = topData[i];
-	xCoord = stock.minute*chartXSpread;
-	yCoord = chartHeight-stock.value*chartYSpread;
-	draw.moveTo(xCoord, yCoord);
-
-	while(++i < topData.length){
-		stock = topData[i];
-		xCoord = stock.minute*chartXSpread;
-		yCoord = chartHeight-stock.value*chartYSpread;
-		draw.lineTo(xCoord, yCoord);
-	}
-	draw.stroke();
-	
-	if(bottomData != null){
-		i = bottomData.length;
-		while(--i > -1){
-			stock = bottomData[i];
-			xCoord = stock.minute*chartXSpread;
-			yCoord = chartHeight-stock.value*chartYSpread;
-			draw.lineTo(xCoord, yCoord);
-		}
-	}else{
-		draw.lineTo(chartWidth, chartHeight);
-		draw.lineTo(0, chartHeight);
-	}
-	draw.fill();
-	draw.closePath();
-}
-
-function updatePerformance(){
-	meter.increment();
-	fps.innerHTML = "Current: "+meter.getFramerate()+" fps";
-	if(testRunning){
-		continueTest();
-	}
-}
-
-//test runner
-var testBegin = 0;
-var testData = [];
-var testRunning = false;
-function startTest(){
-	testBegin = TimeUtil.getTimer();
-	testRunning = true;
-	testData = [];
-	results.innerHTML = "Running..."
-}
-function continueTest(){
-	var time = TimeUtil.getTimer();
-	testData.push(time);
-	if(time-testBegin > 10000){
-		testRunning = false;
-		var output = testData.length/(time-testBegin)*1000;
-		results.innerHTML = "Test Average: "+FPSMeter.formatNumber(output)+" fps"
-	}
-}
-
-//additional classes
-function StockVO(minute, value){
-	this.minute = minute;
-	this.value = value;
-}
-
-function FPSMeter(){
-	var sampleFPS = 0;
-	var lastSampledTime = 0;
-	var sampleFrames = 0;
-	
-	this.sampleDuration = 500;
-	this.increment = function(){
-		sampleFrames++;
-	}
-	this.getFramerate = function(){
-		var diff = TimeUtil.getTimer()-lastSampledTime;
-		if(diff >= this.sampleDuration){
-			var rawFPS = sampleFrames/(diff/1000);
-			sampleFPS = FPSMeter.formatNumber(rawFPS);
-			sampleFrames = 0;
-			lastSampledTime = TimeUtil.getTimer();
-		}
-		return sampleFPS;
-	}
-}
-FPSMeter.formatNumber = function(val){
-	//format as XX.XX
-	return Math.floor(val*100)/100;
-}
-
-TimeUtil = {
-	startTime: new Date().getTime(),
-	getTimer: function(){
-		return new Date().getTime()-TimeUtil.startTime;
-	}
-}
-</script>
-<style type="text/css">
-.header {
-	font-family: Arial, Helvetica, sans-serif;
-	font-size: 15px;
-	font-weight: bold;
-	width: 1200px;
-	height: 30px;
-	background-color: #C0C4DF;
-}
-.header>div {
-	padding: 6px;
-	display: inline-block;
-}
-</style>
-</head>
-
-<body onload="init()" style="margin:0px;">
-	<div class="header">
-		<div style="width:300px">GUIMark - Vector Chart Test</div>
-
-		<div><input type="button" value="Start Test" onclick="startTest()"/></div>
-		<div id="current" style="width:140px">Current: 10 fps</div>
-		<div id="results"></div>
-	</div>
-	<canvas id="canvas" width="1200" height="600"></canvas>
-
-</body>
-</html>
--- a/modules/web/src/test/java/html/h1.html	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,7 +0,0 @@
-<!doctype html>
-<html>
-<head><title>1</title></head>
-<body>
-<p>This is the page #1</p>
-</body>
-</html>
--- a/modules/web/src/test/java/html/h2.html	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,7 +0,0 @@
-<!doctype html>
-<html>
-<head><title>2</title></head>
-<body>
-<p>This is the page #2</p>
-</body>
-</html>
--- a/modules/web/src/test/java/html/h3.html	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,7 +0,0 @@
-<!doctype html>
-<html>
-<head><title>3</title></head>
-<body>
-<p>This is the page #3</p>
-</body>
-</html>
--- a/modules/web/src/test/java/html/h4.html	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,6 +0,0 @@
-<!doctype html>
-<html>
-<body>
-<p>This is the page #4</p>
-</body>
-</html>
--- a/modules/web/src/test/java/html/ipsum.html	Tue Jul 09 18:33:45 2013 +0400
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,20 +0,0 @@
-<!doctype html>
-<html>
-<head><title>Lorem Ipsum</title></head>
-<body>
-<p>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.
-
-<p>Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie consequat, vel illum dolore eu feugiat nulla facilisis at vero eros et accumsan et iusto odio dignissim qui blandit praesent luptatum zzril delenit augue duis dolore te feugait nulla facilisi. Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.
-
-<p>Ut wisi enim ad minim veniam, quis nostrud exerci tation ullamcorper suscipit lobortis nisl ut aliquip ex ea commodo consequat. Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie consequat, vel illum dolore eu feugiat nulla facilisis at vero eros et accumsan et iusto odio dignissim qui blandit praesent luptatum zzril delenit augue duis dolore te feugait nulla facilisi.
-
-<p>Nam liber tempor cum soluta nobis eleifend option congue nihil imperdiet doming id quod mazim placerat facer possim assum. Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat. Ut wisi enim ad minim veniam, quis nostrud exerci tation ullamcorper suscipit lobortis nisl ut aliquip ex ea commodo consequat.
-
-<p>Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie consequat, vel illum dolore eu feugiat nulla facilisis.
-
-<p>At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, At accusam aliquyam diam diam dolore dolores duo eirmod eos erat, et nonumy sed tempor et et invidunt justo labore Stet clita ea et gubergren, kasd magna no rebum. sanctus sea sed takimata ut vero voluptua. est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat. 
-
-<p>Consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.
-
-</body>
-</html>
--- a/modules/web/src/test/java/javafx/scene/web/BindingTest.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/web/src/test/java/javafx/scene/web/BindingTest.java	Wed Jul 10 11:01:52 2013 +0400
@@ -104,7 +104,7 @@
         title.bind(web.titleProperty());
         loc.bind(web.locationProperty());
 
-        load(new File("test/html/ipsum.html"));
+        load(new File("src/test/resources/html/ipsum.html"));
         assertSame("WebEngine.document", web.getDocument(), doc.get());
         assertSame("WebEngine.title",    web.getTitle(),    title.get());
         assertSame("WebEngine.location", web.getLocation(), loc.get());
--- a/modules/web/src/test/java/javafx/scene/web/DOMTest.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/web/src/test/java/javafx/scene/web/DOMTest.java	Wed Jul 10 11:01:52 2013 +0400
@@ -28,7 +28,7 @@
 public class DOMTest extends TestBase {
 
     @Test public void testEmptyTextContent() {
-        final Document doc = getDocumentFor("test/html/dom.html");
+        final Document doc = getDocumentFor("src/test/resources/html/dom.html");
         submit(new Runnable() { public void run() {
             Element emptyP = doc.getElementById("empty-paragraph");
             String textContent = emptyP.getTextContent();
@@ -37,7 +37,7 @@
     }
 
     @Test public void testAppendChild() {
-        final Document doc = getDocumentFor("test/html/dom.html");
+        final Document doc = getDocumentFor("src/test/resources/html/dom.html");
         submit(new Runnable() { public void run() {
             Node p1 = doc.getElementById("p1");
             NodeList c1 = p1.getChildNodes();
@@ -67,7 +67,7 @@
     }
 
     @Test public void testInsertBeforeEnd() {
-        final Document doc = getDocumentFor("test/html/dom.html");
+        final Document doc = getDocumentFor("src/test/resources/html/dom.html");
         submit(new Runnable() { public void run() {
             Node p1 = doc.getElementById("p1");
             NodeList c1 = p1.getChildNodes();
@@ -106,7 +106,7 @@
     }
 
     @Test public void testInsertBefore() {
-        final Document doc = getDocumentFor("test/html/dom.html");
+        final Document doc = getDocumentFor("src/test/resources/html/dom.html");
         submit(new Runnable() { public void run() {
             Node p1 = doc.getElementById("p1");
             NodeList c1 = p1.getChildNodes();
@@ -131,7 +131,7 @@
     }
 
     @Test public void testReplaceChild() {
-        final Document doc = getDocumentFor("test/html/dom.html");
+        final Document doc = getDocumentFor("src/test/resources/html/dom.html");
         submit(new Runnable() { public void run() {
             Node p1 = doc.getElementById("p1");
             NodeList c1 = p1.getChildNodes();
@@ -158,7 +158,7 @@
     }
 
     @Test public void testRemoveChild() {
-        final Document doc = getDocumentFor("test/html/dom.html");
+        final Document doc = getDocumentFor("src/test/resources/html/dom.html");
         submit(new Runnable() { public void run() {
             Node p = doc.getElementById("p1");
             NodeList c = p.getChildNodes();
@@ -176,7 +176,7 @@
     }
 
     @Test public void testRemoveChildWithEventHandler() {
-        final Document doc = getDocumentFor("test/html/dom.html");
+        final Document doc = getDocumentFor("src/test/resources/html/dom.html");
         submit(new Runnable() { public void run() {
             Node p = doc.getElementById("p1");
             NodeList c = p.getChildNodes();
@@ -203,7 +203,7 @@
     }
 
     @Test public void testNodeTypes() {
-        final Document doc = getDocumentFor("test/html/dom.html");
+        final Document doc = getDocumentFor("src/test/resources/html/dom.html");
         submit(new Runnable() { public void run() {
             Element p = doc.getElementById("showcase-paragraph");
             assertEquals("P element's node type", Node.ELEMENT_NODE, p.getNodeType());
@@ -234,7 +234,7 @@
     }
 
     @Test public void testNodeTypification() {
-        final Document doc = getDocumentFor("test/html/dom.html");
+        final Document doc = getDocumentFor("src/test/resources/html/dom.html");
         submit(new Runnable() { public void run() {
             NodeList inputsp = doc.getElementsByTagName("p");
             HTMLParagraphElement elp = (HTMLParagraphElement) inputsp.item(0);
@@ -247,7 +247,7 @@
     }
 
     @Test public void testEventListenerCascade() {
-        final Document doc = getDocumentFor("test/html/dom.html");
+        final Document doc = getDocumentFor("src/test/resources/html/dom.html");
         submit(new Runnable() { public void run() {
             HTMLDocument htmlDoc = (HTMLDocument)doc;
             final HTMLBodyElement body = (HTMLBodyElement)htmlDoc.getBody();
@@ -315,7 +315,7 @@
     }
 
     @Test public void testDOMWindowAndStyleAccess() {
-        final Document doc = getDocumentFor("test/html/dom.html");
+        final Document doc = getDocumentFor("src/test/resources/html/dom.html");
         submit(new Runnable() { public void run() {
             HTMLDocument htmlDoc = (HTMLDocument)doc;
             final HTMLBodyElement body = (HTMLBodyElement)htmlDoc.getBody();
@@ -332,7 +332,7 @@
     }
 
     @Test public void testDOMCSS() {
-        final Document doc = getDocumentFor("test/html/dom.html");
+        final Document doc = getDocumentFor("src/test/resources/html/dom.html");
         submit(new Runnable() { public void run() {
             StyleSheetList shl = ((HTMLDocumentImpl)doc).getStyleSheets();
             for (int i = 0; i < shl.getLength(); ++i ) {
--- a/modules/web/src/test/java/javafx/scene/web/HistoryTest.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/web/src/test/java/javafx/scene/web/HistoryTest.java	Wed Jul 10 11:01:52 2013 +0400
@@ -51,10 +51,10 @@
         });        
         
         // [1*]
-        checkLoad(new File("test/html/h1.html"), 1, 0, "1");
+        checkLoad(new File("src/test/resources/html/h1.html"), 1, 0, "1");
                         
         // [1, 2*]
-        checkLoad(new File("test/html/h2.html"), 2, 1, "2");
+        checkLoad(new File("src/test/resources/html/h2.html"), 2, 1, "2");
         
         //
         // check the list update
@@ -70,7 +70,7 @@
         });        
         
         // [1, 2, 3*]
-        checkLoad(new File("test/html/h3.html"), 3, 2, "3");
+        checkLoad(new File("src/test/resources/html/h3.html"), 3, 2, "3");
         
         ensureValueChanged(entriesChanged, "entries not changed after load");
         
@@ -112,7 +112,7 @@
             }
         });
         waitLoadFinished();
-        check(new File("test/html/h2.html"), 3, 1, "2");
+        check(new File("src/test/resources/html/h2.html"), 3, 1, "2");
                 
         ensureValueChanged(dateChanged, "date not changed after go(-1)");
         ensureValueChanged(indexChanged, "index not changed after go(-1)");
@@ -128,7 +128,7 @@
             }
         });
         waitLoadFinished();
-        check(new File("test/html/h3.html"), 3, 2, "3");
+        check(new File("src/test/resources/html/h3.html"), 3, 2, "3");
         
         submit(new Runnable() {
             public void run() {
@@ -137,7 +137,7 @@
             }
         });
         waitLoadFinished();
-        check(new File("test/html/h1.html"), 3, 0, "1");
+        check(new File("src/test/resources/html/h1.html"), 3, 0, "1");
         
         submit(new Runnable() {
             public void run() {
@@ -163,7 +163,7 @@
             }
         });
         waitLoadFinished();
-        check(new File("test/html/h3.html"), 3, 2, "3");
+        check(new File("src/test/resources/html/h3.html"), 3, 2, "3");
         
         submit(new Runnable() {
             public void run() {
@@ -186,7 +186,7 @@
             }
         });
         // [2, 3, 1*]
-        checkLoad(new File("test/html/h1.html"), 3, 2, "1");
+        checkLoad(new File("src/test/resources/html/h1.html"), 3, 2, "1");
         
         submit(new Runnable() {
             public void run() {
@@ -208,9 +208,9 @@
         waitLoadFinished();
         
         // [2, 1*]
-        checkLoad(new File("test/html/h1.html"), 2, 1, "1");
+        checkLoad(new File("src/test/resources/html/h1.html"), 2, 1, "1");
         // [2, 1, 3*]
-        checkLoad(new File("test/html/h3.html"), 3, 2, "3");
+        checkLoad(new File("src/test/resources/html/h3.html"), 3, 2, "3");
         
         submit(new Runnable() {
             public void run() {
@@ -225,14 +225,14 @@
         //
         
         // [2, 3*]
-        checkLoad(new File("test/html/h3.html"), 2, 1, "3");
+        checkLoad(new File("src/test/resources/html/h3.html"), 2, 1, "3");
 
         //
         // check the date update on reload
         //
         
         // [2, 3, 4*]
-        load(new File("test/html/h4.html"));
+        load(new File("src/test/resources/html/h4.html"));
         
         history.getEntries().get(history.getCurrentIndex()).lastVisitedDateProperty().addListener(newDateListener());
         
--- a/modules/web/src/test/java/javafx/scene/web/JavaScriptBridgeTest.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/web/src/test/java/javafx/scene/web/JavaScriptBridgeTest.java	Wed Jul 10 11:01:52 2013 +0400
@@ -17,7 +17,7 @@
     }
     
     public @Test void testJSBridge1() throws InterruptedException {
-        final Document doc = getDocumentFor("test/html/dom.html");
+        final Document doc = getDocumentFor("src/test/resources/html/dom.html");
         final WebEngine web = getEngine();
         
         submit(new Runnable() { public void run() {
@@ -113,7 +113,7 @@
     }
 
     public @Test void testJSBridge3() throws InterruptedException {
-        //final Document doc = getDocumentFor("test/html/dom.html");
+        //final Document doc = getDocumentFor("src/test/resources/html/dom.html");
         final WebEngine web = getEngine();
 
         submit(new Runnable() { public void run() {
@@ -185,7 +185,7 @@
     }
 
     @Test public void testJSBridge5() throws InterruptedException {
-        final Document doc = getDocumentFor("test/html/dom.html");
+        final Document doc = getDocumentFor("src/test/resources/html/dom.html");
         final WebEngine web = getEngine();
 
         submit(new Runnable() { public void run() {
--- a/modules/web/src/test/java/javafx/scene/web/LeakTest.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/web/src/test/java/javafx/scene/web/LeakTest.java	Wed Jul 10 11:01:52 2013 +0400
@@ -24,7 +24,7 @@
 
     @Ignore // RT-26710: javafx.scene.web.LeakTest hangs
     @Test public void testOleg() throws InterruptedException{
-        final String URL = new File("test/html/guimark2-vector.html").toURI().toASCIIString();
+        final String URL = new File("src/test/resources/html/guimark2-vector.html").toURI().toASCIIString();
         final int CYCLE_COUNT = 16;
         final int CYCLE_LENGTH = 5;
         final CountDownLatch latch = new CountDownLatch(CYCLE_COUNT);
--- a/modules/web/src/test/java/javafx/scene/web/LoadNotificationsTest.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/web/src/test/java/javafx/scene/web/LoadNotificationsTest.java	Wed Jul 10 11:01:52 2013 +0400
@@ -25,7 +25,7 @@
     AssertionError assertion;
 
     @Test public void testSuccessfulLoad() {
-        testFile("test/html/ipsum.html");
+        testFile("src/test/resources/html/ipsum.html");
     }
 
     @Test public void testFailedLoad() {
--- a/modules/web/src/test/java/javafx/scene/web/LoadTest.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/web/src/test/java/javafx/scene/web/LoadTest.java	Wed Jul 10 11:01:52 2013 +0400
@@ -35,7 +35,7 @@
     }
 
     @Test public void testLoadGoodUrl() {
-        final String FILE = "test/html/ipsum.html";
+        final String FILE = "src/test/resources/html/ipsum.html";
         load(new File(FILE));
         WebEngine web = getEngine();
 
@@ -153,7 +153,7 @@
         });
         
         String scriptUrl =
-                new File("test/html/invoke-alert.js").toURI().toASCIIString();
+                new File("src/test/resources/html/invoke-alert.js").toURI().toASCIIString();
         String html =
                 "<html>\n" +
                 "<head><script src=\"" + scriptUrl + "\"></script></head>\n" +
--- a/modules/web/src/test/java/javafx/scene/web/MiscellaneousTest.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/web/src/test/java/javafx/scene/web/MiscellaneousTest.java	Wed Jul 10 11:01:52 2013 +0400
@@ -50,6 +50,7 @@
         private static int dummyField;
     }
 
+    @org.junit.Ignore
     @Test public void testRT30835() throws Exception {
         class Record {
             private final Document document;
@@ -74,7 +75,7 @@
         submit(new Runnable() { public void run() {
             getEngine().getLoadWorker().stateProperty().addListener(listener);
         }});
-        String location = new File("src/test/java/html/RT30835.html")
+        String location = new File("src/test/resources/html/RT30835.html")
                 .toURI().toASCIIString().replaceAll("^file:/", "file:///");
         load(location);
         assertEquals(1, records.size());
--- a/modules/web/src/test/java/javafx/scene/web/WebViewTest.java	Tue Jul 09 18:33:45 2013 +0400
+++ b/modules/web/src/test/java/javafx/scene/web/WebViewTest.java	Wed Jul 10 11:01:52 2013 +0400
@@ -24,7 +24,7 @@
         setZoom(view, ZOOM);
         checkZoom(view, ZOOM);
 
-        load(new File("test/html/ipsum.html"));
+        load(new File("src/test/resources/html/ipsum.html"));
 
         checkFontScale(view, SCALE);
         checkZoom(view, ZOOM);
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/modules/web/src/test/resources/html/RT30835.html	Wed Jul 10 11:01:52 2013 +0400
@@ -0,0 +1,8 @@
+<!DOCTYPE html>
+<html>
+<head>
+<meta http-equiv="Refresh" content="100; URL=ipsum.html" />
+</head>
+<body>
+</body>
+</html>