Add window fitting and automatic resizing.