                 actualSize2 = fitTBoundsHeight(height, matrix,
                                                explicitWidth, explicitHeight,
                                                preferredWidth, preferredHeight,
-                                               minWidth, minHeight,
-                                               maxWidth, maxHeight);
+                                               newMinWidth, newMinHeight, 
+                                               newMaxWidth, newMaxHeight); 
 
                 // If we fit the height, but not the width
                 if (actualSize2)
                 {
                     var fitWidth:Number = transformSize(actualSize2.x, actualSize2.y, matrix).x;
-                    if (fitWidth - tolerance > width)
+                    if (fitWidth - SOLUTION_TOLERANCE > width)
                         actualSize2 = null;
                 }
                 

                actualSize1 = fitTBoundsWidth(width, matrix,
                                              explicitWidth, explicitHeight,
                                              preferredWidth, preferredHeight,
                                              minWidth, minHeight,
                                              maxWidth, maxHeight);

                // If we fit the width, but not the height.
                if (actualSize1)
                {
                    var fitHeight:Number = transformSize(actualSize1.x, actualSize1.y, matrix).y;
                    if (fitHeight - tolerance > height)
                        actualSize1 = null;
                }


        if (isNaN(width) && isNaN(height))
            return new Point(preferredWidth, preferredHeight);
        
        // Allow for precision errors by including tolerance for certain values.
        const newMinWidth:Number = (minWidth < MIN_MAX_TOLERANCE) ? 0 : minWidth - MIN_MAX_TOLERANCE;
        const newMinHeight:Number = (minHeight < MIN_MAX_TOLERANCE) ? 0 : minHeight - MIN_MAX_TOLERANCE;
        const newMaxWidth:Number = maxWidth + MIN_MAX_TOLERANCE;
        const newMaxHeight:Number = maxHeight + MIN_MAX_TOLERANCE;
        
        var actualSize:Point;
        
        if (!isNaN(width) && !isNaN(height))
        {
            actualSize = calcUBoundsToFitTBounds(width, height, matrix,
                                                 newMinWidth, newMinHeight, 
                                                 newMaxWidth, newMaxHeight); 
            
            // If we couldn't fit in both dimensions, try to fit only one and
            // don't stick out of the other
