Improved window resizing when no command is given