//>>built
define("dojox/charting/bidi/Chart","dojox/main dojo/_base/declare dojo/_base/lang dojo/dom-style dojo/_base/array dojo/sniff dojo/dom dojo/dom-construct dojox/gfx dojox/gfx/_gfxBidiSupport ../axis2d/common dojox/string/BidiEngine dojox/lang/functional dojo/dom-attr ./_bidiutils".split(" "),function(l,m,n,f,g,x,y,p,z,A,q,r,t,h,u){function k(a){return/^(ltr|rtl|auto)$/.test(a)?a:null}var v=new r;n.getObject("charting",!0,l);return m(null,{textDir:"",dir:"",isMirrored:!1,getTextDir:function(a){(a="auto"==
this.textDir?v.checkContextual(a):this.textDir)||(a=f.get(this.node,"direction"));return a},postscript:function(a,d){var c=d?d.textDir?k(d.textDir):"":"";this.textDir=c=c?c:f.get(this.node,"direction");this.surface.textDir=c;this.htmlElementsRegistry=[];this.truncatedLabelsRegistry=[];c="ltr";h.has(a,"direction")&&(c=h.get(a,"direction"));this.setDir(d?d.dir?d.dir:c:c)},setTextDir:function(a,d){if(a==this.textDir)return this;if(null!=k(a)){this.textDir=a;this.surface.setTextDir(a);this.truncatedLabelsRegistry&&
"auto"==a&&g.forEach(this.truncatedLabelsRegistry,function(b){var e=this.getTextDir(b.label);b.element.textDir!=e&&b.element.setShape({textDir:e})},this);var c=t.keys(this.axes);0<c.length?(g.forEach(c,function(b,e,w){b=this.axes[b];b.htmlElements[0]&&(b.dirty=!0,b.render(this.dim,this.offsets))},this),this.title&&this._renderTitle(this.dim,this.offsets)):g.forEach(this.htmlElementsRegistry,function(b,e,w){e="auto"==a?this.getTextDir(b[4]):a;b[0].children[0]&&b[0].children[0].dir!=e&&(p.destroy(b[0].children[0]),
b[0].children[0]=q.createText.html(this,this.surface,b[1],b[2],b[3],b[4],b[5],b[6]).children[0])},this)}return this},setDir:function(a){if("rtl"==a||"ltr"==a)this.dir!=a&&(this.dirty=this.isMirrored=!0),this.dir=a;return this},isRightToLeft:function(){return"rtl"==this.dir},applyMirroring:function(a,d,c){u.reverseMatrix(a,d,c,"rtl"==this.dir);f.set(this.node,"direction","ltr");return this},formatTruncatedLabel:function(a,d,c){this.truncateBidi(a,d,c)},truncateBidi:function(a,d,c){"gfx"==c&&(this.truncatedLabelsRegistry.push({element:a,
label:d}),"auto"==this.textDir&&a.setShape({textDir:this.getTextDir(d)}));"html"==c&&"auto"==this.textDir&&(a.children[0].dir=this.getTextDir(d))},render:function(){this.inherited(arguments);this.isMirrored=!1;return this},_resetLeftBottom:function(a){a.vertical&&this.isMirrored&&(a.opt.leftBottom=!a.opt.leftBottom)}})});