                 if (mirror && layoutFeatures == null)
                 {
                     initAdvancedLayoutFeatures();
-                    layoutFeatures.mirror = mirror;
-                    validateTransformMatrix();
+                    if (layoutFeatures != null)
+                    {
+                        layoutFeatures.mirror = mirror;
+                        validateTransformMatrix();
+                    }
                 }
                 else if (!mirror && layoutFeatures)
                 {

     */
    override public function get width():Number
    {
        // Return bounding box width in mirroring case
        return (layoutFeatures == null) ? super.width :
               MatrixUtil.transformSize(layoutFeatures.layoutWidth, _height, transform.matrix).x;
    }
    
    /**

    //  layoutDirection
    //----------------------------------
    
    // Use "ltr" instead of LayoutDirection.LTR to avoid depending
    // on that framework class.
    private var _layoutDirection:String = "ltr";
    
    [Inspectable(category="General", enumeration="ltr,rtl")]
    
