add "if else" as a condition to have a rectangle window