if(!this.shape) return; this.startArrowGroup.remove(this.startArrow); this.endArrowGroup.remove(this.endArrow); this.shape.remove(this.startArrowGroup); this.shape.remove(this.endArrowGroup); this.shape.remove(this.pathShape); this.shape.remove(this.labelShape); this.figure.group.remove(this.shape); this.shape=this.pathShape=this.labelShape=this.startArrowGroup=this.startArrow=this.endArrowGroup=this.endArrow=null;