X-Git-Url: http://git.roojs.org/?a=blobdiff_plain;f=roojs-debug.js;h=a422228ee7184383704d5547a20268590b9ec080;hb=4f45c682d674232d0336fb3cfc4de5c27550ba4b;hp=52f214f20efbaf3c75731aa21f1053face96f0fa;hpb=456d56f8dd548af35fe42dd47d66423d1b98805b;p=roojs1 diff --git a/roojs-debug.js b/roojs-debug.js index 52f214f20e..a422228ee7 100644 --- a/roojs-debug.js +++ b/roojs-debug.js @@ -46211,16 +46211,29 @@ Roo.extend(Roo.htmleditor.FilterWord, Roo.htmleditor.Filter, replaceDocBullets : function(doc) { // this is a bit odd - but it appears some indents use ql-indent-1 + //Roo.log(doc.innerHTML); - var listpara = doc.getElementsByClassName('ql-indent-1'); + var listpara = doc.getElementsByClassName('MsoListParagraphCxSpFirst'); + for( var i = 0; i < listpara.length; i ++) { + listpara.item(i).className = "MsoListParagraph"; + } + // this is a bit hacky - we had one word document where h2 had a miso-list attribute. + var htwo = doc.getElementsByTagName('h2'); + for( var i = 0; i < htwo.length; i ++) { + if (htwo.item(i).getAttribute('style').match(/mso-list:/)) { + htwo.item(i).className = "MsoListParagraph"; + } + } + + listpara = doc.getElementsByClassName('ql-indent-1'); while(listpara.length) { this.replaceDocBullet(listpara.item(0)); } - - var listpara = doc.getElementsByClassName('MsoListParagraph'); + listpara = doc.getElementsByClassName('MsoListParagraph'); while(listpara.length) { this.replaceDocBullet(listpara.item(0)); } + }, replaceDocBullet : function(p) @@ -46290,6 +46303,10 @@ Roo.extend(Roo.htmleditor.FilterWord, Roo.htmleditor.Filter, if (nlvl > lvl) { //new indent var nul = doc.createElement('ul'); // what about number lists... + if (!last_li) { + last_li = doc.createElement('li'); + stack[lvl].appendChild(last_li); + } last_li.appendChild(nul); stack[nlvl] = nul; @@ -49259,7 +49276,6 @@ Roo.extend(Roo.htmleditor.BlockTd, Roo.htmleditor.Block, { */ toObject : function() { - var ret = { tag : 'td', contenteditable : 'true', // this stops cell selection from picking the table. @@ -49401,6 +49417,7 @@ Roo.extend(Roo.htmleditor.BlockTd, Roo.htmleditor.Block, { mergeRight: function() { + console.log("htmleditor.BlockTd mergeRight"); // get the contents of the next cell along.. var tr = this.node.closest('tr'); @@ -49518,6 +49535,9 @@ Roo.extend(Roo.htmleditor.BlockTd, Roo.htmleditor.Block, { }, updateWidths : function(table) { + console.log("htmleditor.BlockTd updateWidths"); + console.log("TABLE"); + console.log(table); for(var r = 0 ; r < table.length; r++) { for(var c = 0 ; c < table[r].length; c++) { @@ -49526,6 +49546,8 @@ Roo.extend(Roo.htmleditor.BlockTd, Roo.htmleditor.Block, { } if (this.colWidths[0] != false && table[r][c].colspan < 2) { + console.log("CELL"); + console.log(table[r][c].cell); var el = Roo.htmleditor.Block.factory(table[r][c].cell); el.width = Math.floor(this.colWidths[c]) +'%'; el.updateElement(el.node);