if(!nexacro.TextArea){nexacro.TextArea_Style=function(_a){nexacro.Style.call(this);if(_a){this._target=_a;}this.linespace=null;this.caretcolor=null;this.compositecolor=null;};var _pTextAreaStyle=nexacro._createPrototype(nexacro.Style,nexacro.TextArea_Style);nexacro.TextArea_Style.prototype=_pTextAreaStyle;eval(nexacro._createValueAttributeEvalStr("_pTextAreaStyle","linespace"));eval(nexacro._createColorAttributeEvalStr("_pTextAreaStyle","caretcolor"));eval(nexacro._createColorAttributeEvalStr("_pTextAreaStyle","compositecolor"));eval(nexacro._createColorAttributeEvalStr("_pTextAreaStyle","selectcolor"));eval(nexacro._createColorAttributeEvalStr("_pTextAreaStyle","selectbackground"));_pTextAreaStyle.__custom_emptyObject=function(){this.linespace=null;this.caretcolor=null;this.compositecolor=null;this.selectcolor=null;this.selectbackground=null;};_pTextAreaStyle.__get_custom_style_value=function(){var _a="";if(this.linespace&&this.linespace._is_empty){_a+="linespace:"+this.linespace._value+"; ";}if(this.caretcolor&&!this.caretcolor._is_empty){_a+="caretcolor:"+this.caretcolor._value+"; ";}if(this.compositecolor&&!this.compositecolor._is_empty){_a+="compositecolor:"+this.compositecolor._value+"; ";}if(this.selectcolor&&!this.selectcolor._is_empty){_a+="selectcolor:"+this.selectcolor._value+"; ";}if(this.selectbackground&&!this.selectbackground._is_empty){_a+="selectbackground:"+this.selectbackground._value+"; ";}return _a;};nexacro.TextArea_CurrentStyle=function(){nexacro.CurrentStyle.call(this);this.linespace=null;this.caretcolor=null;this.compositecolor=null;};var _pTextAreaCurrentStyle=nexacro._createPrototype(nexacro.CurrentStyle,nexacro.TextArea_CurrentStyle);nexacro.TextArea_CurrentStyle.prototype=_pTextAreaCurrentStyle;_pTextAreaCurrentStyle.__custom_emptyObject=_pTextAreaStyle.__custom_emptyObject;_pTextAreaCurrentStyle.__get_custom_style_value=_pTextAreaStyle.__get_custom_style_value;delete _pTextAreaStyle;delete _pTextAreaCurrentStyle;_pTextAreaStyle=null;_pTextAreaCurrentStyle=null;nexacro.TextArea=function(_a,_b,_c,_d,_e,_f,_g,_h,_i){nexacro.Component.call(this,_a,_b,_c,_d,_e,_f,_g,_h,_i,true);this.acceptstab=false;this.autoselect=false;this.autoskip=false;this.displaynulltext="";this.imemode="none";this.inputfilter="none";this.inputmode="normal";this.inputtype="normal";this.lengthunit="utf16";this.maxlength=0;this.readonly=false;this.scrollbars="autoboth";this.tabindentsize=4;this.undotype="char";this.updatebindingvalue="default";this.usecontextmenu=true;this.usecontrolkey=true;this.useinputpanel=true;this.useime="global";this.value=undefined;this.text="";this.wordwrap="none";this.dragscrolltype="all";this._event_list={"onclick":1,"ondblclick":1,"onkeypress":1,"onkeydown":1,"onkeyup":1,"onkillfocus":1,"onsetfocus":1,"ondrag":1,"ondragenter":1,"ondragleave":1,"ondragmove":1,"ondrop":1,"onlbuttondown":1,"onlbuttonup":1,"onmouseenter":1,"onmouseleave":1,"onmousemove":1,"onmove":1,"onsize":1,"onrbuttondown":1,"onrbuttonup":1,"canchange":1,"onchanged":1,"oneditclick":1,"ontextchange":1,"ontextchanged":1,"cancharchange":1,"onchar":1,"onvscroll":1,"onhscroll":1,"onmousewheel":1,"oncontextmenu":1,"ontouchstart":1,"ontouchmove":1,"ontouchend":1,"onflingstart":1,"onfling":1,"onflingend":1,"onpinchstart":1,"onpinch":1,"onpinchend":1,"onlongpress":1,"onslidestart":1,"onslide":1,"onslideend":1};this._activate_flag=false;this._edit_base_api=new nexacro.MultilineEdit(this);this._init_max_scroll_width=0;this._init_max_scroll_height=0;this._input_element=null;this._is_scrollable=true;this._max_scroll_width=0;this._max_scroll_height=0;this._old_max_height=undefined;this._scrollbars=3;this._origin_scrollbars=3;this._wordwrap_scrollbars=1;this._update_scroll_lock=false;this._accessibility_role="textbox";this._caret_pos={begin: -1,end: -1};this._setcaret=false;this._textchanging=false;this._dsupdate_in_textchanging=false;this._dsupdate_cancel=false;this._max_line=null;this._old_selection=[0,0];};var _pTextArea=nexacro._createPrototype(nexacro.Component,nexacro.TextArea);nexacro.TextArea.prototype=_pTextArea;_pTextArea._type_name="TextArea";nexacro.TextArea._default_selectcolor=nexacro._getCachedStyleObj("color","#3e3e3eff");nexacro.TextArea._focused_selectcolor=nexacro._getCachedStyleObj("color","#ffffffff");nexacro.TextArea._default_selectbackground=nexacro._getCachedStyleObj("color","#ffffffb3");_pTextArea.on_apply_custom_pseudo=function(_a){if(_a){this._pseudo=_a;}else if(this._pseudo){_a=this._pseudo;}var _b=this.currentstyle;var _c=this.on_find_CurrentStyle_align(_a);if(_c!=_b.align){_b.align=_c;this.on_apply_style_align(_c);}var _d=this.on_find_CurrentStyle_font(_a);if(_d!=_b.font){_b.font=_d;this.on_apply_style_font(_d);}var _e=this.on_find_CurrentStyle_color(_a);if(_e!=_b.color){_b.color=_e;this.on_apply_style_color(_e);}var _f=this.on_find_CurrentStyle_caretcolor(_a);if(_f!=_b.caretcolor){_b.caretcolor=_f;this.on_apply_style_caretcolor(_f);}var _g=this.on_find_CurrentStyle_compositecolor(_a);if(_g!=_b.compositecolor){_b.compositecolor=_g;this.on_apply_style_compositecolor(_g);}var _h=this.on_find_CurrentStyle_selectcolor(_a);if(_h!=_b.selectcolor){_b.selectcolor=_h;this.on_apply_style_selectcolor(_h);}var _i=this.on_find_CurrentStyle_selectbackground(_a);if(_i!=_b.selectbackground){_b.selectbackground=_i;this.on_apply_style_selectbackground(_i);}var _j=this.on_find_CurrentStyle_linespace(_a);if(_j!=_b.linespace){_b.linespace=_j;this.on_apply_style_linespace(_j);}var _k=this.on_find_CurrentStyle_rtlimagemirroring(_a);if(_k!=_b.rtlimagemirroring){_b.rtlimagemirroring=_k;this.on_apply_style_rtlimagemirroring(_k);}};_pTextArea.on_create_custom_style=function(){return new nexacro.TextArea_Style(this);};_pTextArea.on_create_custom_currentStyle=function(){return new nexacro.TextArea_CurrentStyle();};_pTextArea.on_find_CurrentStyle_align=function(_a){var _b=this._find_pseudo_obj("align",_a,"align");return (_b)?_b:nexacro.Component._default_textarea_align;};_pTextArea.on_find_CurrentStyle_cursor=function(_a){var _b="";if(!this._isEnable()&&this.parent&&!this.parent._is_application){if(!this._is_subcontrol){_b=this.parent._find_pseudo_obj("cursor",_a);}else{var _c=this.parent;while(_c&&_c._is_form){_c=_c.parent;}if(_c){_b=_c._find_pseudo_obj("cursor",_a);}else{_b=null;}}}else{_b=this._find_pseudo_obj("cursor",_a);}return (_b)?_b:nexacro.Component._default_cursor;};_pTextArea.on_find_CurrentStyle_caretcolor=function(_a){return this._find_pseudo_obj("caretcolor",_a,"color");};_pTextArea.on_find_CurrentStyle_compositecolor=function(_a){return this._find_pseudo_obj("compositecolor",_a,"color");};_pTextArea.on_find_CurrentStyle_selectcolor=function(_a){var _b=this._find_pseudo_obj("selectcolor",_a,"color");if(!_b){if(_a=="focused"){_b=nexacro.TextArea._focused_selectcolor;}else{_b=nexacro.TextArea._default_selectcolor;}}return _b;};_pTextArea.on_find_CurrentStyle_selectbackground=function(_a){var _b=this._find_pseudo_obj("selectbackground",_a,"background");return (_b)?_b:nexacro.TextArea._default_selectbackground;};_pTextArea.on_find_CurrentStyle_linespace=function(_a){return this._find_pseudo_obj("linespace",_a,"value");};_pTextArea.on_update_style_cursor=function(){var _a=this.on_find_CurrentStyle_cursor(this._pseudo);this.currentstyle.cursor=_a;this.on_apply_style_cursor(_a);};_pTextArea.on_update_style_caretcolor=function(){var _a=this.on_find_CurrentStyle_caretcolor(this._pseudo);this.currentstyle.caretcolor=_a;this.on_apply_style_caretcolor(_a);};_pTextArea.on_update_style_compositecolor=function(){var _a=this.on_find_CurrentStyle_compositecolor(this._pseudo);this.currentstyle.compositecolor=_a;this.on_apply_style_compositecolor(_a);};_pTextArea.on_update_style_selectcolor=function(){var _a=this.on_find_CurrentStyle_selectcolor(this._pseudo);this.currentstyle.selectcolor=_a;this.on_apply_style_selectcolor(_a);};_pTextArea.on_update_style_selectbackground=function(){var _a=this.on_find_CurrentStyle_selectbackground(this._pseudo);this.currentstyle.selectbackground=_a;this.on_apply_style_selectbackground(_a);};_pTextArea.on_update_style_linespace=function(){var _a=this.on_find_CurrentStyle_linespace(this._pseudo);this.currentstyle.linespace=_a;this.on_apply_style_linespace(_a);};_pTextArea.on_update_style_padding=function(){var _a=this.on_find_CurrentStyle_padding(this._pseudo);this.currentstyle.padding=_a;this.on_apply_style_padding(_a);};_pTextArea.on_apply_style_align=function(_a){var _b=this.currentstyle;var _c=this._edit_base_api;var _d=this._input_element;if(_d){if(_b.align==null||(_b.align&&_b.align._is_empty)){_b.align=nexacro._cloneStyleObject(nexacro.Component._default_left_align);}_c.setPosition();_c._apply_style(_d);}};_pTextArea.on_apply_style_color=function(_a){var _b=this._input_element;if(_b){if(this.currentstyle.color==null){this.currentstyle.color=nexacro._cloneStyleObject(nexacro.Component._default_color);}_b.setElementColor(_a);}};_pTextArea.on_apply_style_cursor=function(_a){var _b=this.getElement();if(_b){_b.setElementCursor(_a);var _c=this._input_element;if(_c){_c.setElementCursor(_a);}}};_pTextArea.on_apply_style_font=function(_a){var _b=this._edit_base_api;var _c=this._input_element;if(_c){if(this.currentstyle.font==null){this.currentstyle.font=nexacro._cloneStyleObject(nexacro.Component._default_font);}_c.setElementFont(_a);_b.setPosition();_b._apply_style(_c);}};_pTextArea.on_apply_style_caretcolor=function(_a){};_pTextArea.on_apply_style_compositecolor=function(_a){};_pTextArea.on_apply_style_selectbackground=function(_a){var _b=this._input_element;if(_b){_b.setElementSelectBackgroundColor(_a);}};_pTextArea.on_apply_style_selectcolor=function(_a){var _b=this._input_element;if(_b){_b.setElementSelectColor(_a);}};_pTextArea.on_apply_style_linespace=function(_a){var _b=this._input_element;if(_b){var _c=_a?_a:0;_b.setElementLineSpace(_c);_b.setElementValue(this.value,true);this._update_scroll();}};_pTextArea.on_apply_style_padding=function(_a){var _b=this._input_element;if(_b){this._edit_base_api.setPosition();this._update_scroll();}};_pTextArea.on_apply_style_accessibility=function(_a){nexacro.Component.prototype.on_apply_style_accessibility.call(this,_a);if(this._input_element){this._input_element.setElementAccessibilityRole(_a.role);}};_pTextArea.on_create_contents=function(){var _a=this.getElement();if(_a){var _b=this.currentstyle;var _c=this._input_element=new nexacro.TextAreaElement(_a);_c.setElementSize(this._client_width,this._client_height);_c.setElementFont(_b.font);_c.setElementColor(_b.color);_c.setElementSelectColor(_b.selectcolor);_c.setElementSelectBackgroundColor(_b.selectbackground);this._setAccessibilityFlagMultiLine(true);delete _c;_c=null;}};_pTextArea.on_created_contents=function(){var _a=this._input_element;if(_a){var _b=nexacro._toString(this.value);var _c=this._edit_base_api;var _d=this.currentstyle;_a.setElementReadonly(this.readonly);_a.setElementMaxLength(this.maxlength);_a.setElementWordWrap(this.wordwrap);_a.setElementUseIme(this.useime);_a.setElementImeMode(this.imemode);_a.setElementEnable(this._isEnable());if(_c){_c.setValue(_b);}if(this.currentstyle&&this.currentstyle.cursor&&this.currentstyle.cursor.value!="auto"){this.on_apply_style_cursor(this.currentstyle.cursor);}_a.create();this.on_apply_lengthunit();_a._bindEvent();this.on_apply_prop_rtldirection();if(_c){_c.setPosition();}if(nexacro._enableaccessibility&&nexacro._accessibilitytype==4){_a._setElementInputLabel();}this.on_apply_displaynulltext();_a.setElementLineSpace(this.currentstyle.linespace);this._update_scroll();this._init_max_scroll_width=this._max_scroll_width=_a.getScrollWidth();this._init_max_scroll_height=this._max_scroll_height=_a.getScrollHeight();if(_d&&_d.cursor){this.on_apply_style_cursor(_d.cursor);}}};_pTextArea.on_destroy_contents=function(){var _a=this._input_element;if(_a){_a._unBindEvent();_a.destroy();this._input_element=null;}var _b=this._edit_base_api;if(_b){_b._destroy();this._edit_base_api=null;}this._caret_pos=null;};_pTextArea.on_change_containerRect=function(_a,_b){var _c=this._input_element;if(_c){_c.setElementSize(_a,_b);if(this._update_scroll_lock==true){return false;}this._update_scroll_lock=true;this._update_scroll();this._update_scroll_lock=false;}};_pTextArea.on_getBindableProperties=function(){return "value";};_pTextArea.on_apply_prop_enable=function(_a){nexacro.Component.prototype.on_apply_prop_enable.call(this,_a);if(this._edit_base_api){this._edit_base_api._set_enable(_a);}var _b=this._input_element;if(_b){_b.setElementEnable(_a);this.on_apply_style_cursor(this.currentstyle.cursor);}};_pTextArea.on_apply_custom_setfocus=function(_a){var _b=this._input_element;var _c=this._edit_base_api;if(_b){if(nexacro._enableaccessibility&&(_a=="downkey"||_a=="upkey")){if(this.vscrollbar&&this.vscrollbar.visible){this.vscrollbar.set_pos(0);}this.setCaretPos(0);}if(_c){_c._changeFocusText(_b);_c._bChangeFocusText=true;}_b.setElementFocus();}};_pTextArea.on_init_bindSource=function(_a,_b,_c){if(_b=="value"){var _d=this._edit_base_api;if(_d){if(_d._undoStack){_d._undoStack.init();}}this._setValue(undefined);return true;}};_pTextArea.on_change_bindSource=function(_a,_b,_c,_d,_e){if(_a=="value"){var _f=_b.getColumn(_c,_d);var _g=this._edit_base_api;var _h=this._input_element;if(_g&&_h){if(_f===this.value&&_f===_g._value&&_f===_h.value){return true;}if(this._textchanging){return true;}}if(_g){if(_g._undoStack){_g._undoStack.init();}}this._setValue(_f);if(_g&&_h){if(nexacro._checkActiveElement(_h)){var _i=_g._getFocusValue();if(_i!=_f){_g._setFocusValue();}}}return true;}return false;};_pTextArea.on_hscroll=function(_a,_b){if(this.onhscroll&&this.onhscroll._has_handlers){_b.fromobject=this;this.onhscroll._fireEvent(this,_b);}var _c=this._control_element;if(_c){this._input_element.setScrollLeft(_b.pos);}return true;};_pTextArea.on_vscroll=function(_a,_b){if(this.onvscroll&&this.onvscroll._has_handlers){_b.fromobject=this;this.onvscroll._fireEvent(this,_b);}var _c=this._control_element;if(_c){this._input_element.setScrollTop(_b.pos);}return true;};_pTextArea.on_get_style_accessibility_label=function(){var _a="";return _a;};_pTextArea._on_getAccessibilityAdditionalLabel=function(){if(this._edit_base_api&&this._isAccessibilityEnable()){return this._edit_base_api._on_getAccessibilityAdditionalLabel();}return "";};_pTextArea._getAccessibilityRole=function(_a){var _b=nexacro.Component.prototype._getAccessibilityRole.call(this,_a);if(nexacro._accessibilitytype==4){return "";}else{return _b;}};_pTextArea._setAccessibilityStatFocus=function(_a){if(this._input_element){var _b=this._getAccessibilityRole(this.on_find_CurrentStyle_accessibility(this._pseudo));if(this._getDescLevel()=="none"){_b="none";}this._input_element.setElementAccessibilityRole(_b);}return nexacro.Component.prototype._setAccessibilityStatFocus.call(this,_a);};_pTextArea._setAccessibilityNotifyEvent=function(_a){if(this._edit_base_api){this._edit_base_api._setAccessibilityNotifyLabel();}return nexacro.Component.prototype._setAccessibilityNotifyEvent.call(this,_a);};_pTextArea.on_apply_prop_rtldirection=function(){nexacro.Component.prototype.on_apply_prop_rtldirection.call(this);var _a=this._edit_base_api;if(_a){_a.setPosition();}};_pTextArea.set_text=function(_a){};_pTextArea.set_value=function(_a){_a=nexacro._toString(_a);if(_a&&_a!==undefined&&_a!=""){_a=_a.replace(/"/g,"\"");if(_a.indexOf("\r\n")!= -1||_a.indexOf("\n\r")!= -1){_a=_a.replace(/\r\n/g,"\n").replace(/\n\r/g,"\n");}else{if(_a.indexOf("\r")!= -1){_a=_a.replace(/\r/g,"");}}}if(_a!=this.value){var _b=this._getRootForm();var _c=this._edit_base_api;if(!this.applyto_bindSource("value",_a)){return;}if(nexacro.Browser=="IE"){if(_c){var _d=_c._accept_keyinput_event;_c._accept_keyinput_event=false;this._setValue(_a);_c._accept_keyinput_event=_d;}else{this._setValue(_a);}if(nexacro.BrowserVersion<=8){if(_b&&_b._bFireLoadEvent){this._recreateInputElement();}}}else{this._setValue(_a);}}};_pTextArea.on_apply_value=function(){var _a=this._edit_base_api;if(_a){_a.setValue(this.value);_a.syncValue();_a.onUpdateStyle(this);}this._refreshAccessibilityValue();};_pTextArea.set_scrollbars=function(_a){if(_a!=this.scrollbars||!this._is_created){switch(_a){case "none":this._scrollbars=0;break;case "autovert":this._scrollbars=1;break;case "autohorz":this._scrollbars=2;break;case "autoboth":this._scrollbars=3;break;case "fixedvert":this._scrollbars=4;break;case "fixedhorz":this._scrollbars=8;break;case "fixedboth":this._scrollbars=12;break;case "alwaysvert":this._scrollbars=16;break;case "alwayshorz":this._scrollbars=32;break;default:this._scrollbars=3;_a="autoboth";}this._origin_scrollbars=this._scrollbars;if((this.wordwrap!="none"&&this.wordwrap!="false"&&this.wordwrap!=false)&&this._scrollbars==3){this._scrollbars=this._wordwrap_scrollbars;}else{this._scrollbars=this._origin_scrollbars;}this.scrollbars=_a;if(this._control_element&&this._is_created){this._onResetScrollBar();}}this._update_scroll();return _a;};_pTextArea.set_displaynulltext=function(_a){var _b=nexacro._isNull(_a);if(_b){_a="";}else{_a=nexacro._toString(_a);_a=_a.replace(/"/g,"\"");}if(_a!=this.displaynulltext){this.displaynulltext=_a;this.on_apply_displaynulltext();}};_pTextArea.on_apply_displaynulltext=function(){var _a=this._input_element;if(_a){_a.setElementDisplayNullText(this.displaynulltext);}};_pTextArea.set_readonly=function(_a){_a=nexacro._toBoolean(_a);if(_a!=this.readonly){this.readonly=_a;this.on_apply_readonly();}};_pTextArea.on_apply_readonly=function(_a){var _b=this.readonly;if(_b){this._stat_change("readonly",this._pseudo);}else{this._stat_change("writable",this._pseudo=="readonly"?"normal":this._pseudo);}var _c=this._input_element;if(_c){_c.setElementReadonly(_b);}};_pTextArea.set_autoselect=function(_a){_a=nexacro._toBoolean(_a);if(_a!=this.autoselect){this.autoselect=_a;}};_pTextArea.set_autoskip=function(_a){_a=nexacro._toBoolean(_a);if(_a!=this.autoskip){this.autoskip=_a;}};_pTextArea.on_apply_autoskip=function(){var _a=this._getRootComponent(this);var _b=this._refform.getNextComponent(_a,true);if(_b){_b.setFocus();}};_pTextArea.set_acceptstab=function(_a){_a=nexacro._toBoolean(_a);if(_a!=this.acceptstab){this.acceptstab=_a;}};_pTextArea.set_maxlength=function(_a){_a=nexacro._toInt(_a);if(_a&&_a!=this.maxlength){this.maxlength=_a;this.on_apply_maxlength();}};_pTextArea.on_apply_maxlength=function(){var _a=this._input_element;if(_a){_a.setElementMaxLength(this.maxlength);}};_pTextArea.set_inputmode=function(_a){_a=nexacro._toString(_a);if(_a&&_a!=this.inputmode){this.inputmode=_a;}};_pTextArea.set_inputfilter=function(_a){_a=nexacro._toString(_a);if(_a&&_a!=this.inputfilter){this.inputfilter=_a;this.on_apply_inputfilter();}};_pTextArea.on_apply_inputfilter=function(){var _a=this._edit_base_api;if(_a){_a.setInputfilter(this.inputfilter);}};_pTextArea.set_inputtype=function(_a){_a=nexacro._toString(_a);if(_a==""){_a="normal";}if(_a&&_a!=this.inputtype){this.inputtype=_a;this.on_apply_inputtype();}};_pTextArea.on_apply_inputtype=function(){var _a=this._edit_base_api;if(_a){_a.setInputType(this.inputtype);}};_pTextArea.set_lengthunit=function(_a){if(_a!=this.lengthunit){this.lengthunit=_a;this.on_apply_lengthunit();}};_pTextArea.on_apply_lengthunit=function(){if(this._edit_base_api){this._edit_base_api.setLengthunit(this.lengthunit);}};_pTextArea.set_imemode=function(_a){this.imemode=nexacro._toString(_a);this.on_apply_imemode();};_pTextArea.on_apply_imemode=function(){var _a=this._input_element;if(_a){_a.setElementImeMode(this.imemode);}};_pTextArea.set_useime=function(_a){this.useime=nexacro._toString(_a);this.on_apply_useime();};_pTextArea.on_apply_useime=function(){var _a=this._input_element;if(_a){_a.setElementUseIme(this.useime);}};_pTextArea.set_wordwrap=function(_a){if(typeof (_a)=="string"){_a=_a.toLowerCase();}if(_a!=this.wordwrap){this.wordwrap=_a;this.on_apply_wordwrap();}};_pTextArea.on_apply_wordwrap=function(){var _a=this._input_element;if(_a){_a.setElementWordWrap(this.wordwrap);}if(this.wordwrap!="false"&&this.wordwrap!=false&&this.wordwrap!="none"&&this._scrollbars==3){this._scrollbars=this._wordwrap_scrollbars;}else{this._scrollbars=this._origin_scrollbars;}this._edit_base_api.onUpdateStyle(this);this.on_apply_value();};_pTextArea.set_linespace=function(_a){_a=nexacro._toInt(_a);if(_a&&_a!=this.linespace){this.linespace=_a;this.on_apply_linespace();this._update_scroll();}};_pTextArea.on_apply_linespace=function(){var _a=this._input_element;if(_a){var _b=(this.linespace<0)?"":this.linespace+"px";_a.setElementLineSpace(_b);}};_pTextArea.set_dragscrolltype=function(_a){nexacro.Form.prototype.set_dragscrolltype.call(this,_a);};_pTextArea.set_tabindentsize=function(_a){_a=nexacro._toInt(_a);if(_a!=this.tabindentsize){this.tabindentsize=_a;}};_pTextArea.set_undotype=function(_a){_a=nexacro._toString(_a);if(_a!=this.undotype){this.undotype=_a;}};_pTextArea.set_usecontrolkey=function(_a){_a=nexacro._toBoolean(_a);if(_a!=this.usecontrolkey){this.usecontrolkey=_a;}};_pTextArea.set_usecontextmenu=function(_a){_a=nexacro._toBoolean(_a);if(_a!=this.usecontextmenu){this.usecontextmenu=_a;}};_pTextArea.set_useinputpanel=function(_a){_a=nexacro._toBoolean(_a);if(_a!=this.useinputpanel){this.useinputpanel=_a;}};_pTextArea.set_updatebindingvalue=function(_a){_a=nexacro._toBoolean(_a);if(_a!=this.updatebindingvalue){this.updatebindingvalue=_a;}};_pTextArea.getLength=function(_a){var _b=this._edit_base_api;if(_b){if(!_a){_a=this.lengthunit;}return _b.getLength(this._input_element,this.value,false,null,_a);}return -1;};_pTextArea.getCaretPos=function(){if(this.readonly){return -1;}var _a=this._input_element;if(_a){if(!_a._checkActiveElement()){return -1;}var _b=_a.getElementCaretPos();if(_b&&_b!= -1){return _b.begin;}}return -1;};_pTextArea.getInputElementAttribute=function(_a){var _b=this._input_element;if(_b){return _b.getInputElementAttribute(_a);}return undefined;};_pTextArea.setInputElementAttribute=function(_a,_b){var _c=this._input_element;if(_c){return _c.setInputElementAttribute(_a,_b);}return false;};_pTextArea.setCaretPos=function(_a){var _b=this._edit_base_api;var _c=this._input_element;if(_c){if(arguments.length==0){_a=0;}else{_a=nexacro._toInt(_a);if(_a== -1){if(_a){_a=this.value.length;}else{_a=0;}}}_c.setElementSetSelect(_a,_a);_b._begin_pos=_b._end_pos=_a;this._caret_pos.begin=_a;this._caret_pos.end=_a;this._setcaret=true;return true;}return false;};_pTextArea.getSelect=function(){var _a=this._input_element;if(_a){if(this._is_focused==false){return this._last_selection;}var _b=_a.getElementCaretPos();return [_b.begin,_b.end];}else{return this._defalut_lastselection;}};_pTextArea.setSelect=function(_a,_b){var _c=this._input_element;if(_c){var _d=this._edit_base_api;var _e=this.text?this.text:"";var _f=_e.length;if(nexacro._isNull(_a)||_a===""){_a=0;}if(nexacro._isNull(_b)||_b===""){_b= -1;}if(!nexacro._isNumber(_a)){_a=nexacro._toInt(_a);}if(!nexacro._isNumber(_b)){_b=nexacro._toInt(_b);}if(_a== -1){_a=_f;}if(_b== -1){_b=_f;}if(_a>_b){var _g=_a;_a=_b;_b=_g;}_d._begin_pos=_a;_d._end_pos=_b;this._caret_pos.begin=_a;this._caret_pos.end=_b;this._setcaret=true;_c.setElementSetSelect(_a,_b);return true;}return false;};_pTextArea.getSelectedText=function(){var _a=this._input_element;if(_a){var _b=this.getSelect();if(this.value&&_b!=undefined){return this.value.substring(_b[0],_b[1]);}}return "";};_pTextArea.setSelectedText=function(_a){_a=nexacro._toString(_a);var _b=this._input_element;if(_a&&_b){var _c=this.getSelect();if(!_b._is_focused){_c[0]=this._old_selection[0];_c[1]=this._old_selection[1];}if(_c[0]==_c[1]){return;}var _d=this.value;var _e=_d.substring(0,_c[0]);var _f=_d.substring(_c[0],_c[1]);var _g=_d.substr(_c[1]);var _h=_e+_a+_g;this.set_value(_h);if(this._is_focused){this.setSelect(_c[0],_c[0]+_a.length);}else{this.applyto_bindSource("value",_h);}if(!_b._is_focused){this._restoreSelect();this._cancelSelect();}return _f;}return undefined;};_pTextArea.isAboveSelected=function(){};_pTextArea.insertText=function(_a,_b){_a=nexacro._toString(_a);if(_a){if(_b==null){_b= -1;}var _c=null;var _d=this.value;if(_d){if(_b<0){_c=_d+_a;}else{var _e=_d.split("");_e.splice(_b,0,_a);_c=_e.join("");}}else{_c=_a;}this.set_value(_c);}};_pTextArea.deleteText=function(_a,_b){_a=_a===undefined?0:parseInt(_a,10);_b=_b===undefined? -1:parseInt(_b,10);if(_b< -1||_a<0||isNaN(_a)||isNaN(_b)){return false;}if(_a==null){_a=0;}if(_b==null){_b= -1;}var _c=null;var _d=this.value;var _e=_d.split("");if(_b== -1){_e.splice(_a,_e.length);}else{_e.splice(_a,_b);}_c=_e.join("");this.set_value(_c);};_pTextArea.find=function(_a,_b){if(_b==null){_b=0;}_b=nexacro._toInt(_b);_a=nexacro._toString(_a);if(_b<0){return -1;}return _a?this.value.indexOf(_a,_b): -1;};_pTextArea.replace=function(_a,_b){if(_b==null){_b="";}_a=nexacro._toString(_a);_b=nexacro._toString(_b);var _c=this.value;if(_a){_c=_c.split(_a).join(_b);this.set_value(_c);}return _c;};_pTextArea.updateToDataset=function(){var _a=this.applyto_bindSource("value",this.value);if(this._textchanging){this._dsupdate_in_textchanging=true;if(!_a){this._dsupdate_cancel=true;}else{this._dsupdate_cancel=false;}}else{this._dsupdate_in_textchanging=false;}return _a;};_pTextArea._on_activate=function(){if(!this._isSelected()){this._stat_change("focus","normal");}this._activate_flag=true;};_pTextArea._on_killfocus=function(_a,_b){if(!this._is_alive){return;}var _c=this._edit_base_api;var _d=this._input_element;if(_c&&_d){var _e=_c._getFocusText();var _f=_c._getFocusValue();var _g=_c._getText();var _h=_c._getValue();if(nexacro.Browser=="IE"&&!_d._is_focused){if(_e!=_g){this.applyto_bindSource("value",this.value);}return;}_c._is_on_killfocus=true;this._on_input_blur(_d);_c._is_on_killfocus=false;if(_e!=_g||(application._is_input_paste&&this==application._input_paste_comp)){application._is_input_paste=false;application._input_paste_comp=null;var _i=this._getWindow();if(_i&&_i._is_active_window!=true&&!_a){_d.setElementValue(_c._value,false,true);return;}var _j=this._on_fire_changeEventSet(_e,_f,_g,_h);if(!_j){return;}}else if(_f===undefined&&_e==_g){_c._setValue(undefined);_c._setText("");_c.syncValue();_d.setElementValue(_c._value);}else{_d.setElementValue(_c._value,false,true);}this._restoreSelect();this._cancelSelect();}};_pTextArea._cancelSelect=function(){var _a=this._edit_base_api;if(nexacro.Browser=="IE"){if(_a._is_selected()){if(this.visible){var _b=this._getRootForm();var _c=_b.getElement();if(_b.vscrollbar){_c._recover_vpos=_b.vscrollbar.pos;}if(_b.hscrollbar){_c._recover_hpos=_b.hscrollbar.pos;}this.setCaretPos(_a._begin_pos);if(nexacro.BrowserVersion<=8){_c._recover_vpos=undefined;_c._recover_hpos=undefined;}}else{this.setCaretPos(_a._begin_pos);}}}};_pTextArea._restoreSelect=function(){this._old_selection=this.getSelect();};_pTextArea._on_click=function(_a,_b,_c,_d,_e,_f,_g,_h,_i){if(!this._is_alive){return;}if(this.visible&&this._isEnable()&&this.enableevent){var _j=this.getCaretPos();var _k=this._getClientXY(_f,_g);this.on_fire_oneditclick(this,_j,_b,_c,_d,_e,_h,_i,_f,_g,_k[0],_k[1],this,this);}};_pTextArea._on_input_keyinput=function(_a){var _b=this._edit_base_api;if(_b){_b._on_input_keyinput(_a);_b._on_input_keyinput_after();}};_pTextArea._on_input_focus=function(_a,_b){var _c=this._edit_base_api;if(_c){_c._on_input_focus(_a,_b);}};_pTextArea._on_input_blur=function(_a,_b){var _c=this._edit_base_api;if(_c){_c._on_input_blur(_a,_b);}};_pTextArea._on_input_keydown=function(_a,_b,_c,_d,_e){var _f=false;var _g=this._edit_base_api;if(_g){_f=_g._on_input_keydown(_a,_b,_c,_d,_e);}return _f;};_pTextArea._on_input_keyup=function(_a,_b,_c,_d,_e){var _f=false;var _g=this._edit_base_api;if(_g){_f=_g._on_input_keyup(_a,_b,_c,_d,_e);}return _f;};_pTextArea._on_input_keypress=function(_a,_b,_c,_d,_e,_f){var _g=false;var _h=this._edit_base_api;if(_h){_g=_h._on_input_keypress(_a,_b,_c,_d,_e,_f);}return _g;};_pTextArea._on_input_mousedown=function(_a,_b,_c,_d){var _e=this._edit_base_api;if(_e){_e._on_input_mousedown(_a,_b,_c,_d);}};_pTextArea._on_input_mouseup=function(_a,_b,_c,_d){var _e=this._edit_base_api;if(_e){_e._on_input_mouseup(_a,_b,_c,_d);}};_pTextArea._on_input_mousemove=function(_a){var _b=this._edit_base_api;if(_b){_b._on_input_mousemove(_a);}};_pTextArea._on_input_touchstart=function(_a){var _b=this._edit_base_api;if(_b){_b._on_input_touchstart(_a);}};_pTextArea._on_input_touchmove=function(_a){var _b=this._edit_base_api;if(_b){_b._on_input_touchmove(_a);}};_pTextArea._on_input_touchend=function(_a){var _b=this._edit_base_api;if(_b){_b._on_input_touchend(_a);}};_pTextArea._on_input_select=function(_a){var _b=this._edit_base_api;if(_b){_b._on_input_select(_a);}};_pTextArea._on_input_paste=function(_a){var _b=this._edit_base_api;if(_b){_b._on_input_paste(_a);}};_pTextArea._on_input_cut=function(_a){var _b=this._edit_base_api;if(_b){_b._on_input_cut(_a);}};_pTextArea._on_input_compositionstart=function(_a){var _b=this._edit_base_api;if(_b){_b._on_input_compositionstart(_a);}};_pTextArea._on_input_compositionupdate=function(_a){var _b=this._edit_base_api;if(_b){_b._on_input_compositionupdate(_a);}};_pTextArea._on_input_compositionend=function(_a){var _b=this._edit_base_api;if(_b){_b._on_input_compositionend(_a);}};_pTextArea.on_fire_user_onkeydown=function(_a,_b,_c,_d,_e,_f){if(nexacro.Browser=="IE"&&nexacro.BrowserVersion<=8){if(nexacro._enableaccessibility){if(_a==nexacro.Event.KEY_DOWN||_a==nexacro.Event.KEY_UP){var _g;if(_a==nexacro.Event.KEY_DOWN){_g=1;}else if(_a==nexacro.Event.KEY_UP){_g=2;}var _h=this._getCaretLineString(null,_g);if(!_h){_h="#textarea:msg_accessibility_emptyline";}this._notifyAccessibility(_h,"valuechange");}}}return nexacro.Component.prototype.on_fire_user_onkeydown.call(this,_a,_b,_c,_d,_e,_f);};_pTextArea.on_fire_cancharchange=function(_a,_b,_c,_d){if(this.cancharchange&&this.cancharchange._has_handlers){var _e=new nexacro.CanCharEventInfo(_a,"cancharchange",_b,_c,"");return this.cancharchange._fireCheckEvent(this,_e);}return true;};_pTextArea.on_fire_canchange=function(_a,_b,_c,_d,_e){if(this.canchange&&this.canchange._has_handlers){var _f=new nexacro.ChangeEventInfo(_a,"canchange",_b,_c,_d,_e);return this.canchange._fireCheckEvent(this,_f);}return true;};_pTextArea.on_fire_onchanged=function(_a,_b,_c,_d,_e){if(this.onchanged&&this.onchanged._has_handlers){var _f=new nexacro.ChangeEventInfo(_a,"onchanged",_b,_c,_d,_e);return this.onchanged._fireEvent(this,_f);}};_pTextArea.on_fire_oneditclick=function(_a,_b,_c,_d,_e,_f,_g,_h,_i,_j,_k,_l,_m,_n){if(this.oneditclick&&this.oneditclick._has_handlers){var _o=new nexacro.EditClickEventInfo(_a,"oneditclick",_b,_c,_d,_e,_f,_g,_h,_i,_j,_k,_l,_m,_n);return this.oneditclick._fireEvent(this,_o);}return true;};_pTextArea.on_fire_ontextchanged=function(_a,_b,_c){this._max_line=null;if(this.ontextchanged&&this.ontextchanged._has_handlers){var _d=new nexacro.TextChangedEventInfo(_a,"ontextchanged",_b,_c);return this.ontextchanged._fireEvent(this,_d);}return true;};_pTextArea.on_fire_ontextchange=function(_a,_b){if(this.ontextchange&&this.ontextchange._has_handlers){if(!_b){var _b=new nexacro.TextChangeEventInfo(this,"ontextchange",_a.chartext,_a.pretext,_a.posttext,_a.preimetext,_a.postimetext);}return this.ontextchange._fireCheckEvent(this,_b);}return true;};_pTextArea.on_fire_onchar=function(_a,_b){if(this.onchar&&this.onchar._has_handlers){if(!_b){var _b=new nexacro.TextChangeEventInfo(this,"onchar",_a.chartext,_a.prechareventtext,_a.posttext);}return this.onchar._fireCheckEvent(this,_b);}return true;};_pTextArea._on_fire_textchangeEventSet=function(_a){var _b=_a.chartext;var _c=_a.chartext;var _d=false;var _e=_a.bInsert;var _f=_a.bCut;var _g=true;var _h=true;var _i=true;var _j=false;var _k=true;var _l=this._edit_base_api;var _m=new nexacro.TextChangeEventInfo(this,"ontextchange",_a.chartext,_a.pretext,_a.posttext,_a.preimetext,_a.postimetext);var _n=new nexacro.TextChangeEventInfo(this,"onchar",_a.chartext,_a.prechareventtext,_a.posttext);_o=this.on_fire_ontextchange(_a,_m);if(_o){if(_b!=_m.chartext){_j=true;_c=_m.chartext;}if(!_l._is_composition()){_o=this.on_fire_cancharchange(this,_a.chartext,_a.prechareventtext,_a.posttext);if(_o){_o=this.on_fire_onchar(_a,_n);if(!_o){_i=false;}if(_b!=_n.chartext){_c=_n.chartext;}}else{_i=false;_h=false;}}else{_k=false;}if(_b!=_c){var _p=_l.applyInputmode(_c);_p=_l._apply_inputfilter(_c);_p=_l._apply_inputtype(_c);if(_c.length>0&&_p.length==0){_d=true;}if(!_d){_e=_l._check_maxlength_from_text_event(_p);if(!_e){_p="";}else{_p=_l._apply_maxlength_from_text_event(_p);if(_p!=_c.chartext){_f=true;}}}_a.chartext=_p;var _q=_a.pretext.substr(0,_l._begin_pos);var _r=_a.pretext.substr(_l._end_pos,_a.pretext.length-_l._end_pos);_a.posttext=_q+_p+_r;if(_j&&_i&&_h){_o=this.on_fire_cancharchange(this,_a.chartext,_a.prechareventtext,_a.posttext);if(_o){evt=new nexacro.TextChangeEventInfo(this,"onchar",_a.chartext,_a.prechareventtext,_a.posttext);_o=this.on_fire_onchar(_a);if(!_o){_i=false;}}else{_i=false;_h=false;}}}}else{_g=false;}var _o={bTextchangeRet:_g,bCancahrchangeRet:_h,bOncharRet:_i,fireCancharEvent:_k,bInsert:_e,bCut:_f};return _o;};_pTextArea._on_fire_changeEventSet=function(_a,_b,_c,_d){var _e=this._edit_base_api;var _f=this._input_element;this._textchanging=true;var _g=this.on_fire_canchange(this,_a,_b,_c,_d);if(!_g){_e._setText(_a);_e._setValue(_b);_e.syncValue();_e._setFocusValue();_f.setElementValue(_e._value);this._init_bind_flag();return false;}_f.setElementValue(_e._value,false,true);if(this._dsupdate_cancel||(!this._dsupdate_in_textchanging&&!this.applyto_bindSource("value",this.value))){_e._setText(_a);_e._setValue(_b);_e.syncValue();_e._setFocusValue();_f.setElementValue(_e._value);this._init_bind_flag();return false;}_e._setFocusValue();this.on_fire_onchanged(this,_a,_b,this.text,this.value);this._init_bind_flag();return true;};_pTextArea._getDlgCode=function(_a,_b,_c,_d){var _e=true;if(nexacro._enableaccessibility){if(_a==nexacro.Event.KEY_UP){var _f=this._input_element;if(_f){var _g=_f.getCaretLine();if(_g<=1){_e=false;}}else{_e=false;}}else if(_a==nexacro.Event.KEY_DOWN){var _f=this._input_element;if(_f){var _g=_f.getCaretLine();var _h=parseInt(this._getTextLine());if(nexacro.Browser=="IE"&&nexacro.BrowserVersion==11){if(_g==(_h-1)){var _i=_f.getElementValue();var _j=_i.substr(_i.length-1,1);if(_j=="\n"||_j=="\r"){_g++ ;}}}if(_g>=_h){_e=false;}}else{_e=false;}}}return {want_tab:this.acceptstab,want_return:false,want_escape:false,want_chars:false,want_arrows:_e};};_pTextArea._init=function(){if(this._edit_base_api){this._edit_base_api._init();}this.set_value(undefined);};_pTextArea._init_bind_flag=function(){this._textchanging=false;this._dsupdate_in_textchanging=false;this._dsupdate_cancel=false;};_pTextArea._getDragData=function(){return this.getSelectedText();};_pTextArea._getHLineInfo=function(_a,_b){var _c=this.getElement();var _d=this._input_element;var _e=this.currentstyle;var _f=0;var _g=0;var _h=_a;var _i;var _j=_d.value;if(!_j){return 0;}_j=_j.replace(/\n/g,"\n\r");var _k=_j.length;var _l="";while(_h>=0&&(_l!='\n'&&_l!='\r')){_l=_j.charAt( --_h);}_f=_h+1;_l="";_h=_a;while(_k>=_h&&(_l!='\n'&&_l!='\r')){_l=_j.charAt(_h++ );}_g=_h-1;_h=_f;var _m=0;while(_h<_g&&_m<=_b){_i=nexacro._getTextSize2(_j.charAt(_h++ ),_e.font,((this.wordwrap!="none"&&this.wordwrap!=false&&this.wordwrap!="false")?true:false));_m+=_i[0];}if(_h>0){_h=_h-1;}var _n=_h;var _o=0;while(_h<=_g&&_o<=_c.client_width){_i=nexacro._getTextSize2(_j.charAt(_h++ ),curstylee.font,((this.wordwrap!="none"&&this.wordwrap!=false&&this.wordwrap!="false")?true:false));_o+=_i[0];}var _p=_h-1;if(_a>_n&&_a<_p){return -1;}if(_a>_n&&_o<_c.client_width&&_m>_b){return -1;}if(_a==_f){return 0;}var _q= -1;if(_a==_g&&_j.charAt(_a)=='\n'&&_a<_n){_q=0;_h=_f;while(_h<_a){_i=nexacro._getTextSize2(_j.charAt(_h++ ),_e.font,((this.wordwrap!="none"&&this.wordwrap!=false&&this.wordwrap!="false")?true:false));_q+=_i[0];}}else if(_a>=_p&&_m>_b){_h=_p;_q=0;while(_h<_a){_i=nexacro._getTextSize2(_j.charAt(_h++ ),_e.font,((this.wordwrap!="none"&&this.wordwrap!=false&&this.wordwrap!="false")?true:false));_q+=_i[0];}_q+=_b;}else if(_a<=_n){_h=_n;_q=0;while(_h>=_a){_i=nexacro._getTextSize2(_j.charAt(_h-- ),_e.font,((this.wordwrap!="none"&&this.wordwrap!=false&&this.wordwrap!="false")?true:false));_q+=_i[0];}_q=_b-_q;if(_q<0){_q=0;}}else if(_a>_f){_h=_f;_q=0;while(_h<_a-1){_i=nexacro._getTextSize2(_j.charAt(_h++ ),_e.font,((this.wordwrap!="none"&&this.wordwrap!=false&&this.wordwrap!="false")?true:false));_q+=_i[0];}if(_q<0){_q=0;}}return _q;};_pTextArea._getVLineInfo=function(_a){var _b=this.getElement();var _c=this.currentstyle;var _d=_c.font;var _e=nexacro._getTextSize2("Wj",_d);var _f=_c.linespace?nexacro._toInt(_c.linespace):0;var _g=_e[1]+_f;var _h=nexacro._toInt(_a/_g)+1;var _i=_h+Math.ceil((_b.client_height)/_g)-1;return {begin:_h,end:_i};};_pTextArea._getMaxTextLine=function(){var _a=this._input_element;var _b=this.currentstyle;var _c=0;var _d=_a.getScrollHeight();if(_d>0){var _e=_b.linespace?nexacro._toInt(_b.linespace):0;var _f=nexacro._getTextSize2("Wj",_b.font,((this.wordwrap!="none"&&this.wordwrap!=false&&this.wordwrap!="false")?true:false))[1]+_e;_c=_d/_f;}return _c;};_pTextArea._getTextLine=function(){var _a=this._input_element;var _b=this.value;var _c=0;var _d=0;var _e=this._client_width;var _f;if(_b){_f=_b.split("\n");_c=_f.length;}if(_a&&_a._handle&&this.wordwrap!="none"&&this.wordwrap!=false&&this.wordwrap!="false"){var _g=0;var _h=0;var _i;for(_g=0;_g<_c;_g++ ){_i=_f[_g];_h+=nexacro._getLineCountWithWordwrap(_a,_i,this.wordwrap);}_c=_h;}this._max_line=_c;return _c;};_pTextArea._getCaretLineString=function(_a,_b){var _c=_a;var _d=1;var _e=this._input_element;if(!_c){_c=this.getCaretPos();if(_e){_d=_e.getCaretLine();}}if(_b==1){var _f=this.value;if(_f){var _g=_f.split("\n");var _h=_g.length;}if(_e&&_e._handle&&this.wordwrap!="none"&&this.wordwrap!=false&&this.wordwrap!="false"){var _i=0;var _j=0;var _k=0;var _l;var _m="";var _n="";var _o=0;var _p=0;for(_i=0;_i<_h;_i++ ){_l=_g[_i];_j+=nexacro._getLineCountWithWordwrap(_e,_l,this.wordwrap);if(_j>_d){_d=_d-_k;for(j=0;j<_l.length;j++ ){var _q=_d;_n=_l[j];_m+=_n;_j=nexacro._getLineCountWithWordwrap(_e,_m,this.wordwrap);if(_j>_d){_o=j;_m="";for(k=j;k<_l.length;k++ ){_n=_l[k];_m+=_n;_j=nexacro._getLineCountWithWordwrap(_e,_m,this.wordwrap);if(_j>1){_p=k;_m=_l.slice(_o,_p);break;}}_p=k;break;}}break;}_k=_j;}}else{return _g[_d+1];}}else if(_b==2){var _f=this.value;if(_f){var _g=_f.split("\n");var _h=_g.length;}if(_e&&_e._handle&&this.wordwrap!="none"&&this.wordwrap!=false&&this.wordwrap!="false"){var _i=0;var _j=0;var _k=0;var _l;var _m="";var _n="";var _o=0;var _p=0;for(_i=0;_i<_h;_i++ ){_l=_g[_i];_j+=nexacro._getLineCountWithWordwrap(_e,_l,this.wordwrap);if(_j>=_d-1){_d=_d-_k-1;for(j=0;j<_l.length;j++ ){var _q=_d;_n=_l[j];_m+=_n;_j=nexacro._getLineCountWithWordwrap(_e,_m,this.wordwrap);if(_j>=_d){_o=j;_m="";for(k=j;k<_l.length;k++ ){_n=_l[k];_m+=_n;_j=nexacro._getLineCountWithWordwrap(_e,_m,this.wordwrap);if(_j>1){_p=k;_m=_l.slice(_o,_p);break;}}_p=k;break;}}break;}_k=_j;}}else{return _g[_d-1];}}else if(_b==0){var _f=this.value;if(_f){var _g=_f.split("\n");var _h=_g.length;}if(_e&&_e._handle&&this.wordwrap!="none"&&this.wordwrap!=false&&this.wordwrap!="false"){var _i=0;var _j=0;var _k=0;var _l;var _m="";var _n="";var _o=0;var _p=0;for(_i=0;_i<_h;_i++ ){_l=_g[_i];_j+=nexacro._getLineCountWithWordwrap(_e,_l,this.wordwrap);if(_j>=_d){_d=_d-_k;for(j=0;j<_l.length;j++ ){var _q=_d;_n=_l[j];_m+=_n;_j=nexacro._getLineCountWithWordwrap(_e,_m,this.wordwrap);if(_j>_d){_p=j;_m=_l.slice(_o,_p);break;}}break;}_k=_j;}}else{return (_g[0])?_g[0]:"";}}return _m;};_pTextArea._update_scroll=function(){var _a=this.getElement();var _b=this._input_element;if(_a&&_b){var _c=_b.getScrollWidth();var _d=_b.getScrollHeight();_a.setElementScrollMaxSize(_c,_d);this._updateClientSize(_a);this._max_scroll_height=_d;if(this.vscrollbar){var _e=_b.getScrollTop();this.vscrollbar.set_pos(_e);}if(this.hscrollbar){var _e=_b.getScrollLeft();this.hscrollbar.set_pos(_e);}this._onResetScrollBar();this._old_max_height=undefined;}};_pTextArea._reset_hscroll=function(){var _a=this.getElement();var _b=this._input_element;if(_a._hscroll_visible){_a.setElementHScrollPos(0);_b.setScrollLeft(0);};};_pTextArea._setValue=function(_a){if(nexacro._isNull(_a)){this.text="";}else{this.text=nexacro._toString(_a);}this.value=_a;this.on_apply_value();};_pTextArea._setVScrollDefaultAction=function(_a,_b){var _c=this.currentstyle;var _d=_c.linespace?nexacro._toInt(_c.linespace):0;var _e=nexacro._getTextSize2("Wj",_c.font,((this.wordwrap!="none"&&this.wordwrap!=false&&this.wordwrap!="false")?true:false))[1]+_d;if(_b>=0){var _f=3;}else{var _f= -3;}_b=_e*_f;_a.set_pos(_a.pos-_b);};_pTextArea._isWheelScrollable=function(_a){var _b=this._input_element;if(!_b){return false;}var _c=_b.getScrollTop();var _d=this._max_scroll_height;var _e=this._client_height;if((_c+_e>=_d&&_a<0)||(_c==0&&_a>0)){return false;}return true;};_pTextArea._accept_keydown_event=function(_a){return true;};_pTextArea._recreateInputElement=function(){var _a=this._input_element;if(_a){_a._destroyInputHandle();_a._input_handle=_a._createInputHandle();_a._bindEvent(_a);}};delete _pTextArea;_pTextArea=null;nexacro.TextAreaCtrl=function(_a,_b,_c,_d,_e,_f,_g,_h,_i){nexacro.TextArea.call(this,_a,_b,_c,_d,_e,_f,_g,_h,_i);this._is_subcontrol=true;};var _pTextAreaCtrl=nexacro._createPrototype(nexacro.TextArea,nexacro.TextAreaCtrl);nexacro.TextAreaCtrl.prototype=_pTextAreaCtrl;nexacro._setForControlStyleFinder(_pTextAreaCtrl);delete _pTextAreaCtrl;_pTextAreaCtrl=null;};