changed 4 space indentation back to 2 for the setWindow method.