diff -r 9ee27703a03f javafx-ui-common/src/javafx/scene/layout/GridPane.java
--- a/javafx-ui-common/src/javafx/scene/layout/GridPane.java	Thu Aug 02 15:49:59 2012 +1200
+++ b/javafx-ui-common/src/javafx/scene/layout/GridPane.java	Thu Aug 02 13:23:20 2012 -0700
@@ -918,9 +918,10 @@
      * @param children the nodes to be added as a row in the gridpane
      */
     public void addRow(int rowIndex, Node... children) {
-        int columnIndex = 0;
-        for (int i = 0; i < getChildren().size(); i++) {
-            Node child = getChildren().get(i);
+        int columnIndex = 0;       
+        final List<Node> list = getChildren();
+        for (int i = 0, size = list.size(); i < size; i++) {
+            Node child = list.get(i);
             if (child.isManaged() && rowIndex == getNodeRowIndex(child)) {
                 int index = getNodeColumnIndex(child);
                 int end = getNodeColumnEnd(child);
@@ -944,8 +945,9 @@
      */
     public void addColumn(int columnIndex, Node... children)  {
         int rowIndex = 0;
-        for (int i = 0; i < getChildren().size(); i++) {
-            Node child = getChildren().get(i);
+        final List<Node> list = getChildren();
+        for (int i = 0, size = list.size(); i < size; i++) {
+            Node child = list.get(i);
             if (child.isManaged() && columnIndex == getNodeColumnIndex(child)) {
                 int index = getNodeRowIndex(child);
                 int end = getNodeRowEnd(child);
@@ -1103,8 +1105,9 @@
         if (metricsDirty) {
             int numRows = getRowConstraints().size();
             int numColumns = getColumnConstraints().size();
-            for (int i = 0; i < getChildren().size(); i++) {
-                Node child = getChildren().get(i);
+            final List<Node> children = getChildren();
+            for (int i = 0, size = children.size(); i < size; i++) {
+                Node child = children.get(i);
                 if (child.isManaged()) {
                     int rowIndex = getNodeRowIndex(child);
                     int columnIndex = getNodeColumnIndex(child);
@@ -1139,8 +1142,9 @@
             boolean computeGrow = true;
             List<Node> startNodes = new ArrayList<Node>();
             List<Node> endNodes = new ArrayList<Node>();
-            for (int j = 0; j < getChildren().size(); j++) {
-                Node child = getChildren().get(j);
+            final List<Node> children = getChildren();
+            for (int j = 0, size = children.size(); j < size; j++) {
+                Node child = children.get(j);
                 if (child.isManaged()) {
                     if (getNodeRowIndex(child) == i) {
                         startNodes.add(child);
@@ -1182,7 +1186,7 @@
             VPos rowVPos = getRowValignment(i);
             Insets margins[] = new Insets[startNodes.size()];
             List<Node> baselineNodes = new ArrayList<Node>();
-            for(int j = 0, k = 0; j < startNodes.size(); j++) {
+            for(int j = 0, k = 0, size = startNodes.size(); j < size; j++) {
                 Node n = startNodes.get(j);
                 if (getValignment(n) == VPos.BASELINE) {
                     baselineNodes.add(n);
@@ -1194,7 +1198,7 @@
 
             if (computeMin || computeMax || computePref || computeGrow || rowVPos == VPos.BASELINE) {
                 // compute from content
-                for (int j = 0; j < endNodes.size(); j++) {
+                for (int j = 0, size = endNodes.size(); j < size; j++) {
                     Node child = endNodes.get(j);                    
                     Insets margin = getMargin(child);
                     double top = margin != null? margin.getTop() : 0;
@@ -1310,8 +1314,9 @@
             boolean computeGrow = true;
             List<Node> startNodes = new ArrayList<Node>();
             List<Node> endNodes = new ArrayList<Node>();
-            for (int j = 0; j < getChildren().size(); j++) {
-                Node child = getChildren().get(j);
+            final List<Node> children = getChildren();
+            for (int j = 0, size = children.size(); j < size; j++) {
+                Node child = children.get(j);
                 if (child.isManaged()) {
                     if (getNodeColumnIndex(child) == i) {
                         startNodes.add(child);
@@ -1353,7 +1358,7 @@
 
             if (computeMin || computeMax || computePref || computeGrow) {
                 // compute from content                
-                for (int j = 0; j < endNodes.size(); j++) {
+                for (int j = 0, size = endNodes.size(); j < size; j++) {
                     Node child = endNodes.get(j);
                     Insets margin = getMargin(child);
                     int columnIndex = getNodeColumnIndex(child);
@@ -1462,8 +1467,9 @@
      * @return null unless one of its children has a content bias.
      */
     @Override public Orientation getContentBias() {
-        for (int i = 0; i < getChildren().size(); i++) {
-            Node child = getChildren().get(i);
+        final List<Node> children = getChildren();
+        for (int i = 0, size = children.size(); i < size; i++) {
+            Node child = children.get(i);
             if (child.isManaged() && child.getContentBias() != null) {
                 return child.getContentBias();
             }
@@ -1515,8 +1521,9 @@
 
         final double x = left + computeXOffset(contentWidth, columnTotal, getAlignment().getHpos());
         final double y = top + computeYOffset(contentHeight, rowTotal, getAlignment().getVpos());
-        for (int i = 0; i < getChildren().size(); i++) {
-            Node child = getChildren().get(i);
+        final List<Node> children = getChildren();
+        for (int i = 0, size = children.size(); i < size; i++) {
+            Node child = children.get(i);
             if (child.isManaged()) {
                 int rowIndex = getNodeRowIndex(child);
                 int columnIndex = getNodeColumnIndex(child);
@@ -1620,7 +1627,7 @@
                 portion = (int)available / adjusting.size(); // negative in shrinking case
             }
             if (portion != 0) {
-                for (int i = 0; i < adjusting.size(); i++) {
+                for (int i = 0, size = adjusting.size(); i < size; i++) {
                     final int index = adjusting.get(i);
                     final double limit = (shrinking? rowMinHeight[index] : rowMaxHeight[index])
                             - rowHeights[index]; // negative in shrinking case
@@ -1633,9 +1640,9 @@
                     }
                     if (available == 0) {
                         break;
-                    }
+                    }   
                 }
-                for (int i = 0; i < adjusted.size(); i++) {
+                for (int i = 0, size = adjusted.size(); i < size; i++) {
                     adjusting.remove(adjusted.get(i));
                 }
                 adjusted.clear();
@@ -1715,7 +1722,7 @@
                 portion = (int)available / adjusting.size(); // negative in shrinking case
             }
             if (portion != 0) {
-                for (int i = 0; i < adjusting.size(); i++) {
+                for (int i = 0, size = adjusting.size(); i < size; i++) {                
                     final int index = adjusting.get(i);
                     final double limit = (shrinking? columnMinWidth[index] : columnMaxWidth[index])
                             - columnWidths[index]; // negative in shrinking case
@@ -1730,7 +1737,7 @@
                         break;
                     }                    
                 }
-                for (int i = 0; i < adjusted.size(); i++) {
+                for (int i = 0, size = adjusted.size(); i < size; i++) {                
                     adjusting.remove(adjusted.get(i));
                 }
                 adjusted.clear();
diff -r 9ee27703a03f javafx-ui-common/src/javafx/scene/layout/HBox.java
--- a/javafx-ui-common/src/javafx/scene/layout/HBox.java	Thu Aug 02 15:49:59 2012 +1200
+++ b/javafx-ui-common/src/javafx/scene/layout/HBox.java	Thu Aug 02 13:23:20 2012 -0700
@@ -412,7 +412,7 @@
         double[] prefAreaWidths = new double [managed.size()];
         final double insideHeight = height == -1? -1 : height -
                                      snapSpace(getInsets().getTop()) - snapSpace(getInsets().getBottom());
-        for (int i = 0; i < managed.size(); i++) {
+        for (int i = 0, size = managed.size(); i < size; i++) {
             Node child = managed.get(i);
             Insets margin = getMargin(child);
             prefAreaWidths[i] = minimum?
@@ -448,7 +448,7 @@
         List<Node> adjustList = new ArrayList<Node>();
         List<Node> adjusting = new ArrayList<Node>();
 
-        for (int i = 0; i < managed.size(); i++) {
+        for (int i = 0, size = managed.size(); i < size; i++) {
             final Node child = managed.get(i);
             if (shrinking || getHgrow(child) == priority) {
                 adjustList.add(child);
@@ -457,7 +457,7 @@
         }
 
         double[] areaLimitWidths = new double[adjustList.size()];
-        for (int i = 0; i < adjustList.size(); i++) {
+        for (int i = 0, size = adjustList.size(); i < size; i++) {
             final Node child = adjustList.get(i);
             final Insets margin = getMargin(child);
             areaLimitWidths[i] = shrinking?
@@ -468,7 +468,7 @@
         while (Math.abs(available) > 1.0 && adjusting.size() > 0) {
             Node[] adjusted = new Node[adjustList.size()];
             final double portion = available / adjusting.size(); // negative in shrinking case
-            for (int i = 0; i < adjusting.size(); i++) {
+            for (int i = 0, size = adjusting.size(); i < size; i++) {
                 final Node child = adjusting.get(i);
                 final int childIndex = managed.indexOf(child);
                 final double limit = areaLimitWidths[adjustList.indexOf(child)] - areaWidths[childIndex]; // negative in shrinking case                
@@ -480,7 +480,8 @@
                     adjusted[i] = child;
                 }
             }
-            for (Node node : adjusted) {
+            for (int i = 0; i < adjusted.length; i++) {
+                Node node = adjusted[i];
                 if (node != null) {
                     adjusting.remove(node);
                 }
@@ -522,7 +523,7 @@
         double baselineOffset = getAlignment().getVpos() == VPos.BASELINE ? getMaxBaselineOffset(managed)
                                     : height/2;
 
-        for (int i = 0; i < managed.size(); i++) {
+        for (int i = 0, size = managed.size(); i < size; i++) {
             Node child = managed.get(i);
             Insets margin = getMargin(child);
             layoutInArea(child, x, y, actualAreaWidths[i], contentHeight,
diff -r 9ee27703a03f javafx-ui-common/src/javafx/scene/layout/Region.java
--- a/javafx-ui-common/src/javafx/scene/layout/Region.java	Thu Aug 02 15:49:59 2012 +1200
+++ b/javafx-ui-common/src/javafx/scene/layout/Region.java	Thu Aug 02 13:23:20 2012 -0700
@@ -350,7 +350,7 @@
                 
                 final List<BorderImage> image_borders = getImageBorders();
                 if (image_borders != null) {
-                    for (int i = 0; i < image_borders.size(); i++) {
+                    for (int i = 0, size = image_borders.size(); i < size; i++) {
                         BorderImage borderImage = image_borders.get(i);
                         Insets offsets = borderImage.getOffsets();
                         // stoked borders assume centered strokes for now
@@ -363,7 +363,7 @@
                 
                 final List<StrokeBorder> stroke_borders = getStrokeBorders();
                 if (stroke_borders != null) {
-                    for (int i = 0; i < stroke_borders.size(); i++) {
+                    for (int i = 0, size = stroke_borders.size(); i < size; i++) {
                         StrokeBorder strokeBorder = stroke_borders.get(i);
                         Insets offsets = strokeBorder.getOffsets();
                         // stoked borders assume centered strokes for now
@@ -2199,7 +2199,7 @@
         
         final List<BackgroundFill> background_fills = getBackgroundFills();
         if (background_fills != null) {
-            for (int i = 0; i < background_fills.size(); i++) {
+            for (int i = 0, size = background_fills.size(); i < size; i++) {
                 BackgroundFill bgFill = background_fills.get(i);
                 Insets offsets = bgFill.getOffsets();
 
diff -r 9ee27703a03f javafx-ui-common/src/javafx/scene/layout/StackPane.java
--- a/javafx-ui-common/src/javafx/scene/layout/StackPane.java	Thu Aug 02 15:49:59 2012 +1200
+++ b/javafx-ui-common/src/javafx/scene/layout/StackPane.java	Thu Aug 02 13:23:20 2012 -0700
@@ -85,7 +85,7 @@
  * {@link javafx.scene.layout.Region Region} for details.</p>
  *
  * <h4>Resizable Range</h4>
- * 
+ *
  * A stackpane's parent will resize the stackpane within the stackpane's resizable range
  * during layout.   By default the stackpane computes this range based on its content
  * as outlined in the table below.
@@ -225,7 +225,7 @@
                 public void invalidated() {
                     requestLayout();
                 }
-                
+
                 @Override
                 public StyleableProperty getStyleableProperty() {
                     return StyleableProperties.ALIGNMENT;
@@ -244,7 +244,7 @@
         }
         return alignment;
     }
-    
+
     private ObjectProperty<Pos> alignment;
     public final void setAlignment(Pos value) { alignmentProperty().set(value); }
     public final Pos getAlignment() { return alignment == null ? Pos.CENTER : alignment.get(); }
@@ -255,8 +255,9 @@
      * have a content bias.
      */
     @Override public Orientation getContentBias() {
-        for (int i = 0; i < getChildren().size(); i++) {
-            Node child = getChildren().get(i);
+        final List<Node> children = getChildren();
+        for (int i = 0, size = children.size(); i < size; i++) {
+            Node child = children.get(i);
             if (child.isManaged() && child.getContentBias() != null) {
                 return child.getContentBias();
             }
@@ -342,7 +343,7 @@
         double bottom = getInsets().getBottom();
         double baselineOffset = getAlignment().getVpos() == VPos.BASELINE ? getMaxBaselineOffset(managed)
                                     : height/2;
-        for (int i = 0; i < managed.size(); i++) {
+        for (int i = 0, size = managed.size(); i < size; i++) {
             Node child = managed.get(i);
             Pos childAlignment = StackPane.getAlignment(child);
             layoutInArea(child, left, top,
@@ -364,9 +365,9 @@
       * @treatAsPrivate implementation detail
       */
      private static class StyleableProperties {
-         private static final StyleableProperty<StackPane,Pos> ALIGNMENT = 
+         private static final StyleableProperty<StackPane,Pos> ALIGNMENT =
              new StyleableProperty<StackPane,Pos>("-fx-alignment",
-                 new EnumConverter<Pos>(Pos.class), 
+                 new EnumConverter<Pos>(Pos.class),
                  Pos.CENTER) {
 
             @Override
@@ -383,7 +384,7 @@
 
          private static final List<StyleableProperty> STYLEABLES;
          static {
-            final List<StyleableProperty> styleables = 
+            final List<StyleableProperty> styleables =
                 new ArrayList<StyleableProperty>(Region.impl_CSS_STYLEABLES());
             Collections.addAll(styleables,
                 ALIGNMENT
diff -r 9ee27703a03f javafx-ui-common/src/javafx/scene/layout/TilePane.java
--- a/javafx-ui-common/src/javafx/scene/layout/TilePane.java	Thu Aug 02 15:49:59 2012 +1200
+++ b/javafx-ui-common/src/javafx/scene/layout/TilePane.java	Thu Aug 02 13:23:20 2012 -0700
@@ -737,7 +737,8 @@
                 Insets[] margins = getMargins(managed);
                 double h = -1;
                 boolean vertBias = false;
-                for (Node child: managed) {
+                for (int i = 0, size = managed.size(); i < size; i++) {
+                    Node child = managed.get(i);
                     if (child.getContentBias() == VERTICAL) {
                         vertBias = true;
                         break;
@@ -761,7 +762,8 @@
                 Insets[] margins = getMargins(managed);
                 double w = -1;
                 boolean horizBias = false;
-                for (Node child: managed) {
+                for (int i = 0, size = managed.size(); i < size; i++) {
+                    Node child = managed.get(i);
                     if (child.getContentBias() == Orientation.HORIZONTAL) {
                         horizBias = true;
                         break;
@@ -853,7 +855,7 @@
         
         int r = 0;
         int c = 0;
-        for (int i = 0; i < managed.size(); i++) {
+        for (int i = 0, size = managed.size(); i < size; i++) {
             Node child = managed.get(i);
             double xoffset = r == (actualRows - 1)? lastRowX : rowX;
             double yoffset = c == (actualColumns - 1)? lastColumnY : columnY;
diff -r 9ee27703a03f javafx-ui-common/src/javafx/scene/layout/VBox.java
--- a/javafx-ui-common/src/javafx/scene/layout/VBox.java	Thu Aug 02 15:49:59 2012 +1200
+++ b/javafx-ui-common/src/javafx/scene/layout/VBox.java	Thu Aug 02 13:23:20 2012 -0700
@@ -46,6 +46,8 @@
 import com.sun.javafx.css.converters.EnumConverter;
 import com.sun.javafx.css.converters.SizeConverter;
 import javafx.beans.value.WritableValue;
+import javafx.geometry.HPos;
+import javafx.geometry.VPos;
 
 /**
  * VBox lays out its children in a single vertical column.
@@ -324,8 +326,9 @@
      * @return null unless one of its children has a content bias.
      */
     @Override public Orientation getContentBias() {        
-        for (int i = 0; i < getChildren().size(); i++) {
-            Node child = getChildren().get(i);
+        final List<Node> children = getChildren();
+        for (int i=0, size=children.size(); i<size; i++) {
+            Node child = children.get(i);
             if (child.isManaged() && child.getContentBias() != null) {
                 return child.getContentBias();
             }
@@ -388,7 +391,7 @@
         double[] prefAreaHeights = new double [managed.size()];
         final double insideWidth = width == -1? -1 : width -
                 snapSpace(getInsets().getLeft()) - snapSpace(getInsets().getRight());
-        for (int i = 0; i < managed.size(); i++) {
+        for (int i = 0, size = managed.size(); i < size; i++) {
             Node child = managed.get(i);
             Insets margin = getMargin(child);
             prefAreaHeights[i] = minimum?
@@ -425,7 +428,7 @@
         List<Node> adjustList = new ArrayList<Node>();
         List<Node> adjusting = new ArrayList<Node>();
 
-        for (int i = 0; i < managed.size(); i++) {
+        for (int i = 0, size = managed.size(); i < size; i++) {
             Node child = managed.get(i);
             if (shrinking || getVgrow(child) == priority) {
                 adjustList.add(child);
@@ -434,7 +437,7 @@
         }
 
         double[] areaLimitHeights = new double[adjustList.size()];
-        for (int i = 0; i < adjustList.size(); i++) {
+        for (int i = 0, size = adjustList.size(); i < size; i++) {        
             Node child = adjustList.get(i);
             Insets margin  = getMargin(child);
             areaLimitHeights[i] = shrinking?
@@ -445,7 +448,7 @@
         while (Math.abs(available) > 1.0 && adjusting.size() > 0) {
             Node[] adjusted = new Node[adjustList.size()];
             final double portion = available / adjusting.size(); // negative in shrinking case
-            for (int i = 0; i < adjusting.size(); i++) {
+            for (int i = 0, size = adjusting.size(); i < size; i++) {
                 final Node child = adjusting.get(i);
                 final int childIndex = managed.indexOf(child);
                 final double limit = areaLimitHeights[adjustList.indexOf(child)] - areaHeights[childIndex]; // negative in shrinking case
@@ -486,20 +489,22 @@
         double bottom = snapSpace(insets.getBottom());
         double right = snapSpace(insets.getRight());
         double space = snapSpace(getSpacing());
+        HPos hpos = getAlignment().getHpos();
+        VPos vpos = getAlignment().getVpos();
 
         actualAreaHeights = getAreaHeights(managed, width, false);
         double contentWidth = width - left - right;
         double contentHeight = adjustAreaHeights(managed, actualAreaHeights, height, width);
 
         double x = left;
-        double y = top + computeYOffset(height - top - bottom, contentHeight, getAlignment().getVpos());
+        double y = top + computeYOffset(height - top - bottom, contentHeight, vpos);
 
-        for (int i = 0; i < managed.size(); i++) {
+        for (int i = 0, size = managed.size(); i < size; i++) {
             Node child = managed.get(i);            
             layoutInArea(child, x, y, contentWidth, actualAreaHeights[i],
                        /* baseline shouldn't matter */actualAreaHeights[i],
                        getMargin(child), isFillWidth(), true,
-                       getAlignment().getHpos(), getAlignment().getVpos());
+                       hpos, vpos);
             y += actualAreaHeights[i] + space;
         }
     }
