Some improvements to avoid as much layout thrashing as possible - batch together operations which force a layout and those which invalidate a layout. Add option to remove preload areas from DOM.