rectangle drawing implemented