fix a bug that creating an annotation may freeze xygraph