fix color alpha code, add mouse up when pointer leaves canvas