                 else
                     layoutElementHeight = layoutElement.getPreferredBoundsHeight();
                     
-                containerHeight = Math.max(containerHeight, layoutElementHeight);
+                containerHeight = Math.max(containerHeight, Math.ceil(layoutElementHeight));
             }
         }
 

                continue;

            // Set the layout element's position
            var y:Number = y0 + (containerHeight - layoutElement.getLayoutBoundsHeight()) * vAlign;
            // In case we have VerticalAlign.MIDDLE we have to round
            if (vAlign == 0.5)
                y = Math.round(y);
            layoutElement.setLayoutBoundsPosition(x, y);

            // Update maxX,Y, first,lastVisibleIndex, and x
            var dx:Number = layoutElement.getLayoutBoundsWidth();
            var dy:Number = layoutElement.getLayoutBoundsHeight();
            maxX = Math.max(maxX, x + dx);
            maxY = Math.max(maxY, y + dy);            
            if (!clipAndEnableScrolling || 

        var layoutElement:ILayoutElement;
        
        // columnWidth can be expensive to compute
        var cw:Number = (variableColumnWidth) ? 0 : Math.ceil(columnWidth);
        var count:uint = target.numElements;
        var totalCount:uint = count; // number of elements to use in gap calculation
        
