/*
jQWidgets v4.5.2 (2017-May)
Copyright (c) 2011-2017 jQWidgets.
License: http://jqwidgets.com/license/
*/
!function(a){a.extend(a.jqx._jqxChart.prototype,{_moduleAnnotations:!0,_renderAnnotation:function(a,b,c){var d=this.seriesGroups[a],e=this.renderer;if(!isNaN(a)){var f=this._get([this.getXAxisDataPointOffset(b.xValue,a),b.x]),g=this._get([this.getValueAxisDataPointOffset(b.yValue,a),b.y]),h=this._get([this.getXAxisDataPointOffset(b.xValue2,a),b.x2]),i=this._get([this.getValueAxisDataPointOffset(b.yValue2,a),b.y2]);if(d.polar||d.spider){var j=this.getPolarDataPointOffset(b.xValue,b.yValue,a);!j||isNaN(j.x)||isNaN(j.y)?(f=b.x,g=b.y):(f=j.x,g=j.y)}if(isNaN(g)||isNaN(f))return!1;if("horizontal"==d.orientation){var k=f;f=g,g=k,k=h,h=i,i=k}b.offset&&(isNaN(b.offset.x)||(f+=b.offset.x,h+=b.offset.x),isNaN(b.offset.y)||(g+=b.offset.y,i+=b.offset.y));var l,m=this._get([b.width,h-f]),n=this._get([b.height,i-g]);switch(b.type){case"rect":l=e.rect(f,g,m,n);break;case"circle":l=e.rect(f,g,b.radius);break;case"line":l=e.rect(f,g,h,i);break;case"path":l=e.path(b.path)}e.attr(l,{fill:b.fillColor,stroke:b.lineColor,opacity:this._get([b.fillOpacity,b.opacity]),"stroke-opacity":this._get([b.lineOpacity,b.opacity]),"stroke-width":b.lineWidth,"stroke-dasharray":b.dashStyle||"none"});var o;if(b.text){var p=b.text,q=0,r=0;p.offset&&(isNaN(p.offset.x)||(q+=p.offset.x),isNaN(p.offset.y)||(r+=p.offset.y)),o=e.text(p.value,f+q,g+r,NaN,NaN,p.angle,{},p.clip===!0,p.horizontalAlignment||"center",p.verticalAlignment||"center",p.rotationPoint||"centermiddle"),e.attr(o,{fill:p.fillColor,stroke:p.lineColor,class:p.class})}for(var s=["click","mouseenter","mouseleave"],t=this,u=0;u<s.length;u++){var v=this._getEvent(s[u])||s[u];l&&this.renderer.addHandler(l,v,function(){t._raiseAnnotationEvent(b,v)}),o&&this.renderer.addHandler(o,v,function(){t._raiseAnnotationEvent(b,v)})}}},_raiseAnnotationEvent:function(a,b){this._raiseEvent("annotation_"+b,{annotation:a})}})}(jqxBaseFramework);

