InsertTable._pluginInfo={name:"InsertTable",origin:"Xinha Core",version:"$LastChangedRevision: 688 $".replace(/^[^:]*:\s*(.*)\s*\$$/,"$1"),developer:"The Xinha Core Developer Team",developer_url:"$HeadURL: http://svn.xinha.python-hosting.com/trunk/modules/InsertTable/insert_table.js $".replace(/^[^:]*:\s*(.*)\s*\$$/,"$1"),sponsor:"",sponsor_url:"",license:"htmlArea"};function InsertTable(A){}Xinha.prototype._insertTable=function(){var C=this.getSelection();var B=this.createRange(C);var A=this;Dialog(A.config.URIs.insert_table,function(K){if(!K){return false}var J=A._doc;var I=J.createElement("table");for(var H in K){var G=K[H];if(!G){continue}switch(H){case"f_width":I.style.width=G+K.f_unit;break;case"f_align":I.align=G;break;case"f_border":I.border=parseInt(G,10);break;case"f_spacing":I.cellSpacing=parseInt(G,10);break;case"f_padding":I.cellPadding=parseInt(G,10);break}}var N=0;if(K.f_fixed){N=Math.floor(100/parseInt(K.f_cols,10))}var M=J.createElement("tbody");I.appendChild(M);for(var F=0;F<K.f_rows;++F){var L=J.createElement("tr");M.appendChild(L);for(var E=0;E<K.f_cols;++E){var D=J.createElement("td");if(N){D.style.width=N+"%"}L.appendChild(D);D.appendChild(J.createTextNode("\xa0"))}}if(Xinha.is_ie){B.pasteHTML(I.outerHTML)}else{A.insertNodeAtSelection(I)}return true},null)};