added autofitting to XL