fix column widths docs
authorAlan <alan@roojs.com>
Thu, 18 Jan 2024 08:44:34 +0000 (16:44 +0800)
committerAlan <alan@roojs.com>
Thu, 18 Jan 2024 08:44:34 +0000 (16:44 +0800)
docs/src/Roo_htmleditor_BlockTd.js.html
roojs-all.js
roojs-bootstrap-debug.js
roojs-bootstrap.js
roojs-debug.js
roojs-ui-debug.js
roojs-ui.js

index c84005e..6fde687 100644 (file)
                 </span><span class="jsdoc-keyword">if </span><span class="jsdoc-syntax">(</span><span class="jsdoc-var">this.colWidths</span><span class="jsdoc-syntax">[0] != </span><span class="jsdoc-keyword">false </span><span class="jsdoc-syntax">&amp;&amp; </span><span class="jsdoc-var">table</span><span class="jsdoc-syntax">[</span><span class="jsdoc-var">r</span><span class="jsdoc-syntax">][</span><span class="jsdoc-var">c</span><span class="jsdoc-syntax">]</span><span class="jsdoc-var">.colspan </span><span class="jsdoc-syntax">&gt; 1) {
                     </span><span class="jsdoc-keyword">var </span><span class="jsdoc-var">el </span><span class="jsdoc-syntax">= </span><span class="jsdoc-var">Roo.htmleditor.Block.factory</span><span class="jsdoc-syntax">(</span><span class="jsdoc-var">table</span><span class="jsdoc-syntax">[</span><span class="jsdoc-var">r</span><span class="jsdoc-syntax">][</span><span class="jsdoc-var">c</span><span class="jsdoc-syntax">]</span><span class="jsdoc-var">.cell</span><span class="jsdoc-syntax">);
                     </span><span class="jsdoc-keyword">var </span><span class="jsdoc-var">width </span><span class="jsdoc-syntax">= 0;
+                    </span><span class="jsdoc-keyword">var </span><span class="jsdoc-var">lv </span><span class="jsdoc-syntax">= </span><span class="jsdoc-keyword">false</span><span class="jsdoc-syntax">;
                     </span><span class="jsdoc-keyword">for</span><span class="jsdoc-syntax">(</span><span class="jsdoc-keyword">var </span><span class="jsdoc-var">i </span><span class="jsdoc-syntax">= 0; </span><span class="jsdoc-var">i </span><span class="jsdoc-syntax">&lt; </span><span class="jsdoc-var">table</span><span class="jsdoc-syntax">[</span><span class="jsdoc-var">r</span><span class="jsdoc-syntax">][</span><span class="jsdoc-var">c</span><span class="jsdoc-syntax">]</span><span class="jsdoc-var">.colspan</span><span class="jsdoc-syntax">; </span><span class="jsdoc-var">i </span><span class="jsdoc-syntax">++) {
+                        </span><span class="jsdoc-keyword">if </span><span class="jsdoc-syntax">(</span><span class="jsdoc-keyword">typeof</span><span class="jsdoc-syntax">(</span><span class="jsdoc-var">this.colWidths</span><span class="jsdoc-syntax">[</span><span class="jsdoc-var">c </span><span class="jsdoc-syntax">+ </span><span class="jsdoc-var">i</span><span class="jsdoc-syntax">]) != </span><span class="jsdoc-string">'undefined'</span><span class="jsdoc-syntax">) {
+                            </span><span class="jsdoc-var">lv </span><span class="jsdoc-syntax">= </span><span class="jsdoc-var">this.colWidths</span><span class="jsdoc-syntax">[</span><span class="jsdoc-var">c </span><span class="jsdoc-syntax">+ </span><span class="jsdoc-var">i</span><span class="jsdoc-syntax">];
+                        } </span><span class="jsdoc-keyword">else </span><span class="jsdoc-syntax">{
+                            </span><span class="jsdoc-var">this.colWidths</span><span class="jsdoc-syntax">[</span><span class="jsdoc-var">c </span><span class="jsdoc-syntax">+ </span><span class="jsdoc-var">i</span><span class="jsdoc-syntax">] = </span><span class="jsdoc-var">lv</span><span class="jsdoc-syntax">;
+                        }
                         </span><span class="jsdoc-var">width </span><span class="jsdoc-syntax">+= </span><span class="jsdoc-var">Math.floor</span><span class="jsdoc-syntax">(</span><span class="jsdoc-var">this.colWidths</span><span class="jsdoc-syntax">[</span><span class="jsdoc-var">c </span><span class="jsdoc-syntax">+ </span><span class="jsdoc-var">i</span><span class="jsdoc-syntax">]);
                     }
                     </span><span class="jsdoc-var">el.width </span><span class="jsdoc-syntax">= </span><span class="jsdoc-var">width  </span><span class="jsdoc-syntax">+</span><span class="jsdoc-string">'%'</span><span class="jsdoc-syntax">;
index 6fdcff4..0720fcf 100644 (file)
@@ -2181,14 +2181,15 @@ c<cd.col+cd.colspan;c++){if(r==cd.row&&c==cd.col){this.node.removeAttribute('row
 ;}}this.redrawAllCells(A);},redrawAllCells:function(A){var B=this.node.closest('tr').closest('table');var C=B.rows[0].parentNode;Array.from(B.rows).forEach(function(r,ri){Array.from(r.cells).forEach(function(ce,ci){ce.parentNode.removeChild(ce);});r.parentNode.removeChild(r);
 });for(var r=0;r<A.length;r++){var re=B.rows[r];var re=B.ownerDocument.createElement('tr');C.appendChild(re);for(var c=0;c<A[r].length;c++){if(A[r][c].cell===false){continue;}re.appendChild(A[r][c].cell);A[r][c].cell=false;}}},updateWidths:function(A){for(var r=0;
 r<A.length;r++){for(var c=0;c<A[r].length;c++){if(A[r][c].cell===false){continue;}if(this.colWidths[0]!=false&&A[r][c].colspan<2){var el=Roo.htmleditor.Block.factory(A[r][c].cell);el.width=Math.floor(this.colWidths[c])+'%';el.updateElement(el.node);}if(this.colWidths[0]!=false&&A[r][c].colspan>1){var el=Roo.htmleditor.Block.factory(A[r][c].cell);
-var B=0;for(var i=0;i<A[r][c].colspan;i++){B+=Math.floor(this.colWidths[c+i]);}el.width=B+'%';el.updateElement(el.node);}A[r][c].cell=false;}}},normalizeWidths:function(A){if(this.colWidths[0]===false){var nw=100.0/this.colWidths.length;this.colWidths.forEach(function(w,i){this.colWidths[i]=nw;
-},this);return;}var t=0,B=[];this.colWidths.forEach(function(w,i){this.colWidths[i]=this.colWidths[i]==''?0:(this.colWidths[i]+'').replace(/[^0-9]+/g,'')*1;var D=this.colWidths[i];if(D>0){t+=D;return;}B.push(i);},this);var nc=this.colWidths.length;if(B.length){var C=(nc-B.length)/(1.0*nc);
-var t=C*t;var ew=(100-t)/(1.0*B.length);this.colWidths.forEach(function(w,i){if(w>0){this.colWidths[i]=w*C;return;}this.colWidths[i]=ew;},this);}},shrinkColumn:function(){var A=this.toTableArray();this.normalizeWidths(A);var B=this.cellData.col;var nw=this.colWidths[B]*0.8;
-if(nw<5){return;}var C=(this.colWidths[B]*0.2)/(this.colWidths.length-1);this.colWidths.forEach(function(w,i){if(i==B){this.colWidths[i]=nw;return;}if(typeof(this.colWidths[i])=='undefined'){this.colWidths[i]=C;}else{this.colWidths[i]+=C;}},this);this.updateWidths(A);
-},growColumn:function(){var A=this.toTableArray();this.normalizeWidths(A);var B=this.cellData.col;var nw=this.colWidths[B]*1.2;if(nw>90){return;}var C=(this.colWidths[B]*0.2)/(this.colWidths.length-1);this.colWidths.forEach(function(w,i){if(i==B){this.colWidths[i]=nw;
-return;}if(typeof(this.colWidths[i])=='undefined'){this.colWidths[i]=C;}else{this.colWidths[i]-=C;}},this);this.updateWidths(A);},deleteRow:function(){var A=this.toTableArray();for(var i=0;i<A[this.cellData.row].length;i++){var c=A[this.cellData.row][i];if(c.row!=this.cellData.row){c.rowspan--;
-c.cell.setAttribute('rowspan',c.rowspan);continue;}if(c.rowspan>1){c.rowspan--;c.cell.setAttribute('rowspan',c.rowspan);}}A.splice(this.cellData.row,1);this.redrawAllCells(A);},deleteColumn:function(){var A=this.toTableArray();for(var i=0;i<A.length;i++){var c=A[i][this.cellData.col];
-if(c.col!=this.cellData.col){A[i][this.cellData.col].colspan--;}else if(c.colspan>1){c.colspan--;c.cell.setAttribute('colspan',c.colspan);}A[i].splice(this.cellData.col,1);}this.redrawAllCells(A);}})
+var B=0;var lv=false;for(var i=0;i<A[r][c].colspan;i++){if(typeof(this.colWidths[c+i])!='undefined'){lv=this.colWidths[c+i];}else{this.colWidths[c+i]=lv;}B+=Math.floor(this.colWidths[c+i]);}el.width=B+'%';el.updateElement(el.node);}A[r][c].cell=false;}}},normalizeWidths:function(A){if(this.colWidths[0]===false){var nw=100.0/this.colWidths.length;
+this.colWidths.forEach(function(w,i){this.colWidths[i]=nw;},this);return;}var t=0,B=[];this.colWidths.forEach(function(w,i){this.colWidths[i]=this.colWidths[i]==''?0:(this.colWidths[i]+'').replace(/[^0-9]+/g,'')*1;var D=this.colWidths[i];if(D>0){t+=D;return;
+}B.push(i);},this);var nc=this.colWidths.length;if(B.length){var C=(nc-B.length)/(1.0*nc);var t=C*t;var ew=(100-t)/(1.0*B.length);this.colWidths.forEach(function(w,i){if(w>0){this.colWidths[i]=w*C;return;}this.colWidths[i]=ew;},this);}},shrinkColumn:function(){var A=this.toTableArray();
+this.normalizeWidths(A);var B=this.cellData.col;var nw=this.colWidths[B]*0.8;if(nw<5){return;}var C=(this.colWidths[B]*0.2)/(this.colWidths.length-1);this.colWidths.forEach(function(w,i){if(i==B){this.colWidths[i]=nw;return;}if(typeof(this.colWidths[i])=='undefined'){this.colWidths[i]=C;
+}else{this.colWidths[i]+=C;}},this);this.updateWidths(A);},growColumn:function(){var A=this.toTableArray();this.normalizeWidths(A);var B=this.cellData.col;var nw=this.colWidths[B]*1.2;if(nw>90){return;}var C=(this.colWidths[B]*0.2)/(this.colWidths.length-1);
+this.colWidths.forEach(function(w,i){if(i==B){this.colWidths[i]=nw;return;}if(typeof(this.colWidths[i])=='undefined'){this.colWidths[i]=C;}else{this.colWidths[i]-=C;}},this);this.updateWidths(A);},deleteRow:function(){var A=this.toTableArray();for(var i=0;
+i<A[this.cellData.row].length;i++){var c=A[this.cellData.row][i];if(c.row!=this.cellData.row){c.rowspan--;c.cell.setAttribute('rowspan',c.rowspan);continue;}if(c.rowspan>1){c.rowspan--;c.cell.setAttribute('rowspan',c.rowspan);}}A.splice(this.cellData.row,1);
+this.redrawAllCells(A);},deleteColumn:function(){var A=this.toTableArray();for(var i=0;i<A.length;i++){var c=A[i][this.cellData.col];if(c.col!=this.cellData.col){A[i][this.cellData.col].colspan--;}else if(c.colspan>1){c.colspan--;c.cell.setAttribute('colspan',c.colspan);
+}A[i].splice(this.cellData.col,1);}this.redrawAllCells(A);}})
 // Roo/HtmlEditorCore.js
 Roo.HtmlEditorCore=function(A){Roo.HtmlEditorCore.superclass.constructor.call(this,A);this.addEvents({initialize:true,activate:true,beforesync:true,beforepush:true,sync:true,push:true,editorevent:true});this.applyBlacklists();};Roo.extend(Roo.HtmlEditorCore,Roo.Component,{owner:false,resize:false,height:300,width:500,autoClean:true,enableBlocks:true,stylesheets:false,language:'en',allowComments:false,frameId:false,validationEvent:false,deferHeight:true,initialized:false,activated:false,sourceEditMode:false,onFocus:Roo.emptyFn,iframePad:3,hideMode:'offsets',clearUp:true,black:false,white:false,bodyCls:'',undoManager:false,getDocMarkup:function(){var st='';
 if(this.stylesheets===false){Roo.get(document.head).select('style').each(function(B){st+=B.dom.outerHTML||new XMLSerializer().serializeToString(B.dom);});Roo.get(document.head).select('link').each(function(B){st+=B.dom.outerHTML||new XMLSerializer().serializeToString(B.dom);
index 0a37793..f1ce730 100644 (file)
@@ -31231,7 +31231,13 @@ Roo.extend(Roo.htmleditor.BlockTd, Roo.htmleditor.Block, {
                 if (this.colWidths[0] != false && table[r][c].colspan > 1) {
                     var el = Roo.htmleditor.Block.factory(table[r][c].cell);
                     var width = 0;
+                    var lv = false;
                     for(var i = 0; i < table[r][c].colspan; i ++) {
+                        if (typeof(this.colWidths[c + i]) != 'undefined') {
+                            lv = this.colWidths[c + i];
+                        } else {
+                            this.colWidths[c + i] = lv;
+                        }
                         width += Math.floor(this.colWidths[c + i]);
                     }
                     el.width = width  +'%';
index 7b40010..127a61b 100644 (file)
@@ -1352,14 +1352,15 @@ c<cd.col+cd.colspan;c++){if(r==cd.row&&c==cd.col){this.node.removeAttribute('row
 ;}}this.redrawAllCells(A);},redrawAllCells:function(A){var B=this.node.closest('tr').closest('table');var C=B.rows[0].parentNode;Array.from(B.rows).forEach(function(r,ri){Array.from(r.cells).forEach(function(ce,ci){ce.parentNode.removeChild(ce);});r.parentNode.removeChild(r);
 });for(var r=0;r<A.length;r++){var re=B.rows[r];var re=B.ownerDocument.createElement('tr');C.appendChild(re);for(var c=0;c<A[r].length;c++){if(A[r][c].cell===false){continue;}re.appendChild(A[r][c].cell);A[r][c].cell=false;}}},updateWidths:function(A){for(var r=0;
 r<A.length;r++){for(var c=0;c<A[r].length;c++){if(A[r][c].cell===false){continue;}if(this.colWidths[0]!=false&&A[r][c].colspan<2){var el=Roo.htmleditor.Block.factory(A[r][c].cell);el.width=Math.floor(this.colWidths[c])+'%';el.updateElement(el.node);}if(this.colWidths[0]!=false&&A[r][c].colspan>1){var el=Roo.htmleditor.Block.factory(A[r][c].cell);
-var B=0;for(var i=0;i<A[r][c].colspan;i++){B+=Math.floor(this.colWidths[c+i]);}el.width=B+'%';el.updateElement(el.node);}A[r][c].cell=false;}}},normalizeWidths:function(A){if(this.colWidths[0]===false){var nw=100.0/this.colWidths.length;this.colWidths.forEach(function(w,i){this.colWidths[i]=nw;
-},this);return;}var t=0,B=[];this.colWidths.forEach(function(w,i){this.colWidths[i]=this.colWidths[i]==''?0:(this.colWidths[i]+'').replace(/[^0-9]+/g,'')*1;var D=this.colWidths[i];if(D>0){t+=D;return;}B.push(i);},this);var nc=this.colWidths.length;if(B.length){var C=(nc-B.length)/(1.0*nc);
-var t=C*t;var ew=(100-t)/(1.0*B.length);this.colWidths.forEach(function(w,i){if(w>0){this.colWidths[i]=w*C;return;}this.colWidths[i]=ew;},this);}},shrinkColumn:function(){var A=this.toTableArray();this.normalizeWidths(A);var B=this.cellData.col;var nw=this.colWidths[B]*0.8;
-if(nw<5){return;}var C=(this.colWidths[B]*0.2)/(this.colWidths.length-1);this.colWidths.forEach(function(w,i){if(i==B){this.colWidths[i]=nw;return;}if(typeof(this.colWidths[i])=='undefined'){this.colWidths[i]=C;}else{this.colWidths[i]+=C;}},this);this.updateWidths(A);
-},growColumn:function(){var A=this.toTableArray();this.normalizeWidths(A);var B=this.cellData.col;var nw=this.colWidths[B]*1.2;if(nw>90){return;}var C=(this.colWidths[B]*0.2)/(this.colWidths.length-1);this.colWidths.forEach(function(w,i){if(i==B){this.colWidths[i]=nw;
-return;}if(typeof(this.colWidths[i])=='undefined'){this.colWidths[i]=C;}else{this.colWidths[i]-=C;}},this);this.updateWidths(A);},deleteRow:function(){var A=this.toTableArray();for(var i=0;i<A[this.cellData.row].length;i++){var c=A[this.cellData.row][i];if(c.row!=this.cellData.row){c.rowspan--;
-c.cell.setAttribute('rowspan',c.rowspan);continue;}if(c.rowspan>1){c.rowspan--;c.cell.setAttribute('rowspan',c.rowspan);}}A.splice(this.cellData.row,1);this.redrawAllCells(A);},deleteColumn:function(){var A=this.toTableArray();for(var i=0;i<A.length;i++){var c=A[i][this.cellData.col];
-if(c.col!=this.cellData.col){A[i][this.cellData.col].colspan--;}else if(c.colspan>1){c.colspan--;c.cell.setAttribute('colspan',c.colspan);}A[i].splice(this.cellData.col,1);}this.redrawAllCells(A);}})
+var B=0;var lv=false;for(var i=0;i<A[r][c].colspan;i++){if(typeof(this.colWidths[c+i])!='undefined'){lv=this.colWidths[c+i];}else{this.colWidths[c+i]=lv;}B+=Math.floor(this.colWidths[c+i]);}el.width=B+'%';el.updateElement(el.node);}A[r][c].cell=false;}}},normalizeWidths:function(A){if(this.colWidths[0]===false){var nw=100.0/this.colWidths.length;
+this.colWidths.forEach(function(w,i){this.colWidths[i]=nw;},this);return;}var t=0,B=[];this.colWidths.forEach(function(w,i){this.colWidths[i]=this.colWidths[i]==''?0:(this.colWidths[i]+'').replace(/[^0-9]+/g,'')*1;var D=this.colWidths[i];if(D>0){t+=D;return;
+}B.push(i);},this);var nc=this.colWidths.length;if(B.length){var C=(nc-B.length)/(1.0*nc);var t=C*t;var ew=(100-t)/(1.0*B.length);this.colWidths.forEach(function(w,i){if(w>0){this.colWidths[i]=w*C;return;}this.colWidths[i]=ew;},this);}},shrinkColumn:function(){var A=this.toTableArray();
+this.normalizeWidths(A);var B=this.cellData.col;var nw=this.colWidths[B]*0.8;if(nw<5){return;}var C=(this.colWidths[B]*0.2)/(this.colWidths.length-1);this.colWidths.forEach(function(w,i){if(i==B){this.colWidths[i]=nw;return;}if(typeof(this.colWidths[i])=='undefined'){this.colWidths[i]=C;
+}else{this.colWidths[i]+=C;}},this);this.updateWidths(A);},growColumn:function(){var A=this.toTableArray();this.normalizeWidths(A);var B=this.cellData.col;var nw=this.colWidths[B]*1.2;if(nw>90){return;}var C=(this.colWidths[B]*0.2)/(this.colWidths.length-1);
+this.colWidths.forEach(function(w,i){if(i==B){this.colWidths[i]=nw;return;}if(typeof(this.colWidths[i])=='undefined'){this.colWidths[i]=C;}else{this.colWidths[i]-=C;}},this);this.updateWidths(A);},deleteRow:function(){var A=this.toTableArray();for(var i=0;
+i<A[this.cellData.row].length;i++){var c=A[this.cellData.row][i];if(c.row!=this.cellData.row){c.rowspan--;c.cell.setAttribute('rowspan',c.rowspan);continue;}if(c.rowspan>1){c.rowspan--;c.cell.setAttribute('rowspan',c.rowspan);}}A.splice(this.cellData.row,1);
+this.redrawAllCells(A);},deleteColumn:function(){var A=this.toTableArray();for(var i=0;i<A.length;i++){var c=A[i][this.cellData.col];if(c.col!=this.cellData.col){A[i][this.cellData.col].colspan--;}else if(c.colspan>1){c.colspan--;c.cell.setAttribute('colspan',c.colspan);
+}A[i].splice(this.cellData.col,1);}this.redrawAllCells(A);}})
 // Roo/HtmlEditorCore.js
 Roo.HtmlEditorCore=function(A){Roo.HtmlEditorCore.superclass.constructor.call(this,A);this.addEvents({initialize:true,activate:true,beforesync:true,beforepush:true,sync:true,push:true,editorevent:true});this.applyBlacklists();};Roo.extend(Roo.HtmlEditorCore,Roo.Component,{owner:false,resize:false,height:300,width:500,autoClean:true,enableBlocks:true,stylesheets:false,language:'en',allowComments:false,frameId:false,validationEvent:false,deferHeight:true,initialized:false,activated:false,sourceEditMode:false,onFocus:Roo.emptyFn,iframePad:3,hideMode:'offsets',clearUp:true,black:false,white:false,bodyCls:'',undoManager:false,getDocMarkup:function(){var st='';
 if(this.stylesheets===false){Roo.get(document.head).select('style').each(function(B){st+=B.dom.outerHTML||new XMLSerializer().serializeToString(B.dom);});Roo.get(document.head).select('link').each(function(B){st+=B.dom.outerHTML||new XMLSerializer().serializeToString(B.dom);
index 77876a5..d2f4c69 100644 (file)
@@ -51836,7 +51836,13 @@ Roo.extend(Roo.htmleditor.BlockTd, Roo.htmleditor.Block, {
                 if (this.colWidths[0] != false && table[r][c].colspan > 1) {
                     var el = Roo.htmleditor.Block.factory(table[r][c].cell);
                     var width = 0;
+                    var lv = false;
                     for(var i = 0; i < table[r][c].colspan; i ++) {
+                        if (typeof(this.colWidths[c + i]) != 'undefined') {
+                            lv = this.colWidths[c + i];
+                        } else {
+                            this.colWidths[c + i] = lv;
+                        }
                         width += Math.floor(this.colWidths[c + i]);
                     }
                     el.width = width  +'%';
index d4047dd..25a2ef0 100644 (file)
@@ -27334,7 +27334,13 @@ Roo.extend(Roo.htmleditor.BlockTd, Roo.htmleditor.Block, {
                 if (this.colWidths[0] != false && table[r][c].colspan > 1) {
                     var el = Roo.htmleditor.Block.factory(table[r][c].cell);
                     var width = 0;
+                    var lv = false;
                     for(var i = 0; i < table[r][c].colspan; i ++) {
+                        if (typeof(this.colWidths[c + i]) != 'undefined') {
+                            lv = this.colWidths[c + i];
+                        } else {
+                            this.colWidths[c + i] = lv;
+                        }
                         width += Math.floor(this.colWidths[c + i]);
                     }
                     el.width = width  +'%';
index 4740899..5126a44 100644 (file)
@@ -1234,14 +1234,15 @@ c<cd.col+cd.colspan;c++){if(r==cd.row&&c==cd.col){this.node.removeAttribute('row
 ;}}this.redrawAllCells(A);},redrawAllCells:function(A){var B=this.node.closest('tr').closest('table');var C=B.rows[0].parentNode;Array.from(B.rows).forEach(function(r,ri){Array.from(r.cells).forEach(function(ce,ci){ce.parentNode.removeChild(ce);});r.parentNode.removeChild(r);
 });for(var r=0;r<A.length;r++){var re=B.rows[r];var re=B.ownerDocument.createElement('tr');C.appendChild(re);for(var c=0;c<A[r].length;c++){if(A[r][c].cell===false){continue;}re.appendChild(A[r][c].cell);A[r][c].cell=false;}}},updateWidths:function(A){for(var r=0;
 r<A.length;r++){for(var c=0;c<A[r].length;c++){if(A[r][c].cell===false){continue;}if(this.colWidths[0]!=false&&A[r][c].colspan<2){var el=Roo.htmleditor.Block.factory(A[r][c].cell);el.width=Math.floor(this.colWidths[c])+'%';el.updateElement(el.node);}if(this.colWidths[0]!=false&&A[r][c].colspan>1){var el=Roo.htmleditor.Block.factory(A[r][c].cell);
-var B=0;for(var i=0;i<A[r][c].colspan;i++){B+=Math.floor(this.colWidths[c+i]);}el.width=B+'%';el.updateElement(el.node);}A[r][c].cell=false;}}},normalizeWidths:function(A){if(this.colWidths[0]===false){var nw=100.0/this.colWidths.length;this.colWidths.forEach(function(w,i){this.colWidths[i]=nw;
-},this);return;}var t=0,B=[];this.colWidths.forEach(function(w,i){this.colWidths[i]=this.colWidths[i]==''?0:(this.colWidths[i]+'').replace(/[^0-9]+/g,'')*1;var D=this.colWidths[i];if(D>0){t+=D;return;}B.push(i);},this);var nc=this.colWidths.length;if(B.length){var C=(nc-B.length)/(1.0*nc);
-var t=C*t;var ew=(100-t)/(1.0*B.length);this.colWidths.forEach(function(w,i){if(w>0){this.colWidths[i]=w*C;return;}this.colWidths[i]=ew;},this);}},shrinkColumn:function(){var A=this.toTableArray();this.normalizeWidths(A);var B=this.cellData.col;var nw=this.colWidths[B]*0.8;
-if(nw<5){return;}var C=(this.colWidths[B]*0.2)/(this.colWidths.length-1);this.colWidths.forEach(function(w,i){if(i==B){this.colWidths[i]=nw;return;}if(typeof(this.colWidths[i])=='undefined'){this.colWidths[i]=C;}else{this.colWidths[i]+=C;}},this);this.updateWidths(A);
-},growColumn:function(){var A=this.toTableArray();this.normalizeWidths(A);var B=this.cellData.col;var nw=this.colWidths[B]*1.2;if(nw>90){return;}var C=(this.colWidths[B]*0.2)/(this.colWidths.length-1);this.colWidths.forEach(function(w,i){if(i==B){this.colWidths[i]=nw;
-return;}if(typeof(this.colWidths[i])=='undefined'){this.colWidths[i]=C;}else{this.colWidths[i]-=C;}},this);this.updateWidths(A);},deleteRow:function(){var A=this.toTableArray();for(var i=0;i<A[this.cellData.row].length;i++){var c=A[this.cellData.row][i];if(c.row!=this.cellData.row){c.rowspan--;
-c.cell.setAttribute('rowspan',c.rowspan);continue;}if(c.rowspan>1){c.rowspan--;c.cell.setAttribute('rowspan',c.rowspan);}}A.splice(this.cellData.row,1);this.redrawAllCells(A);},deleteColumn:function(){var A=this.toTableArray();for(var i=0;i<A.length;i++){var c=A[i][this.cellData.col];
-if(c.col!=this.cellData.col){A[i][this.cellData.col].colspan--;}else if(c.colspan>1){c.colspan--;c.cell.setAttribute('colspan',c.colspan);}A[i].splice(this.cellData.col,1);}this.redrawAllCells(A);}})
+var B=0;var lv=false;for(var i=0;i<A[r][c].colspan;i++){if(typeof(this.colWidths[c+i])!='undefined'){lv=this.colWidths[c+i];}else{this.colWidths[c+i]=lv;}B+=Math.floor(this.colWidths[c+i]);}el.width=B+'%';el.updateElement(el.node);}A[r][c].cell=false;}}},normalizeWidths:function(A){if(this.colWidths[0]===false){var nw=100.0/this.colWidths.length;
+this.colWidths.forEach(function(w,i){this.colWidths[i]=nw;},this);return;}var t=0,B=[];this.colWidths.forEach(function(w,i){this.colWidths[i]=this.colWidths[i]==''?0:(this.colWidths[i]+'').replace(/[^0-9]+/g,'')*1;var D=this.colWidths[i];if(D>0){t+=D;return;
+}B.push(i);},this);var nc=this.colWidths.length;if(B.length){var C=(nc-B.length)/(1.0*nc);var t=C*t;var ew=(100-t)/(1.0*B.length);this.colWidths.forEach(function(w,i){if(w>0){this.colWidths[i]=w*C;return;}this.colWidths[i]=ew;},this);}},shrinkColumn:function(){var A=this.toTableArray();
+this.normalizeWidths(A);var B=this.cellData.col;var nw=this.colWidths[B]*0.8;if(nw<5){return;}var C=(this.colWidths[B]*0.2)/(this.colWidths.length-1);this.colWidths.forEach(function(w,i){if(i==B){this.colWidths[i]=nw;return;}if(typeof(this.colWidths[i])=='undefined'){this.colWidths[i]=C;
+}else{this.colWidths[i]+=C;}},this);this.updateWidths(A);},growColumn:function(){var A=this.toTableArray();this.normalizeWidths(A);var B=this.cellData.col;var nw=this.colWidths[B]*1.2;if(nw>90){return;}var C=(this.colWidths[B]*0.2)/(this.colWidths.length-1);
+this.colWidths.forEach(function(w,i){if(i==B){this.colWidths[i]=nw;return;}if(typeof(this.colWidths[i])=='undefined'){this.colWidths[i]=C;}else{this.colWidths[i]-=C;}},this);this.updateWidths(A);},deleteRow:function(){var A=this.toTableArray();for(var i=0;
+i<A[this.cellData.row].length;i++){var c=A[this.cellData.row][i];if(c.row!=this.cellData.row){c.rowspan--;c.cell.setAttribute('rowspan',c.rowspan);continue;}if(c.rowspan>1){c.rowspan--;c.cell.setAttribute('rowspan',c.rowspan);}}A.splice(this.cellData.row,1);
+this.redrawAllCells(A);},deleteColumn:function(){var A=this.toTableArray();for(var i=0;i<A.length;i++){var c=A[i][this.cellData.col];if(c.col!=this.cellData.col){A[i][this.cellData.col].colspan--;}else if(c.colspan>1){c.colspan--;c.cell.setAttribute('colspan',c.colspan);
+}A[i].splice(this.cellData.col,1);}this.redrawAllCells(A);}})
 // Roo/HtmlEditorCore.js
 Roo.HtmlEditorCore=function(A){Roo.HtmlEditorCore.superclass.constructor.call(this,A);this.addEvents({initialize:true,activate:true,beforesync:true,beforepush:true,sync:true,push:true,editorevent:true});this.applyBlacklists();};Roo.extend(Roo.HtmlEditorCore,Roo.Component,{owner:false,resize:false,height:300,width:500,autoClean:true,enableBlocks:true,stylesheets:false,language:'en',allowComments:false,frameId:false,validationEvent:false,deferHeight:true,initialized:false,activated:false,sourceEditMode:false,onFocus:Roo.emptyFn,iframePad:3,hideMode:'offsets',clearUp:true,black:false,white:false,bodyCls:'',undoManager:false,getDocMarkup:function(){var st='';
 if(this.stylesheets===false){Roo.get(document.head).select('style').each(function(B){st+=B.dom.outerHTML||new XMLSerializer().serializeToString(B.dom);});Roo.get(document.head).select('link').each(function(B){st+=B.dom.outerHTML||new XMLSerializer().serializeToString(B.dom);