implemented xor drawing