got square working on vertical rectangle