Better support for large layouts

Many of the constants assume the layout size is 1x1.  This may not be the case if pos and/or fixed are passed.