+ resize support
* improved resizing code