--- a/includes/clientside/tinymce/plugins/xhtmlxtras/js/del.js Sun Dec 21 15:35:46 2008 -0500
+++ b/includes/clientside/tinymce/plugins/xhtmlxtras/js/del.js Sun Dec 21 16:28:00 2008 -0500
@@ -27,7 +27,7 @@
if (elm == null) {
var s = SXE.inst.selection.getContent();
if(s.length > 0) {
- tinyMCEPopup.execCommand('mceInsertContent', false, '<del id="#sxe_temp_del#">' + s + '</del>');
+ insertInlineElement('del');
var elementArray = tinymce.grep(SXE.inst.dom.select('del'), function(n) {return n.id == '#sxe_temp_del#';});
for (var i=0; i<elementArray.length; i++) {
var elm = elementArray[i];
@@ -42,6 +42,16 @@
tinyMCEPopup.close();
}
+function insertInlineElement(en) {
+ var ed = tinyMCEPopup.editor, dom = ed.dom;
+
+ ed.getDoc().execCommand('FontName', false, 'mceinline');
+ tinymce.each(dom.select(tinymce.isWebKit ? 'span' : 'font'), function(n) {
+ if (n.style.fontFamily == 'mceinline' || n.face == 'mceinline')
+ dom.replace(dom.create(en), n, 1);
+ });
+}
+
function removeDel() {
SXE.removeElement('del');
tinyMCEPopup.close();