forked from extern/egroupware
Add TineMCE, the future htmlArea Replacement. A clean WYSIWYG editor
see tinymce.moxiecode.com/ for more info
This commit is contained in:
parent
17710c20ab
commit
8b6404cbc2
BIN
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/contextmenu/images/spacer.gif
vendored
Normal file
BIN
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/contextmenu/images/spacer.gif
vendored
Normal file
Binary file not shown.
After Width: | Height: | Size: 43 B |
BIN
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/directionality/images/ltr.gif
vendored
Normal file
BIN
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/directionality/images/ltr.gif
vendored
Normal file
Binary file not shown.
After Width: | Height: | Size: 314 B |
BIN
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/directionality/images/rtl.gif
vendored
Normal file
BIN
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/directionality/images/rtl.gif
vendored
Normal file
Binary file not shown.
After Width: | Height: | Size: 314 B |
4
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/directionality/langs/en.js
vendored
Normal file
4
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/directionality/langs/en.js
vendored
Normal file
@ -0,0 +1,4 @@
|
||||
// UK lang variables
|
||||
|
||||
tinyMCELang['lang_directionality_ltr_desc'] = 'Direction left to right'
|
||||
tinyMCELang['lang_directionality_rtl_desc'] = 'Direction right to left';
|
4
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/directionality/langs/sv.js
vendored
Normal file
4
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/directionality/langs/sv.js
vendored
Normal file
@ -0,0 +1,4 @@
|
||||
// SV lang variables
|
||||
|
||||
tinyMCELang['lang_directionality_ltr_desc'] = 'Riktning från vänster till höger'
|
||||
tinyMCELang['lang_directionality_rtl_desc'] = 'Riktning från höger till vänster';
|
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/emotions/editor_plugin.js
vendored
Normal file
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/emotions/editor_plugin.js
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
/* Import plugin specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('emotions','en,sv,zh_cn,cs,fa,fr_ca,fr,de,pl');function TinyMCE_emotions_getControlHTML(control_name){switch(control_name){case "emotions":return '<img id="{$editor_id}_emotions" src="{$pluginurl}/images/emotions.gif" title="{$lang_emotions_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceEmotion\');">';}return "";}function TinyMCE_emotions_execCommand(editor_id,element,command,user_interface,value){switch(command){case "mceEmotion":var template=new Array();template['file']='../../plugins/emotions/emotions.htm';template['width']=150;template['height']=180;tinyMCE.openWindow(template,{editor_id:editor_id});return true;}return false;}
|
36
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/emotions/editor_plugin_src.js
vendored
Normal file
36
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/emotions/editor_plugin_src.js
vendored
Normal file
@ -0,0 +1,36 @@
|
||||
/* Import plugin specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('emotions', 'en,sv,zh_cn,cs,fa,fr_ca,fr,de,pl');
|
||||
|
||||
/**
|
||||
* Returns the HTML contents of the emotions control.
|
||||
*/
|
||||
function TinyMCE_emotions_getControlHTML(control_name) {
|
||||
switch (control_name) {
|
||||
case "emotions":
|
||||
return '<img id="{$editor_id}_emotions" src="{$pluginurl}/images/emotions.gif" title="{$lang_emotions_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceEmotion\');">';
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
/**
|
||||
* Executes the mceEmotion command.
|
||||
*/
|
||||
function TinyMCE_emotions_execCommand(editor_id, element, command, user_interface, value) {
|
||||
// Handle commands
|
||||
switch (command) {
|
||||
case "mceEmotion":
|
||||
var template = new Array();
|
||||
|
||||
template['file'] = '../../plugins/emotions/emotions.htm'; // Relative to theme
|
||||
template['width'] = 150;
|
||||
template['height'] = 180;
|
||||
|
||||
tinyMCE.openWindow(template, {editor_id : editor_id});
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
// Pass to next handler in chain
|
||||
return false;
|
||||
}
|
45
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/emotions/emotions.htm
vendored
Normal file
45
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/emotions/emotions.htm
vendored
Normal file
@ -0,0 +1,45 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_insert_emotions_title}</title>
|
||||
<script language="javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script language="javascript">
|
||||
function insertEmotion(file_name) {
|
||||
if (window.opener) {
|
||||
tinyMCE.insertImage(tinyMCE.baseURL + "/plugins/emotions/images/" + file_name);
|
||||
window.close();
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body onload="window.focus();">
|
||||
<div align="center">
|
||||
<div class="title">{$lang_insert_emotions_title}:<br /><br /></div>
|
||||
<table border="0" cellspacing="0" cellpadding="4">
|
||||
<tr>
|
||||
<td><a href="javascript:void(0);" onmousedown="insertEmotion('smiley-cool.gif');"><img src="images/smiley-cool.gif" width="18" height="18" border="0" /></a></td>
|
||||
<td><a href="javascript:void(0);" onmousedown="insertEmotion('smiley-cry.gif');"><img src="images/smiley-cry.gif" width="18" height="18" border="0" /></a></td>
|
||||
<td><a href="javascript:void(0);" onmousedown="insertEmotion('smiley-embarassed.gif');"><img src="images/smiley-embarassed.gif" width="18" height="18" border="0" /></a></td>
|
||||
<td><a href="javascript:void(0);" onmousedown="insertEmotion('smiley-foot-in-mouth.gif');"><img src="images/smiley-foot-in-mouth.gif" width="18" height="18" border="0" /></a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a href="javascript:void(0);" onmousedown="insertEmotion('smiley-frown.gif');"><img src="images/smiley-frown.gif" width="18" height="18" border="0" /></a></td>
|
||||
<td><a href="javascript:void(0);" onmousedown="insertEmotion('smiley-innocent.gif');"><img src="images/smiley-innocent.gif" width="18" height="18" border="0" /></a></td>
|
||||
<td><a href="javascript:void(0);" onmousedown="insertEmotion('smiley-kiss.gif');"><img src="images/smiley-kiss.gif" width="18" height="18" border="0" /></a></td>
|
||||
<td><a href="javascript:void(0);" onmousedown="insertEmotion('smiley-laughing.gif');"><img src="images/smiley-laughing.gif" width="18" height="18" border="0" /></a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a href="javascript:void(0);" onmousedown="insertEmotion('smiley-money-mouth.gif');"><img src="images/smiley-money-mouth.gif" width="18" height="18" border="0" /></a></td>
|
||||
<td><a href="javascript:void(0);" onmousedown="insertEmotion('smiley-sealed.gif');"><img src="images/smiley-sealed.gif" width="18" height="18" border="0" /></a></td>
|
||||
<td><a href="javascript:void(0);" onmousedown="insertEmotion('smiley-smile.gif');"><img src="images/smiley-smile.gif" width="18" height="18" border="0" /></a></td>
|
||||
<td><a href="javascript:void(0);" onmousedown="insertEmotion('smiley-surprised.gif');"><img src="images/smiley-surprised.gif" width="18" height="18" border="0" /></a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a href="javascript:void(0);" onmousedown="insertEmotion('smiley-tongue-out.gif');"><img src="images/smiley-tongue-out.gif" width="18" height="18" border="0" /></a></td>
|
||||
<td><a href="javascript:void(0);" onmousedown="insertEmotion('smiley-undecided.gif');"><img src="images/smiley-undecided.gif" width="18" height="18" border="0" /></a></td>
|
||||
<td><a href="javascript:void(0);" onmousedown="insertEmotion('smiley-wink.gif');"><img src="images/smiley-wink.gif" width="18" height="18" border="0" /></a></td>
|
||||
<td><a href="javascript:void(0);" onmousedown="insertEmotion('smiley-yell.gif');"><img src="images/smiley-yell.gif" width="18" height="18" border="0" /></a></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
20
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/emotions/readme.txt
vendored
Normal file
20
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/emotions/readme.txt
vendored
Normal file
@ -0,0 +1,20 @@
|
||||
Emotions plugin for TinyMCE
|
||||
------------------------------
|
||||
|
||||
Installation instructions:
|
||||
* Copy the emotions directory to the plugins directory of TinyMCE (/jscripts/tiny_mce/plugins).
|
||||
* Add plugin to TinyMCE plugin option list example: plugins : "emotions".
|
||||
* Add the emotions button name to button list, example: theme_advanced_buttons3_add : "emotions".
|
||||
|
||||
Initialization example:
|
||||
tinyMCE.init({
|
||||
theme : "advanced",
|
||||
mode : "textareas",
|
||||
plugins : "emotions",
|
||||
theme_advanced_buttons3_add : "emotions"
|
||||
});
|
||||
|
||||
Copyright notice:
|
||||
These emotions where taken from Mozilla Thunderbird.
|
||||
I hope they don't get angry if I use them here after all this is a open source project
|
||||
aswell and I realy love their product.
|
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/flash/editor_plugin.js
vendored
Normal file
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/flash/editor_plugin.js
vendored
Normal file
File diff suppressed because one or more lines are too long
225
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/flash/editor_plugin_src.js
vendored
Normal file
225
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/flash/editor_plugin_src.js
vendored
Normal file
@ -0,0 +1,225 @@
|
||||
/* Import plugin specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('flash', 'en,de,sv,zh_cn,cs,fa,fr_ca,fr,pl');
|
||||
|
||||
function TinyMCE_flash_initInstance(inst) {
|
||||
if (!tinyMCE.settings['flash_skip_plugin_css'])
|
||||
tinyMCE.importCSS(inst.getDoc(), tinyMCE.baseURL + "/plugins/flash/flash.css");
|
||||
}
|
||||
|
||||
function TinyMCE_flash_getControlHTML(control_name) {
|
||||
switch (control_name) {
|
||||
case "flash":
|
||||
return '<img id="{$editor_id}_flash" src="{$pluginurl}/images/flash.gif" title="{$lang_insert_flash}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceFlash\');" />';
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
function TinyMCE_flash_parseAttributes(attribute_string) {
|
||||
var attributeName = "";
|
||||
var attributeValue = "";
|
||||
var withInName;
|
||||
var withInValue;
|
||||
var attributes = new Array();
|
||||
var whiteSpaceRegExp = new RegExp('^[ \n\r\t]+', 'g');
|
||||
|
||||
if (attribute_string == null || attribute_string.length < 2)
|
||||
return null;
|
||||
|
||||
withInName = withInValue = false;
|
||||
|
||||
for (var i=0; i<attribute_string.length; i++) {
|
||||
var chr = attribute_string.charAt(i);
|
||||
|
||||
if ((chr == '"' || chr == "'") && !withInValue)
|
||||
withInValue = true;
|
||||
else if ((chr == '"' || chr == "'") && withInValue) {
|
||||
withInValue = false;
|
||||
|
||||
var pos = attributeName.lastIndexOf(' ');
|
||||
if (pos != -1)
|
||||
attributeName = attributeName.substring(pos+1);
|
||||
|
||||
attributes[attributeName.toLowerCase()] = attributeValue.substring(1).toLowerCase();
|
||||
|
||||
attributeName = "";
|
||||
attributeValue = "";
|
||||
} else if (!whiteSpaceRegExp.test(chr) && !withInName && !withInValue)
|
||||
withInName = true;
|
||||
|
||||
if (chr == '=' && withInName)
|
||||
withInName = false;
|
||||
|
||||
if (withInName)
|
||||
attributeName += chr;
|
||||
|
||||
if (withInValue)
|
||||
attributeValue += chr;
|
||||
}
|
||||
|
||||
return attributes;
|
||||
}
|
||||
|
||||
function TinyMCE_flash_execCommand(editor_id, element, command, user_interface, value) {
|
||||
function getAttrib(elm, name) {
|
||||
return elm.getAttribute(name) ? elm.getAttribute(name) : "";
|
||||
}
|
||||
|
||||
// Handle commands
|
||||
switch (command) {
|
||||
case "mceFlash":
|
||||
var name = "", swffile = "", swfwidth = "", swfheight = "", action = "insert";
|
||||
var template = new Array();
|
||||
var inst = tinyMCE.getInstanceById(editor_id);
|
||||
var focusElm = inst.getFocusElement();
|
||||
|
||||
template['file'] = '../../plugins/flash/flash.htm'; // Relative to theme
|
||||
template['width'] = 400;
|
||||
template['height'] = 195;
|
||||
|
||||
// Is selection a image
|
||||
if (focusElm != null && focusElm.nodeName.toLowerCase() == "img") {
|
||||
name = getAttrib(focusElm, 'name');
|
||||
|
||||
if (name != 'mce_plugin_flash') // Not a Flash
|
||||
return true;
|
||||
|
||||
// Get rest of Flash items
|
||||
swffile = getAttrib(focusElm, 'alt');
|
||||
swffile = eval(tinyMCE.settings['urlconverter_callback'] + "(swffile, null, true);");
|
||||
swfwidth = getAttrib(focusElm, 'width');
|
||||
swfheight = getAttrib(focusElm, 'height');
|
||||
action = "update";
|
||||
}
|
||||
|
||||
tinyMCE.openWindow(template, {editor_id : editor_id, swffile : swffile, swfwidth : swfwidth, swfheight : swfheight, action : action});
|
||||
return true;
|
||||
}
|
||||
|
||||
// Pass to next handler in chain
|
||||
return false;
|
||||
}
|
||||
|
||||
function TinyMCE_flash_cleanup(type, content) {
|
||||
switch (type) {
|
||||
case "insert_to_editor_dom":
|
||||
var imgs = content.getElementsByTagName("img");
|
||||
for (var i=0; i<imgs.length; i++) {
|
||||
if (tinyMCE.getAttrib(imgs[i], "name") == "mce_plugin_flash") {
|
||||
var src = tinyMCE.getAttrib(imgs[i], "alt");
|
||||
|
||||
src = tinyMCE.convertRelativeToAbsoluteURL(tinyMCE.settings['base_href'], src);
|
||||
|
||||
imgs[i].setAttribute('alt', src);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
case "get_from_editor_dom":
|
||||
var imgs = content.getElementsByTagName("img");
|
||||
for (var i=0; i<imgs.length; i++) {
|
||||
if (tinyMCE.getAttrib(imgs[i], "name") == "mce_plugin_flash") {
|
||||
var src = tinyMCE.getAttrib(imgs[i], "alt");
|
||||
|
||||
src = eval(tinyMCE.settings['urlconverter_callback'] + "(src, null, true);");
|
||||
|
||||
imgs[i].setAttribute('alt', src);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
case "insert_to_editor":
|
||||
var startPos = 0;
|
||||
var embedList = new Array();
|
||||
|
||||
// Fix the embed and object elements
|
||||
content = content.replace(new RegExp('<[ ]*embed','gi'),'<embed');
|
||||
content = content.replace(new RegExp('<[ ]*/embed[ ]*>','gi'),'</embed>');
|
||||
content = content.replace(new RegExp('<[ ]*object','gi'),'<object');
|
||||
content = content.replace(new RegExp('<[ ]*/object[ ]*>','gi'),'</object>');
|
||||
|
||||
// Parse all embed tags
|
||||
while ((startPos = content.indexOf('<embed', startPos+1)) != -1) {
|
||||
var endPos = content.indexOf('>', startPos);
|
||||
var attribs = TinyMCE_flash_parseAttributes(content.substring(startPos + 6, endPos));
|
||||
embedList[embedList.length] = attribs;
|
||||
}
|
||||
|
||||
// Parse all object tags and replace them with images from the embed data
|
||||
var index = 0;
|
||||
while ((startPos = content.indexOf('<object', startPos)) != -1) {
|
||||
if (index >= embedList.length)
|
||||
break;
|
||||
|
||||
var attribs = embedList[index];
|
||||
|
||||
// Find end of object
|
||||
endPos = content.indexOf('</object>', startPos);
|
||||
endPos += 9;
|
||||
|
||||
// Insert image
|
||||
var contentAfter = content.substring(endPos);
|
||||
content = content.substring(0, startPos);
|
||||
content += '<img name="mce_plugin_flash" width="' + attribs["width"] + '" height="' + attribs["height"] + '"';
|
||||
content += ' src="' + (tinyMCE.getParam("theme_href") + '/images/spacer.gif') + '" title="' + attribs["src"] + '"';
|
||||
content += ' alt="' + attribs["src"] + '" class="mce_plugin_flash" />' + content.substring(endPos);
|
||||
content += contentAfter;
|
||||
index++;
|
||||
|
||||
startPos++;
|
||||
}
|
||||
break;
|
||||
|
||||
case "get_from_editor":
|
||||
// Parse all img tags and replace them with object+embed
|
||||
var startPos = -1;
|
||||
while ((startPos = content.indexOf('<img', startPos+1)) != -1) {
|
||||
var endPos = content.indexOf('/>', startPos);
|
||||
var attribs = TinyMCE_flash_parseAttributes(content.substring(startPos + 4, endPos));
|
||||
|
||||
// Is not flash, skip it
|
||||
if (attribs['name'] != "mce_plugin_flash")
|
||||
continue;
|
||||
|
||||
endPos += 2;
|
||||
|
||||
var embedHTML = '';
|
||||
|
||||
// Insert object + embed
|
||||
embedHTML += '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"';
|
||||
embedHTML += ' codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0"';
|
||||
embedHTML += ' width="' + attribs["width"] + '" height="' + attribs["height"] + '">';
|
||||
embedHTML += '<param name="movie" value="' + attribs["title"] + '" />';
|
||||
embedHTML += '<param name="quality" value="high" />';
|
||||
embedHTML += '<param name="menu" value="false" />';
|
||||
embedHTML += '<embed src="' + attribs["title"] + '" quality="high" menu="false" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="' + attribs["width"] + '" height="' + attribs["height"] + '"></embed></object>';
|
||||
|
||||
// Insert embed/object chunk
|
||||
chunkBefore = content.substring(0, startPos);
|
||||
chunkAfter = content.substring(endPos);
|
||||
content = chunkBefore + embedHTML + chunkAfter;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
// Pass through to next handler in chain
|
||||
return content;
|
||||
}
|
||||
|
||||
function TinyMCE_flash_handleNodeChange(editor_id, node, undo_index, undo_levels, visual_aid, any_selection) {
|
||||
function getAttrib(elm, name) {
|
||||
return elm.getAttribute(name) ? elm.getAttribute(name) : "";
|
||||
}
|
||||
|
||||
tinyMCE.switchClassSticky(editor_id + '_flash', 'mceButtonNormal');
|
||||
|
||||
if (node == null)
|
||||
return;
|
||||
|
||||
do {
|
||||
if (node.nodeName.toLowerCase() == "img" && getAttrib(node, 'name').indexOf('mce_plugin_flash') == 0)
|
||||
tinyMCE.switchClassSticky(editor_id + '_flash', 'mceButtonSelected');
|
||||
} while ((node = node.parentNode));
|
||||
|
||||
return true;
|
||||
}
|
7
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/flash/flash.css
vendored
Normal file
7
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/flash/flash.css
vendored
Normal file
@ -0,0 +1,7 @@
|
||||
.mce_plugin_flash {
|
||||
border: 1px dotted #cc0000;
|
||||
background-image: url(images/flash.gif);
|
||||
background-position: center;
|
||||
background-repeat: no-repeat;
|
||||
background-color: #ffffcc;
|
||||
}
|
181
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/flash/flash.htm
vendored
Normal file
181
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/flash/flash.htm
vendored
Normal file
@ -0,0 +1,181 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_insert_flash}</title>
|
||||
<script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script language="javascript">
|
||||
var url = tinyMCE.getParam("flash_external_list_url");
|
||||
if (url != null) {
|
||||
// Fix relative
|
||||
if (url.charAt(0) != '/')
|
||||
url = tinyMCE.documentBasePath + "/" + url;
|
||||
|
||||
document.write('<sc'+'ript language="javascript" type="text/javascript" src="' + url + '?rnd=' + new Date().getTime() + '"></sc'+'ript>');
|
||||
}
|
||||
</script>
|
||||
<script language="javascript" type="text/javascript">
|
||||
<!--
|
||||
function init() {
|
||||
// modified 2004-11-10 by Michael Keck (me@michaelkeck.de)
|
||||
// supporting onclick event to open pop windows
|
||||
var formObj = document.forms[0];
|
||||
var swffile = tinyMCE.getWindowArg('swffile');
|
||||
var swfwidth = '' + tinyMCE.getWindowArg('swfwidth');
|
||||
var swfheight = '' + tinyMCE.getWindowArg('swfheight');
|
||||
if (swfwidth.indexOf('%')!=-1) {
|
||||
formObj.width2.value = "%";
|
||||
formObj.width.value = swfwidth.substring(0,swfwidth.length-1);
|
||||
} else {
|
||||
formObj.width2.value = "px";
|
||||
formObj.width.value = swfwidth;
|
||||
}
|
||||
if (swfheight.indexOf('%')!=-1) {
|
||||
formObj.height2.value = "%";
|
||||
formObj.height.value = swfheight.substring(0,swfheight.length-1);
|
||||
} else {
|
||||
formObj.height2.value = "px";
|
||||
formObj.height.value = swfheight;
|
||||
}
|
||||
formObj.file.value = swffile;
|
||||
formObj.insert.value = tinyMCE.getLang('lang_' + tinyMCE.getWindowArg('action'), 'Insert', true);
|
||||
|
||||
// Handle file browser
|
||||
if (tinyMCE.getParam("file_browser_callback") != null) {
|
||||
document.getElementById('file').style.width = '230px';
|
||||
|
||||
var html = '';
|
||||
|
||||
html += '<img id="browserBtn" src="../../themes/advanced/images/browse.gif"';
|
||||
html += ' onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');"';
|
||||
html += ' onmouseout="tinyMCE.restoreClass(this);"';
|
||||
html += ' onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');"';
|
||||
html += ' onclick="javascript:tinyMCE.openFileBrowser(\'file\',document.forms[0].file.value,\'flash\',window);"';
|
||||
html += ' width="20" height="18" border="0" title="' + tinyMCE.getLang('lang_browse') + '"';
|
||||
html += ' class="mceButtonNormal" alt="' + tinyMCE.getLang('lang_browse') + '" />';
|
||||
|
||||
document.getElementById('browser').innerHTML = html;
|
||||
}
|
||||
|
||||
// Auto select flash in list
|
||||
if (typeof(tinyMCEFlashList) != "undefined" && tinyMCEFlashList.length > 0) {
|
||||
for (var i=0; i<formObj.link_list.length; i++) {
|
||||
if (formObj.link_list.options[i].value == tinyMCE.getWindowArg('swffile'))
|
||||
formObj.link_list.options[i].selected = true;
|
||||
}
|
||||
}
|
||||
|
||||
window.focus();
|
||||
}
|
||||
|
||||
function insertFlash() {
|
||||
var formObj = document.forms[0];
|
||||
if (window.opener) {
|
||||
var html = '';
|
||||
var file = formObj.file.value;
|
||||
var width = formObj.width.value;
|
||||
var height = formObj.height.value;
|
||||
if (formObj.width2.value=='%') {
|
||||
width = width + '%';
|
||||
}
|
||||
if (formObj.height2.value=='%') {
|
||||
height = height + '%';
|
||||
}
|
||||
|
||||
if (width == "")
|
||||
width = 100;
|
||||
|
||||
if (height == "")
|
||||
height = 100;
|
||||
|
||||
html += ''
|
||||
+ '<img src="' + (tinyMCE.getParam("theme_href") + "/images/spacer.gif") + '" '
|
||||
+ 'width="' + width + '" height="' + height + '" '
|
||||
+ 'border="0" alt="' + file + '" title="' + file + '" class="mce_plugin_flash" name="mce_plugin_flash" />';
|
||||
tinyMCE.execCommand("mceInsertContent",true,html);
|
||||
tinyMCE.selectedInstance.repaint();
|
||||
top.close();
|
||||
}
|
||||
}
|
||||
|
||||
function cancelAction() {
|
||||
top.close();
|
||||
}
|
||||
|
||||
//-->
|
||||
</script>
|
||||
<style type="text/css">
|
||||
<!--
|
||||
input.radio {
|
||||
border: 1px none #000000;
|
||||
background-color: transparent;
|
||||
vertical-align: middle;
|
||||
}
|
||||
-->
|
||||
</style>
|
||||
</head>
|
||||
<body onload="init();">
|
||||
<form onsubmit="insertFlash();return false;">
|
||||
<table border="0" cellpadding="0" cellspacing="4" width="100%">
|
||||
<tr>
|
||||
<td class="title">{$lang_insert_flash}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><hr size="1" noshade="noshade" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center" valign="middle"><table border="0" cellpadding="4" cellspacing="0">
|
||||
<tr>
|
||||
<td align="right">{$lang_insert_flash_file}:</td>
|
||||
<td nowrap="nowrap">
|
||||
<table border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td><input name="file" type="text" id="file" value="" onfocus="this.select();" style="width: 250px; vertical-align: middle;" /></td>
|
||||
<td id="browser"></td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<!-- Link list -->
|
||||
<script language="javascript">
|
||||
if (typeof(tinyMCEFlashList) != "undefined" && tinyMCEFlashList.length > 0) {
|
||||
var html = "";
|
||||
|
||||
html += '<tr><td align="right">{$lang_insert_flash_list}:</td>';
|
||||
html += '<td><select name="link_list" style="width: 250px" onchange="this.form.file.value=this.options[this.selectedIndex].value;">';
|
||||
html += '<option value="">---</option>';
|
||||
|
||||
for (var i=0; i<tinyMCEFlashList.length; i++)
|
||||
html += '<option value="' + tinyMCEFlashList[i][1] + '">' + tinyMCEFlashList[i][0] + '</option>';
|
||||
|
||||
html += '</select></td></tr>';
|
||||
|
||||
document.write(html);
|
||||
}
|
||||
</script>
|
||||
<!-- /Link list -->
|
||||
<tr>
|
||||
<td align="right">{$lang_insert_flash_size}:</td>
|
||||
<td nowrap="nowrap">
|
||||
<input name="width" type="text" id="width" value="" onfocus="this.select();" style="width: 50px; vertical-align: middle;" />
|
||||
<select name="width2" id="width2" style="width: 50px; vertical-align: middle;">
|
||||
<option value="">px</option>
|
||||
<option value="%">%</option>
|
||||
</select> x <input name="height" type="text" id="height" value="" onfocus="this.select();" style="width: 50px; vertical-align: middle;" />
|
||||
<select name="height2" id="height2" style="width: 50px; vertical-align: middle;">
|
||||
<option value="">px</option>
|
||||
<option value="%">%</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
</table></td>
|
||||
<tr>
|
||||
<td><hr size="1" noshade="noshade" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td nowrap="nowrap" align="left">
|
||||
<input style="float:left" type="button" name="insert" value="{$lang_insert}" onclick="insertFlash();" id="insert" /><input style="float:right" type="button" name="cancel" value="{$lang_cancel}" onclick="cancelAction();" id="cancel" />
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
48
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/flash/readme.txt
vendored
Normal file
48
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/flash/readme.txt
vendored
Normal file
@ -0,0 +1,48 @@
|
||||
FLASH plugin for TinyMCE
|
||||
-----------------------------
|
||||
|
||||
About:
|
||||
This is the INSERT FLASH Dialog contributed by Michael Keck.
|
||||
This one supports popup windows and targets.
|
||||
|
||||
Note:
|
||||
The placeholder for Flash is called 'mce_plugin_flash' and needs a class 'mce_plugin_flash' in the 'css_-style'.
|
||||
Do not name another image 'name="mce_plugin_flash"!
|
||||
|
||||
Installation instructions:
|
||||
* Copy the flash directory to the plugins directory of TinyMCE (/jscripts/tiny_mce/plugins).
|
||||
* Add plugin to TinyMCE plugin option list example: plugins : "flash".
|
||||
* Add this "img[class|src|border=0|alt|title|hspace|vspace|width|height|align|onmouseover|onmouseout|name]" to extended_valid_elements option.
|
||||
|
||||
Initialization example:
|
||||
tinyMCE.init({
|
||||
theme : "advanced",
|
||||
mode : "textareas",
|
||||
plugins : "flash",
|
||||
extended_valid_elements : "img[class|src|border=0|alt|title|hspace|vspace|width|height|align|onmouseover|onmouseout|name]"
|
||||
flash_external_list_url : "example_flash_list.js" // Optional URL to a list of Flash movies
|
||||
});
|
||||
|
||||
|
||||
----------------------------------------------------------------
|
||||
ADDITIONAL NOTE:
|
||||
|
||||
The flash plugin has been heavily modified (the original is editor_plugin_original.js) since the original did not play nicely with html content that
|
||||
already contained existing flash tags and in fact stripped out the object
|
||||
tags for existing flash html. The rewrite corrects this as well attempts
|
||||
to preserve the existing flash tags where possible. The tinyMCE.init call
|
||||
should be be something like:
|
||||
|
||||
Initialization example:
|
||||
tinyMCE.init({
|
||||
theme : "advanced",
|
||||
mode : "textareas",
|
||||
plugins : "flash",
|
||||
extended_valid_elements : "img[class|src|border=0|alt|title|hspace|vspace|width|height|align|onmouseover|onmouseout|name|obj|param|embed]"
|
||||
});
|
||||
|
||||
Note the extra obj,param,embed attributes for the img tag. These attributes
|
||||
are used to serialize data from existing flash tags so that they can be
|
||||
properly restored. Editing a flash tag with the plugin will cause this
|
||||
information to be lost (sorry !) but still produces a working flash nevertheless.
|
||||
|
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/fullscreen/editor_plugin.js
vendored
Normal file
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/fullscreen/editor_plugin.js
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
/* Import plugin specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('fullscreen','en,sv');function TinyMCE_fullscreen_getControlHTML(control_name){switch(control_name){case "fullscreen":return '<img id="{$editor_id}_fullscreen" src="{$pluginurl}/images/fullscreen.gif" title="{$lang_fullscreen_desc}" width="20" height="20" class="mceButton'+(tinyMCE.getParam('fullscreen_is_enabled')?'Selected':'Normal')+'" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceFullScreen\');" />';}return "";}function TinyMCE_fullscreen_execCommand(editor_id,element,command,user_interface,value){switch(command){case "mceFullScreen":if(tinyMCE.getParam('fullscreen_is_enabled')){window.opener.tinyMCE.execInstanceCommand(tinyMCE.getParam('fullscreen_editor_id'),'mceSetContent',false,tinyMCE.getContent(editor_id));top.close();}else{tinyMCE.setWindowArg('editor_id',editor_id);var win=window.open(tinyMCE.baseURL+"/plugins/fullscreen/fullscreen.htm","mceFullScreenPopup","fullscreen=yes,menubar=no,toolbar=no,scrollbars=no,resizable=yes,left=0,top=0,width="+screen.availWidth+",height="+screen.availHeight);}return true;}return false;}
|
34
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/fullscreen/editor_plugin_src.js
vendored
Normal file
34
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/fullscreen/editor_plugin_src.js
vendored
Normal file
@ -0,0 +1,34 @@
|
||||
/* Import plugin specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('fullscreen', 'en,sv');
|
||||
|
||||
function TinyMCE_fullscreen_getControlHTML(control_name) {
|
||||
switch (control_name) {
|
||||
case "fullscreen":
|
||||
return '<img id="{$editor_id}_fullscreen" src="{$pluginurl}/images/fullscreen.gif" title="{$lang_fullscreen_desc}" width="20" height="20" class="mceButton' + (tinyMCE.getParam('fullscreen_is_enabled') ? 'Selected' : 'Normal') + '" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceFullScreen\');" />';
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
function TinyMCE_fullscreen_execCommand(editor_id, element, command, user_interface, value) {
|
||||
// Handle commands
|
||||
switch (command) {
|
||||
case "mceFullScreen":
|
||||
if (tinyMCE.getParam('fullscreen_is_enabled')) {
|
||||
// In fullscreen mode
|
||||
window.opener.tinyMCE.execInstanceCommand(tinyMCE.getParam('fullscreen_editor_id'), 'mceSetContent', false, tinyMCE.getContent(editor_id));
|
||||
top.close();
|
||||
} else {
|
||||
tinyMCE.setWindowArg('editor_id', editor_id);
|
||||
|
||||
var win = window.open(tinyMCE.baseURL + "/plugins/fullscreen/fullscreen.htm", "mceFullScreenPopup", "fullscreen=yes,menubar=no,toolbar=no,scrollbars=no,resizable=yes,left=0,top=0,width=" + screen.availWidth + ",height=" + screen.availHeight);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
// Pass to next handler in chain
|
||||
return false;
|
||||
}
|
||||
|
||||
|
43
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/fullscreen/fullscreen.htm
vendored
Normal file
43
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/fullscreen/fullscreen.htm
vendored
Normal file
@ -0,0 +1,43 @@
|
||||
<html>
|
||||
<head>
|
||||
<title></title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<script language="javascript" type="text/javascript" src="../../tiny_mce.js"></script>
|
||||
<script language="javascript" type="text/javascript">
|
||||
var settings = new Array();
|
||||
|
||||
// Clone array
|
||||
for (var name in window.opener.tinyMCE.settings)
|
||||
settings[name] = window.opener.tinyMCE.settings[name];
|
||||
|
||||
// Set options
|
||||
settings['mode'] = 'exact';
|
||||
settings['elements'] = 'fullscreenarea';
|
||||
settings['ask'] = false;
|
||||
settings['setupcontent_callback'] = 'setupContent';
|
||||
settings['fullscreen_is_enabled'] = true;
|
||||
settings['fullscreen_editor_id'] = window.opener.tinyMCE.getWindowArg("editor_id");
|
||||
|
||||
// Init
|
||||
tinyMCE.init(settings);
|
||||
|
||||
function setupContent(editor_id, body, doc) {
|
||||
var inst = tinyMCE.getInstanceById(editor_id);
|
||||
var backInst = window.opener.tinyMCE.getInstanceById(tinyMCE.getParam('fullscreen_editor_id'));
|
||||
|
||||
// Setup title
|
||||
var divElm = document.createElement("div");
|
||||
divElm.innerHTML = tinyMCELang['lang_fullscreen_title'];
|
||||
document.title = divElm.innerHTML;
|
||||
|
||||
// Get content
|
||||
inst.getBody().innerHTML = backInst.getBody().innerHTML;
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body style="margin: 0px; overflow: hidden;" scrolling="no" scroll="no" onload="window.focus();">
|
||||
|
||||
<textarea id="fullscreenarea" style="width: 100%; height: 100%"></textarea>
|
||||
|
||||
</body>
|
||||
</html>
|
17
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/fullscreen/readme.txt
vendored
Normal file
17
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/fullscreen/readme.txt
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
Fullscreen plugin for TinyMCE
|
||||
------------------------------
|
||||
|
||||
This plugin adds fullscreen mode to TinyMCE.
|
||||
|
||||
Installation instructions:
|
||||
* Add plugin to TinyMCE plugin option list example: plugins : "fullscreen".
|
||||
* Add the fullscreen button name to button list, example: theme_advanced_buttons3_add : "fullscreen".
|
||||
|
||||
Initialization example:
|
||||
tinyMCE.init({
|
||||
theme : "advanced",
|
||||
mode : "textareas",
|
||||
plugins : "fullscreen",
|
||||
theme_advanced_buttons3_add : "fullscreen",
|
||||
plaintext_create_paragraphs : false
|
||||
});
|
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/iespell/editor_plugin.js
vendored
Normal file
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/iespell/editor_plugin.js
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
/* Import plugin specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('iespell','cs,el,en,fr_ca,it,ko,sv,zh_cn,fr,de,pl');function TinyMCE_iespell_getControlHTML(control_name){if(control_name=="iespell"&&tinyMCE.isMSIE)return '<img id="{$editor_id}_iespell" src="{$pluginurl}/images/iespell.gif" title="{$lang_iespell_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceIESpell\');">';return "";}function TinyMCE_iespell_execCommand(editor_id,element,command,user_interface,value){if(command=="mceIESpell"){try{var ieSpell=new ActiveXObject("ieSpell.ieSpellExtension");ieSpell.CheckDocumentNode(tinyMCE.getInstanceById(editor_id).contentDocument.documentElement);}catch(e){if(e.number==-2146827859){if(confirm(tinyMCE.getLang("lang_iespell_download","",true)))window.open('http://www.iespell.com/download.php','ieSpellDownload','');}else alert("Error Loading ieSpell: Exception "+e.number);}return true;}return false;}
|
37
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/iespell/editor_plugin_src.js
vendored
Normal file
37
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/iespell/editor_plugin_src.js
vendored
Normal file
@ -0,0 +1,37 @@
|
||||
/* Import plugin specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('iespell', 'cs,el,en,fr_ca,it,ko,sv,zh_cn,fr,de,pl');
|
||||
|
||||
/**
|
||||
* Returns the HTML contents of the iespell control.
|
||||
*/
|
||||
function TinyMCE_iespell_getControlHTML(control_name) {
|
||||
// Is it the iespell control and is the brower MSIE.
|
||||
if (control_name == "iespell" && tinyMCE.isMSIE)
|
||||
return '<img id="{$editor_id}_iespell" src="{$pluginurl}/images/iespell.gif" title="{$lang_iespell_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceIESpell\');">';
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
/**
|
||||
* Executes the mceIESpell command.
|
||||
*/
|
||||
function TinyMCE_iespell_execCommand(editor_id, element, command, user_interface, value) {
|
||||
// Handle ieSpellCommand
|
||||
if (command == "mceIESpell") {
|
||||
try {
|
||||
var ieSpell = new ActiveXObject("ieSpell.ieSpellExtension");
|
||||
ieSpell.CheckDocumentNode(tinyMCE.getInstanceById(editor_id).contentDocument.documentElement);
|
||||
} catch (e) {
|
||||
if (e.number == -2146827859) {
|
||||
if (confirm(tinyMCE.getLang("lang_iespell_download", "", true)))
|
||||
window.open('http://www.iespell.com/download.php', 'ieSpellDownload', '');
|
||||
} else
|
||||
alert("Error Loading ieSpell: Exception " + e.number);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
// Pass to next handler in chain
|
||||
return false;
|
||||
}
|
20
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/iespell/readme.txt
vendored
Normal file
20
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/iespell/readme.txt
vendored
Normal file
@ -0,0 +1,20 @@
|
||||
ieSpell plugin for TinyMCE
|
||||
----------------------------
|
||||
|
||||
Installation instructions:
|
||||
* Copy the iespell directory to the plugins directory of TinyMCE (/jscripts/tiny_mce/plugins).
|
||||
* Add plugin to TinyMCE plugin option list example: plugins : "iespell".
|
||||
* Add the iespell button name to button list, example: theme_advanced_buttons3_add : "iespell".
|
||||
|
||||
Initialization example:
|
||||
tinyMCE.init({
|
||||
theme : "advanced",
|
||||
mode : "textareas",
|
||||
plugins : "iespell",
|
||||
theme_advanced_buttons3_add : "iespell"
|
||||
});
|
||||
|
||||
Requirements:
|
||||
The end user will need MSIE on Windows with the ieSpell installed. This can be downloaded
|
||||
from http://www.iespell.com/download.php. Notice on other browsers than MSIE the spellchecking
|
||||
button will not be visible.
|
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/insertdatetime/editor_plugin.js
vendored
Normal file
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/insertdatetime/editor_plugin.js
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
/* Import plugin specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('insertdatetime','cs,el,en,fr_ca,it,ko,sv,zh_cn,fa,fr,de,pl');function TinyMCE_insertdatetime_getControlHTML(control_name){var safariPatch='" onclick="';if(tinyMCE.isSafari)safariPatch="";switch(control_name){case "insertdate":return '<img id="{$editor_id}_insertdate" src="{$pluginurl}/images/insertdate.gif" title="{$lang_insertdate_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');'+safariPatch+'tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceInsertDate\');">';case "inserttime":return '<img id="{$editor_id}_inserttime" src="{$pluginurl}/images/inserttime.gif" title="{$lang_inserttime_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');'+safariPatch+'tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceInsertTime\');">';}return "";}function TinyMCE_insertdatetime_execCommand(editor_id,element,command,user_interface,value){function addZeros(value,len){value=""+value;if(value.length<len){for(var i=0;i<(len-value.length);i++)value="0"+value;}return value;}function getDateTime(date,format){format=tinyMCE.regexpReplace(format,"%D","%m/%d/%y");format=tinyMCE.regexpReplace(format,"%r","%I:%M:%S %p");format=tinyMCE.regexpReplace(format,"%Y",""+date.getFullYear());format=tinyMCE.regexpReplace(format,"%y",""+date.getYear());format=tinyMCE.regexpReplace(format,"%m",addZeros(date.getMonth()+1,2));format=tinyMCE.regexpReplace(format,"%d",addZeros(date.getDate(),2));format=tinyMCE.regexpReplace(format,"%H",""+addZeros(date.getHours(),2));format=tinyMCE.regexpReplace(format,"%M",""+addZeros(date.getMinutes(),2));format=tinyMCE.regexpReplace(format,"%S",""+addZeros(date.getSeconds(),2));format=tinyMCE.regexpReplace(format,"%I",""+(date.getHours()<12?(date.getHours()+1):24-date.getHours()));format=tinyMCE.regexpReplace(format,"%p",""+(date.getHours()<12?"AM":"PM"));format=tinyMCE.regexpReplace(format,"%B",""+tinyMCE.getLang("lang_inserttime_months_long")[date.getMonth()]);format=tinyMCE.regexpReplace(format,"%b",""+tinyMCE.getLang("lang_inserttime_months_short")[date.getMonth()]);format=tinyMCE.regexpReplace(format,"%A",""+tinyMCE.getLang("lang_inserttime_day_long")[date.getDay()]);format=tinyMCE.regexpReplace(format,"%a",""+tinyMCE.getLang("lang_inserttime_day_short")[date.getDay()]);format=tinyMCE.regexpReplace(format,"%%","%");return format;}switch(command){case "mceInsertDate":tinyMCE.execInstanceCommand(editor_id,'mceInsertContent',false,getDateTime(new Date(),tinyMCE.getParam("plugin_insertdate_dateFormat","%Y-%m-%d")));return true;case "mceInsertTime":tinyMCE.execInstanceCommand(editor_id,'mceInsertContent',false,getDateTime(new Date(),tinyMCE.getParam("plugin_insertdate_timeFormat","%H:%M:%S")));return true;}return false;}
|
75
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/insertdatetime/editor_plugin_src.js
vendored
Normal file
75
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/insertdatetime/editor_plugin_src.js
vendored
Normal file
@ -0,0 +1,75 @@
|
||||
/* Import plugin specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('insertdatetime', 'cs,el,en,fr_ca,it,ko,sv,zh_cn,fa,fr,de,pl');
|
||||
|
||||
/**
|
||||
* Returns the HTML contents of the insertdate, inserttime controls.
|
||||
*/
|
||||
function TinyMCE_insertdatetime_getControlHTML(control_name) {
|
||||
var safariPatch = '" onclick="';
|
||||
|
||||
if (tinyMCE.isSafari)
|
||||
safariPatch = "";
|
||||
|
||||
switch (control_name) {
|
||||
case "insertdate":
|
||||
return '<img id="{$editor_id}_insertdate" src="{$pluginurl}/images/insertdate.gif" title="{$lang_insertdate_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');' + safariPatch + 'tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceInsertDate\');">';
|
||||
|
||||
case "inserttime":
|
||||
return '<img id="{$editor_id}_inserttime" src="{$pluginurl}/images/inserttime.gif" title="{$lang_inserttime_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');' + safariPatch + 'tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceInsertTime\');">';
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
/**
|
||||
* Executes the mceInsertDate command.
|
||||
*/
|
||||
function TinyMCE_insertdatetime_execCommand(editor_id, element, command, user_interface, value) {
|
||||
/* Adds zeros infront of value */
|
||||
function addZeros(value, len) {
|
||||
value = "" + value;
|
||||
|
||||
if (value.length < len) {
|
||||
for (var i=0; i<(len-value.length); i++)
|
||||
value = "0" + value;
|
||||
}
|
||||
|
||||
return value;
|
||||
}
|
||||
|
||||
/* Returns the date object in the specified format */
|
||||
function getDateTime(date, format) {
|
||||
format = tinyMCE.regexpReplace(format, "%D", "%m/%d/%y");
|
||||
format = tinyMCE.regexpReplace(format, "%r", "%I:%M:%S %p");
|
||||
format = tinyMCE.regexpReplace(format, "%Y", "" + date.getFullYear());
|
||||
format = tinyMCE.regexpReplace(format, "%y", "" + date.getYear());
|
||||
format = tinyMCE.regexpReplace(format, "%m", addZeros(date.getMonth()+1, 2));
|
||||
format = tinyMCE.regexpReplace(format, "%d", addZeros(date.getDate(), 2));
|
||||
format = tinyMCE.regexpReplace(format, "%H", "" + addZeros(date.getHours(), 2));
|
||||
format = tinyMCE.regexpReplace(format, "%M", "" + addZeros(date.getMinutes(), 2));
|
||||
format = tinyMCE.regexpReplace(format, "%S", "" + addZeros(date.getSeconds(), 2));
|
||||
format = tinyMCE.regexpReplace(format, "%I", "" + (date.getHours() < 12 ? (date.getHours()+1) : 24-date.getHours()));
|
||||
format = tinyMCE.regexpReplace(format, "%p", "" + (date.getHours() < 12 ? "AM" : "PM"));
|
||||
format = tinyMCE.regexpReplace(format, "%B", "" + tinyMCE.getLang("lang_inserttime_months_long")[date.getMonth()]);
|
||||
format = tinyMCE.regexpReplace(format, "%b", "" + tinyMCE.getLang("lang_inserttime_months_short")[date.getMonth()]);
|
||||
format = tinyMCE.regexpReplace(format, "%A", "" + tinyMCE.getLang("lang_inserttime_day_long")[date.getDay()]);
|
||||
format = tinyMCE.regexpReplace(format, "%a", "" + tinyMCE.getLang("lang_inserttime_day_short")[date.getDay()]);
|
||||
format = tinyMCE.regexpReplace(format, "%%", "%");
|
||||
|
||||
return format;
|
||||
}
|
||||
|
||||
// Handle commands
|
||||
switch (command) {
|
||||
case "mceInsertDate":
|
||||
tinyMCE.execInstanceCommand(editor_id, 'mceInsertContent', false, getDateTime(new Date(), tinyMCE.getParam("plugin_insertdate_dateFormat", "%Y-%m-%d")));
|
||||
return true;
|
||||
|
||||
case "mceInsertTime":
|
||||
tinyMCE.execInstanceCommand(editor_id, 'mceInsertContent', false, getDateTime(new Date(), tinyMCE.getParam("plugin_insertdate_timeFormat", "%H:%M:%S")));
|
||||
return true;
|
||||
}
|
||||
|
||||
// Pass to next handler in chain
|
||||
return false;
|
||||
}
|
35
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/insertdatetime/readme.txt
vendored
Normal file
35
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/insertdatetime/readme.txt
vendored
Normal file
@ -0,0 +1,35 @@
|
||||
InsertDateTime plugin for TinyMCE
|
||||
-----------------------------------
|
||||
|
||||
Installation instructions:
|
||||
* Copy the insertdatetime directory to the plugins directory of TinyMCE (/jscripts/tiny_mce/plugins).
|
||||
* Add plugin to TinyMCE plugin option list example: plugins : "insertdatetime".
|
||||
* Add the insertdate or inserttime button name to button list, example: theme_advanced_buttons3_add : "insertdate,inserttime".
|
||||
|
||||
Initialization example:
|
||||
tinyMCE.init({
|
||||
theme : "advanced",
|
||||
mode : "textareas",
|
||||
plugins : "insertdatetime",
|
||||
theme_advanced_buttons3_add : "insertdate,inserttime",
|
||||
plugin_insertdate_dateFormat : "%Y-%m-%d",
|
||||
plugin_insertdate_timeFormat : "%H:%M:%S"
|
||||
});
|
||||
|
||||
Configuration:
|
||||
plugin_insertdate_dateFormat - Format that the date is output as. Defaults to: "%Y-%m-%d".
|
||||
Replacement variables:
|
||||
%y - year as a decimal number without a century (range 00 to 99)
|
||||
%Y - year as a decimal number including the century
|
||||
%d - day of the month as a decimal number (range 01 to 31)
|
||||
%m - month as a decimal number (range 01 to 12)
|
||||
%D - same as %m/%d/%y
|
||||
%r - time in a.m. and p.m. notation
|
||||
%H - hour as a decimal number using a 24-hour clock (range 00 to 23)
|
||||
%I - hour as a decimal number using a 12-hour clock (range 01 to 12)
|
||||
%M - minute as a decimal number (range 00-59)
|
||||
%S - second as a decimal number (range 00-59)
|
||||
%p - either `am' or `pm' according to the given time value
|
||||
%% - a literal `%' character
|
||||
|
||||
plugin_insertdate_timeFormat - Format that the time is output as. Defaults to: "%H:%M:%S".
|
15
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/paste/blank.htm
vendored
Normal file
15
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/paste/blank.htm
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<title>blank_page</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
|
||||
<script language="javascript">
|
||||
function init() {
|
||||
document.designMode = 'on';
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body onload="init();">
|
||||
|
||||
</body>
|
||||
</html>
|
25
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/paste/editor_plugin.js
vendored
Normal file
25
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/paste/editor_plugin.js
vendored
Normal file
@ -0,0 +1,25 @@
|
||||
// Tiny MCE Paste Plugin
|
||||
// Updated by speednet 25 May 2005 - IE converts and pastes without opening popup window
|
||||
tinyMCE.importPluginLanguagePack('paste','en,sv');function TinyMCE_paste_getControlHTML(control_name){switch(control_name){case "pastetext":return '<img id="{$editor_id}pastetext" src="{$pluginurl}/images/pastetext.gif" title="{$lang_paste_text_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcePasteText\');" />';case "pasteword":return '<img id="{$editor_id}pasteword" src="{$pluginurl}/images/pasteword.gif" title="{$lang_paste_word_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcePasteWord\');" />';case "selectall":return '<img id="{$editor_id}selectall" src="{$pluginurl}/images/selectall.gif" title="{$lang_selectall_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceSelectAll\');" />';}return '';}function TinyMCE_paste_execCommand(editor_id,element,command,user_interface,value){switch(command){case "mcePasteText":if(tinyMCE.isMSIE&&tinyMCE.getParam('paste_use_dialog',false))TinyMCE_paste__insertText(clipboardData.getData("Text"),true);else{var template=new Array();template['file']='../../plugins/paste/pastetext.htm';template['width']=450;template['height']=400;var plain_text="";tinyMCE.openWindow(template,{editor_id:editor_id,plain_text:plain_text,resizable:"yes",scrollbars:"no",mceDo:'insert'});}return true;case "mcePasteWord":if(tinyMCE.isMSIE&&tinyMCE.getParam('paste_use_dialog',false)){var html=TinyMCE_paste__clipboardHTML();if(html&&html.length>0)TinyMCE_paste__insertWordContent(html);}else{var template=new Array();template['file']='../../plugins/paste/pasteword.htm';template['width']=450;template['height']=400;var plain_text="";tinyMCE.openWindow(template,{editor_id:editor_id,plain_text:plain_text,resizable:"yes",scrollbars:"no",mceDo:'insert'});}return true;case "mceSelectAll":tinyMCE.execInstanceCommand(editor_id,'selectall');return true;}return false;}function TinyMCE_paste__insertText(content,bLinebreaks){if(content&&content.length>0){if(bLinebreaks){if(tinyMCE.getParam("plaintext_create_paragraphs",true)){content=tinyMCE.regexpReplace(content,"\r\n\r\n","</p><p>","gi");content=tinyMCE.regexpReplace(content,"\r\r","</p><p>","gi");content=tinyMCE.regexpReplace(content,"\n\n","</p><p>","gi");if((pos=content.indexOf('</p><p>'))!=-1){tinyMCE.execCommand("Delete");var node=tinyMCE.selectedInstance.getFocusElement();var breakElms=new Array();do{if(node.nodeType==1){if(node.nodeName=="TD"||node.nodeName=="BODY")break;breakElms[breakElms.length]=node;}}while(node=node.parentNode);var before="",after="</p>";before+=content.substring(0,pos);for(var i=0;i<breakElms.length;i++){before+="</"+breakElms[i].nodeName+">";after+="<"+breakElms[(breakElms.length-1)-i].nodeName+">";}before+="<p>";content=before+content.substring(pos+7)+after;}}content=tinyMCE.regexpReplace(content,"\r\n","<br />","gi");content=tinyMCE.regexpReplace(content,"\r","<br />","gi");content=tinyMCE.regexpReplace(content,"\n","<br />","gi");}tinyMCE.execCommand("mceInsertRawHTML",false,content);}}function TinyMCE_paste__insertWordContent(content){if(content&&content.length>0){content=content.replace(new RegExp('<(!--)([^>]*)(--)>','g'),"");content=content.replace(/<\/?span[^>]*>/gi,"");content=content.replace(/<(\w[^>]*)style="([^"]*)"([^>]*)/gi, "<$1$3");
|
||||
content = content.replace(/<\/?font[^>]*>/gi, "");
|
||||
content = content.replace(/<(\w[^>]*) class=([^ |>]*)([^>]*)/gi, "<$1$3");
|
||||
content = content.replace(/<(\w[^>]*) lang=([^ |>]*)([^>]*)/gi, "<$1$3");
|
||||
content = content.replace(/<\\?\?xml[^>]*>/gi, "");
|
||||
content = content.replace(/<\/?\w+:[^>]*>/gi, "");
|
||||
content = content.replace(/\/? */gi, "");
|
||||
content = content.replace('<p> </p>', '' ,'g');
|
||||
|
||||
if (!tinyMCE.settings['force_p_newlines']) {
|
||||
content = content.replace('', '' ,'gi');
|
||||
content = content.replace('</p>', '<br /><br />' ,'gi');
|
||||
}
|
||||
|
||||
if (!tinyMCE.isMSIE && !tinyMCE.settings['force_p_newlines']) {
|
||||
content = content.replace(/<\/?p[^>]*>/gi, "");
|
||||
}
|
||||
|
||||
content = content.replace(/<\/?div[^>]*>/gi, "");
|
||||
|
||||
// Insert cleaned content
|
||||
tinyMCE.execCommand("mceAddUndoLevel");
|
||||
tinyMCE.execCommand("mceInsertContent",false,content);}}function TinyMCE_paste__clipboardHTML(){var div=document.getElementById('_TinyMCE_clipboardHTML');if(!div){var div=document.createElement('DIV');div.id='_TinyMCE_clipboardHTML';with(div.style){visibility='hidden';overflow='hidden';position='absolute';width=1;height=1;}document.body.appendChild(div);}div.innerHTML='';var rng=document.body.createTextRange();rng.moveToElementText(div);rng.execCommand('Paste');var html=div.innerHTML;div.innerHTML='';return html;}
|
174
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/paste/editor_plugin_src.js
vendored
Normal file
174
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/paste/editor_plugin_src.js
vendored
Normal file
@ -0,0 +1,174 @@
|
||||
// Tiny MCE Paste Plugin
|
||||
// Updated by speednet 25 May 2005 - IE converts and pastes without opening popup window
|
||||
|
||||
/* Import plugin specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('paste', 'en,sv');
|
||||
|
||||
function TinyMCE_paste_getControlHTML(control_name) {
|
||||
switch (control_name) {
|
||||
case "pastetext":
|
||||
return '<img id="{$editor_id}pastetext" src="{$pluginurl}/images/pastetext.gif" title="{$lang_paste_text_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcePasteText\');" />';
|
||||
|
||||
case "pasteword":
|
||||
return '<img id="{$editor_id}pasteword" src="{$pluginurl}/images/pasteword.gif" title="{$lang_paste_word_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcePasteWord\');" />';
|
||||
|
||||
case "selectall":
|
||||
return '<img id="{$editor_id}selectall" src="{$pluginurl}/images/selectall.gif" title="{$lang_selectall_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceSelectAll\');" />';
|
||||
}
|
||||
|
||||
return '';
|
||||
}
|
||||
|
||||
function TinyMCE_paste_execCommand(editor_id, element, command, user_interface, value) {
|
||||
switch (command) {
|
||||
case "mcePasteText":
|
||||
if (tinyMCE.isMSIE && tinyMCE.getParam('paste_use_dialog', false))
|
||||
TinyMCE_paste__insertText(clipboardData.getData("Text"), true);
|
||||
else {
|
||||
var template = new Array();
|
||||
template['file'] = '../../plugins/paste/pastetext.htm'; // Relative to theme
|
||||
template['width'] = 450;
|
||||
template['height'] = 400;
|
||||
var plain_text = "";
|
||||
tinyMCE.openWindow(template, {editor_id : editor_id, plain_text: plain_text, resizable : "yes", scrollbars : "no", mceDo : 'insert'});
|
||||
}
|
||||
|
||||
return true;
|
||||
|
||||
case "mcePasteWord":
|
||||
if (tinyMCE.isMSIE && tinyMCE.getParam('paste_use_dialog', false)) {
|
||||
var html = TinyMCE_paste__clipboardHTML();
|
||||
|
||||
if (html && html.length > 0)
|
||||
TinyMCE_paste__insertWordContent(html);
|
||||
} else {
|
||||
var template = new Array();
|
||||
template['file'] = '../../plugins/paste/pasteword.htm'; // Relative to theme
|
||||
template['width'] = 450;
|
||||
template['height'] = 400;
|
||||
var plain_text = "";
|
||||
tinyMCE.openWindow(template, {editor_id : editor_id, plain_text: plain_text, resizable : "yes", scrollbars : "no", mceDo : 'insert'});
|
||||
}
|
||||
|
||||
return true;
|
||||
|
||||
case "mceSelectAll":
|
||||
tinyMCE.execInstanceCommand(editor_id, 'selectall');
|
||||
return true;
|
||||
|
||||
}
|
||||
|
||||
// Pass to next handler in chain
|
||||
return false;
|
||||
}
|
||||
|
||||
function TinyMCE_paste__insertText(content, bLinebreaks) {
|
||||
|
||||
if (content && content.length > 0) {
|
||||
if (bLinebreaks) {
|
||||
// Special paragraph treatment
|
||||
if (tinyMCE.getParam("plaintext_create_paragraphs", true)) {
|
||||
content = tinyMCE.regexpReplace(content, "\r\n\r\n", "</p><p>", "gi");
|
||||
content = tinyMCE.regexpReplace(content, "\r\r", "</p><p>", "gi");
|
||||
content = tinyMCE.regexpReplace(content, "\n\n", "</p><p>", "gi");
|
||||
|
||||
// Has paragraphs
|
||||
if ((pos = content.indexOf('</p><p>')) != -1) {
|
||||
tinyMCE.execCommand("Delete");
|
||||
|
||||
var node = tinyMCE.selectedInstance.getFocusElement();
|
||||
|
||||
// Get list of elements to break
|
||||
var breakElms = new Array();
|
||||
|
||||
do {
|
||||
if (node.nodeType == 1) {
|
||||
// Don't break tables and break at body
|
||||
if (node.nodeName == "TD" || node.nodeName == "BODY")
|
||||
break;
|
||||
|
||||
breakElms[breakElms.length] = node;
|
||||
}
|
||||
} while(node = node.parentNode);
|
||||
|
||||
var before = "", after = "</p>";
|
||||
before += content.substring(0, pos);
|
||||
|
||||
for (var i=0; i<breakElms.length; i++) {
|
||||
before += "</" + breakElms[i].nodeName + ">";
|
||||
after += "<" + breakElms[(breakElms.length-1)-i].nodeName + ">";
|
||||
}
|
||||
|
||||
before += "<p>";
|
||||
content = before + content.substring(pos+7) + after;
|
||||
}
|
||||
}
|
||||
|
||||
content = tinyMCE.regexpReplace(content, "\r\n", "<br />", "gi");
|
||||
content = tinyMCE.regexpReplace(content, "\r", "<br />", "gi");
|
||||
content = tinyMCE.regexpReplace(content, "\n", "<br />", "gi");
|
||||
}
|
||||
|
||||
tinyMCE.execCommand("mceInsertRawHTML", false, content);
|
||||
}
|
||||
}
|
||||
|
||||
function TinyMCE_paste__insertWordContent(content) {
|
||||
|
||||
if (content && content.length > 0) {
|
||||
// Cleanup Word content
|
||||
content = content.replace(new RegExp('<(!--)([^>]*)(--)>', 'g'), ""); // Word comments
|
||||
content = content.replace(/<\/?span[^>]*>/gi, "");
|
||||
content = content.replace(/<(\w[^>]*) style="([^"]*)"([^>]*)/gi, "<$1$3");
|
||||
content = content.replace(/<\/?font[^>]*>/gi, "");
|
||||
content = content.replace(/<(\w[^>]*) class=([^ |>]*)([^>]*)/gi, "<$1$3");
|
||||
content = content.replace(/<(\w[^>]*) lang=([^ |>]*)([^>]*)/gi, "<$1$3");
|
||||
content = content.replace(/<\\?\?xml[^>]*>/gi, "");
|
||||
content = content.replace(/<\/?\w+:[^>]*>/gi, "");
|
||||
content = content.replace(/\/? */gi, "");
|
||||
content = content.replace('<p> </p>', '' ,'g');
|
||||
|
||||
if (!tinyMCE.settings['force_p_newlines']) {
|
||||
content = content.replace('', '' ,'gi');
|
||||
content = content.replace('</p>', '<br /><br />' ,'gi');
|
||||
}
|
||||
|
||||
if (!tinyMCE.isMSIE && !tinyMCE.settings['force_p_newlines']) {
|
||||
content = content.replace(/<\/?p[^>]*>/gi, "");
|
||||
}
|
||||
|
||||
content = content.replace(/<\/?div[^>]*>/gi, "");
|
||||
|
||||
// Insert cleaned content
|
||||
tinyMCE.execCommand("mceAddUndoLevel");
|
||||
tinyMCE.execCommand("mceInsertContent", false, content);
|
||||
}
|
||||
}
|
||||
|
||||
function TinyMCE_paste__clipboardHTML() {
|
||||
var div = document.getElementById('_TinyMCE_clipboardHTML');
|
||||
|
||||
if (!div) {
|
||||
var div = document.createElement('DIV');
|
||||
div.id = '_TinyMCE_clipboardHTML';
|
||||
|
||||
with (div.style) {
|
||||
visibility = 'hidden';
|
||||
overflow = 'hidden';
|
||||
position = 'absolute';
|
||||
width = 1;
|
||||
height = 1;
|
||||
}
|
||||
|
||||
document.body.appendChild(div);
|
||||
}
|
||||
|
||||
div.innerHTML = '';
|
||||
var rng = document.body.createTextRange();
|
||||
rng.moveToElementText(div);
|
||||
rng.execCommand('Paste');
|
||||
var html = div.innerHTML;
|
||||
div.innerHTML = '';
|
||||
return html;
|
||||
}
|
||||
|
77
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/paste/pastetext.htm
vendored
Normal file
77
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/paste/pastetext.htm
vendored
Normal file
@ -0,0 +1,77 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_paste_text_desc}</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta http-equiv="Pragma" content="no-cache" />
|
||||
<meta http-equiv="Cache-Control" content="no-store, no-cache, must-revalidate" />
|
||||
<meta http-equiv="Expires" content="Fri, Oct 24 1976 00:00:00 GMT" />
|
||||
<script type="text/javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script type="text/javascript">
|
||||
<!--
|
||||
// Ryan Demmer 12/05/2005 (ryandemmer@gmail.com)
|
||||
// Pretty much a hack of the HTML Source Editor
|
||||
|
||||
// Updated by speednet 24 May 2005
|
||||
|
||||
tinyMCE.setWindowArg('mce_windowresize', false);
|
||||
|
||||
function saveContent() {
|
||||
if (window.opener) {
|
||||
if (document.forms[0].htmlSource.value == ''){
|
||||
window.close();
|
||||
return false;
|
||||
} else
|
||||
window.opener.TinyMCE_paste__insertText(document.forms[0].htmlSource.value, document.forms[0].linebreaks.checked);
|
||||
|
||||
window.close();
|
||||
}
|
||||
}
|
||||
|
||||
function onLoadInit() {
|
||||
resizeInputs();
|
||||
}
|
||||
|
||||
var wHeight=0, wWidth=0, owHeight=0, owWidth=0;
|
||||
|
||||
function resizeInputs() {
|
||||
if (!tinyMCE.isMSIE) {
|
||||
wHeight = self.innerHeight-80;
|
||||
wWidth = self.innerWidth-25;
|
||||
}
|
||||
else {
|
||||
wHeight = document.body.clientHeight-80;
|
||||
wWidth = document.body.clientWidth-25;
|
||||
}
|
||||
|
||||
document.forms[0].htmlSource.style.height = Math.abs(wHeight) + 'px';
|
||||
document.forms[0].htmlSource.style.width = Math.abs(wWidth) + 'px';
|
||||
}
|
||||
|
||||
window.focus();
|
||||
//--></script>
|
||||
</head>
|
||||
<body scroll="no" onload="onLoadInit();" onresize="resizeInputs();">
|
||||
<form name="source" onsubmit="saveContent();">
|
||||
<table border="0" cellpadding="0" cellspacing="2" align="center">
|
||||
<tr>
|
||||
<td class="title">{$lang_paste_text_desc}</td>
|
||||
<td align="right" nowrap="nowrap">
|
||||
<input type="checkbox" name="linebreaks" id="linebreaks" class="wordWrapCode" checked="checked" /><label for="linebreaks">{$lang_paste_text_linebreaks}</label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">{$lang_paste_text_title}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2" align="center">
|
||||
<textarea name="htmlSource" id="htmlSource" rows="15" cols="100" style="width: 100%; height: 100%; font-family: 'Courier New',Courier,mono; font-size: 12px;" dir="ltr" wrap="soft"></textarea>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="50%" align="left"><input type="button" id="insert" name="insert" value="{$lang_insert}" onclick="saveContent();" /></td>
|
||||
<td width="50%" align="right"><input type="button" value="{$lang_cancel}" onclick="window.close();" /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
111
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/paste/pasteword.htm
vendored
Normal file
111
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/paste/pasteword.htm
vendored
Normal file
@ -0,0 +1,111 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_paste_word_desc}</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta http-equiv="Pragma" content="no-cache" />
|
||||
<meta http-equiv="Cache-Control" content="no-store, no-cache, must-revalidate" />
|
||||
<meta http-equiv="Expires" content="Fri, Oct 24 1976 00:00:00 GMT" />
|
||||
<script type="text/javascript" src="../../tiny_mce.js"></script>
|
||||
<script type="text/javascript">
|
||||
<!--
|
||||
// Updated by speednet 25 May 2005
|
||||
|
||||
// Because we can't load tiny_mce_popup.js.
|
||||
// Get tinyMCE window
|
||||
var win = window.opener ? window.opener : window.dialogArguments;
|
||||
|
||||
var tinyMCE = null;
|
||||
var tinyMCELang = null;
|
||||
|
||||
// Use top window if not defined
|
||||
if (!win)
|
||||
win = top;
|
||||
|
||||
// Setup window opener
|
||||
window.opener = win;
|
||||
|
||||
var tinyMCE = win.tinyMCE;
|
||||
var tinyMCELang = win.tinyMCELang;
|
||||
|
||||
if (!tinyMCE)
|
||||
alert("tinyMCE object reference not found from popup.");
|
||||
|
||||
// Setup dir
|
||||
if (tinyMCELang['lang_dir'])
|
||||
document.dir = tinyMCELang['lang_dir'];
|
||||
|
||||
// Setup title
|
||||
var re = new RegExp('{|\\\$|}', 'g');
|
||||
var title = document.title.replace(re, "");
|
||||
|
||||
if (typeof tinyMCELang[title] != "undefined") {
|
||||
var divElm = document.createElement("div");
|
||||
divElm.innerHTML = tinyMCELang[title];
|
||||
document.title = divElm.innerHTML;
|
||||
}
|
||||
|
||||
function saveContent() {
|
||||
if (win) {
|
||||
var html = document.getElementById("frmData").contentWindow.document.body.innerHTML;
|
||||
|
||||
if (html == ''){
|
||||
window.close();
|
||||
return false;
|
||||
}
|
||||
|
||||
win.TinyMCE_paste__insertWordContent(html);
|
||||
window.close();
|
||||
}
|
||||
}
|
||||
|
||||
function onLoadInit() {
|
||||
document.body.innerHTML = tinyMCE.applyTemplate(document.body.innerHTML, tinyMCE.windowArgs);
|
||||
document.getElementById("frmData").contentWindow.document.designMode='on';
|
||||
document.getElementById("frmData").src = "blank.htm";
|
||||
resizeInputs();
|
||||
}
|
||||
|
||||
var wHeight=0, wWidth=0, owHeight=0, owWidth=0;
|
||||
|
||||
function resizeInputs() {
|
||||
if (!tinyMCE.isMSIE) {
|
||||
wHeight = self.innerHeight - 80;
|
||||
wWidth = self.innerWidth - 25;
|
||||
}
|
||||
else {
|
||||
wHeight = document.body.clientHeight - 80;
|
||||
wWidth = document.body.clientWidth - 25;
|
||||
}
|
||||
|
||||
document.getElementById('frmData').style.height = Math.abs(wHeight) + 'px';
|
||||
document.getElementById('frmData').style.width = Math.abs(wWidth) + 'px';
|
||||
}
|
||||
|
||||
// Output Popup CSS class
|
||||
document.write('<link href="' + tinyMCE.getParam("popups_css") + '" rel="stylesheet" type="text/css">');
|
||||
window.focus();
|
||||
//--></script>
|
||||
|
||||
</head>
|
||||
<body scroll="no" onload="onLoadInit();" onresize="resizeInputs();">
|
||||
<form name="source" onsubmit="saveContent();">
|
||||
<table border="0" cellpadding="0" cellspacing="2" align="center">
|
||||
<tr>
|
||||
<td colspan="2" class="title">{$lang_paste_word_desc}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">{$lang_paste_word_title}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2" align="center">
|
||||
<iframe id="frmData" name="frmData" src="blank.htm" height="280" width="400" style="font-family:'Courier New',Courier,mono; font-size:10px; background-color:#FFFFFF; width:100%;" dir="ltr" wrap="soft"></iframe>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="50%" align="left"><input type="button" id="insert" name="insert" value="{$lang_insert}" onclick="saveContent();" /></td>
|
||||
<td width="50%" align="right"><input type="button" value="{$lang_cancel}" onclick="window.close();" /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
28
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/paste/readme.txt
vendored
Normal file
28
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/paste/readme.txt
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
Paste plugin for TinyMCE
|
||||
------------------------------
|
||||
|
||||
This plugin adds paste as plain text and paste from Word icons to TinyMCE. This plugin was developed by Ryan Demmer and modified by
|
||||
the TinyMCE crew to be more general and some extra features where added.
|
||||
|
||||
On 25 May 2005, this plugin was modified by speednet: IE now pastes directly into the editor, bypassing the extra steps of opening the Insert box, selecting options, and clicking Insert. Speednet also added the Select All command, which highlights all the content in the editor when the user clicks the toolbar button. (Other miscellaneous cleanup also.)
|
||||
|
||||
|
||||
Installation instructions:
|
||||
* Add plugin to TinyMCE plugin option list example: plugins : "paste".
|
||||
* Add the plaintext button name to button list, example: theme_advanced_buttons3_add : "pastetext,pasteword,selectall".
|
||||
|
||||
Initialization example:
|
||||
tinyMCE.init({
|
||||
theme : "advanced",
|
||||
mode : "textareas",
|
||||
plugins : "paste",
|
||||
theme_advanced_buttons3_add : "pastetext,pasteword,selectall",
|
||||
paste_create_paragraphs : false,
|
||||
paste_use_dialog : true
|
||||
});
|
||||
|
||||
Options:
|
||||
[paste_create_paragraphs] - If enabled double linefeeds are converted to paragraph
|
||||
elements when using the plain text dialog. This is enabled by default.
|
||||
[paste_use_dialog] - MSIE specific option, if you set this to false both Mozilla and MSIE will present a paste dialog.
|
||||
if you set it to true pasting in MSIE will be done directly. This option is set to false by default.
|
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/preview/editor_plugin.js
vendored
Normal file
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/preview/editor_plugin.js
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
/* Import plugin specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('preview','cs,de,el,en,fr_ca,it,ko,pt,sv,zh_cn,fa,fr,pl');function TinyMCE_preview_getControlHTML(control_name){switch(control_name){case "preview":return '<img id="{$editor_id}_preview" src="{$pluginurl}/images/preview.gif" title="{$lang_preview_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcePreview\');" />';}return "";}function TinyMCE_preview_execCommand(editor_id,element,command,user_interface,value){switch(command){case "mcePreview":var previewPage=tinyMCE.getParam("plugin_preview_pageurl",null);var previewWidth=tinyMCE.getParam("plugin_preview_width","550");var previewHeight=tinyMCE.getParam("plugin_preview_height","600");if(previewPage){var template=new Array();template['file']=previewPage;template['width']=previewWidth;template['height']=previewHeight;tinyMCE.openWindow(template,{editor_id:editor_id,resizable:"yes",scrollbars:"yes",content:tinyMCE.getContent(),content_css:tinyMCE.getParam("content_css")});}else{var win=window.open("","mcePreview","menubar=no,toolbar=no,scrollbars=yes,resizable=yes,left=20,top=20,width="+previewWidth+",height="+previewHeight);var html="";html+='<!doctype html public "-//w3c//dtd html 4.0 transitional//en">';html+='<html>';html+='<head>';html+='<title>'+tinyMCE.getLang('lang_preview_desc')+'</title>';html+='<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">';html+='<link href="'+tinyMCE.getParam("content_css")+'" rel="stylesheet" type="text/css">';html+='</head>';html+='<body>';html+=tinyMCE.getContent();html+='</body>';html+='</html>';win.document.write(html);win.document.close();}return true;}return false;}
|
61
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/preview/editor_plugin_src.js
vendored
Normal file
61
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/preview/editor_plugin_src.js
vendored
Normal file
@ -0,0 +1,61 @@
|
||||
/* Import plugin specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('preview', 'cs,de,el,en,fr_ca,it,ko,pt,sv,zh_cn,fa,fr,pl');
|
||||
|
||||
/**
|
||||
* Returns the HTML contents of the preview control.
|
||||
*/
|
||||
function TinyMCE_preview_getControlHTML(control_name) {
|
||||
switch (control_name) {
|
||||
case "preview":
|
||||
return '<img id="{$editor_id}_preview" src="{$pluginurl}/images/preview.gif" title="{$lang_preview_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcePreview\');" />';
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
/**
|
||||
* Executes the mcePreview command.
|
||||
*/
|
||||
function TinyMCE_preview_execCommand(editor_id, element, command, user_interface, value) {
|
||||
// Handle commands
|
||||
switch (command) {
|
||||
case "mcePreview":
|
||||
var previewPage = tinyMCE.getParam("plugin_preview_pageurl", null);
|
||||
var previewWidth = tinyMCE.getParam("plugin_preview_width", "550");
|
||||
var previewHeight = tinyMCE.getParam("plugin_preview_height", "600");
|
||||
|
||||
// Use a custom preview page
|
||||
if (previewPage) {
|
||||
var template = new Array();
|
||||
|
||||
template['file'] = previewPage;
|
||||
template['width'] = previewWidth;
|
||||
template['height'] = previewHeight;
|
||||
|
||||
tinyMCE.openWindow(template, {editor_id : editor_id, resizable : "yes", scrollbars : "yes", content : tinyMCE.getContent(), content_css : tinyMCE.getParam("content_css")});
|
||||
} else {
|
||||
var win = window.open("", "mcePreview", "menubar=no,toolbar=no,scrollbars=yes,resizable=yes,left=20,top=20,width=" + previewWidth + ",height=" + previewHeight);
|
||||
var html = "";
|
||||
|
||||
html += '<!doctype html public "-//w3c//dtd html 4.0 transitional//en">';
|
||||
html += '<html>';
|
||||
html += '<head>';
|
||||
html += '<title>' + tinyMCE.getLang('lang_preview_desc') + '</title>';
|
||||
html += '<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">';
|
||||
html += '<link href="' + tinyMCE.getParam("content_css") + '" rel="stylesheet" type="text/css">';
|
||||
html += '</head>';
|
||||
html += '<body>';
|
||||
html += tinyMCE.getContent();
|
||||
html += '</body>';
|
||||
html += '</html>';
|
||||
|
||||
win.document.write(html);
|
||||
win.document.close();
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
// Pass to next handler in chain
|
||||
return false;
|
||||
}
|
14
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/preview/example.html
vendored
Normal file
14
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/preview/example.html
vendored
Normal file
@ -0,0 +1,14 @@
|
||||
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
|
||||
<html>
|
||||
<head>
|
||||
<script language="javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<title>Example of a custom preview page</title>
|
||||
<link href="{$content_css}" rel="stylesheet" type="text/css">
|
||||
</head>
|
||||
<body>
|
||||
|
||||
Editor contents: <br />
|
||||
{$content}
|
||||
|
||||
</body>
|
||||
</html>
|
23
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/preview/readme.txt
vendored
Normal file
23
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/preview/readme.txt
vendored
Normal file
@ -0,0 +1,23 @@
|
||||
Preview plugin for TinyMCE
|
||||
-----------------------------------
|
||||
|
||||
Installation instructions:
|
||||
* Copy the preview directory to the plugins directory of TinyMCE (/jscripts/tiny_mce/plugins).
|
||||
* Add plugin to TinyMCE plugin option list example: plugins : "preview".
|
||||
* Add the preview button name to button list, example: theme_advanced_buttons3_add : "preview".
|
||||
|
||||
Initialization example:
|
||||
tinyMCE.init({
|
||||
theme : "advanced",
|
||||
mode : "textareas",
|
||||
plugins : "preview",
|
||||
theme_advanced_buttons3_add : "preview",
|
||||
plugin_preview_width : "500",
|
||||
plugin_preview_height : "600"
|
||||
});
|
||||
|
||||
Configuration:
|
||||
plugin_preview_width - Preview window width. Defaults to 550.
|
||||
plugin_preview_height - Preview window height. Defaults to 600.
|
||||
plugin_preview_pageurl - Custom preview page URL relative from theme
|
||||
use "../../plugins/preview/example.html" for a example.
|
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/print/editor_plugin.js
vendored
Normal file
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/print/editor_plugin.js
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
/* Import theme specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('print','en,sv,zh_cn,fa,fr_ca,fr,de,pl');function TinyMCE_print_getControlHTML(control_name){switch(control_name){case "print":return '<img id="{$editor_id}_print" src="{$pluginurl}/images/print.gif" title="{$lang_print_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcePrint\',true);" />';}return "";}function TinyMCE_print_execCommand(editor_id,element,command,user_interface,value){switch(command){case "mcePrint":tinyMCE.getInstanceById(editor_id).contentWindow.print();return true;}return false;}
|
26
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/print/editor_plugin_src.js
vendored
Normal file
26
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/print/editor_plugin_src.js
vendored
Normal file
@ -0,0 +1,26 @@
|
||||
/* Import theme specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('print', 'en,sv,zh_cn,fa,fr_ca,fr,de,pl');
|
||||
|
||||
function TinyMCE_print_getControlHTML(control_name) {
|
||||
switch (control_name) {
|
||||
case "print":
|
||||
return '<img id="{$editor_id}_print" src="{$pluginurl}/images/print.gif" title="{$lang_print_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mcePrint\',true);" />';
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
/**
|
||||
* Executes the search/replace commands.
|
||||
*/
|
||||
function TinyMCE_print_execCommand(editor_id, element, command, user_interface, value) {
|
||||
// Handle commands
|
||||
switch (command) {
|
||||
case "mcePrint":
|
||||
tinyMCE.getInstanceById(editor_id).contentWindow.print();
|
||||
return true;
|
||||
}
|
||||
|
||||
// Pass to next handler in chain
|
||||
return false;
|
||||
}
|
17
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/print/readme.txt
vendored
Normal file
17
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/print/readme.txt
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
Print plugin for TinyMCE
|
||||
-----------------------------
|
||||
|
||||
About:
|
||||
This plugin adds a print button to TinyMCE.
|
||||
|
||||
Installation instructions:
|
||||
* Copy the print directory to the plugins directory of TinyMCE (/jscripts/tiny_mce/plugins).
|
||||
* Add plugin to TinyMCE plugin option list example: plugins : "print".
|
||||
|
||||
Initialization example:
|
||||
tinyMCE.init({
|
||||
theme : "advanced",
|
||||
mode : "textareas",
|
||||
plugins : "print",
|
||||
theme_advanced_buttons1_add : "print",
|
||||
});
|
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/save/editor_plugin.js
vendored
Normal file
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/save/editor_plugin.js
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
/* Import plugin specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('save','en,zh_cn,cs,fa,fr_ca,fr,de,pl');function TinyMCE_save_getControlHTML(control_name){switch(control_name){case "save":return '<img id="{$editor_id}_save" src="{$pluginurl}/images/save.gif" title="{$lang_save_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.switchClass(this,\'mceButtonNormal\');" onmousedown="tinyMCE.switchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceSave\');" />';}return "";}function TinyMCE_save_execCommand(editor_id,element,command,user_interface,value){switch(command){case "mceSave":var formObj=tinyMCE.selectedInstance.formElement.form;if(formObj){tinyMCE.triggerSave();for(var i=0;i<formObj.elements.length;i++){var elementId=formObj.elements[i].name?formObj.elements[i].name:formObj.elements[i].id;if(elementId.indexOf('mce_editor_')==0)formObj.elements[i].disabled=true;}tinyMCE.selectedInstance.formElement.form.submit();}else alert("Error: No form element found.");return true;}return false;}
|
43
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/save/editor_plugin_src.js
vendored
Normal file
43
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/save/editor_plugin_src.js
vendored
Normal file
@ -0,0 +1,43 @@
|
||||
/* Import plugin specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('save', 'en,zh_cn,cs,fa,fr_ca,fr,de,pl');
|
||||
|
||||
/**
|
||||
* Returns the HTML contents of the save control.
|
||||
*/
|
||||
function TinyMCE_save_getControlHTML(control_name) {
|
||||
switch (control_name) {
|
||||
case "save":
|
||||
return '<img id="{$editor_id}_save" src="{$pluginurl}/images/save.gif" title="{$lang_save_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.switchClass(this,\'mceButtonNormal\');" onmousedown="tinyMCE.switchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceSave\');" />';
|
||||
}
|
||||
return "";
|
||||
}
|
||||
|
||||
/**
|
||||
* Executes the save command.
|
||||
*/
|
||||
function TinyMCE_save_execCommand(editor_id, element, command, user_interface, value) {
|
||||
// Handle commands
|
||||
switch (command) {
|
||||
case "mceSave":
|
||||
var formObj = tinyMCE.selectedInstance.formElement.form;
|
||||
|
||||
if (formObj) {
|
||||
tinyMCE.triggerSave();
|
||||
|
||||
// Disable all UI form elements that TinyMCE created
|
||||
for (var i=0; i<formObj.elements.length; i++) {
|
||||
var elementId = formObj.elements[i].name ? formObj.elements[i].name : formObj.elements[i].id;
|
||||
|
||||
if (elementId.indexOf('mce_editor_') == 0)
|
||||
formObj.elements[i].disabled = true;
|
||||
}
|
||||
|
||||
tinyMCE.selectedInstance.formElement.form.submit();
|
||||
} else
|
||||
alert("Error: No form element found.");
|
||||
|
||||
return true;
|
||||
}
|
||||
// Pass to next handler in chain
|
||||
return false;
|
||||
}
|
19
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/save/readme.txt
vendored
Normal file
19
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/save/readme.txt
vendored
Normal file
@ -0,0 +1,19 @@
|
||||
Save plugin for TinyMCE
|
||||
(Dec 2004) by SlyD - d.herwald@dsh-elektronik.de
|
||||
--------------------------
|
||||
|
||||
About:
|
||||
Adds a "save" button that submits the form.
|
||||
|
||||
Installation instructions:
|
||||
* Copy the save directory to the plugins directory of TinyMCE (/jscripts/tiny_mce/plugins).
|
||||
* Add plugin to TinyMCE plugin option list example: plugins : "save".
|
||||
* Add the save button name to button list, example: theme_advanced_buttons3_add : "save".
|
||||
|
||||
Initialization example:
|
||||
tinyMCE.init({
|
||||
theme : "advanced",
|
||||
mode : "textareas",
|
||||
plugins : "save",
|
||||
theme_advanced_buttons3_add : "save"
|
||||
});
|
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/searchreplace/editor_plugin.js
vendored
Normal file
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/searchreplace/editor_plugin.js
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
/* Import theme specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('searchreplace','en,sv,zh_cn,fa,fr_ca,fr,de,pl');function TinyMCE_searchreplace_getControlHTML(control_name){switch(control_name){case "search":return '<img id="{$editor_id}_search" src="{$pluginurl}/images/search.gif" title="{$lang_searchreplace_search_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceSearch\',true);" />';case "replace":return '<img id="{$editor_id}_replace" src="{$pluginurl}/images/replace.gif" title="{$lang_searchreplace_replace_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceSearchReplace\',true);" />';}return "";}function TinyMCE_searchreplace_execCommand(editor_id,element,command,user_interface,value){function defValue(key,default_value){value[key]=typeof(value[key])=="undefined"?default_value:value[key];}function replaceSel(search_str,str){if(!tinyMCE.isMSIE){var sel=instance.contentWindow.getSelection();var rng=sel.getRangeAt(0);}else{var rng=instance.contentWindow.document.selection.createRange();}if(!tinyMCE.isMSIE){var doc=instance.contentWindow.document;if(str.indexOf(search_str)==-1){rng.deleteContents();rng.insertNode(rng.createContextualFragment(str));rng.collapse(false);}else{doc.execCommand("insertimage",false,"#mce_temp_url#");var elm=tinyMCE.getElementByAttributeValue(doc.body,"img","src","#mce_temp_url#");elm.parentNode.replaceChild(doc.createTextNode(str),elm);}}else{if(rng.item)rng.item(0).outerHTML=str;else rng.pasteHTML(str);}}var instance=tinyMCE.getInstanceById(editor_id);if(!value)value=new Array();defValue("editor_id",editor_id);defValue("searchstring","");defValue("replacestring",null);defValue("replacemode","none");defValue("casesensitive",false);defValue("backwards",false);defValue("wrap",false);defValue("wholeword",false);switch(command){case "mceResetSearch":tinyMCE.lastSearchRng=null;return true;case "mceSearch":if(user_interface){var template=new Array();if(value['replacestring']!=null){template['file']='../../plugins/searchreplace/replace.htm';template['width']=310;template['height']=180;}else{template['file']='../../plugins/searchreplace/search.htm';template['width']=280;template['height']=180;}tinyMCE.openWindow(template,value);}else{var win=tinyMCE.getInstanceById(editor_id).contentWindow;var doc=tinyMCE.getInstanceById(editor_id).contentWindow.document;var body=tinyMCE.getInstanceById(editor_id).contentWindow.document.body;if(body.innerHTML==""){alert(tinyMCE.getLang('lang_searchreplace_notfound'));return true;}if(value['replacemode']=="current"){replaceSel(value['string'],value['replacestring']);value['replacemode']="none";tinyMCE.execInstanceCommand(editor_id,'mceSearch',user_interface,value,false);return true;}if(tinyMCE.isMSIE){var rng=tinyMCE.lastSearchRng?tinyMCE.lastSearchRng:doc.selection.createRange();var flags=0;if(value['wholeword'])flags=flags|2;if(value['casesensitive'])flags=flags|4;if(value['replacemode']=="all"){while(rng.findText(value['string'],value['backwards']?-1:1,flags)){rng.scrollIntoView();rng.select();rng.collapse(false);replaceSel(value['string'],value['replacestring']);}alert(tinyMCE.getLang('lang_searchreplace_allreplaced'));return true;}if(rng.findText(value['string'],value['backwards']?-1:1,flags)){rng.scrollIntoView();rng.select();rng.collapse(value['backwards']);tinyMCE.lastSearchRng=rng;}else alert(tinyMCE.getLang('lang_searchreplace_notfound'));}else{if(value['replacemode']=="all"){while(win.find(value['string'],value['casesensitive'],value['backwards'],value['wrap'],value['wholeword'],false,false))replaceSel(value['string'],value['replacestring']);alert(tinyMCE.getLang('lang_searchreplace_allreplaced'));return true;}if(!win.find(value['string'],value['casesensitive'],value['backwards'],value['wrap'],value['wholeword'],false,false))alert(tinyMCE.getLang('lang_searchreplace_notfound'));}}return true;case "mceSearchReplace":value['replacestring']="";tinyMCE.execInstanceCommand(editor_id,'mceSearch',user_interface,value,false);return true;}return false;}function TinyMCE_searchreplace_handleNodeChange(editor_id,node,undo_index,undo_levels,visual_aid,any_selection){return true;}
|
173
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/searchreplace/editor_plugin_src.js
vendored
Normal file
173
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/searchreplace/editor_plugin_src.js
vendored
Normal file
@ -0,0 +1,173 @@
|
||||
/* Import theme specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('searchreplace', 'en,sv,zh_cn,fa,fr_ca,fr,de,pl');
|
||||
|
||||
function TinyMCE_searchreplace_getControlHTML(control_name) {
|
||||
switch (control_name) {
|
||||
case "search":
|
||||
return '<img id="{$editor_id}_search" src="{$pluginurl}/images/search.gif" title="{$lang_searchreplace_search_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceSearch\',true);" />';
|
||||
|
||||
case "replace":
|
||||
return '<img id="{$editor_id}_replace" src="{$pluginurl}/images/replace.gif" title="{$lang_searchreplace_replace_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" onclick="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceSearchReplace\',true);" />';
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
/**
|
||||
* Executes the search/replace commands.
|
||||
*/
|
||||
function TinyMCE_searchreplace_execCommand(editor_id, element, command, user_interface, value) {
|
||||
function defValue(key, default_value) {
|
||||
value[key] = typeof(value[key]) == "undefined" ? default_value : value[key];
|
||||
}
|
||||
|
||||
function replaceSel(search_str, str) {
|
||||
// Get current selection
|
||||
if (!tinyMCE.isMSIE) {
|
||||
var sel = instance.contentWindow.getSelection();
|
||||
var rng = sel.getRangeAt(0);
|
||||
} else {
|
||||
var rng = instance.contentWindow.document.selection.createRange();
|
||||
}
|
||||
|
||||
// Replace current one
|
||||
if (!tinyMCE.isMSIE) {
|
||||
var doc = instance.contentWindow.document;
|
||||
|
||||
// This way works when the replace doesn't contain the search string
|
||||
if (str.indexOf(search_str) == -1) {
|
||||
rng.deleteContents();
|
||||
rng.insertNode(rng.createContextualFragment(str));
|
||||
rng.collapse(false);
|
||||
} else {
|
||||
// Insert content ugly way! Needed to move selection to after replace item
|
||||
doc.execCommand("insertimage", false, "#mce_temp_url#");
|
||||
var elm = tinyMCE.getElementByAttributeValue(doc.body, "img", "src", "#mce_temp_url#");
|
||||
elm.parentNode.replaceChild(doc.createTextNode(str), elm);
|
||||
}
|
||||
} else {
|
||||
if (rng.item)
|
||||
rng.item(0).outerHTML = str;
|
||||
else
|
||||
rng.pasteHTML(str);
|
||||
}
|
||||
}
|
||||
|
||||
var instance = tinyMCE.getInstanceById(editor_id);
|
||||
|
||||
if (!value)
|
||||
value = new Array();
|
||||
|
||||
// Setup defualt values
|
||||
defValue("editor_id", editor_id);
|
||||
defValue("searchstring", "");
|
||||
defValue("replacestring", null);
|
||||
defValue("replacemode", "none");
|
||||
defValue("casesensitive", false);
|
||||
defValue("backwards", false);
|
||||
defValue("wrap", false);
|
||||
defValue("wholeword", false);
|
||||
|
||||
// Handle commands
|
||||
switch (command) {
|
||||
case "mceResetSearch":
|
||||
tinyMCE.lastSearchRng = null;
|
||||
return true;
|
||||
|
||||
case "mceSearch":
|
||||
if (user_interface) {
|
||||
// Open search dialog
|
||||
var template = new Array();
|
||||
|
||||
if (value['replacestring'] != null) {
|
||||
template['file'] = '../../plugins/searchreplace/replace.htm'; // Relative to theme
|
||||
template['width'] = 310;
|
||||
template['height'] = 180;
|
||||
} else {
|
||||
template['file'] = '../../plugins/searchreplace/search.htm'; // Relative to theme
|
||||
template['width'] = 280;
|
||||
template['height'] = 180;
|
||||
}
|
||||
|
||||
tinyMCE.openWindow(template, value);
|
||||
} else {
|
||||
var win = tinyMCE.getInstanceById(editor_id).contentWindow;
|
||||
var doc = tinyMCE.getInstanceById(editor_id).contentWindow.document;
|
||||
var body = tinyMCE.getInstanceById(editor_id).contentWindow.document.body;
|
||||
|
||||
// Whats the point
|
||||
if (body.innerHTML == "") {
|
||||
alert(tinyMCE.getLang('lang_searchreplace_notfound'));
|
||||
return true;
|
||||
}
|
||||
|
||||
// Handle replace current
|
||||
if (value['replacemode'] == "current") {
|
||||
replaceSel(value['string'], value['replacestring']);
|
||||
|
||||
// Search next one
|
||||
value['replacemode'] = "none";
|
||||
tinyMCE.execInstanceCommand(editor_id, 'mceSearch', user_interface, value, false);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
if (tinyMCE.isMSIE) {
|
||||
var rng = tinyMCE.lastSearchRng ? tinyMCE.lastSearchRng : doc.selection.createRange();
|
||||
var flags = 0;
|
||||
|
||||
if (value['wholeword'])
|
||||
flags = flags | 2;
|
||||
|
||||
if (value['casesensitive'])
|
||||
flags = flags | 4;
|
||||
|
||||
// Handle replace all mode
|
||||
if (value['replacemode'] == "all") {
|
||||
while (rng.findText(value['string'], value['backwards'] ? -1 : 1, flags)) {
|
||||
rng.scrollIntoView();
|
||||
rng.select();
|
||||
rng.collapse(false);
|
||||
replaceSel(value['string'], value['replacestring']);
|
||||
}
|
||||
|
||||
alert(tinyMCE.getLang('lang_searchreplace_allreplaced'));
|
||||
return true;
|
||||
}
|
||||
|
||||
if (rng.findText(value['string'], value['backwards'] ? -1 : 1, flags)) {
|
||||
rng.scrollIntoView();
|
||||
rng.select();
|
||||
rng.collapse(value['backwards']);
|
||||
tinyMCE.lastSearchRng = rng;
|
||||
} else
|
||||
alert(tinyMCE.getLang('lang_searchreplace_notfound'));
|
||||
} else {
|
||||
if (value['replacemode'] == "all") {
|
||||
while (win.find(value['string'], value['casesensitive'], value['backwards'], value['wrap'], value['wholeword'], false, false))
|
||||
replaceSel(value['string'], value['replacestring']);
|
||||
|
||||
alert(tinyMCE.getLang('lang_searchreplace_allreplaced'));
|
||||
return true;
|
||||
}
|
||||
|
||||
if (!win.find(value['string'], value['casesensitive'], value['backwards'], value['wrap'], value['wholeword'], false, false))
|
||||
alert(tinyMCE.getLang('lang_searchreplace_notfound'));
|
||||
}
|
||||
}
|
||||
return true;
|
||||
|
||||
case "mceSearchReplace":
|
||||
value['replacestring'] = "";
|
||||
|
||||
tinyMCE.execInstanceCommand(editor_id, 'mceSearch', user_interface, value, false);
|
||||
return true;
|
||||
}
|
||||
|
||||
// Pass to next handler in chain
|
||||
return false;
|
||||
}
|
||||
|
||||
function TinyMCE_searchreplace_handleNodeChange(editor_id, node, undo_index, undo_levels, visual_aid, any_selection) {
|
||||
return true;
|
||||
}
|
18
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/searchreplace/readme.txt
vendored
Normal file
18
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/searchreplace/readme.txt
vendored
Normal file
@ -0,0 +1,18 @@
|
||||
searchreplace plugin for TinyMCE
|
||||
-----------------------------
|
||||
|
||||
About:
|
||||
This plugin adds search/replace dialogs to TinyMCE.
|
||||
|
||||
Installation instructions:
|
||||
* Copy the searchreplace directory to the plugins directory of TinyMCE (/jscripts/tiny_mce/plugins).
|
||||
* Add plugin to TinyMCE plugin option list example: plugins : "searchreplace".
|
||||
* Add buttons "search,replace" to the button list.
|
||||
|
||||
Initialization example:
|
||||
tinyMCE.init({
|
||||
theme : "advanced",
|
||||
mode : "textareas",
|
||||
plugins : "searchreplace",
|
||||
theme_advanced_buttons1_add : "search,replace",
|
||||
});
|
88
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/searchreplace/replace.htm
vendored
Normal file
88
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/searchreplace/replace.htm
vendored
Normal file
@ -0,0 +1,88 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_searchreplace_replace_title}</title>
|
||||
<script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script language="javascript" type="text/javascript">
|
||||
<!--
|
||||
function init() {
|
||||
var formObj = document.forms[0];
|
||||
|
||||
formObj.searchstring.value = tinyMCE.getWindowArg("searchstring");
|
||||
formObj.replacestring.value = tinyMCE.getWindowArg("replacestring");
|
||||
formObj.casesensitivebox.checked = tinyMCE.getWindowArg("casesensitive");
|
||||
formObj.backwards[0].checked = tinyMCE.getWindowArg("backwards");
|
||||
formObj.backwards[1].checked = !tinyMCE.getWindowArg("backwards");
|
||||
// formObj.wrapatend.checked = tinyMCE.getWindowArg("wrap");
|
||||
// formObj.wholeword.checked = tinyMCE.getWindowArg("wholeword");
|
||||
|
||||
tinyMCE.execInstanceCommand(tinyMCE.getWindowArg("editor_id"), "mceResetSearch", false, {dummy : ""}, false);
|
||||
window.focus();
|
||||
}
|
||||
|
||||
function searchNext(replacemode) {
|
||||
var formObj = document.forms[0];
|
||||
|
||||
// Whats the point?
|
||||
if (formObj.searchstring.value == "" || formObj.searchstring.value == formObj.replacestring.value)
|
||||
return;
|
||||
|
||||
// Do search
|
||||
tinyMCE.execInstanceCommand(tinyMCE.getWindowArg("editor_id"), 'mceSearch', false, {
|
||||
string : formObj.searchstring.value,
|
||||
replacestring : formObj.replacestring.value,
|
||||
replacemode : replacemode,
|
||||
casesensitive : formObj.casesensitivebox.checked,
|
||||
backwards : formObj.backwards[0].checked
|
||||
// wrap : formObj.wrapatend.checked,
|
||||
// wholeword : formObj.wholeword.checked
|
||||
}, false);
|
||||
}
|
||||
|
||||
function cancelAction() {
|
||||
top.close();
|
||||
}
|
||||
//-->
|
||||
</script>
|
||||
</head>
|
||||
<body onload="init();" style="margin: 4px;">
|
||||
<form onsubmit="searchNext('none');return false;">
|
||||
<table border="0" cellspacing="0" cellpadding="2">
|
||||
<tr>
|
||||
<td>{$lang_searchreplace_findwhat}: </td>
|
||||
<td><input type="text" name="searchstring" style="width: 200px" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{$lang_searchreplace_replacewith}: </td>
|
||||
<td><input type="text" name="replacestring" style="width: 200px" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2"><table border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td>{$lang_searchreplace_direction}: </td>
|
||||
<td><input name="backwards" class="radio" type="radio" value="true" /></td>
|
||||
<td>{$lang_searchreplace_up}</td>
|
||||
<td><input name="backwards" class="radio" type="radio" value="false" /></td>
|
||||
<td>{$lang_searchreplace_down}</td>
|
||||
</tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2"><table border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td><input class="checkbox" type="checkbox" name="casesensitivebox" value="true" /></td>
|
||||
<td>{$lang_searchreplace_case}</td>
|
||||
</tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
</table>
|
||||
<table border="0" width="100%" cellspacing="0" cellpadding="4">
|
||||
<tr>
|
||||
<td><input name="findBtn" type="button" id="findBtn" value="{$lang_searchreplace_findnext}" onclick="searchNext('none');" /></td>
|
||||
<td><input name="replaceBtn" type="button" id="replaceBtn" value="{$lang_searchreplace_replace}" onclick="searchNext('current');" /></td>
|
||||
<td><input name="replaceBtn" type="button" id="replaceAllBtn" value="{$lang_searchreplace_replaceall}" onclick="searchNext('all');" /></td>
|
||||
<td align="right"><input name="cancelBtn" type="button" id="cancelBtn" value="{$lang_searchreplace_cancel}" onclick="cancelAction();" /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
77
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/searchreplace/search.htm
vendored
Normal file
77
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/searchreplace/search.htm
vendored
Normal file
@ -0,0 +1,77 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_searchreplace_search_title}</title>
|
||||
<script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script language="javascript" type="text/javascript">
|
||||
<!--
|
||||
function init() {
|
||||
var formObj = document.forms[0];
|
||||
|
||||
formObj.searchstring.value = tinyMCE.getWindowArg("searchstring");
|
||||
formObj.casesensitivebox.checked = tinyMCE.getWindowArg("casesensitive");
|
||||
formObj.backwards[0].checked = tinyMCE.getWindowArg("backwards");
|
||||
formObj.backwards[1].checked = !tinyMCE.getWindowArg("backwards");
|
||||
// formObj.wrapatend.checked = tinyMCE.getWindowArg("wrap");
|
||||
// formObj.wholeword.checked = tinyMCE.getWindowArg("wholeword");
|
||||
|
||||
tinyMCE.execInstanceCommand(tinyMCE.getWindowArg("editor_id"), "mceResetSearch", false, {dummy : ""}, false);
|
||||
window.focus();
|
||||
}
|
||||
|
||||
function searchNext() {
|
||||
var formObj = document.forms[0];
|
||||
|
||||
if (formObj.searchstring.value == "")
|
||||
return;
|
||||
|
||||
// Do search
|
||||
tinyMCE.execInstanceCommand(tinyMCE.getWindowArg("editor_id"), 'mceSearch', false, {
|
||||
string : formObj.searchstring.value,
|
||||
casesensitive : formObj.casesensitivebox.checked,
|
||||
backwards : formObj.backwards[0].checked
|
||||
// wrap : formObj.wrapatend.checked,
|
||||
// wholeword : formObj.wholeword.checked
|
||||
}, false);
|
||||
}
|
||||
|
||||
function cancelAction() {
|
||||
top.close();
|
||||
}
|
||||
//-->
|
||||
</script>
|
||||
</head>
|
||||
<body onload="init();" style="margin: 4px;">
|
||||
<form onsubmit="searchNext();return false;">
|
||||
<table border="0" cellspacing="0" cellpadding="2">
|
||||
<tr>
|
||||
<td>{$lang_searchreplace_findwhat}: <input type="text" name="searchstring" style="width: 200px" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><table border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td>{$lang_searchreplace_direction}: </td>
|
||||
<td><input name="backwards" class="radio" type="radio" value="true" /></td>
|
||||
<td>{$lang_searchreplace_up}</td>
|
||||
<td><input name="backwards" class="radio" type="radio" value="false" /></td>
|
||||
<td>{$lang_searchreplace_down}</td>
|
||||
</tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><table border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td><input class="checkbox" type="checkbox" name="casesensitivebox" value="true" /></td>
|
||||
<td>{$lang_searchreplace_case}</td>
|
||||
</tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
</table>
|
||||
<table border="0" width="100%" cellspacing="0" cellpadding="4">
|
||||
<tr>
|
||||
<td><input name="findBtn" type="submit" id="findBtn" value="{$lang_searchreplace_findnext}" /></td>
|
||||
<td align="right"><input name="cancelBtn" type="button" id="cancelBtn" value="{$lang_searchreplace_cancel}" onclick="cancelAction();" /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
139
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/table/cell.htm
vendored
Normal file
139
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/table/cell.htm
vendored
Normal file
@ -0,0 +1,139 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_table_cell_title}</title>
|
||||
<script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script language="javascript" type="text/javascript">
|
||||
// Disable auto resize
|
||||
tinyMCE.getWindowArg('mce_windowresize', false);
|
||||
|
||||
function insertTable() {
|
||||
if (window.opener) {
|
||||
var args = new Array();
|
||||
|
||||
args["width"] = document.forms[0].width.value;
|
||||
args["height"] = document.forms[0].height.value;
|
||||
args["align"] = document.forms[0].align.options[document.forms[0].align.selectedIndex].value;
|
||||
args["valign"] = document.forms[0].valign.options[document.forms[0].valign.selectedIndex].value;
|
||||
args["className"] = document.forms[0].styleSelect.options[document.forms[0].styleSelect.selectedIndex].value;
|
||||
args["bordercolor"] = document.forms[0].bordercolor.value;
|
||||
args["bgcolor"] = document.forms[0].bgcolor.value;
|
||||
|
||||
window.opener.tinyMCE.execCommand("mceTableCellProps", false, args);
|
||||
top.close();
|
||||
}
|
||||
}
|
||||
|
||||
function init() {
|
||||
if (tinyMCE.settings['table_color_fields']) {
|
||||
document.getElementById('colors').style.display = tinyMCE.isMSIE ? 'block' : 'table-row';
|
||||
TinyMCEPlugin_onLoad(); // Resize again
|
||||
}
|
||||
|
||||
document.forms[0].bordercolor.value = tinyMCE.getWindowArg('bordercolor');
|
||||
document.forms[0].bgcolor.value = tinyMCE.getWindowArg('bgcolor');
|
||||
|
||||
for (var i=0; i<document.forms[0].align.options.length; i++) {
|
||||
if (document.forms[0].align.options[i].value == tinyMCE.getWindowArg('align'))
|
||||
document.forms[0].align.options.selectedIndex = i;
|
||||
}
|
||||
|
||||
for (var i=0; i<document.forms[0].valign.options.length; i++) {
|
||||
if (document.forms[0].valign.options[i].value == tinyMCE.getWindowArg('valign'))
|
||||
document.forms[0].valign.options.selectedIndex = i;
|
||||
}
|
||||
|
||||
var className = tinyMCE.getWindowArg('className');
|
||||
var styleSelectElm = document.forms[0].styleSelect;
|
||||
var stylesAr = tinyMCE.getParam('theme_advanced_styles', false);
|
||||
if (stylesAr) {
|
||||
stylesAr = stylesAr.split(';');
|
||||
|
||||
for (var i=0; i<stylesAr.length; i++) {
|
||||
var key, value;
|
||||
|
||||
key = stylesAr[i].split('=')[0];
|
||||
value = stylesAr[i].split('=')[1];
|
||||
|
||||
styleSelectElm.options[styleSelectElm.length] = new Option(key, value);
|
||||
if (value == className)
|
||||
styleSelectElm.options.selectedIndex = styleSelectElm.options.length-1;
|
||||
}
|
||||
} else {
|
||||
var csses = tinyMCE.getCSSClasses(tinyMCE.getWindowArg('editor_id'));
|
||||
for (var i=0; i<csses.length; i++) {
|
||||
styleSelectElm.options[styleSelectElm.length] = new Option(csses[i], csses[i]);
|
||||
if (csses[i] == className)
|
||||
styleSelectElm.options.selectedIndex = styleSelectElm.options.length-1;
|
||||
}
|
||||
}
|
||||
|
||||
var formObj = document.forms[0];
|
||||
formObj.width.value = tinyMCE.getWindowArg('width');
|
||||
formObj.height.value = tinyMCE.getWindowArg('height');
|
||||
|
||||
// Autoresize and focus
|
||||
TinyMCEPopup_autoResize();
|
||||
window.focus();
|
||||
}
|
||||
|
||||
function cancelAction() {
|
||||
top.close();
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body onload="window.focus();init();">
|
||||
<form onsubmit="insertTable();return false;">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="200">
|
||||
<tr>
|
||||
<td align="center" valign="middle"><table border="0" cellpadding="4" cellspacing="0">
|
||||
<tr>
|
||||
<td colspan="4" class="title">{$lang_table_cell_title}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{$lang_insert_table_align}:</td>
|
||||
<td><select name="align">
|
||||
<option value="">{$lang_insert_table_align_default}</option>
|
||||
<option value="center">{$lang_insert_table_align_middle}</option>
|
||||
<option value="left">{$lang_insert_table_align_left}</option>
|
||||
<option value="right">{$lang_insert_table_align_right}</option>
|
||||
</select></td>
|
||||
<td>{$lang_insert_table_class}:</td>
|
||||
<td><select name="styleSelect">
|
||||
<option value="" selected="selected">-- {$lang_theme_style_select} --</option>
|
||||
</select></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{$lang_insert_table_valign}:</td>
|
||||
<td><select name="valign">
|
||||
<option value="">{$lang_insert_table_align_default}</option>
|
||||
<option value="top">{$lang_insert_table_align_top}</option>
|
||||
<option value="middle">{$lang_insert_table_align_middle}</option>
|
||||
<option value="bottom">{$lang_insert_table_align_bottom}</option>
|
||||
</select></td>
|
||||
<td> </td>
|
||||
<td> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{$lang_insert_table_width}:</td>
|
||||
<td><input name="width" type="text" id="width" value="" size="4" maxlength="4"></td>
|
||||
<td>{$lang_insert_table_height}: </td>
|
||||
<td><input name="height" type="text" id="height" value="" size="4" maxlength="4"></td>
|
||||
</tr>
|
||||
<tr id="colors" style="display: none">
|
||||
<td>{$lang_table_bordercolor}:</td>
|
||||
<td><input name="bordercolor" type="text" id="bordercolor" value="" size="9" maxlength="7"></td>
|
||||
<td>{$lang_table_bgcolor}:</td>
|
||||
<td><input name="bgcolor" type="text" id="bgcolor" value="" size="9" maxlength="7"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><input type="button" id="insert" name="insert" value="{$lang_update}" onclick="insertTable();"></td>
|
||||
<td align="right"> </td>
|
||||
<td align="right"> </td>
|
||||
<td align="right"><input type="button" id="cancel" name="cancel" value="{$lang_cancel}" onclick="cancelAction();"></td>
|
||||
</tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/table/editor_plugin.js
vendored
Normal file
2
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/table/editor_plugin.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1141
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/table/editor_plugin_src.js
vendored
Normal file
1141
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/table/editor_plugin_src.js
vendored
Normal file
File diff suppressed because it is too large
Load Diff
60
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/table/merge_cells.htm
vendored
Normal file
60
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/table/merge_cells.htm
vendored
Normal file
@ -0,0 +1,60 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_table_merge_cells_title}</title>
|
||||
<script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script language="javascript" type="text/javascript">
|
||||
// Disable auto resize
|
||||
tinyMCE.getWindowArg('mce_windowresize', false);
|
||||
|
||||
function init() {
|
||||
var formObj = document.forms[0];
|
||||
|
||||
formObj.numcols.value = tinyMCE.getWindowArg('numcols', 1);
|
||||
formObj.numrows.value = tinyMCE.getWindowArg('numrows', 1);
|
||||
|
||||
// Autoresize and focus
|
||||
TinyMCEPopup_autoResize();
|
||||
window.focus();
|
||||
}
|
||||
|
||||
function mergeCells() {
|
||||
if (window.opener) {
|
||||
var args = new Array();
|
||||
var formObj = document.forms[0];
|
||||
|
||||
args["numcols"] = formObj.numcols.value;
|
||||
args["numrows"] = formObj.numrows.value;
|
||||
|
||||
window.opener.tinyMCE.execCommand("mceTableMergeCells", false, args);
|
||||
top.close();
|
||||
}
|
||||
}
|
||||
|
||||
function cancelAction() {
|
||||
top.close();
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body onload="window.focus();init();" style="margin: 8px">
|
||||
<form onsubmit="insertTable();return false;">
|
||||
<fieldset>
|
||||
<legend>{$lang_table_merge_cells_title}</legend>
|
||||
<table border="0" cellpadding="0" cellspacing="3" width="200">
|
||||
<tr>
|
||||
<td>{$lang_insert_table_cols}:</td>
|
||||
<td align="right"><input type="text" name="numcols" value="" style="width: 30px" /></td>
|
||||
<td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{$lang_insert_table_rows}:</td>
|
||||
<td align="right"><input type="text" name="numrows" value="" style="width: 30px" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><input type="button" id="insert" name="insert" value="{$lang_update}" onclick="mergeCells();"></td>
|
||||
<td align="right"><input type="button" id="cancel" name="cancel" value="{$lang_cancel}" onclick="cancelAction();"></td>
|
||||
</tr>
|
||||
</table>
|
||||
</fieldset>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
44
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/table/readme.txt
vendored
Normal file
44
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/table/readme.txt
vendored
Normal file
@ -0,0 +1,44 @@
|
||||
Table plugin for TinyMCE
|
||||
------------------------------
|
||||
|
||||
Installation instructions:
|
||||
* Copy the table directory to the plugins directory of TinyMCE (/jscripts/tiny_mce/plugins).
|
||||
* Add plugin to TinyMCE plugin option list example: plugins : "table".
|
||||
* Add the table button name to button list, example: theme_advanced_buttons3_add_before : "tablecontrols".
|
||||
|
||||
Initialization example:
|
||||
tinyMCE.init({
|
||||
theme : "advanced",
|
||||
mode : "textareas",
|
||||
plugins : "table",
|
||||
theme_advanced_buttons3_add_before : "tablecontrols"
|
||||
});
|
||||
|
||||
Table controls:
|
||||
tablecontrols All table control below and some separators between them.
|
||||
table Insert table control.
|
||||
row_props Edit row properties (tr).
|
||||
cell_props Edit cell properties (td).
|
||||
delete_col Delete column control.
|
||||
delete_row Delete row control.
|
||||
col_after Column after control.
|
||||
col_before Column before control.
|
||||
row_after Row after control.
|
||||
row_before Row before control.
|
||||
row_after Row after control.
|
||||
row_before Row before control.
|
||||
|
||||
Table plugin commands:
|
||||
mceInsertTable Inserts a new table at cursor location the default size is 2x2.
|
||||
If the value parameter is specified it should contain a name/value array,
|
||||
this array has the following options cols, rows, border, cellspacing, cellpadding.
|
||||
The default border is set to: 0.
|
||||
mceTableInsertRowBefore Inserts a row before/above the current cursor location.
|
||||
mceTableInsertRowAfter Inserts a row after/under the current cursor location.
|
||||
mceTableDeleteRow Deletes the row at the current cursor location.
|
||||
mceTableInsertColBefore Inserts a column before the current cursor location.
|
||||
mceTableInsertColAfter Inserts a column after the current cursor location.
|
||||
mceTableDeleteCol Deletes the column at the current cursor location.
|
||||
|
||||
Options:
|
||||
table_color_fields If set to true, tables dialogs will have color fields.
|
131
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/table/row.htm
vendored
Normal file
131
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/table/row.htm
vendored
Normal file
@ -0,0 +1,131 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_table_row_title}</title>
|
||||
<script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script language="javascript" type="text/javascript">
|
||||
// Disable auto resize
|
||||
tinyMCE.getWindowArg('mce_windowresize', false);
|
||||
|
||||
function insertTable() {
|
||||
if (window.opener) {
|
||||
var args = new Array();
|
||||
|
||||
args["height"] = document.forms[0].height.value;
|
||||
args["align"] = document.forms[0].align.options[document.forms[0].align.selectedIndex].value;
|
||||
args["valign"] = document.forms[0].valign.options[document.forms[0].valign.selectedIndex].value;
|
||||
args["className"] = document.forms[0].styleSelect.options[document.forms[0].styleSelect.selectedIndex].value;
|
||||
args["bordercolor"] = document.forms[0].bordercolor.value;
|
||||
args["bgcolor"] = document.forms[0].bgcolor.value;
|
||||
|
||||
window.opener.tinyMCE.execCommand("mceTableRowProps", false, args);
|
||||
top.close();
|
||||
}
|
||||
}
|
||||
|
||||
function init() {
|
||||
if (tinyMCE.settings['table_color_fields']) {
|
||||
document.getElementById('colors').style.display = tinyMCE.isMSIE ? 'block' : 'table-row';
|
||||
TinyMCEPlugin_onLoad(); // Resize again
|
||||
}
|
||||
|
||||
document.forms[0].bordercolor.value = tinyMCE.getWindowArg('bordercolor');
|
||||
document.forms[0].bgcolor.value = tinyMCE.getWindowArg('bgcolor');
|
||||
|
||||
for (var i=0; i<document.forms[0].align.options.length; i++) {
|
||||
if (document.forms[0].align.options[i].value == tinyMCE.getWindowArg('align'))
|
||||
document.forms[0].align.options.selectedIndex = i;
|
||||
}
|
||||
|
||||
for (var i=0; i<document.forms[0].valign.options.length; i++) {
|
||||
if (document.forms[0].valign.options[i].value == tinyMCE.getWindowArg('valign'))
|
||||
document.forms[0].valign.options.selectedIndex = i;
|
||||
}
|
||||
|
||||
var className = tinyMCE.getWindowArg('className');
|
||||
var styleSelectElm = document.forms[0].styleSelect;
|
||||
var stylesAr = tinyMCE.getParam('theme_advanced_styles', false);
|
||||
if (stylesAr) {
|
||||
stylesAr = stylesAr.split(';');
|
||||
|
||||
for (var i=0; i<stylesAr.length; i++) {
|
||||
var key, value;
|
||||
|
||||
key = stylesAr[i].split('=')[0];
|
||||
value = stylesAr[i].split('=')[1];
|
||||
|
||||
styleSelectElm.options[styleSelectElm.length] = new Option(key, value);
|
||||
if (value == className)
|
||||
styleSelectElm.options.selectedIndex = styleSelectElm.options.length-1;
|
||||
}
|
||||
} else {
|
||||
var csses = tinyMCE.getCSSClasses(tinyMCE.getWindowArg('editor_id'));
|
||||
for (var i=0; i<csses.length; i++) {
|
||||
styleSelectElm.options[styleSelectElm.length] = new Option(csses[i], csses[i]);
|
||||
if (csses[i] == className)
|
||||
styleSelectElm.options.selectedIndex = styleSelectElm.options.length-1;
|
||||
}
|
||||
}
|
||||
|
||||
var formObj = document.forms[0];
|
||||
formObj.height.value = tinyMCE.getWindowArg('height');
|
||||
|
||||
// Autoresize and focus
|
||||
TinyMCEPopup_autoResize();
|
||||
window.focus();
|
||||
}
|
||||
|
||||
function cancelAction() {
|
||||
top.close();
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body onload="window.focus();init();">
|
||||
<form onsubmit="insertTable();return false;">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="200">
|
||||
<tr>
|
||||
<td align="center" valign="middle"><table border="0" cellpadding="4" cellspacing="0">
|
||||
<tr>
|
||||
<td colspan="4" class="title">{$lang_table_row_title}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{$lang_insert_table_align}:</td>
|
||||
<td><select name="align">
|
||||
<option value="">{$lang_insert_table_align_default}</option>
|
||||
<option value="center">{$lang_insert_table_align_middle}</option>
|
||||
<option value="left">{$lang_insert_table_align_left}</option>
|
||||
<option value="right">{$lang_insert_table_align_right}</option>
|
||||
</select></td>
|
||||
<td>{$lang_insert_table_class}:</td>
|
||||
<td><select name="styleSelect">
|
||||
<option value="" selected="selected">-- {$lang_theme_style_select} --</option>
|
||||
</select></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{$lang_insert_table_valign}:</td>
|
||||
<td><select name="valign">
|
||||
<option value="">{$lang_insert_table_align_default}</option>
|
||||
<option value="top">{$lang_insert_table_align_top}</option>
|
||||
<option value="middle">{$lang_insert_table_align_middle}</option>
|
||||
<option value="bottom">{$lang_insert_table_align_bottom}</option>
|
||||
</select></td>
|
||||
<td>{$lang_insert_table_height}: </td>
|
||||
<td><input name="height" type="text" id="height" value="" size="4" maxlength="4" /></td>
|
||||
</tr>
|
||||
<tr id="colors" style="display: none">
|
||||
<td>{$lang_table_bordercolor}:</td>
|
||||
<td><input name="bordercolor" type="text" id="bordercolor" value="" size="9" maxlength="7"></td>
|
||||
<td>{$lang_table_bgcolor}:</td>
|
||||
<td><input name="bgcolor" type="text" id="bgcolor" value="" size="9" maxlength="7"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><input type="button" id="insert" name="insert" value="{$lang_update}" onclick="insertTable();"></td>
|
||||
<td align="right"> </td>
|
||||
<td align="right"> </td>
|
||||
<td align="right"><input type="button" id="cancel" name="cancel" value="{$lang_cancel}" onclick="cancelAction();"></td>
|
||||
</tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
156
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/table/table.htm
vendored
Normal file
156
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/table/table.htm
vendored
Normal file
@ -0,0 +1,156 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_insert_table_title}</title>
|
||||
<script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script language="javascript" type="text/javascript">
|
||||
// Disable auto resize
|
||||
tinyMCE.getWindowArg('mce_windowresize', false);
|
||||
|
||||
function insertTable() {
|
||||
if (window.opener) {
|
||||
var args = new Array();
|
||||
|
||||
args["cols"] = document.forms[0].cols.value;
|
||||
args["rows"] = document.forms[0].rows.value;
|
||||
args["border"] = document.forms[0].border.value;
|
||||
args["cellpadding"] = document.forms[0].cellpadding.value;
|
||||
args["cellspacing"] = document.forms[0].cellspacing.value;
|
||||
args["width"] = document.forms[0].width.value;
|
||||
args["height"] = document.forms[0].height.value;
|
||||
args["bordercolor"] = document.forms[0].bordercolor.value;
|
||||
args["bgcolor"] = document.forms[0].bgcolor.value;
|
||||
args["align"] = document.forms[0].align.options[document.forms[0].align.selectedIndex].value;
|
||||
args["className"] = document.forms[0].styleSelect.options[document.forms[0].styleSelect.selectedIndex].value;
|
||||
|
||||
window.opener.tinyMCE.execCommand("mceInsertTable", false, args);
|
||||
top.close();
|
||||
}
|
||||
}
|
||||
|
||||
function init() {
|
||||
if (tinyMCE.settings['table_color_fields']) {
|
||||
document.getElementById('colors').style.display = tinyMCE.isMSIE ? 'block' : 'table-row';
|
||||
TinyMCEPlugin_onLoad(); // Resize again
|
||||
}
|
||||
|
||||
for (var i=0; i<document.forms[0].align.options.length; i++) {
|
||||
if (document.forms[0].align.options[i].value == tinyMCE.getWindowArg('align'))
|
||||
document.forms[0].align.options.selectedIndex = i;
|
||||
}
|
||||
|
||||
var className = tinyMCE.getWindowArg('className');
|
||||
var styleSelectElm = document.forms[0].styleSelect;
|
||||
var stylesAr = tinyMCE.getParam('theme_advanced_styles', false);
|
||||
if (stylesAr) {
|
||||
stylesAr = stylesAr.split(';');
|
||||
|
||||
for (var i=0; i<stylesAr.length; i++) {
|
||||
var key, value;
|
||||
|
||||
key = stylesAr[i].split('=')[0];
|
||||
value = stylesAr[i].split('=')[1];
|
||||
|
||||
styleSelectElm.options[styleSelectElm.length] = new Option(key, value);
|
||||
if (value == className)
|
||||
styleSelectElm.options.selectedIndex = styleSelectElm.options.length-1;
|
||||
}
|
||||
} else {
|
||||
var csses = tinyMCE.getCSSClasses(tinyMCE.getWindowArg('editor_id'));
|
||||
for (var i=0; i<csses.length; i++) {
|
||||
styleSelectElm.options[styleSelectElm.length] = new Option(csses[i], csses[i]);
|
||||
if (csses[i] == className)
|
||||
styleSelectElm.options.selectedIndex = styleSelectElm.options.length-1;
|
||||
}
|
||||
}
|
||||
|
||||
if (tinyMCE.getWindowArg('action') == "update") {
|
||||
document.forms[0].cols.disabled = true;
|
||||
document.forms[0].rows.disabled = true;
|
||||
}
|
||||
|
||||
var formObj = document.forms[0];
|
||||
formObj.cols.value = tinyMCE.getWindowArg('cols');
|
||||
formObj.rows.value = tinyMCE.getWindowArg('rows');
|
||||
formObj.border.value = tinyMCE.getWindowArg('border');
|
||||
formObj.cellpadding.value = tinyMCE.getWindowArg('cellpadding');
|
||||
formObj.cellspacing.value = tinyMCE.getWindowArg('cellspacing');
|
||||
formObj.width.value = tinyMCE.getWindowArg('width');
|
||||
formObj.height.value = tinyMCE.getWindowArg('height');
|
||||
formObj.bordercolor.value = tinyMCE.getWindowArg('bordercolor');
|
||||
formObj.bgcolor.value = tinyMCE.getWindowArg('bgcolor');
|
||||
formObj.insert.value = tinyMCE.getLang('lang_' + tinyMCE.getWindowArg('action'), 'Insert', true);
|
||||
|
||||
// Autoresize and focus
|
||||
TinyMCEPopup_autoResize();
|
||||
window.focus();
|
||||
}
|
||||
|
||||
function cancelAction() {
|
||||
top.close();
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body onload="window.focus();init();">
|
||||
<form onsubmit="insertTable();return false;">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="200">
|
||||
<tr>
|
||||
<td align="center" valign="middle"><table border="0" cellpadding="4" cellspacing="0">
|
||||
<tr>
|
||||
<td colspan="4" class="title">{$lang_insert_table_title}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{$lang_insert_table_cols}:</td>
|
||||
<td><input name="cols" type="text" id="cols" value="" size="3" maxlength="3"></td>
|
||||
<td>{$lang_insert_table_rows}:</td>
|
||||
<td><input name="rows" type="text" id="rows" value="" size="3" maxlength="3"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{$lang_insert_table_cellpadding}:</td>
|
||||
<td><input name="cellpadding" type="text" id="cellpadding" value="" size="3" maxlength="3"></td>
|
||||
<td>{$lang_insert_table_cellspacing}:</td>
|
||||
<td><input name="cellspacing" type="text" id="cellspacing" value="" size="3" maxlength="3"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{$lang_insert_table_align}:</td>
|
||||
<td><select name="align">
|
||||
<option value="">{$lang_insert_table_align_default}</option>
|
||||
<option value="center">{$lang_insert_table_align_middle}</option>
|
||||
<option value="left">{$lang_insert_table_align_left}</option>
|
||||
<option value="right">{$lang_insert_table_align_right}</option>
|
||||
</select></td>
|
||||
<td>{$lang_insert_table_border}:</td>
|
||||
<td><input name="border" type="text" id="border" value="" size="3" maxlength="3"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{$lang_insert_table_width}:</td>
|
||||
<td><input name="width" type="text" id="width" value="" size="4" maxlength="4"></td>
|
||||
<td>{$lang_insert_table_height}: </td>
|
||||
<td><input name="height" type="text" id="height" value="" size="4" maxlength="4"></td>
|
||||
</tr>
|
||||
<tr id="colors" style="display: none">
|
||||
<td>{$lang_table_bordercolor}:</td>
|
||||
<td><input name="bordercolor" type="text" id="bordercolor" value="" size="9" maxlength="7"></td>
|
||||
<td>{$lang_table_bgcolor}:</td>
|
||||
<td><input name="bgcolor" type="text" id="bgcolor" value="" size="9" maxlength="7"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{$lang_insert_table_class}:</td>
|
||||
<td>
|
||||
<select name="styleSelect">
|
||||
<option value="" selected>-- {$lang_theme_style_select} --</option>
|
||||
</select></td>
|
||||
<td align="right"> </td>
|
||||
<td align="right"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><input type="button" id="insert" name="insert" value="{$lang_insert}" onclick="insertTable();"></td>
|
||||
<td align="right"> </td>
|
||||
<td align="right"> </td>
|
||||
<td align="right"><input type="button" id="cancel" name="cancel" value="{$lang_cancel}" onclick="cancelAction();"></td>
|
||||
</tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
7
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/zoom/editor_plugin.js
vendored
Normal file
7
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/zoom/editor_plugin.js
vendored
Normal file
@ -0,0 +1,7 @@
|
||||
/* Import plugin specific language pack */
|
||||
function TinyMCE_zoom_getControlHTML(control_name){if(!tinyMCE.isMSIE||tinyMCE.isMSIE5_0)return "";switch(control_name){case "zoom":return '<select id="{$editor_id}_formatSelect" name="{$editor_id}_zoomSelect" onchange="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceZoom\',false,this.options[this.selectedIndex].value);" class="mceSelectList">\
|
||||
<option value="100%">+ 100%</option>\
|
||||
<option value="150%">+ 150%</option>\
|
||||
<option value="200%">+ 200%</option>\
|
||||
<option value="250%">+ 250%</option>\
|
||||
</select>';}return "";}function TinyMCE_zoom_execCommand(editor_id,element,command,user_interface,value){switch(command){case "mceZoom":tinyMCE.getInstanceById(editor_id).contentDocument.body.style.zoom=value;tinyMCE.getInstanceById(editor_id).contentDocument.body.style.mozZoom=value;return true;}return false;}
|
38
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/zoom/editor_plugin_src.js
vendored
Normal file
38
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/zoom/editor_plugin_src.js
vendored
Normal file
@ -0,0 +1,38 @@
|
||||
/* Import plugin specific language pack */
|
||||
//tinyMCE.importPluginLanguagePack('zoom', 'en,sv,pt,fr_ca,fr,de');
|
||||
|
||||
/**
|
||||
* Returns the HTML contents of the zoom control.
|
||||
*/
|
||||
function TinyMCE_zoom_getControlHTML(control_name) {
|
||||
if (!tinyMCE.isMSIE || tinyMCE.isMSIE5_0)
|
||||
return "";
|
||||
|
||||
switch (control_name) {
|
||||
case "zoom":
|
||||
return '<select id="{$editor_id}_formatSelect" name="{$editor_id}_zoomSelect" onchange="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceZoom\',false,this.options[this.selectedIndex].value);" class="mceSelectList">\
|
||||
<option value="100%">+ 100%</option>\
|
||||
<option value="150%">+ 150%</option>\
|
||||
<option value="200%">+ 200%</option>\
|
||||
<option value="250%">+ 250%</option>\
|
||||
</select>';
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
/**
|
||||
* Executes the mceZoom command.
|
||||
*/
|
||||
function TinyMCE_zoom_execCommand(editor_id, element, command, user_interface, value) {
|
||||
// Handle commands
|
||||
switch (command) {
|
||||
case "mceZoom":
|
||||
tinyMCE.getInstanceById(editor_id).contentDocument.body.style.zoom = value;
|
||||
tinyMCE.getInstanceById(editor_id).contentDocument.body.style.mozZoom = value;
|
||||
return true;
|
||||
}
|
||||
|
||||
// Pass to next handler in chain
|
||||
return false;
|
||||
}
|
22
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/zoom/readme.txt
vendored
Normal file
22
phpgwapi/js/tinymce/jscripts/tiny_mce/plugins/zoom/readme.txt
vendored
Normal file
@ -0,0 +1,22 @@
|
||||
Zoom plugin for TinyMCE
|
||||
--------------------------
|
||||
|
||||
About:
|
||||
Adds a zoom drop list in MSIE5.5+, this plugin was mostly created to
|
||||
show how to add custom droplists as plugins.
|
||||
|
||||
Installation instructions:
|
||||
* Copy the zoom directory to the plugins directory of TinyMCE (/jscripts/tiny_mce/plugins).
|
||||
* Add plugin to TinyMCE plugin option list example: plugins : "zoom".
|
||||
* Add the preview button name to button list, example: theme_advanced_buttons3_add : "zoom".
|
||||
|
||||
Initialization example:
|
||||
tinyMCE.init({
|
||||
theme : "advanced",
|
||||
mode : "textareas",
|
||||
plugins : "preview",
|
||||
theme_advanced_buttons3_add : "zoom"
|
||||
});
|
||||
|
||||
Requirement:
|
||||
This plugin requires MSIE on Mozilla the button will not be visible.
|
52
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/anchor.htm
vendored
Normal file
52
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/anchor.htm
vendored
Normal file
@ -0,0 +1,52 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_insert_anchor_title}</title>
|
||||
<script language="javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script language="javascript">
|
||||
// Disable auto resize
|
||||
tinyMCE.getWindowArg('mce_windowresize', false);
|
||||
|
||||
function init() {
|
||||
document.forms[0].anchorName.value = tinyMCE.getWindowArg('name');
|
||||
document.forms[0].insert.value = tinyMCE.getLang('lang_' + tinyMCE.getWindowArg('action'), 'Insert', true);
|
||||
|
||||
// Autoresize and focus
|
||||
TinyMCEPopup_autoResize();
|
||||
window.focus();
|
||||
}
|
||||
|
||||
function insertAnchor() {
|
||||
if (window.opener) {
|
||||
tinyMCE.execInstanceCommand(tinyMCE.getWindowArg('editor_id'), 'mceAnchor', false, document.forms[0].anchorName.value);
|
||||
top.close();
|
||||
}
|
||||
}
|
||||
|
||||
function cancelAction() {
|
||||
top.close();
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body onload="init();">
|
||||
<form onsubmit="insertAnchor();return false;">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="200">
|
||||
<tr>
|
||||
<td align="center" valign="middle"><table border="0" cellpadding="4" cellspacing="0">
|
||||
<tr>
|
||||
<td colspan="2" class="title">{$lang_insert_anchor_title}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td nowrap="nowrap">{$lang_insert_anchor_name}:</td>
|
||||
<td><input name="anchorName" type="text" id="anchorName" value="" style="width: 200px"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><input type="button" id="insert" name="insert" value="{$lang_insert}" onclick="insertAnchor();">
|
||||
</td>
|
||||
<td align="right"><input type="button" id="cancel" name="cancel" value="{$lang_cancel}" onclick="cancelAction();"></td>
|
||||
</tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
380
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/charmap.htm
vendored
Normal file
380
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/charmap.htm
vendored
Normal file
@ -0,0 +1,380 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_theme_charmap_title}</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
<script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script language="javascript" type="text/javascript">
|
||||
<!--
|
||||
var charmap = new Array();
|
||||
|
||||
// for mor details please see w3c.org
|
||||
// now here is the complete list ;)
|
||||
|
||||
charmap = [
|
||||
[' ', ' ', true, 'no-break space'],
|
||||
['&', '&', true, 'ampersand'],
|
||||
['"', '"', true, 'quotation mark'],
|
||||
// finance
|
||||
['¢', '¢', true, 'cent sign'],
|
||||
['€', '€', true, 'euro sign'],
|
||||
['£', '£', true, 'pound sign'],
|
||||
['¥', '¥', true, 'yen sign'],
|
||||
// signs
|
||||
['©', '©', true, 'copyright sign'],
|
||||
['®', '®', true, 'registered sign'],
|
||||
['™', '™', true, 'trade mark sign'],
|
||||
['‰', '‰', true, 'per mille sign'],
|
||||
['µ', 'µ', true, 'micro sign'],
|
||||
['·', '·', true, 'middle dot'],
|
||||
['•', '•', true, 'bullet'],
|
||||
['…', '…', true, 'three dot leader'],
|
||||
['′', '′', true, 'minutes / feet'],
|
||||
['″', '″', true, 'seconds / inches'],
|
||||
['§', '§', true, 'section sign'],
|
||||
['¶', '¶', true, 'paragraph sign'],
|
||||
['ß', 'ß', true, 'sharp s / ess-zed'],
|
||||
// quotations
|
||||
['‹', '‹', true, 'single left-pointing angle quotation mark'],
|
||||
['›', '›', true, 'single right-pointing angle quotation mark'],
|
||||
['«', '«', true, 'left pointing guillemet'],
|
||||
['»', '»', true, 'right pointing guillemet'],
|
||||
['‘', '‘', true, 'left single quotation mark'],
|
||||
['’', '’', true, 'right single quotation mark'],
|
||||
['“', '“', true, 'left double quotation mark'],
|
||||
['”', '”', true, 'right double quotation mark'],
|
||||
['‚', '‚', true, 'single low-9 quotation mark'],
|
||||
['„', '„', true, 'double low-9 quotation mark'],
|
||||
['<', '<', true, 'less-than sign'],
|
||||
['>', '>', true, 'greater-than sign'],
|
||||
['≤', '≤', true, 'less-than or equal to'],
|
||||
['≥', '≥', true, 'greater-than or equal to'],
|
||||
['–', '–', true, 'en dash'],
|
||||
['—', '—', true, 'em dash'],
|
||||
['¯', '¯', true, 'macron'],
|
||||
['‾', '‾', true, 'overline'],
|
||||
['¤', '¤', true, 'currency sign'],
|
||||
['¦', '¦', true, 'broken bar'],
|
||||
['¨', '¨', true, 'diaeresis'],
|
||||
['¡', '¡', true, 'inverted exclamation mark'],
|
||||
['¿', '¿', true, 'turned question mark'],
|
||||
['ˆ', 'ˆ', true, 'circumflex accent'],
|
||||
['˜', '˜', true, 'small tilde'],
|
||||
['°', '°', true, 'degree sign'],
|
||||
['−', '−', true, 'minus sign'],
|
||||
['±', '±', true, 'plus-minus sign'],
|
||||
['÷', '÷', true, 'division sign'],
|
||||
['⁄', '⁄', true, 'fraction slash'],
|
||||
['×', '×', true, 'multiplication sign'],
|
||||
['¹', '¹', true, 'superscript one'],
|
||||
['²', '²', true, 'superscript two'],
|
||||
['³', '³', true, 'superscript three'],
|
||||
['¼', '¼', true, 'fraction one quarter'],
|
||||
['½', '½', true, 'fraction one half'],
|
||||
['¾', '¾', true, 'fraction three quarters'],
|
||||
// math / logical
|
||||
['ƒ', 'ƒ', true, 'function / florin'],
|
||||
['∫', '∫', true, 'integral'],
|
||||
['∑', '∑', true, 'n-ary sumation'],
|
||||
['∞', '∞', true, 'infinity'],
|
||||
['√', '√', true, 'square root'],
|
||||
['∼', '∼', false,'similar to'],
|
||||
['≅', '≅', false,'approximately equal to'],
|
||||
['≈', '≈', true, 'almost equal to'],
|
||||
['≠', '≠', true, 'not equal to'],
|
||||
['≡', '≡', true, 'identical to'],
|
||||
['∈', '∈', false,'element of'],
|
||||
['∉', '∉', false,'not an element of'],
|
||||
['∋', '∋', false,'contains as member'],
|
||||
['∏', '∏', true, 'n-ary product'],
|
||||
['∧', '∧', false,'logical and'],
|
||||
['∨', '∨', false,'logical or'],
|
||||
['¬', '¬', true, 'not sign'],
|
||||
['∩', '∩', true, 'intersection'],
|
||||
['∪', '∪', false,'union'],
|
||||
['∂', '∂', true, 'partial differential'],
|
||||
['∀', '∀', false,'for all'],
|
||||
['∃', '∃', false,'there exists'],
|
||||
['∅', '∅', false,'diameter'],
|
||||
['∇', '∇', false,'backward difference'],
|
||||
['∗', '∗', false,'asterisk operator'],
|
||||
['∝', '∝', false,'proportional to'],
|
||||
['∠', '∠', false,'angle'],
|
||||
// undefined
|
||||
['´', '´', true, 'acute accent'],
|
||||
['¸', '¸', true, 'cedilla'],
|
||||
['ª', 'ª', true, 'feminine ordinal indicator'],
|
||||
['º', 'º', true, 'masculine ordinal indicator'],
|
||||
['†', '†', true, 'dagger'],
|
||||
['‡', '‡', true, 'double dagger'],
|
||||
// alphabetical special chars
|
||||
['À', 'À', true, 'A - grave'],
|
||||
['Á', 'Á', true, 'A - acute'],
|
||||
['Â', 'Â', true, 'A - circumflex'],
|
||||
['Ã', 'Ã', true, 'A - tilde'],
|
||||
['Ä', 'Ä', true, 'A - diaeresis'],
|
||||
['Å', 'Å', true, 'A - ring above'],
|
||||
['Æ', 'Æ', true, 'ligature AE'],
|
||||
['Ç', 'Ç', true, 'C - cedilla'],
|
||||
['È', 'È', true, 'E - grave'],
|
||||
['É', 'É', true, 'E - acute'],
|
||||
['Ê', 'Ê', true, 'E - circumflex'],
|
||||
['Ë', 'Ë', true, 'E - diaeresis'],
|
||||
['Ì', 'Ì', true, 'I - grave'],
|
||||
['Í', 'Í', true, 'I - acute'],
|
||||
['Î', 'Î', true, 'I - circumflex'],
|
||||
['Ï', 'Ï', true, 'I - diaeresis'],
|
||||
['Ð', 'Ð', true, 'ETH'],
|
||||
['Ñ', 'Ñ', true, 'N - tilde'],
|
||||
['Ò', 'Ò', true, 'O - grave'],
|
||||
['Ó', 'Ó', true, 'O - acute'],
|
||||
['Ô', 'Ô', true, 'O - circumflex'],
|
||||
['Õ', 'Õ', true, 'O - tilde'],
|
||||
['Ö', 'Ö', true, 'O - diaeresis'],
|
||||
['Ø', 'Ø', true, 'O - slash'],
|
||||
['Œ', 'Œ', true, 'ligature OE'],
|
||||
['Š', 'Š', true, 'S - caron'],
|
||||
['Ù', 'Ù', true, 'U - grave'],
|
||||
['Ú', 'Ú', true, 'U - acute'],
|
||||
['Û', 'Û', true, 'U - circumflex'],
|
||||
['Ü', 'Ü', true, 'U - diaeresis'],
|
||||
['Ý', 'Ý', true, 'Y - acute'],
|
||||
['Ÿ', 'Ÿ', true, 'Y - diaeresis'],
|
||||
['Þ', 'Þ', true, 'THORN'],
|
||||
['à', 'à', true, 'a - grave'],
|
||||
['á', 'á', true, 'a - acute'],
|
||||
['â', 'â', true, 'a - circumflex'],
|
||||
['ã', 'ã', true, 'a - tilde'],
|
||||
['ä', 'ä', true, 'a - diaeresis'],
|
||||
['å', 'å', true, 'a - ring above'],
|
||||
['æ', 'æ', true, 'ligature ae'],
|
||||
['ç', 'ç', true, 'c - cedilla'],
|
||||
['è', 'è', true, 'e - grave'],
|
||||
['é', 'é', true, 'e - acute'],
|
||||
['ê', 'ê', true, 'e - circumflex'],
|
||||
['ë', 'ë', true, 'e - diaeresis'],
|
||||
['ì', 'ì', true, 'i - grave'],
|
||||
['í', 'í', true, 'i - acute'],
|
||||
['î', 'î', true, 'i - circumflex'],
|
||||
['ï', 'ï', true, 'i - diaeresis'],
|
||||
['ð', 'ð', true, 'eth'],
|
||||
['ñ', 'ñ', true, 'n - tilde'],
|
||||
['ò', 'ò', true, 'o - grave'],
|
||||
['ó', 'ó', true, 'o - acute'],
|
||||
['ô', 'ô', true, 'o - circumflex'],
|
||||
['õ', 'õ', true, 'o - tilde'],
|
||||
['ö', 'ö', true, 'o - diaeresis'],
|
||||
['ø', 'ø', true, 'o slash'],
|
||||
['œ', 'œ', true, 'ligature oe'],
|
||||
['š', 'š', true, 's - caron'],
|
||||
['ù', 'ù', true, 'u - grave'],
|
||||
['ú', 'ú', true, 'u - acute'],
|
||||
['û', 'û', true, 'u - circumflex'],
|
||||
['ü', 'ü', true, 'u - diaeresis'],
|
||||
['ý', 'ý', true, 'y - acute'],
|
||||
['þ', 'þ', true, 'thorn'],
|
||||
['ÿ', 'ÿ', true, 'y - diaeresis'],
|
||||
// ['Α', 'Α', true, 'Alpha'],
|
||||
['Β', 'Β', true, 'Beta'],
|
||||
['Γ', 'Γ', true, 'Gamma'],
|
||||
['Δ', 'Δ', true, 'Delta'],
|
||||
['Ε', 'Ε', true, 'Epsilon'],
|
||||
['Ζ', 'Ζ', true, 'Zeta'],
|
||||
['Η', 'Η', true, 'Eta'],
|
||||
['Θ', 'Θ', true, 'Theta'],
|
||||
['Ι', 'Ι', true, 'Iota'],
|
||||
['Κ', 'Κ', true, 'Kappa'],
|
||||
['Λ', 'Λ', true, 'Lambda'],
|
||||
['Μ', 'Μ', true, 'Mu'],
|
||||
['Ν', 'Ν', true, 'Nu'],
|
||||
['Ξ', 'Ξ', true, 'Xi'],
|
||||
['Ο', 'Ο', true, 'Omicron'],
|
||||
['Π', 'Π', true, 'Pi'],
|
||||
['Ρ', 'Ρ', true, 'Rho'],
|
||||
['Σ', 'Σ', true, 'Sigma'],
|
||||
['Τ', 'Τ', true, 'Tau'],
|
||||
['Υ', 'Υ', true, 'Upsilon'],
|
||||
['Φ', 'Φ', true, 'Phi'],
|
||||
['Χ', 'Χ', true, 'Chi'],
|
||||
['Ψ', 'Ψ', true, 'Psi'],
|
||||
['Ω', 'Ω', true, 'Omega'],
|
||||
['α', 'α', true, 'alpha'],
|
||||
['β', 'β', true, 'beta'],
|
||||
['γ', 'γ', true, 'gamma'],
|
||||
['δ', 'δ', true, 'delta'],
|
||||
['ε', 'ε', true, 'epsilon'],
|
||||
['ζ', 'ζ', true, 'zeta'],
|
||||
['η', 'η', true, 'eta'],
|
||||
['θ', 'θ', true, 'theta'],
|
||||
['ι', 'ι', true, 'iota'],
|
||||
['κ', 'κ', true, 'kappa'],
|
||||
['λ', 'λ', true, 'lambda'],
|
||||
['μ', 'μ', true, 'mu'],
|
||||
['ν', 'ν', true, 'nu'],
|
||||
['ξ', 'ξ', true, 'xi'],
|
||||
['ο', 'ο', true, 'omicron'],
|
||||
['π', 'π', true, 'pi'],
|
||||
['ρ', 'ρ', true, 'rho'],
|
||||
['ς', 'ς', true, 'final sigma'],
|
||||
['σ', 'σ', true, 'sigma'],
|
||||
['τ', 'τ', true, 'tau'],
|
||||
['υ', 'υ', true, 'upsilon'],
|
||||
['φ', 'φ', true, 'phi'],
|
||||
['χ', 'χ', true, 'chi'],
|
||||
['ψ', 'ψ', true, 'psi'],
|
||||
['ω', 'ω', true, 'omega'],
|
||||
// symbols
|
||||
['ℵ', 'ℵ', false,'alef symbol'],
|
||||
['ϖ', 'ϖ', false,'pi symbol'],
|
||||
['ℜ', 'ℜ', false,'real part symbol'],
|
||||
['ϑ','ϑ', false,'theta symbol'],
|
||||
['ϒ', 'ϒ', false,'upsilon - hook symbol'],
|
||||
['℘', '℘', false,'Weierstrass p'],
|
||||
['ℑ', 'ℑ', false,'imaginary part'],
|
||||
// arrows
|
||||
['←', '←', true, 'leftwards arrow'],
|
||||
['↑', '↑', true, 'upwards arrow'],
|
||||
['→', '→', true, 'rightwards arrow'],
|
||||
['↓', '↓', true, 'downwards arrow'],
|
||||
['↔', '↔', true, 'left right arrow'],
|
||||
['↵', '↵', false,'carriage return'],
|
||||
['⇐', '⇐', false,'leftwards double arrow'],
|
||||
['⇑', '⇑', false,'upwards double arrow'],
|
||||
['⇒', '⇒', false,'rightwards double arrow'],
|
||||
['⇓', '⇓', false,'downwards double arrow'],
|
||||
['⇔', '⇔', false,'left right double arrow'],
|
||||
['∴', '∴', false,'therefore'],
|
||||
['⊂', '⊂', false,'subset of'],
|
||||
['⊃', '⊃', false,'superset of'],
|
||||
['⊄', '⊄', false,'not a subset of'],
|
||||
['⊆', '⊆', false,'subset of or equal to'],
|
||||
['⊇', '⊇', false,'superset of or equal to'],
|
||||
['⊕', '⊕', false,'circled plus'],
|
||||
['⊗', '⊗', false,'circled times'],
|
||||
['⊥', '⊥', false,'perpendicular'],
|
||||
['⋅', '⋅', false,'dot operator'],
|
||||
['⌈', '⌈', false,'left ceiling'],
|
||||
['⌉', '⌉', false,'right ceiling'],
|
||||
['⌊', '⌊', false,'left floor'],
|
||||
['⌋', '⌋', false,'right floor'],
|
||||
['⟨', '〈', false,'left-pointing angle bracket'],
|
||||
['⟩', '〉', false,'right-pointing angle bracket'],
|
||||
['◊', '◊', true,'lozenge'],
|
||||
['♠', '♠', false,'black spade suit'],
|
||||
['♣', '♣', true, 'black club suit'],
|
||||
['♥', '♥', true, 'black heart suit'],
|
||||
['♦', '♦', true, 'black diamond suit'],
|
||||
[' ', ' ', false,'en space'],
|
||||
[' ', ' ', false,'em space'],
|
||||
[' ', ' ', false,'thin space'],
|
||||
['‌', '‌', false,'zero width non-joiner'],
|
||||
['‍', '‍', false,'zero width joiner'],
|
||||
['‎', '‎', false,'left-to-right mark'],
|
||||
['‏', '‏', false,'right-to-left mark'],
|
||||
['­', '­', false,'soft hyphen']
|
||||
];
|
||||
|
||||
function renderCharMapHTML() {
|
||||
var charsPerRow = 20, tdWidth=20, tdHeight=20;
|
||||
var html = '<table border="0" cellspacing="1" cellpadding="0" width="' + (tdWidth*charsPerRow) + '"><tr height="' + tdHeight + '">';
|
||||
var cols=-1;
|
||||
for (var i=0; i<charmap.length; i++) {
|
||||
if (charmap[i][2]==true) {
|
||||
cols++;
|
||||
html += ''
|
||||
+ '<td width="' + tdWidth + '" height="' + tdHeight + '" class="charmap"'
|
||||
+ ' onmouseover="tinyMCE.switchClass(this,\'charmapOver\');'
|
||||
+ 'previewChar(\'' + charmap[i][1].substring(1,charmap[i][1].length) + '\',\'' + charmap[i][0].substring(1,charmap[i][0].length) + '\',\'' + charmap[i][3] + '\');"'
|
||||
+ ' onmouseout="tinyMCE.restoreClass(this,\'charmapOver\');"'
|
||||
+ ' onclick="insertChar(\'' + charmap[i][1].substring(2,charmap[i][1].length-1) + '\');return false;"'
|
||||
+ ' title="' + charmap[i][3] + '" nowrap="nowrap">'
|
||||
+ charmap[i][1]
|
||||
+ '</td>';
|
||||
if ((cols+1) % charsPerRow == 0)
|
||||
html += '</tr><tr height="' + tdHeight + '">';
|
||||
}
|
||||
}
|
||||
if (cols % charsPerRow > 0) {
|
||||
var padd = charsPerRow - (cols % charsPerRow);
|
||||
for (var i=0; i<padd-1; i++)
|
||||
html += '<td width="' + tdWidth + '" height="' + tdHeight + '" class="charmap"> </td>';
|
||||
}
|
||||
html += '</tr></table>';
|
||||
document.write(html);
|
||||
}
|
||||
|
||||
function insertChar(chr) {
|
||||
tinyMCE.execInstanceCommand(tinyMCE.getWindowArg('editor_id'), 'mceInsertContent', false, '\&#' + chr + ';');
|
||||
//window.close();
|
||||
self.focus();
|
||||
}
|
||||
|
||||
function previewChar(codeA, codeB, codeN) {
|
||||
var elmA = document.getElementById('codeA');
|
||||
var elmB = document.getElementById('codeB');
|
||||
var elmV = document.getElementById('codeV');
|
||||
var elmN = document.getElementById('codeN');
|
||||
|
||||
if (codeA=='#160;') {
|
||||
elmV.innerHTML = '__';
|
||||
} else {
|
||||
elmV.innerHTML = '&' + codeA;
|
||||
}
|
||||
|
||||
elmB.innerHTML = '&' + codeA;
|
||||
elmA.innerHTML = '&' + codeB;
|
||||
elmN.innerHTML = codeN;
|
||||
}
|
||||
|
||||
window.focus();
|
||||
//-->
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<table align="center" border="0" cellspacing="0" cellpadding="2">
|
||||
<tr>
|
||||
<td colspan="2" class="title">{$lang_theme_charmap_title}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td rowspan="2" align="left" valign="top">
|
||||
<script language="javascript" type="text/javascript">
|
||||
<!--
|
||||
renderCharMapHTML();
|
||||
//-->
|
||||
</script>
|
||||
</td>
|
||||
<td width="100" align="center" valign="top">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="100" height="100">
|
||||
<tr>
|
||||
<td class="charmapOver" style="font-size: 40px; height:80px;" id="codeV"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="font-size: 10px; font-family: Arial, Helvetica, sans-serif; text-align:center;" id="codeN"> </td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td valign="bottom" style="padding-bottom: 3px;">
|
||||
<table width="100" align="center" border="0" cellpadding="2" cellspacing="0">
|
||||
<tr>
|
||||
<td align="center" style="border-left: 1px solid #666699; border-top: 1px solid #666699; border-right: 1px solid #666699;">HTML-Code</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="font-size: 16px; font-weight: bold; border-left: 1px solid #666699; border-bottom: 1px solid #666699; border-right: 1px solid #666699;" id="codeA" align="center"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="font-size: 1px;"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center" style="border-left: 1px solid #666699; border-top: 1px solid #666699; border-right: 1px solid #666699;">NUM-Code</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="font-size: 16px; font-weight: bold; border-left: 1px solid #666699; border-bottom: 1px solid #666699; border-right: 1px solid #666699;" id="codeB" align="center"> </td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
</body>
|
||||
</html>
|
272
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/color_picker.htm
vendored
Normal file
272
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/color_picker.htm
vendored
Normal file
@ -0,0 +1,272 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_theme_colorpicker_title}</title>
|
||||
<script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script language="javascript" type="text/javascript">
|
||||
<!--
|
||||
function selectColor() {
|
||||
var color = document.getElementById("selectedColorBox").value;
|
||||
if (window.opener)
|
||||
window.opener.tinyMCE.execInstanceCommand(tinyMCE.getWindowArg('editor_id'),tinyMCE.getWindowArg('command'),false,color);
|
||||
window.close();
|
||||
}
|
||||
function showColor(color) {
|
||||
document.getElementById("selectedColor").style.backgroundColor = color;
|
||||
document.getElementById("selectedColorBox").value = color;
|
||||
}
|
||||
|
||||
window.focus();
|
||||
|
||||
var colorPicker = "";
|
||||
var colors = new Array(
|
||||
"#000000",
|
||||
"#000033",
|
||||
"#000066",
|
||||
"#000099",
|
||||
"#0000cc",
|
||||
"#0000ff",
|
||||
"#330000",
|
||||
"#330033",
|
||||
"#330066",
|
||||
"#330099",
|
||||
"#3300cc",
|
||||
"#3300ff",
|
||||
"#660000",
|
||||
"#660033",
|
||||
"#660066",
|
||||
"#660099",
|
||||
"#6600cc",
|
||||
"#6600ff",
|
||||
"#990000",
|
||||
"#990033",
|
||||
"#990066",
|
||||
"#990099",
|
||||
"#9900cc",
|
||||
"#9900ff",
|
||||
"#cc0000",
|
||||
"#cc0033",
|
||||
"#cc0066",
|
||||
"#cc0099",
|
||||
"#cc00cc",
|
||||
"#cc00ff",
|
||||
"#ff0000",
|
||||
"#ff0033",
|
||||
"#ff0066",
|
||||
"#ff0099",
|
||||
"#ff00cc",
|
||||
"#ff00ff",
|
||||
"#003300",
|
||||
"#003333",
|
||||
"#003366",
|
||||
"#003399",
|
||||
"#0033cc",
|
||||
"#0033ff",
|
||||
"#333300",
|
||||
"#333333",
|
||||
"#333366",
|
||||
"#333399",
|
||||
"#3333cc",
|
||||
"#3333ff",
|
||||
"#663300",
|
||||
"#663333",
|
||||
"#663366",
|
||||
"#663399",
|
||||
"#6633cc",
|
||||
"#6633ff",
|
||||
"#993300",
|
||||
"#993333",
|
||||
"#993366",
|
||||
"#993399",
|
||||
"#9933cc",
|
||||
"#9933ff",
|
||||
"#cc3300",
|
||||
"#cc3333",
|
||||
"#cc3366",
|
||||
"#cc3399",
|
||||
"#cc33cc",
|
||||
"#cc33ff",
|
||||
"#ff3300",
|
||||
"#ff3333",
|
||||
"#ff3366",
|
||||
"#ff3399",
|
||||
"#ff33cc",
|
||||
"#ff33ff",
|
||||
"#006600",
|
||||
"#006633",
|
||||
"#006666",
|
||||
"#006699",
|
||||
"#0066cc",
|
||||
"#0066ff",
|
||||
"#336600",
|
||||
"#336633",
|
||||
"#336666",
|
||||
"#336699",
|
||||
"#3366cc",
|
||||
"#3366ff",
|
||||
"#666600",
|
||||
"#666633",
|
||||
"#666666",
|
||||
"#666699",
|
||||
"#6666cc",
|
||||
"#6666ff",
|
||||
"#996600",
|
||||
"#996633",
|
||||
"#996666",
|
||||
"#996699",
|
||||
"#9966cc",
|
||||
"#9966ff",
|
||||
"#cc6600",
|
||||
"#cc6633",
|
||||
"#cc6666",
|
||||
"#cc6699",
|
||||
"#cc66cc",
|
||||
"#cc66ff",
|
||||
"#ff6600",
|
||||
"#ff6633",
|
||||
"#ff6666",
|
||||
"#ff6699",
|
||||
"#ff66cc",
|
||||
"#ff66ff",
|
||||
"#009900",
|
||||
"#009933",
|
||||
"#009966",
|
||||
"#009999",
|
||||
"#0099cc",
|
||||
"#0099ff",
|
||||
"#339900",
|
||||
"#339933",
|
||||
"#339966",
|
||||
"#339999",
|
||||
"#3399cc",
|
||||
"#3399ff",
|
||||
"#669900",
|
||||
"#669933",
|
||||
"#669966",
|
||||
"#669999",
|
||||
"#6699cc",
|
||||
"#6699ff",
|
||||
"#999900",
|
||||
"#999933",
|
||||
"#999966",
|
||||
"#999999",
|
||||
"#9999cc",
|
||||
"#9999ff",
|
||||
"#cc9900",
|
||||
"#cc9933",
|
||||
"#cc9966",
|
||||
"#cc9999",
|
||||
"#cc99cc",
|
||||
"#cc99ff",
|
||||
"#ff9900",
|
||||
"#ff9933",
|
||||
"#ff9966",
|
||||
"#ff9999",
|
||||
"#ff99cc",
|
||||
"#ff99ff",
|
||||
"#00cc00",
|
||||
"#00cc33",
|
||||
"#00cc66",
|
||||
"#00cc99",
|
||||
"#00cccc",
|
||||
"#00ccff",
|
||||
"#33cc00",
|
||||
"#33cc33",
|
||||
"#33cc66",
|
||||
"#33cc99",
|
||||
"#33cccc",
|
||||
"#33ccff",
|
||||
"#66cc00",
|
||||
"#66cc33",
|
||||
"#66cc66",
|
||||
"#66cc99",
|
||||
"#66cccc",
|
||||
"#66ccff",
|
||||
"#99cc00",
|
||||
"#99cc33",
|
||||
"#99cc66",
|
||||
"#99cc99",
|
||||
"#99cccc",
|
||||
"#99ccff",
|
||||
"#cccc00",
|
||||
"#cccc33",
|
||||
"#cccc66",
|
||||
"#cccc99",
|
||||
"#cccccc",
|
||||
"#ccccff",
|
||||
"#ffcc00",
|
||||
"#ffcc33",
|
||||
"#ffcc66",
|
||||
"#ffcc99",
|
||||
"#ffcccc",
|
||||
"#ffccff",
|
||||
"#00ff00",
|
||||
"#00ff33",
|
||||
"#00ff66",
|
||||
"#00ff99",
|
||||
"#00ffcc",
|
||||
"#00ffff",
|
||||
"#33ff00",
|
||||
"#33ff33",
|
||||
"#33ff66",
|
||||
"#33ff99",
|
||||
"#33ffcc",
|
||||
"#33ffff",
|
||||
"#66ff00",
|
||||
"#66ff33",
|
||||
"#66ff66",
|
||||
"#66ff99",
|
||||
"#66ffcc",
|
||||
"#66ffff",
|
||||
"#99ff00",
|
||||
"#99ff33",
|
||||
"#99ff66",
|
||||
"#99ff99",
|
||||
"#99ffcc",
|
||||
"#99ffff",
|
||||
"#ccff00",
|
||||
"#ccff33",
|
||||
"#ccff66",
|
||||
"#ccff99",
|
||||
"#ccffcc",
|
||||
"#ccffff",
|
||||
"#ffff00",
|
||||
"#ffff33",
|
||||
"#ffff66",
|
||||
"#ffff99",
|
||||
"#ffffcc",
|
||||
"#ffffff"
|
||||
);
|
||||
|
||||
colorPicker += '<table border="0" cellspacing="1" cellpadding="0">'
|
||||
+ '<tr>';
|
||||
for (var i=0; i<colors.length; i++) {
|
||||
colorPicker += '<td bgcolor="' + colors[i] + '">'
|
||||
+ '<a href="#top" onclick="selectColor();return false;" onmouseover="showColor(\'' + colors[i] + '\');">'
|
||||
+ '<img border="0" src="images/spacer.gif" width="10" height="10" /></a></td>';
|
||||
if ((i+1) % 18 == 0)
|
||||
colorPicker += '</tr><tr>';
|
||||
}
|
||||
colorPicker += '<tr><td colspan="18">'
|
||||
+ '<table width="100%" border="0" cellspacing="0" cellpadding="0">'
|
||||
+ '<tr><td>'
|
||||
+ '<img id="selectedColor" style="background-color:' + tinyMCE.getWindowArg('input_color') + '" border="0" src="images/spacer.gif" width="80" height="16" />'
|
||||
+ '</td><td align="right">'
|
||||
+ '<input id="selectedColorBox" name="selectedColorBox" type="text" size="7" maxlength="7" style="width:65px" value="' + tinyMCE.getWindowArg('input_color') + '" />'
|
||||
+ '</td></tr>'
|
||||
+ '</table>'
|
||||
+ '<input type="button" id="insert" name="insert" value="{$lang_theme_colorpicker_apply}" style="margin-top:3px" onclick="selectColor();">'
|
||||
+ '</td></tr>'
|
||||
+ '</table>';
|
||||
//-->
|
||||
</script>
|
||||
</head>
|
||||
<body marginheight="3" topmargin="3" leftmargin="3" marginwidth="3">
|
||||
<div align="center">
|
||||
<script language="javascript" type="text/javascript">
|
||||
<!--
|
||||
document.write(colorPicker);
|
||||
//-->
|
||||
</script>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
27
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/editor_content.css
vendored
Normal file
27
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/editor_content.css
vendored
Normal file
@ -0,0 +1,27 @@
|
||||
body {
|
||||
background-color: #FFFFFF;
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 10px;
|
||||
scrollbar-3dlight-color: #F0F0EE;
|
||||
scrollbar-arrow-color: #676662;
|
||||
scrollbar-base-color: #F0F0EE;
|
||||
scrollbar-darkshadow-color: #DDDDDD;
|
||||
scrollbar-face-color: #E0E0DD;
|
||||
scrollbar-highlight-color: #F0F0EE;
|
||||
scrollbar-shadow-color: #F0F0EE;
|
||||
scrollbar-track-color: #F5F5F5;
|
||||
}
|
||||
|
||||
td {
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 10px;
|
||||
}
|
||||
|
||||
pre {
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 10px;
|
||||
}
|
||||
|
||||
.mceVisualAid {
|
||||
border: 1px dashed #BBBBBB;
|
||||
}
|
121
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/editor_popup.css
vendored
Normal file
121
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/editor_popup.css
vendored
Normal file
@ -0,0 +1,121 @@
|
||||
body {
|
||||
background-color: #F0F0EE;
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 11px;
|
||||
scrollbar-3dlight-color: #F0F0EE;
|
||||
scrollbar-arrow-color: #676662;
|
||||
scrollbar-base-color: #F0F0EE;
|
||||
scrollbar-darkshadow-color: #DDDDDD;
|
||||
scrollbar-face-color: #E0E0DD;
|
||||
scrollbar-highlight-color: #F0F0EE;
|
||||
scrollbar-shadow-color: #F0F0EE;
|
||||
scrollbar-track-color: #F5F5F5;
|
||||
}
|
||||
|
||||
td {
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 11px;
|
||||
}
|
||||
|
||||
input {
|
||||
background: #FFFFFF;
|
||||
border: 1px solid #cccccc;
|
||||
}
|
||||
|
||||
td, input, select, textarea {
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 10px;
|
||||
}
|
||||
|
||||
input, select, textarea {
|
||||
border: 1px solid #808080;
|
||||
}
|
||||
|
||||
.input_noborder {
|
||||
border: 0px solid #808080;
|
||||
}
|
||||
|
||||
#insert {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
#cancel {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 12px;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
table.charmap {
|
||||
border-style: solid;
|
||||
border-width: 1px;
|
||||
border-color: #AAAAAA;
|
||||
}
|
||||
|
||||
td.charmap, td.charmapOver {
|
||||
color: #000000;
|
||||
border-color: #AAAAAA;
|
||||
border-style: solid;
|
||||
border-width: 1px;
|
||||
text-align: center;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
td.charmapOver {
|
||||
background-color: #CCCCCC;
|
||||
cursor: arrow;
|
||||
}
|
||||
|
||||
a.charmap {
|
||||
color: #000000;
|
||||
text-decoration: none
|
||||
}
|
||||
|
||||
.wordWrapCode {
|
||||
vertical-align: middle;
|
||||
border: 1px none #000000;
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
input.radio {
|
||||
border: 1px none #000000;
|
||||
background-color: transparent;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
input.checkbox {
|
||||
border: 1px none #000000;
|
||||
background-color: transparent;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.mceButtonNormal, .mceButtonOver, .mceButtonDown, .mceSeparator, .mceButtonDisabled, .mceButtonSelected {
|
||||
margin-left: 1px;
|
||||
}
|
||||
|
||||
.mceButtonNormal {
|
||||
border-top: 1px solid;
|
||||
border-left: 1px solid;
|
||||
border-bottom: 1px solid;
|
||||
border-right: 1px solid;
|
||||
border-color: #F0F0EE;
|
||||
cursor: arrow;
|
||||
}
|
||||
|
||||
.mceButtonOver {
|
||||
border: 1px solid #0A246A;
|
||||
cursor: arrow;
|
||||
background-color: #B6BDD2;
|
||||
}
|
||||
|
||||
.mceButtonDown {
|
||||
cursor: arrow;
|
||||
border: 1px solid #0A246A;
|
||||
background-color: #8592B5;
|
||||
}
|
||||
|
||||
legend {
|
||||
font-weight: bold;
|
||||
}
|
23
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/editor_template.js
vendored
Normal file
23
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/editor_template.js
vendored
Normal file
File diff suppressed because one or more lines are too long
763
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/editor_template_src.js
vendored
Normal file
763
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/editor_template_src.js
vendored
Normal file
@ -0,0 +1,763 @@
|
||||
/* Import theme specific language pack */
|
||||
tinyMCE.importThemeLanguagePack('advanced');
|
||||
|
||||
// Variable declarations
|
||||
var TinyMCE_advanced_autoImportCSSClasses = true;
|
||||
var TinyMCE_advanced_foreColor = "#000000";
|
||||
var TinyMCE_advanced_anchorName = "";
|
||||
var TinyMCE_advanced_buttons = [
|
||||
// Control id, button img, button title, command, user_interface, value
|
||||
['bold', '{$lang_bold_img}', '{$lang_bold_desc}', 'Bold'],
|
||||
['italic', '{$lang_italic_img}', '{$lang_italic_desc}', 'Italic'],
|
||||
['underline', '{$lang_underline_img}', '{$lang_underline_desc}', 'Underline'],
|
||||
['strikethrough', 'strikethrough.gif', '{$lang_striketrough_desc}', 'Strikethrough'],
|
||||
['justifyleft', 'left.gif', '{$lang_justifyleft_desc}', 'JustifyLeft'],
|
||||
['justifycenter', 'center.gif', '{$lang_justifycenter_desc}', 'JustifyCenter'],
|
||||
['justifyright', 'right.gif', '{$lang_justifyright_desc}', 'JustifyRight'],
|
||||
['justifyfull', 'full.gif', '{$lang_justifyfull_desc}', 'JustifyFull'],
|
||||
['bullist', 'bullist.gif', '{$lang_bullist_desc}', 'InsertUnorderedList'],
|
||||
['numlist', 'numlist.gif', '{$lang_numlist_desc}', 'InsertOrderedList'],
|
||||
['outdent', 'outdent.gif', '{$lang_outdent_desc}', 'Outdent'],
|
||||
['indent', 'indent.gif', '{$lang_indent_desc}', 'Indent'],
|
||||
['cut', 'cut.gif', '{$lang_cut_desc}', 'Cut'],
|
||||
['copy', 'copy.gif', '{$lang_copy_desc}', 'Copy'],
|
||||
['paste', 'paste.gif', '{$lang_paste_desc}', 'Paste'],
|
||||
['undo', 'undo.gif', '{$lang_undo_desc}', 'Undo'],
|
||||
['redo', 'redo.gif', '{$lang_redo_desc}', 'Redo'],
|
||||
['link', 'link.gif', '{$lang_link_desc}', 'mceLink', true],
|
||||
['unlink', 'unlink.gif', '{$lang_unlink_desc}', 'unlink'],
|
||||
['image', 'image.gif', '{$lang_image_desc}', 'mceImage', true],
|
||||
['cleanup', 'cleanup.gif', '{$lang_cleanup_desc}', 'mceCleanup'],
|
||||
['help', 'help.gif', '{$lang_help_desc}', 'mceHelp'],
|
||||
['code', 'code.gif', '{$lang_theme_code_desc}', 'mceCodeEditor'],
|
||||
['hr', 'hr.gif', '{$lang_theme_hr_desc}', 'inserthorizontalrule'],
|
||||
['removeformat', 'removeformat.gif', '{$lang_theme_removeformat_desc}', 'removeformat'],
|
||||
['sub', 'sub.gif', '{$lang_theme_sub_desc}', 'subscript'],
|
||||
['sup', 'sup.gif', '{$lang_theme_sup_desc}', 'superscript'],
|
||||
['forecolor', 'forecolor.gif', '{$lang_theme_forecolor_desc}', 'mceForeColor', true],
|
||||
['backcolor', 'backcolor.gif', '{$lang_theme_backcolor_desc}', 'mceBackColor', true],
|
||||
['charmap', 'charmap.gif', '{$lang_theme_charmap_desc}', 'mceCharMap'],
|
||||
['visualaid', 'visualaid.gif', '{$lang_theme_visualaid_desc}', 'mceToggleVisualAid'],
|
||||
['anchor', 'anchor.gif', '{$lang_theme_anchor_desc}', 'mceInsertAnchor'],
|
||||
['newdocument', 'newdocument.gif', '{$lang_newdocument_desc}', 'mceSetContent', false, '']
|
||||
];
|
||||
|
||||
|
||||
/**
|
||||
* Returns HTML code for the specificed control.
|
||||
*/
|
||||
function TinyMCE_advanced_getControlHTML(button_name) {
|
||||
var buttonTileMap = new Array('anchor.gif','backcolor.gif','bullist.gif','center.gif','charmap.gif','cleanup.gif','code.gif','copy.gif','custom_1.gif','cut.gif','forecolor.gif','full.gif','help.gif','hr.gif','image.gif','indent.gif','left.gif','link.gif','numlist.gif','outdent.gif','paste.gif','redo.gif','removeformat.gif','right.gif','strikethrough.gif','sub.gif','sup.gif','undo.gif','unlink.gif','visualaid.gif');
|
||||
|
||||
// Lookup button in button list
|
||||
for (var i=0; i<TinyMCE_advanced_buttons.length; i++) {
|
||||
var but = TinyMCE_advanced_buttons[i];
|
||||
if (but[0] == button_name) {
|
||||
var safariPatch = '" onclick="';
|
||||
|
||||
if (tinyMCE.isSafari)
|
||||
safariPatch = "";
|
||||
|
||||
// Check for it in tilemap
|
||||
if (tinyMCE.settings['button_tile_map']) {
|
||||
for (var x=0; !tinyMCE.isMSIE && x<buttonTileMap.length; x++) {
|
||||
if (buttonTileMap[x] == but[1])
|
||||
return '<img id="{$editor_id}_' + but[0] + '" src="{$themeurl}/images/spacer.gif" style="background-image:url({$themeurl}/images/buttons.gif); background-position: ' + (0-(x*20)) + 'px 0px" title="' + but[2] + '" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');' + safariPatch + 'tinyMCE.execInstanceCommand(\'{$editor_id}\',\'' + but[3] + '\', ' + (but.length > 4 ? but[4] : false) + (but.length > 5 ? ', \'' + but[5] + '\'' : '') + ')">';
|
||||
}
|
||||
}
|
||||
|
||||
// Old style
|
||||
return '<img id="{$editor_id}_' + but[0] + '" src="{$themeurl}/images/' + but[1] + '" title="' + but[2] + '" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');' + safariPatch + 'tinyMCE.execInstanceCommand(\'{$editor_id}\',\'' + but[3] + '\', ' + (but.length > 4 ? but[4] : false) + (but.length > 5 ? ', \'' + but[5] + '\'' : '') + ')">';
|
||||
}
|
||||
}
|
||||
|
||||
// Custom controlls other than buttons
|
||||
switch (button_name) {
|
||||
case "formatselect":
|
||||
var html = '<select id="{$editor_id}_formatSelect" name="{$editor_id}_formatSelect" onchange="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'FormatBlock\',false,this.options[this.selectedIndex].value);" class="mceSelectList">';
|
||||
var formats = tinyMCE.getParam("theme_advanced_blockformats", "p,address,pre,h1,h2,h3,h4,h5,h6", true).split(',');
|
||||
var lookup = [
|
||||
['p', '{$lang_theme_paragraph}'],
|
||||
['address', '{$lang_theme_address}'],
|
||||
['pre', '{$lang_theme_pre}'],
|
||||
['h1', '{$lang_theme_h1}'],
|
||||
['h2', '{$lang_theme_h2}'],
|
||||
['h3', '{$lang_theme_h3}'],
|
||||
['h4', '{$lang_theme_h4}'],
|
||||
['h5', '{$lang_theme_h5}'],
|
||||
['h6', '{$lang_theme_h6}']
|
||||
];
|
||||
|
||||
// Build format select
|
||||
for (var i=0; i<formats.length; i++) {
|
||||
for (var x=0; x<lookup.length; x++) {
|
||||
if (formats[i] == lookup[x][0])
|
||||
html += '<option value="<' + lookup[x][0] + '>">' + lookup[x][1] + '</option>';
|
||||
}
|
||||
}
|
||||
|
||||
html += '</select>';
|
||||
|
||||
return html;
|
||||
|
||||
|
||||
case "styleselect":
|
||||
return '<select id="{$editor_id}_styleSelect" onmousedown="TinyMCE_advanced_setupCSSClasses(\'{$editor_id}\');" name="{$editor_id}_styleSelect" onchange="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceSetCSSClass\',false,this.options[this.selectedIndex].value);" class="mceSelectList">{$style_select_options}</select>';
|
||||
|
||||
case "fontselect":
|
||||
return '<select id="{$editor_id}_fontNameSelect" name="{$editor_id}_fontNameSelect" onchange="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'FontName\',false,this.options[this.selectedIndex].value);" class="mceSelectList">\
|
||||
<option value="">{$lang_theme_fontdefault}</option>\
|
||||
<option value="arial,helvetica,sans-serif">Arial</option>\
|
||||
<option value="times new roman,times,serif">Times New Roman</option>\
|
||||
<option value="verdana,arial,helvetica,sans-serif">Verdana</option>\
|
||||
<option value="courier new,courier,monospace">Courier</option>\
|
||||
<option value="georgia,times new roman,times,serif">Georgia</option>\
|
||||
<option value="tahoma,arial,helvetica,sans-serif">Tahoma</option>\
|
||||
</select>';
|
||||
|
||||
case "fontsizeselect":
|
||||
return '<select id="{$editor_id}_fontSizeSelect" name="{$editor_id}_fontSizeSelect" onchange="tinyMCE.execInstanceCommand(\'{$editor_id}\',\'FontSize\',false,this.options[this.selectedIndex].value);" class="mceSelectList">\
|
||||
<option value="0">-- {$lang_theme_font_size} --</option>\
|
||||
<option value="1">1 (8 pt)</option>\
|
||||
<option value="2">2 (10 pt)</option>\
|
||||
<option value="3">3 (12 pt)</option>\
|
||||
<option value="4">4 (14 pt)</option>\
|
||||
<option value="5">5 (18 pt)</option>\
|
||||
<option value="6">6 (24 pt)</option>\
|
||||
<option value="7">7 (36 pt)</option>\
|
||||
</select>';
|
||||
|
||||
case "|":
|
||||
case "separator":
|
||||
return '<img src="{$themeurl}/images/spacer.gif" width="1" height="15" class="mceSeparatorLine">';
|
||||
|
||||
case "spacer":
|
||||
return '<img src="{$themeurl}/images/spacer.gif" width="1" height="15" border="0" class="mceSeparatorLine" style="vertical-align: middle" />';
|
||||
|
||||
case "rowseparator":
|
||||
return '<br />';
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
/**
|
||||
* Theme specific exec command handeling.
|
||||
*/
|
||||
function TinyMCE_advanced_execCommand(editor_id, element, command, user_interface, value) {
|
||||
switch (command) {
|
||||
case "mceForeColor":
|
||||
var template = new Array();
|
||||
var inputColor = TinyMCE_advanced_foreColor;
|
||||
|
||||
if (!inputColor)
|
||||
inputColor = "#000000";
|
||||
|
||||
template['file'] = 'color_picker.htm';
|
||||
template['width'] = 210;
|
||||
template['height'] = 200;
|
||||
|
||||
tinyMCE.openWindow(template, {editor_id : editor_id, command : "forecolor", input_color : inputColor});
|
||||
return true;
|
||||
|
||||
case "mceBackColor":
|
||||
var template = new Array();
|
||||
var inputColor = TinyMCE_advanced_foreColor;
|
||||
|
||||
if (!inputColor)
|
||||
inputColor = "#000000";
|
||||
|
||||
template['file'] = 'color_picker.htm';
|
||||
template['width'] = 210;
|
||||
template['height'] = 200;
|
||||
|
||||
tinyMCE.openWindow(template, {editor_id : editor_id, command : "HiliteColor", input_color : inputColor});
|
||||
return true;
|
||||
|
||||
case "mceCodeEditor":
|
||||
var template = new Array();
|
||||
|
||||
template['file'] = 'source_editor.htm';
|
||||
template['width'] = tinyMCE.getParam("theme_advanced_source_editor_width", 500);
|
||||
template['height'] = tinyMCE.getParam("theme_advanced_source_editor_height", 400);
|
||||
|
||||
tinyMCE.openWindow(template, {editor_id : editor_id, resizable : "yes", scrollbars : "no"});
|
||||
return true;
|
||||
|
||||
case "mceCharMap":
|
||||
var template = new Array();
|
||||
|
||||
template['file'] = 'charmap.htm';
|
||||
template['width'] = 550;
|
||||
template['height'] = 280;
|
||||
|
||||
tinyMCE.openWindow(template, {editor_id : editor_id});
|
||||
return true;
|
||||
|
||||
case "mceInsertAnchor":
|
||||
var template = new Array();
|
||||
|
||||
template['file'] = 'anchor.htm';
|
||||
template['width'] = 320;
|
||||
template['height'] = 130;
|
||||
|
||||
tinyMCE.openWindow(template, {editor_id : editor_id, name : TinyMCE_advanced_anchorName, action : (TinyMCE_advanced_anchorName == "" ? "insert" : "update")});
|
||||
return true;
|
||||
}
|
||||
|
||||
// Default behavior
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Editor instance template function.
|
||||
*/
|
||||
function TinyMCE_advanced_getEditorTemplate(settings) {
|
||||
function removeFromArray(in_array, remove_array) {
|
||||
var outArray = new Array();
|
||||
for (var i=0; i<in_array.length; i++) {
|
||||
skip = false;
|
||||
|
||||
for (var j=0; j<remove_array.length; j++) {
|
||||
if (in_array[i] == remove_array[j])
|
||||
skip = true;
|
||||
}
|
||||
|
||||
if (!skip)
|
||||
outArray[outArray.length] = in_array[i];
|
||||
}
|
||||
|
||||
return outArray;
|
||||
}
|
||||
|
||||
function addToArray(in_array, add_array) {
|
||||
for (var i=0; i<add_array.length; i++)
|
||||
in_array[in_array.length] = add_array[i];
|
||||
|
||||
return in_array;
|
||||
}
|
||||
|
||||
var template = new Array();
|
||||
var deltaHeight = 0;
|
||||
|
||||
//###########################################################################################################
|
||||
// <Layout Manager Modification by SlyD, 14.1.2005>
|
||||
//###########################################################################################################
|
||||
|
||||
var pathHTML = '{$lang_theme_path}: <span id="{$editor_id}_path"> </span>';
|
||||
var layoutManager = tinyMCE.getParam("theme_advanced_layout_manager", "SimpleLayout");
|
||||
|
||||
switch(layoutManager) {
|
||||
case "SimpleLayout" : //the default TinyMCE Layout (for backwards compatibility)...
|
||||
var toolbarHTML = "";
|
||||
var toolbarLocation = tinyMCE.getParam("theme_advanced_toolbar_location", "bottom");
|
||||
var toolbarAlign = tinyMCE.getParam("theme_advanced_toolbar_align", "center");
|
||||
var pathLocation = tinyMCE.getParam("theme_advanced_path_location", "none");
|
||||
|
||||
// Render row 1
|
||||
var buttonNamesRow1 = tinyMCE.getParam("theme_advanced_buttons1", "bold,italic,underline,strikethrough,separator,justifyleft,justifycenter,justifyright,justifyfull,separator,styleselect,formatselect", true, ',');
|
||||
buttonNamesRow1 = removeFromArray(buttonNamesRow1, tinyMCE.getParam("theme_advanced_disable", "", true, ','));
|
||||
buttonNamesRow1 = addToArray(buttonNamesRow1, tinyMCE.getParam("theme_advanced_buttons1_add", "", true, ','));
|
||||
buttonNamesRow1 = addToArray(tinyMCE.getParam("theme_advanced_buttons1_add_before", "", true, ','), buttonNamesRow1);
|
||||
for (var i=0; i<buttonNamesRow1.length; i++)
|
||||
toolbarHTML += tinyMCE.getControlHTML(buttonNamesRow1[i]);
|
||||
|
||||
if (buttonNamesRow1.length > 0) {
|
||||
toolbarHTML += "<br />";
|
||||
deltaHeight -= 23;
|
||||
}
|
||||
|
||||
// Render row 2
|
||||
var buttonNamesRow2 = tinyMCE.getParam("theme_advanced_buttons2", "bullist,numlist,separator,outdent,indent,separator,undo,redo,separator,link,unlink,anchor,image,cleanup,help,code", true, ',');
|
||||
buttonNamesRow2 = removeFromArray(buttonNamesRow2, tinyMCE.getParam("theme_advanced_disable", "", true, ','));
|
||||
buttonNamesRow2 = addToArray(buttonNamesRow2, tinyMCE.getParam("theme_advanced_buttons2_add", "", true, ','));
|
||||
buttonNamesRow2 = addToArray(tinyMCE.getParam("theme_advanced_buttons2_add_before", "", true, ','), buttonNamesRow2);
|
||||
for (var i=0; i<buttonNamesRow2.length; i++)
|
||||
toolbarHTML += tinyMCE.getControlHTML(buttonNamesRow2[i]);
|
||||
|
||||
if (buttonNamesRow2.length > 0) {
|
||||
toolbarHTML += "<br />";
|
||||
deltaHeight -= 23;
|
||||
}
|
||||
|
||||
// Render row 3
|
||||
var buttonNamesRow3 = tinyMCE.getParam("theme_advanced_buttons3", "hr,removeformat,visualaid,separator,sub,sup,separator,charmap", true, ',');
|
||||
buttonNamesRow3 = removeFromArray(buttonNamesRow3, tinyMCE.getParam("theme_advanced_disable", "", true, ','));
|
||||
buttonNamesRow3 = addToArray(buttonNamesRow3, tinyMCE.getParam("theme_advanced_buttons3_add", "", true, ','));
|
||||
buttonNamesRow3 = addToArray(tinyMCE.getParam("theme_advanced_buttons3_add_before", "", true, ','), buttonNamesRow3);
|
||||
for (var i=0; i<buttonNamesRow3.length; i++)
|
||||
toolbarHTML += tinyMCE.getControlHTML(buttonNamesRow3[i]);
|
||||
|
||||
if (buttonNamesRow3.length > 0)
|
||||
deltaHeight -= 20;
|
||||
|
||||
// Setup template html
|
||||
template['html'] = '<table class="mceEditor" border="0" cellpadding="0" cellspacing="0" width="{$width}" height="{$height}"><tbody>';
|
||||
|
||||
if (toolbarLocation == "top")
|
||||
template['html'] += '<tr><td class="mceToolbarTop" align="' + toolbarAlign + '" height="1" nowrap="nowrap">' + toolbarHTML + '</td></tr>';
|
||||
|
||||
if (pathLocation == "top") {
|
||||
template['html'] += '<tr><td class="mcePathTop" height="1">' + pathHTML + '</td></tr>';
|
||||
deltaHeight -= 23;
|
||||
}
|
||||
|
||||
/* template['html'] += '<tr><td align="center">\
|
||||
<iframe id="{$editor_id}" class="mceEditorArea" border="1" frameborder="0" src="{$default_document}" marginwidth="0" marginheight="0" leftmargin="0" topmargin="0" style="width:{$area_width};height:{$area_height}" width="{$area_width}" height="{$area_height}"></iframe>\
|
||||
</td></tr>';*/
|
||||
template['html'] += '<tr><td align="center">\
|
||||
<span id="{$editor_id}"></span>\
|
||||
</td></tr>';
|
||||
|
||||
if (toolbarLocation == "bottom")
|
||||
template['html'] += '<tr><td class="mceToolbarBottom" align="' + toolbarAlign + '" height="1">' + toolbarHTML + '</td></tr>';
|
||||
|
||||
if (pathLocation == "bottom") {
|
||||
template['html'] += '<tr><td class="mcePathBottom" height="1">' + pathHTML + '</td></tr>';
|
||||
deltaHeight -= 23;
|
||||
}
|
||||
|
||||
template['html'] += '</table>';
|
||||
break;
|
||||
|
||||
case "RowLayout" : //Container Layout - containers defined in "theme_advanced_containers" are rendered from top to bottom.
|
||||
template['html'] = '<table class="mceEditor" border="0" cellpadding="0" cellspacing="0" width="{$width}" height="{$height}"><tbody>';
|
||||
|
||||
var containers = tinyMCE.getParam("theme_advanced_containers", "", true, ",");
|
||||
var defaultContainerCSS = tinyMCE.getParam("theme_advanced_containers_default_class", "container");
|
||||
var defaultContainerAlign = tinyMCE.getParam("theme_advanced_containers_default_align", "center");
|
||||
|
||||
//Render Containers:
|
||||
for(var i = 0; i < containers.length; i++)
|
||||
{
|
||||
if(containers[i] == "mceEditor") //Exceptions for mceEditor and ...
|
||||
{
|
||||
template['html'] += '<tr><td align="center" class="mceEditor_border">\
|
||||
<span id="{$editor_id}"></span>\
|
||||
</td></tr>';
|
||||
}
|
||||
else if(containers[i] == "mceElementpath") // ... mceElementpath:
|
||||
{
|
||||
var pathClass = "mcePath";
|
||||
|
||||
if (i == containers.length-1)
|
||||
pathClass = "mcePathBottom";
|
||||
else if (i == 0)
|
||||
pathClass = "mcePathTop";
|
||||
else
|
||||
deltaHeight-=2;
|
||||
|
||||
template['html'] += '<tr><td class="' + pathClass + '" height="1">' + pathHTML + '</td></tr>';
|
||||
deltaHeight -= 22;
|
||||
}
|
||||
else //Render normal Container:
|
||||
{
|
||||
var curContainer = tinyMCE.getParam("theme_advanced_container_"+containers[i], "", true, ',');
|
||||
var curContainerHTML = "";
|
||||
var curAlign = tinyMCE.getParam("theme_advanced_container_"+containers[i]+"_align", defaultContainerAlign);
|
||||
var curCSS = tinyMCE.getParam("theme_advanced_container_"+containers[i]+"_class", defaultContainerCSS);
|
||||
|
||||
for (var j=0; j<curContainer.length; j++)
|
||||
curContainerHTML += tinyMCE.getControlHTML(curContainer[j]);
|
||||
|
||||
if (curContainer.length > 0) {
|
||||
curContainerHTML += "<br />";
|
||||
deltaHeight -= 23;
|
||||
}
|
||||
|
||||
template['html'] += '<tr><td class="' + curCSS + '" align="' + curAlign + '" height="1">' + curContainerHTML + '</td></tr>';
|
||||
}
|
||||
}
|
||||
|
||||
template['html'] += '</tbody></table>';
|
||||
break;
|
||||
case "BorderLayout" : //will be like java.awt.BorderLayout of SUN Java...
|
||||
// Not implemented yet...
|
||||
break;
|
||||
case "CustomLayout" : //User defined layout callback...
|
||||
var customLayout = tinyMCE.getParam("theme_advanced_custom_layout","");
|
||||
if (customLayout != "" && eval("typeof(" + customLayout + ")") != "undefined")
|
||||
template = eval(customLayout + "(template);");
|
||||
break;
|
||||
default:
|
||||
alert('UNDEFINED LAYOUT MANAGER! PLEASE CHECK YOUR TINYMCE CONFIG!');
|
||||
break;
|
||||
}
|
||||
|
||||
//###########################################################################################################
|
||||
// </Modification by SlyD, 14.1.2005>
|
||||
//###########################################################################################################
|
||||
|
||||
// Setup style select options
|
||||
var styleSelectHTML = '<option value="">-- {$lang_theme_style_select} --</option>';
|
||||
if (settings['theme_advanced_styles']) {
|
||||
var stylesAr = settings['theme_advanced_styles'].split(';');
|
||||
for (var i=0; i<stylesAr.length; i++) {
|
||||
var key, value;
|
||||
|
||||
key = stylesAr[i].split('=')[0];
|
||||
value = stylesAr[i].split('=')[1];
|
||||
|
||||
styleSelectHTML += '<option value="' + value + '">' + key + '</option>';
|
||||
}
|
||||
|
||||
TinyMCE_advanced_autoImportCSSClasses = false;
|
||||
}
|
||||
|
||||
template['html'] = tinyMCE.replaceVar(template['html'], 'style_select_options', styleSelectHTML);
|
||||
template['delta_width'] = 0;
|
||||
template['delta_height'] = deltaHeight;
|
||||
|
||||
return template;
|
||||
}
|
||||
|
||||
/**
|
||||
* Insert link template function.
|
||||
*/
|
||||
function TinyMCE_advanced_getInsertLinkTemplate() {
|
||||
var template = new Array();
|
||||
|
||||
template['file'] = 'link.htm';
|
||||
template['width'] = 300;
|
||||
template['height'] = 150;
|
||||
|
||||
// Language specific width and height addons
|
||||
template['width'] += tinyMCE.getLang('lang_insert_link_delta_width', 0);
|
||||
template['height'] += tinyMCE.getLang('lang_insert_link_delta_height', 0);
|
||||
|
||||
return template;
|
||||
}
|
||||
|
||||
/**
|
||||
* Insert image template function.
|
||||
*/
|
||||
function TinyMCE_advanced_getInsertImageTemplate() {
|
||||
var template = new Array();
|
||||
|
||||
template['file'] = 'image.htm?src={$src}';
|
||||
template['width'] = 340;
|
||||
template['height'] = 280;
|
||||
|
||||
// Language specific width and height addons
|
||||
template['width'] += tinyMCE.getLang('lang_insert_image_delta_width', 0);
|
||||
template['height'] += tinyMCE.getLang('lang_insert_image_delta_height', 0);
|
||||
|
||||
return template;
|
||||
}
|
||||
|
||||
/**
|
||||
* Node change handler.
|
||||
*/
|
||||
function TinyMCE_advanced_handleNodeChange(editor_id, node, undo_index, undo_levels, visual_aid, any_selection) {
|
||||
function selectByValue(select_elm, value) {
|
||||
if (select_elm) {
|
||||
for (var i=0; i<select_elm.options.length; i++) {
|
||||
if (select_elm.options[i].value == value) {
|
||||
select_elm.selectedIndex = i;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
// No node provided
|
||||
if (node == null)
|
||||
return;
|
||||
|
||||
// Update path
|
||||
var pathElm = document.getElementById(editor_id + "_path");
|
||||
if (pathElm) {
|
||||
// Get node path
|
||||
var parentNode = node;
|
||||
var path = new Array();
|
||||
while (parentNode) {
|
||||
if (parentNode.nodeName.toLowerCase() == "body")
|
||||
break;
|
||||
|
||||
// Only append element nodes to path
|
||||
if (parentNode.nodeType == 1)
|
||||
path[path.length] = parentNode;
|
||||
|
||||
parentNode = parentNode.parentNode;
|
||||
}
|
||||
|
||||
// Setup HTML
|
||||
var html = "";
|
||||
for (var i=path.length-1; i>=0; i--) {
|
||||
var nodeName = path[i].nodeName.toLowerCase();
|
||||
var nodeData = "";
|
||||
var className = tinyMCE.getVisualAidClass(tinyMCE.getAttrib(path[i], 'class'), false);
|
||||
|
||||
if (nodeName == "b")
|
||||
nodeName = "strong";
|
||||
|
||||
if (nodeName == "i")
|
||||
nodeName = "em";
|
||||
|
||||
if (tinyMCE.getAttrib(path[i], 'id') != "")
|
||||
nodeData += "id: " + path[i].getAttribute('id') + " ";
|
||||
|
||||
if (className != "")
|
||||
nodeData += "class: " + className + " ";
|
||||
|
||||
if (tinyMCE.getAttrib(path[i], 'src') != "")
|
||||
nodeData += "src: " + path[i].getAttribute('src') + " ";
|
||||
|
||||
if (tinyMCE.getAttrib(path[i], 'href') != "")
|
||||
nodeData += "href: " + path[i].getAttribute('href') + " ";
|
||||
|
||||
if (nodeName == "img" && tinyMCE.getAttrib(path[i], 'name') == "mce_plugin_flash") {
|
||||
nodeName = "flash";
|
||||
nodeData = "";
|
||||
}
|
||||
|
||||
if (tinyMCE.getAttrib(path[i], 'name').indexOf("mce_") != 0) {
|
||||
if (className != "")
|
||||
nodeName += "." + className;
|
||||
}
|
||||
|
||||
if (tinyMCE.isMSIE || tinyMCE.isSafari)
|
||||
html += '<a title="' + nodeData + '" href="javascript:void(0);" onmousedown="tinyMCE.execInstanceCommand(\'' + editor_id + '\',\'mceSelectNodeDepth\',false,\'' + i + '\');return false;" class="mcePathItem">' + nodeName + '</a>';
|
||||
else
|
||||
html += '<a title="' + nodeData + '" href="javascript:tinyMCE.execInstanceCommand(\'' + editor_id + '\',\'mceSelectNodeDepth\',false,\'' + i + '\');" class="mcePathItem">' + nodeName + '</a>';
|
||||
|
||||
if (i > 0)
|
||||
html += " » ";
|
||||
}
|
||||
|
||||
pathElm.innerHTML = html + " ";
|
||||
}
|
||||
|
||||
// Get element color
|
||||
var colorElm = tinyMCE.getParentElement(node, "font", "color");
|
||||
if (colorElm)
|
||||
TinyMCE_advanced_foreColor = "" + colorElm.color.toUpperCase();
|
||||
|
||||
// Reset old states
|
||||
tinyMCE.switchClassSticky(editor_id + '_justifyleft', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_justifyright', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_justifycenter', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_justifyfull', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_bold', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_italic', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_underline', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_strikethrough', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_bullist', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_numlist', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_sub', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_sup', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_anchor', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_link', 'mceButtonDisabled', true);
|
||||
tinyMCE.switchClassSticky(editor_id + '_unlink', 'mceButtonDisabled', true);
|
||||
tinyMCE.switchClassSticky(editor_id + '_outdent', 'mceButtonDisabled', true);
|
||||
tinyMCE.switchClassSticky(editor_id + '_image', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_hr', 'mceButtonNormal');
|
||||
|
||||
// Get anchor name
|
||||
var anchorName = tinyMCE.getParentElement(node, "a", "name");
|
||||
TinyMCE_advanced_anchorName = "";
|
||||
if (anchorName) {
|
||||
TinyMCE_advanced_anchorName = anchorName.getAttribute("name");
|
||||
tinyMCE.switchClassSticky(editor_id + '_anchor', 'mceButtonSelected');
|
||||
}
|
||||
|
||||
// Get link
|
||||
var anchorLink = tinyMCE.getParentElement(node, "a", "href");
|
||||
if (anchorLink || any_selection) {
|
||||
tinyMCE.switchClassSticky(editor_id + '_link', anchorLink ? 'mceButtonSelected' : 'mceButtonNormal', false);
|
||||
tinyMCE.switchClassSticky(editor_id + '_unlink', anchorLink ? 'mceButtonSelected' : 'mceButtonNormal', false);
|
||||
}
|
||||
|
||||
// Handle visual aid
|
||||
tinyMCE.switchClassSticky(editor_id + '_visualaid', visual_aid ? 'mceButtonSelected' : 'mceButtonNormal', false);
|
||||
|
||||
if (undo_levels != -1) {
|
||||
tinyMCE.switchClassSticky(editor_id + '_undo', 'mceButtonDisabled', true);
|
||||
tinyMCE.switchClassSticky(editor_id + '_redo', 'mceButtonDisabled', true);
|
||||
}
|
||||
|
||||
// Within li, blockquote
|
||||
if (tinyMCE.getParentElement(node, "li,blockquote"))
|
||||
tinyMCE.switchClassSticky(editor_id + '_outdent', 'mceButtonNormal', false);
|
||||
|
||||
// Has redo levels
|
||||
if (undo_index != -1 && (undo_index < undo_levels-1 && undo_levels > 0))
|
||||
tinyMCE.switchClassSticky(editor_id + '_redo', 'mceButtonNormal', false);
|
||||
|
||||
// Has undo levels
|
||||
if (undo_index != -1 && (undo_index > 0 && undo_levels > 0))
|
||||
tinyMCE.switchClassSticky(editor_id + '_undo', 'mceButtonNormal', false);
|
||||
|
||||
// Select class in select box
|
||||
var selectElm = document.getElementById(editor_id + "_styleSelect");
|
||||
if (selectElm) {
|
||||
TinyMCE_advanced_setupCSSClasses(editor_id);
|
||||
|
||||
classNode = node;
|
||||
breakOut = false;
|
||||
var index = 0;
|
||||
|
||||
do {
|
||||
if (classNode && classNode.className) {
|
||||
for (var i=0; i<selectElm.options.length; i++) {
|
||||
if (selectElm.options[i].value == classNode.className) {
|
||||
index = i;
|
||||
breakOut = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} while (!breakOut && classNode != null && (classNode = classNode.parentNode));
|
||||
|
||||
selectElm.selectedIndex = index;
|
||||
}
|
||||
|
||||
// Select formatblock
|
||||
var selectElm = document.getElementById(editor_id + "_formatSelect");
|
||||
if (selectElm) {
|
||||
var elm = tinyMCE.getParentElement(node, "p,div,h1,h2,h3,h4,h5,h6,pre,address");
|
||||
if (elm) {
|
||||
selectByValue(selectElm, "<" + elm.nodeName.toLowerCase() + ">");
|
||||
} else
|
||||
selectByValue(selectElm, "<p>");
|
||||
}
|
||||
|
||||
// Select fontselect
|
||||
var selectElm = document.getElementById(editor_id + "_fontNameSelect");
|
||||
if (selectElm) {
|
||||
var elm = tinyMCE.getParentElement(node, "font", "face");
|
||||
if (elm)
|
||||
selectByValue(selectElm, elm.getAttribute("face"));
|
||||
else
|
||||
selectByValue(selectElm, "");
|
||||
}
|
||||
|
||||
// Select fontsize
|
||||
var selectElm = document.getElementById(editor_id + "_fontSizeSelect");
|
||||
if (selectElm) {
|
||||
var elm = tinyMCE.getParentElement(node, "font", "size");
|
||||
if (elm && tinyMCE.getAttrib(elm, "size") != "")
|
||||
selectByValue(selectElm, elm.getAttribute("size"));
|
||||
else
|
||||
selectByValue(selectElm, "0");
|
||||
}
|
||||
|
||||
// Handle align attributes
|
||||
alignNode = node;
|
||||
breakOut = false;
|
||||
do {
|
||||
if (!alignNode.getAttribute || !alignNode.getAttribute('align'))
|
||||
continue;
|
||||
|
||||
switch (alignNode.getAttribute('align').toLowerCase()) {
|
||||
case "left":
|
||||
tinyMCE.switchClassSticky(editor_id + '_justifyleft', 'mceButtonSelected');
|
||||
breakOut = true;
|
||||
break;
|
||||
|
||||
case "right":
|
||||
tinyMCE.switchClassSticky(editor_id + '_justifyright', 'mceButtonSelected');
|
||||
breakOut = true;
|
||||
break;
|
||||
|
||||
case "middle":
|
||||
case "center":
|
||||
tinyMCE.switchClassSticky(editor_id + '_justifycenter', 'mceButtonSelected');
|
||||
breakOut = true;
|
||||
break;
|
||||
|
||||
case "justify":
|
||||
tinyMCE.switchClassSticky(editor_id + '_justifyfull', 'mceButtonSelected');
|
||||
breakOut = true;
|
||||
break;
|
||||
}
|
||||
} while (!breakOut && (alignNode = alignNode.parentNode));
|
||||
|
||||
// Do special text
|
||||
if (tinyMCE.isGecko && node.nodeType == 3) {
|
||||
var inst = tinyMCE.getInstanceById(editor_id);
|
||||
var doc = inst.getDoc();
|
||||
|
||||
if (doc.queryCommandState("Bold"))
|
||||
tinyMCE.switchClassSticky(editor_id + '_bold', 'mceButtonSelected');
|
||||
|
||||
if (doc.queryCommandState("Italic"))
|
||||
tinyMCE.switchClassSticky(editor_id + '_italic', 'mceButtonSelected');
|
||||
|
||||
if (doc.queryCommandState("Underline") && (node.parentNode == null || node.parentNode.nodeName != "A"))
|
||||
tinyMCE.switchClassSticky(editor_id + '_underline', 'mceButtonSelected');
|
||||
|
||||
if (doc.queryCommandState("Strikethrough"))
|
||||
tinyMCE.switchClassSticky(editor_id + '_strikethrough', 'mceButtonSelected');
|
||||
}
|
||||
|
||||
// Handle elements
|
||||
do {
|
||||
switch (node.nodeName.toLowerCase()) {
|
||||
case "b":
|
||||
case "strong":
|
||||
tinyMCE.switchClassSticky(editor_id + '_bold', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "i":
|
||||
case "em":
|
||||
tinyMCE.switchClassSticky(editor_id + '_italic', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "u":
|
||||
tinyMCE.switchClassSticky(editor_id + '_underline', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "strike":
|
||||
tinyMCE.switchClassSticky(editor_id + '_strikethrough', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "ul":
|
||||
tinyMCE.switchClassSticky(editor_id + '_bullist', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "ol":
|
||||
tinyMCE.switchClassSticky(editor_id + '_numlist', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "sub":
|
||||
tinyMCE.switchClassSticky(editor_id + '_sub', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "sup":
|
||||
tinyMCE.switchClassSticky(editor_id + '_sup', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "hr":
|
||||
tinyMCE.switchClassSticky(editor_id + '_hr', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "img":
|
||||
if (tinyMCE.getAttrib(node, 'name').indexOf('mce_') != 0)
|
||||
tinyMCE.switchClassSticky(editor_id + '_image', 'mceButtonSelected');
|
||||
break;
|
||||
}
|
||||
} while ((node = node.parentNode));
|
||||
}
|
||||
|
||||
// This function auto imports CSS classes into the class selection droplist
|
||||
function TinyMCE_advanced_setupCSSClasses(editor_id) {
|
||||
if (!TinyMCE_advanced_autoImportCSSClasses)
|
||||
return;
|
||||
|
||||
var selectElm = document.getElementById(editor_id + '_styleSelect');
|
||||
|
||||
if (selectElm && selectElm.getAttribute('cssImported') != 'true') {
|
||||
var csses = tinyMCE.getCSSClasses(editor_id);
|
||||
if (csses && selectElm) {
|
||||
for (var i=0; i<csses.length; i++)
|
||||
selectElm.options[selectElm.length] = new Option(csses[i], csses[i]);
|
||||
}
|
||||
|
||||
// Only do this once
|
||||
if (csses != null && csses.length > 0)
|
||||
selectElm.setAttribute('cssImported', 'true');
|
||||
}
|
||||
}
|
148
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/editor_ui.css
vendored
Normal file
148
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/editor_ui.css
vendored
Normal file
@ -0,0 +1,148 @@
|
||||
.mceButtonNormal, .mceButtonOver, .mceButtonDown, .mceSeparator, .mceButtonDisabled, .mceButtonSelected {
|
||||
margin-top: 1px;
|
||||
margin-left: 1px;
|
||||
}
|
||||
|
||||
.mceButtonNormal {
|
||||
border-top: 1px solid;
|
||||
border-left: 1px solid;
|
||||
border-bottom: 1px solid;
|
||||
border-right: 1px solid;
|
||||
border-color: #F0F0EE;
|
||||
cursor: arrow;
|
||||
}
|
||||
|
||||
.mceButtonOver {
|
||||
/* border-top: 1px solid buttonhighlight;
|
||||
border-left: 1px solid buttonhighlight;
|
||||
border-bottom: 1px solid buttonshadow;
|
||||
border-right: 1px solid buttonshadow;*/
|
||||
border: 1px solid #0A246A;
|
||||
cursor: arrow;
|
||||
background-color: #B6BDD2;
|
||||
}
|
||||
|
||||
.mceButtonDown {
|
||||
/* border-bottom: 1px solid buttonhighlight;
|
||||
border-right: 1px solid buttonhighlight;
|
||||
border-top: 1px solid buttonshadow;
|
||||
border-left: 1px solid buttonshadow;*/
|
||||
cursor: arrow;
|
||||
border: 1px solid #0A246A;
|
||||
background-color: #8592B5;
|
||||
}
|
||||
|
||||
.mceButtonSelected {
|
||||
border: 1px solid;
|
||||
border-color: #C0C0BB;
|
||||
cursor: arrow;
|
||||
}
|
||||
|
||||
.mceButtonDisabled {
|
||||
filter:progid:DXImageTransform.Microsoft.Alpha(opacity=30);
|
||||
-moz-opacity:0.3;
|
||||
opacity: 0.3;
|
||||
border-top: 1px solid;
|
||||
border-left: 1px solid;
|
||||
border-bottom: 1px solid;
|
||||
border-right: 1px solid;
|
||||
border-color: #F0F0EE;
|
||||
cursor: arrow;
|
||||
}
|
||||
|
||||
.mceSeparator {
|
||||
border-top: 1px solid buttonhighlight;
|
||||
border-left: 1px solid buttonhighlight;
|
||||
border-bottom: 1px solid buttonshadow;
|
||||
border-right: 1px solid buttonshadow;
|
||||
margin-right: 2px;
|
||||
margin-left: 2px;
|
||||
}
|
||||
|
||||
.mceSeparatorLine {
|
||||
margin:2px;
|
||||
margin-left: 4px;
|
||||
background-color: #F0F0EE;
|
||||
border-top: 1px solid buttonshadow;
|
||||
border-left: 1px solid buttonshadow;
|
||||
border-bottom: 1px solid buttonhighlight;
|
||||
border-right: 1px solid buttonhighlight;
|
||||
width: 0px;
|
||||
height: 15px;
|
||||
}
|
||||
|
||||
.mceSelectList {
|
||||
font-family: "MS Sans Serif";
|
||||
font-size: 7pt;
|
||||
font-weight: normal;
|
||||
margin-top: 3px;
|
||||
padding: 0px;
|
||||
display: inline;
|
||||
vertical-align: top;
|
||||
background-color: #F0F0EE
|
||||
}
|
||||
|
||||
.mceLabel, .mceLabelDisabled {
|
||||
font-family: "MS Sans Serif";
|
||||
font-size: 9pt;
|
||||
}
|
||||
|
||||
.mceLabel {
|
||||
color: #000000;
|
||||
}
|
||||
|
||||
.mceLabelDisabled {
|
||||
cursor: text;
|
||||
color: #999999;
|
||||
}
|
||||
|
||||
.mceEditor {
|
||||
background: #F0F0EE;
|
||||
border: 1px solid #cccccc;
|
||||
}
|
||||
|
||||
.mceEditorArea {
|
||||
font-family: "MS Sans Serif";
|
||||
background: #FFFFFF;
|
||||
}
|
||||
|
||||
.mceToolbarTop, .mceToolbarBottom {
|
||||
background: #F0F0EE;
|
||||
}
|
||||
|
||||
.mceToolbarTop {
|
||||
border-bottom: 1px solid #cccccc;
|
||||
}
|
||||
|
||||
.mceToolbarBottom {
|
||||
border-top: 1px solid #cccccc;
|
||||
}
|
||||
|
||||
.mcePathTop, .mcePathBottom, .mcePath {
|
||||
font-family: "MS Sans Serif";
|
||||
font-size: 9pt;
|
||||
padding: 2px;
|
||||
height: 20px;
|
||||
}
|
||||
|
||||
.mcePathTop {
|
||||
border-bottom: 1px solid #cccccc;
|
||||
}
|
||||
|
||||
.mcePathBottom {
|
||||
border-top: 1px solid #cccccc;
|
||||
}
|
||||
|
||||
.mcePathItem, .mcePathItem:link, .mcePathItem:visited, .mcePathItem:hover {
|
||||
text-decoration: none;
|
||||
font-family: "MS Sans Serif";
|
||||
font-size: 9pt;
|
||||
}
|
||||
|
||||
.mcePathItem:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
.mcePath {
|
||||
border-bottom: 1px solid #cccccc;
|
||||
}
|
193
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/image.htm
vendored
Normal file
193
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/image.htm
vendored
Normal file
@ -0,0 +1,193 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_insert_image_title}</title>
|
||||
<script language="javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script language="javascript">
|
||||
var url = tinyMCE.getParam("external_image_list_url");
|
||||
if (url != null) {
|
||||
// Fix relative
|
||||
if (url.charAt(0) != '/')
|
||||
url = tinyMCE.documentBasePath + "/" + url;
|
||||
|
||||
document.write('<sc'+'ript language="javascript" type="text/javascript" src="' + url + '?rnd=' + new Date().getTime() + '"></sc'+'ript>');
|
||||
}
|
||||
</script>
|
||||
<script language="javascript">
|
||||
// Disable auto resize
|
||||
tinyMCE.getWindowArg('mce_windowresize', false);
|
||||
|
||||
function insertImage() {
|
||||
if (window.opener) {
|
||||
var src = document.forms[0].src.value;
|
||||
var alt = document.forms[0].alt.value;
|
||||
var border = document.forms[0].border.value;
|
||||
var vspace = document.forms[0].vspace.value;
|
||||
var hspace = document.forms[0].hspace.value;
|
||||
var width = document.forms[0].width.value;
|
||||
var height = document.forms[0].height.value;
|
||||
var align = document.forms[0].align.options[document.forms[0].align.selectedIndex].value;
|
||||
|
||||
window.opener.tinyMCE.insertImage(src, alt, border, hspace, vspace, width, height, align);
|
||||
top.close();
|
||||
}
|
||||
}
|
||||
|
||||
function init() {
|
||||
var formObj = document.forms[0];
|
||||
|
||||
for (var i=0; i<document.forms[0].align.options.length; i++) {
|
||||
if (document.forms[0].align.options[i].value == tinyMCE.getWindowArg('align'))
|
||||
document.forms[0].align.options.selectedIndex = i;
|
||||
}
|
||||
|
||||
formObj.src.value = tinyMCE.getWindowArg('src');
|
||||
formObj.alt.value = tinyMCE.getWindowArg('alt');
|
||||
formObj.border.value = tinyMCE.getWindowArg('border');
|
||||
formObj.vspace.value = tinyMCE.getWindowArg('vspace');
|
||||
formObj.hspace.value = tinyMCE.getWindowArg('hspace');
|
||||
formObj.width.value = tinyMCE.getWindowArg('width');
|
||||
formObj.height.value = tinyMCE.getWindowArg('height');
|
||||
formObj.insert.value = tinyMCE.getLang('lang_' + tinyMCE.getWindowArg('action'), 'Insert', true);
|
||||
|
||||
// Handle file browser
|
||||
if (tinyMCE.getParam("file_browser_callback") != null) {
|
||||
document.getElementById('src').style.width = '180px';
|
||||
|
||||
var html = '';
|
||||
|
||||
html += '<img id="browserBtn" src="images/browse.gif"';
|
||||
html += ' onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');"';
|
||||
html += ' onmouseout="tinyMCE.restoreClass(this);"';
|
||||
html += ' onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');"';
|
||||
html += ' onclick="javascript:tinyMCE.openFileBrowser(\'src\',document.forms[0].src.value,\'image\',window);"';
|
||||
html += ' width="20" height="18" border="0" title="' + tinyMCE.getLang('lang_browse') + '"';
|
||||
html += ' class="mceButtonNormal" alt="' + tinyMCE.getLang('lang_browse') + '" />';
|
||||
|
||||
document.getElementById('browser').innerHTML = html;
|
||||
}
|
||||
|
||||
// Auto select image in list
|
||||
if (typeof(tinyMCEImageList) != "undefined" && tinyMCEImageList.length > 0) {
|
||||
for (var i=0; i<formObj.image_list.length; i++) {
|
||||
if (formObj.image_list.options[i].value == tinyMCE.getWindowArg('src'))
|
||||
formObj.image_list.options[i].selected = true;
|
||||
}
|
||||
}
|
||||
|
||||
// Autoresize and focus
|
||||
TinyMCEPopup_autoResize();
|
||||
window.focus();
|
||||
}
|
||||
|
||||
function cancelAction() {
|
||||
top.close();
|
||||
}
|
||||
|
||||
var preloadImg = new Image();
|
||||
|
||||
function resetImageData() {
|
||||
var formObj = document.forms[0];
|
||||
formObj.width.value = formObj.height.value = "";
|
||||
}
|
||||
|
||||
function updateImageData() {
|
||||
var formObj = document.forms[0];
|
||||
|
||||
if (formObj.width.value == "")
|
||||
formObj.width.value = preloadImg.width;
|
||||
|
||||
if (formObj.height.value == "")
|
||||
formObj.height.value = preloadImg.height;
|
||||
}
|
||||
|
||||
function getImageData() {
|
||||
preloadImg = new Image();
|
||||
tinyMCE.addEvent(preloadImg, "load", updateImageData);
|
||||
tinyMCE.addEvent(preloadImg, "error", function () {var formObj = document.forms[0];formObj.width.value = formObj.height.value = "";});
|
||||
preloadImg.src = tinyMCE.convertRelativeToAbsoluteURL(tinyMCE.settings['base_href'], document.forms[0].src.value);
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body onload="window.focus();init();">
|
||||
<form onsubmit="insertImage();return false;">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="200">
|
||||
<tr>
|
||||
<td align="center" valign="middle"><table border="0" cellpadding="4" cellspacing="0">
|
||||
<tr>
|
||||
<td colspan="2" class="title" nowrap="nowrap">{$lang_insert_image_title}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td nowrap="nowrap">{$lang_insert_image_src}:</td>
|
||||
<td><table border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td><input name="src" type="text" id="src" value="" style="width: 200px" onchange="getImageData();"></td>
|
||||
<td id="browser"></td>
|
||||
</tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
<!-- Image list -->
|
||||
<script language="javascript">
|
||||
if (typeof(tinyMCEImageList) != "undefined" && tinyMCEImageList.length > 0) {
|
||||
var html = "";
|
||||
|
||||
html += '<tr><td>{$lang_image_list}:</td>';
|
||||
html += '<td><select name="image_list" style="width: 200px" onchange="this.form.src.value=this.options[this.selectedIndex].value;resetImageData();getImageData();">';
|
||||
html += '<option value="">---</option>';
|
||||
|
||||
for (var i=0; i<tinyMCEImageList.length; i++)
|
||||
html += '<option value="' + tinyMCEImageList[i][1] + '">' + tinyMCEImageList[i][0] + '</option>';
|
||||
|
||||
html += '</select></td></tr>';
|
||||
|
||||
document.write(html);
|
||||
}
|
||||
</script>
|
||||
<!-- /Image list -->
|
||||
<tr>
|
||||
<td nowrap="nowrap">{$lang_insert_image_alt}:</td>
|
||||
<td><input name="alt" type="text" id="alt" value="" style="width: 200px"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td nowrap="nowrap">{$lang_insert_image_align}:</td>
|
||||
<td><select name="align">
|
||||
<option value="">{$lang_insert_image_align_default}</option>
|
||||
<option value="baseline">{$lang_insert_image_align_baseline}</option>
|
||||
<option value="top">{$lang_insert_image_align_top}</option>
|
||||
<option value="middle">{$lang_insert_image_align_middle}</option>
|
||||
<option value="bottom">{$lang_insert_image_align_bottom}</option>
|
||||
<option value="texttop">{$lang_insert_image_align_texttop}</option>
|
||||
<option value="absmiddle">{$lang_insert_image_align_absmiddle}</option>
|
||||
<option value="absbottom">{$lang_insert_image_align_absbottom}</option>
|
||||
<option value="left">{$lang_insert_image_align_left}</option>
|
||||
<option value="right">{$lang_insert_image_align_right}</option>
|
||||
</select></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td nowrap="nowrap">{$lang_insert_image_dimensions}:</td>
|
||||
<td><input name="width" type="text" id="width" value="" size="3" maxlength="3">
|
||||
x
|
||||
<input name="height" type="text" id="height" value="" size="3" maxlength="3"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td nowrap="nowrap">{$lang_insert_image_border}:</td>
|
||||
<td><input name="border" type="text" id="border" value="" size="3" maxlength="3"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td nowrap="nowrap">{$lang_insert_image_vspace}:</td>
|
||||
<td><input name="vspace" type="text" id="vspace" value="" size="3" maxlength="3"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td nowrap="nowrap">{$lang_insert_image_hspace}:</td>
|
||||
<td><input name="hspace" type="text" id="hspace" value="" size="3" maxlength="3"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td nowrap="nowrap"><input type="button" id="insert" name="insert" value="{$lang_insert}" onclick="insertImage();">
|
||||
</td>
|
||||
<td align="right"><input type="button" id="cancel" name="cancel" value="{$lang_cancel}" onclick="cancelAction();"></td>
|
||||
</tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
135
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/link.htm
vendored
Normal file
135
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/link.htm
vendored
Normal file
@ -0,0 +1,135 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_insert_link_title}</title>
|
||||
<script language="javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script language="javascript">
|
||||
var url = tinyMCE.getParam("external_link_list_url");
|
||||
if (url != null) {
|
||||
// Fix relative
|
||||
if (url.charAt(0) != '/')
|
||||
url = tinyMCE.documentBasePath + "/" + url;
|
||||
|
||||
document.write('<sc'+'ript language="javascript" type="text/javascript" src="' + url + '?rnd=' + new Date().getTime() + '"></sc'+'ript>');
|
||||
}
|
||||
</script>
|
||||
<script language="javascript">
|
||||
// Disable auto resize
|
||||
tinyMCE.getWindowArg('mce_windowresize', false);
|
||||
|
||||
function init() {
|
||||
for (var i=0; i<document.forms[0].target.options.length; i++) {
|
||||
var option = document.forms[0].target.options[i];
|
||||
|
||||
if (option.value == tinyMCE.getWindowArg('target'))
|
||||
option.selected = true;
|
||||
}
|
||||
|
||||
document.forms[0].href.value = tinyMCE.getWindowArg('href');
|
||||
document.forms[0].linktitle.value = tinyMCE.getWindowArg('title');
|
||||
document.forms[0].insert.value = tinyMCE.getLang('lang_' + tinyMCE.getWindowArg('action'), 'Insert', true);
|
||||
|
||||
// Handle file browser
|
||||
if (tinyMCE.getParam("file_browser_callback") != null) {
|
||||
document.getElementById('href').style.width = '180px';
|
||||
|
||||
var html = '';
|
||||
|
||||
html += '<img id="browserBtn" src="images/browse.gif"';
|
||||
html += ' onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');"';
|
||||
html += ' onmouseout="tinyMCE.restoreClass(this);"';
|
||||
html += ' onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');"';
|
||||
html += ' onclick="javascript:tinyMCE.openFileBrowser(\'href\',document.forms[0].href.value,\'file\',window);"';
|
||||
html += ' width="20" height="18" border="0" title="' + tinyMCE.getLang('lang_browse') + '"';
|
||||
html += ' class="mceButtonNormal" alt="' + tinyMCE.getLang('lang_browse') + '" />';
|
||||
|
||||
document.getElementById('browser').innerHTML = html;
|
||||
}
|
||||
|
||||
// Auto select link in list
|
||||
if (typeof(tinyMCELinkList) != "undefined" && tinyMCELinkList.length > 0) {
|
||||
var formObj = document.forms[0];
|
||||
|
||||
for (var i=0; i<formObj.link_list.length; i++) {
|
||||
if (formObj.link_list.options[i].value == tinyMCE.getWindowArg('href'))
|
||||
formObj.link_list.options[i].selected = true;
|
||||
}
|
||||
}
|
||||
|
||||
// Autoresize and focus
|
||||
TinyMCEPopup_autoResize();
|
||||
window.focus();
|
||||
}
|
||||
|
||||
function insertLink() {
|
||||
if (window.opener) {
|
||||
var href = document.forms[0].href.value;
|
||||
var target = document.forms[0].target.options[document.forms[0].target.selectedIndex].value;
|
||||
var title = document.forms[0].linktitle.value;
|
||||
|
||||
window.opener.tinyMCE.insertLink(href, target, title);
|
||||
top.close();
|
||||
}
|
||||
}
|
||||
|
||||
function cancelAction() {
|
||||
top.close();
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body onload="init();">
|
||||
<form onsubmit="insertLink();return false;">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="100">
|
||||
<tr>
|
||||
<td align="center" valign="middle"><table border="0" cellpadding="4" cellspacing="0">
|
||||
<tr>
|
||||
<td colspan="2" class="title" nowrap="nowrap">{$lang_insert_link_title}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td nowrap="nowrap">{$lang_insert_link_url}:</td>
|
||||
<td> <table border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td><input name="href" type="text" id="href" value="" style="width: 200px"></td>
|
||||
<td id="browser"></td>
|
||||
</tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
<!-- Link list -->
|
||||
<script language="javascript">
|
||||
if (typeof(tinyMCELinkList) != "undefined" && tinyMCELinkList.length > 0) {
|
||||
var html = "";
|
||||
|
||||
html += '<tr><td>{$lang_link_list}:</td>';
|
||||
html += '<td><select name="link_list" style="width: 200px" onchange="this.form.href.value=this.options[this.selectedIndex].value;">';
|
||||
html += '<option value="">---</option>';
|
||||
|
||||
for (var i=0; i<tinyMCELinkList.length; i++)
|
||||
html += '<option value="' + tinyMCELinkList[i][1] + '">' + tinyMCELinkList[i][0] + '</option>';
|
||||
|
||||
html += '</select></td></tr>';
|
||||
|
||||
document.write(html);
|
||||
}
|
||||
</script>
|
||||
<!-- /Link list -->
|
||||
<tr>
|
||||
<td nowrap="nowrap">{$lang_insert_link_target}:</td>
|
||||
<td><select name="target" style="width: 200px">
|
||||
<option value="_self">{$lang_insert_link_target_same}</option>
|
||||
<option value="_blank">{$lang_insert_link_target_blank}</option>
|
||||
</select></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td nowrap="nowrap">{$lang_theme_insert_link_titlefield}:</td>
|
||||
<td><input name="linktitle" type="text" id="linktitle" value="" style="width: 200px"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><input type="button" id="insert" name="insert" value="{$lang_insert}" onclick="insertLink();">
|
||||
</td>
|
||||
<td align="right"><input type="button" id="cancel" name="cancel" value="{$lang_cancel}" onclick="cancelAction();"></td>
|
||||
</tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
88
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/source_editor.htm
vendored
Normal file
88
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/advanced/source_editor.htm
vendored
Normal file
@ -0,0 +1,88 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_theme_code_title}</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<script language="javascript" type="text/javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script language="javascript" type="text/javascript">
|
||||
<!--
|
||||
tinyMCE.setWindowArg('mce_windowresize', false);
|
||||
|
||||
function saveContent() {
|
||||
if (window.opener) {
|
||||
window.opener.tinyMCE.setContent(document.getElementById('htmlSource').value);
|
||||
window.close();
|
||||
}
|
||||
}
|
||||
|
||||
// Fixes some charcode issues
|
||||
function fixContent(html) {
|
||||
html = html.replace(new RegExp('<(p|hr|table|tr|td|ol|ul|object|embed|li|blockquote)', 'gi'),'\n<$1');
|
||||
html = html.replace(new RegExp('<\/(p|ol|ul|li|table|tr|td|blockquote|object)>', 'gi'),'</$1>\n');
|
||||
html = tinyMCE.regexpReplace(html, '<br />','<br />\n','gi');
|
||||
html = tinyMCE.regexpReplace(html, '\n\n','\n','gi');
|
||||
return html;
|
||||
}
|
||||
|
||||
function onLoadInit() {
|
||||
document.forms[0].htmlSource.value = fixContent(tinyMCE.getContent(tinyMCE.getWindowArg('editor_id')));
|
||||
resizeInputs();
|
||||
setWrap('off');
|
||||
}
|
||||
|
||||
function setWrap(val) {
|
||||
// hard soft off
|
||||
document.forms[0].htmlSource.wrap = val;
|
||||
}
|
||||
|
||||
function toggleWordWrap(elm) {
|
||||
if (elm.checked)
|
||||
setWrap('soft');
|
||||
else
|
||||
setWrap('off');
|
||||
}
|
||||
|
||||
var wHeight=0, wWidth=0, owHeight=0, owWidth=0;
|
||||
|
||||
function resizeInputs() {
|
||||
if (!tinyMCE.isMSIE) {
|
||||
wHeight = self.innerHeight-80;
|
||||
wWidth = self.innerWidth-25;
|
||||
} else {
|
||||
wHeight = document.body.clientHeight-80;
|
||||
wWidth = document.body.clientWidth-25;
|
||||
}
|
||||
|
||||
document.forms[0].htmlSource.style.height = Math.abs(wHeight) + 'px';
|
||||
document.forms[0].htmlSource.style.width = Math.abs(wWidth) + 'px';
|
||||
|
||||
}
|
||||
|
||||
window.focus();
|
||||
//-->
|
||||
</script>
|
||||
</head>
|
||||
<body scroll="no" onload="onLoadInit();" onresize="resizeInputs();">
|
||||
<form name="source" onsubmit="saveContent();">
|
||||
<table border="0" cellpadding="0" cellspacing="2" align="center">
|
||||
<tr>
|
||||
<td class="title">{$lang_theme_code_title}</td>
|
||||
<td align="right"><script language="javascript" type="text/javascript">
|
||||
<!--
|
||||
if (tinyMCE.isMSIE) {
|
||||
document.write('<input type="checkbox" name="wraped" id="wraped" onclick="toggleWordWrap(this);" class="wordWrapCode" /><label for="wraped">{$lang_theme_code_wordwrap}</label>');
|
||||
}
|
||||
//-->
|
||||
</script></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2" align="center">
|
||||
<textarea name="htmlSource" id="htmlSource" rows="15" cols="100" style="width: 100%; height: 100%; font-family: 'Courier New',Courier,mono; font-size: 12px;" dir="ltr" wrap="soft"></textarea>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2" align="right"><input type="button" id="insert" name="insert" value="{$lang_update}" onclick="saveContent();" /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
27
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/default/editor_content.css
vendored
Normal file
27
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/default/editor_content.css
vendored
Normal file
@ -0,0 +1,27 @@
|
||||
body {
|
||||
background-color: #FFFFFF;
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 10px;
|
||||
scrollbar-3dlight-color: #F0F0EE;
|
||||
scrollbar-arrow-color: #676662;
|
||||
scrollbar-base-color: #F0F0EE;
|
||||
scrollbar-darkshadow-color: #DDDDDD;
|
||||
scrollbar-face-color: #E0E0DD;
|
||||
scrollbar-highlight-color: #F0F0EE;
|
||||
scrollbar-shadow-color: #F0F0EE;
|
||||
scrollbar-track-color: #F5F5F5;
|
||||
}
|
||||
|
||||
td {
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 10px;
|
||||
}
|
||||
|
||||
pre {
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 10px;
|
||||
}
|
||||
|
||||
.mceVisualAid {
|
||||
border: 1px dashed #BBBBBB;
|
||||
}
|
41
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/default/editor_popup.css
vendored
Normal file
41
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/default/editor_popup.css
vendored
Normal file
@ -0,0 +1,41 @@
|
||||
body {
|
||||
background-color: #F0F0EE;
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 11px;
|
||||
scrollbar-3dlight-color: #F0F0EE;
|
||||
scrollbar-arrow-color: #676662;
|
||||
scrollbar-base-color: #F0F0EE;
|
||||
scrollbar-darkshadow-color: #DDDDDD;
|
||||
scrollbar-face-color: #E0E0DD;
|
||||
scrollbar-highlight-color: #F0F0EE;
|
||||
scrollbar-shadow-color: #F0F0EE;
|
||||
scrollbar-track-color: #F5F5F5;
|
||||
}
|
||||
|
||||
td {
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 11px;
|
||||
}
|
||||
|
||||
input {
|
||||
background: #FFFFFF;
|
||||
border: 1px solid #cccccc;
|
||||
}
|
||||
|
||||
td, input, select, textarea {
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 10px;
|
||||
}
|
||||
|
||||
input, select, textarea {
|
||||
border: 1px solid #808080;
|
||||
}
|
||||
|
||||
.input_noborder {
|
||||
border: 0px solid #808080;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 12px;
|
||||
font-weight: bold;
|
||||
}
|
32
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/default/editor_template.js
vendored
Normal file
32
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/default/editor_template.js
vendored
Normal file
@ -0,0 +1,32 @@
|
||||
function TinyMCE_default_getEditorTemplate(){var template=new Array();template['html']='\
|
||||
<table class="mceEditor" border="0" cellpadding="0" cellspacing="0" width="{$width}" height="{$height}">\
|
||||
<tr><td align="center">\
|
||||
<span id="{$editor_id}">IFRAME</span>\
|
||||
</td></tr>\
|
||||
<tr><td class="mceToolbar" align="center" height="1">\
|
||||
<img id="{$editor_id}_bold" src="{$themeurl}/images/{$lang_bold_img}" title="{$lang_bold_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Bold\')">\
|
||||
<img id="{$editor_id}_italic" src="{$themeurl}/images/{$lang_italic_img}" title="{$lang_italic_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Italic\')">\
|
||||
<img id="{$editor_id}_underline" src="{$themeurl}/images/{$lang_underline_img}" title="{$lang_underline_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Underline\')">\
|
||||
<img id="{$editor_id}_strikethrough" src="{$themeurl}/images/strikethrough.gif" title="{$lang_striketrough_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Strikethrough\')">\
|
||||
<img src="{$themeurl}/images/spacer.gif" width="1" height="15" class="mceSeparatorLine">\
|
||||
<img id="{$editor_id}_left" src="{$themeurl}/images/left.gif" title="{$lang_justifyleft_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'JustifyLeft\')">\
|
||||
<img id="{$editor_id}_center" src="{$themeurl}/images/center.gif" title="{$lang_justifycenter_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'JustifyCenter\')">\
|
||||
<img id="{$editor_id}_right" src="{$themeurl}/images/right.gif" title="{$lang_justifyright_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'JustifyRight\')">\
|
||||
<img id="{$editor_id}_full" src="{$themeurl}/images/full.gif" title="{$lang_justifyfull_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'JustifyFull\')">\
|
||||
<img src="{$themeurl}/images/spacer.gif" width="1" height="15" class="mceSeparatorLine">\
|
||||
<img src="{$themeurl}/images/outdent.gif" title="{$lang_outdent_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Outdent\')">\
|
||||
<img src="{$themeurl}/images/indent.gif" title="{$lang_indent_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Indent\')">\
|
||||
<br>\
|
||||
<img id="{$editor_id}_bullist" src="{$themeurl}/images/bullist.gif" title="{$lang_bullist_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'InsertUnorderedList\')">\
|
||||
<img id="{$editor_id}_numlist" src="{$themeurl}/images/numlist.gif" title="{$lang_numlist_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'InsertOrderedList\')">\
|
||||
<img src="{$themeurl}/images/spacer.gif" width="1" height="15" width="20" height="20" class="mceSeparatorLine">\
|
||||
<img src="{$themeurl}/images/undo.gif" title="{$lang_undo_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Undo\')">\
|
||||
<img src="{$themeurl}/images/redo.gif" title="{$lang_redo_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Redo\')">\
|
||||
<img src="{$themeurl}/images/spacer.gif" width="1" height="15" class="mceSeparatorLine">\
|
||||
<img id="{$editor_id}_link" src="{$themeurl}/images/link.gif" title="{$lang_link_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceLink\', true)">\
|
||||
<img src="{$themeurl}/images/unlink.gif" title="{$lang_unlink_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'unlink\')">\
|
||||
<img id="{$editor_id}_image" src="{$themeurl}/images/image.gif" title="{$lang_image_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceImage\', true)">\
|
||||
<img src="{$themeurl}/images/cleanup.gif" title="{$lang_cleanup_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceCleanup\')">\
|
||||
<img src="{$themeurl}/images/help.gif" title="{$lang_help_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceHelp\')">\
|
||||
</td></tr>\
|
||||
</table>';template['delta_width']=0;template['delta_height']=-40;return template;}function TinyMCE_default_getInsertLinkTemplate(){var template=new Array();template['file']='link.htm';template['width']=320;template['height']=200;template['width']+=tinyMCE.getLang('lang_insert_link_delta_width',0);template['height']+=tinyMCE.getLang('lang_insert_link_delta_height',0);return template;}function TinyMCE_default_getInsertImageTemplate(){var template=new Array();template['file']='image.htm';template['width']=360;template['height']=200;template['width']+=tinyMCE.getLang('lang_insert_image_delta_width',0);template['height']+=tinyMCE.getLang('lang_insert_image_delta_height',0);return template;}function TinyMCE_default_handleNodeChange(editor_id,node){tinyMCE.switchClassSticky(editor_id+'_left','mceButtonNormal');tinyMCE.switchClassSticky(editor_id+'_right','mceButtonNormal');tinyMCE.switchClassSticky(editor_id+'_center','mceButtonNormal');tinyMCE.switchClassSticky(editor_id+'_full','mceButtonNormal');tinyMCE.switchClassSticky(editor_id+'_bold','mceButtonNormal');tinyMCE.switchClassSticky(editor_id+'_italic','mceButtonNormal');tinyMCE.switchClassSticky(editor_id+'_underline','mceButtonNormal');tinyMCE.switchClassSticky(editor_id+'_strikethrough','mceButtonNormal');tinyMCE.switchClassSticky(editor_id+'_bullist','mceButtonNormal');tinyMCE.switchClassSticky(editor_id+'_numlist','mceButtonNormal');alignNode=node;breakOut=false;do{if(!alignNode.getAttribute||!alignNode.getAttribute('align'))continue;switch(alignNode.getAttribute('align').toLowerCase()){case "left":tinyMCE.switchClassSticky(editor_id+'_left','mceButtonSelected');breakOut=true;break;case "right":tinyMCE.switchClassSticky(editor_id+'_right','mceButtonSelected');breakOut=true;break;case "middle":case "center":tinyMCE.switchClassSticky(editor_id+'_center','mceButtonSelected');breakOut=true;break;case "justify":tinyMCE.switchClassSticky(editor_id+'_full','mceButtonSelected');breakOut=true;break;}}while(!breakOut&&(alignNode=alignNode.parentNode));do{switch(node.nodeName.toLowerCase()){case "b":case "strong":tinyMCE.switchClassSticky(editor_id+'_bold','mceButtonSelected');break;case "i":case "em":tinyMCE.switchClassSticky(editor_id+'_italic','mceButtonSelected');break;case "u":tinyMCE.switchClassSticky(editor_id+'_underline','mceButtonSelected');break;case "strike":tinyMCE.switchClassSticky(editor_id+'_strikethrough','mceButtonSelected');break;case "ul":tinyMCE.switchClassSticky(editor_id+'_bullist','mceButtonSelected');break;case "ol":tinyMCE.switchClassSticky(editor_id+'_numlist','mceButtonSelected');break;}}while((node=node.parentNode));}
|
151
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/default/editor_template_src.js
vendored
Normal file
151
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/default/editor_template_src.js
vendored
Normal file
@ -0,0 +1,151 @@
|
||||
function TinyMCE_default_getEditorTemplate() {
|
||||
var template = new Array();
|
||||
|
||||
template['html'] = '\
|
||||
<table class="mceEditor" border="0" cellpadding="0" cellspacing="0" width="{$width}" height="{$height}">\
|
||||
<tr><td align="center">\
|
||||
<span id="{$editor_id}">IFRAME</span>\
|
||||
</td></tr>\
|
||||
<tr><td class="mceToolbar" align="center" height="1">\
|
||||
<img id="{$editor_id}_bold" src="{$themeurl}/images/{$lang_bold_img}" title="{$lang_bold_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Bold\')">\
|
||||
<img id="{$editor_id}_italic" src="{$themeurl}/images/{$lang_italic_img}" title="{$lang_italic_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Italic\')">\
|
||||
<img id="{$editor_id}_underline" src="{$themeurl}/images/{$lang_underline_img}" title="{$lang_underline_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Underline\')">\
|
||||
<img id="{$editor_id}_strikethrough" src="{$themeurl}/images/strikethrough.gif" title="{$lang_striketrough_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Strikethrough\')">\
|
||||
<img src="{$themeurl}/images/spacer.gif" width="1" height="15" class="mceSeparatorLine">\
|
||||
<img id="{$editor_id}_left" src="{$themeurl}/images/left.gif" title="{$lang_justifyleft_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'JustifyLeft\')">\
|
||||
<img id="{$editor_id}_center" src="{$themeurl}/images/center.gif" title="{$lang_justifycenter_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'JustifyCenter\')">\
|
||||
<img id="{$editor_id}_right" src="{$themeurl}/images/right.gif" title="{$lang_justifyright_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'JustifyRight\')">\
|
||||
<img id="{$editor_id}_full" src="{$themeurl}/images/full.gif" title="{$lang_justifyfull_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'JustifyFull\')">\
|
||||
<img src="{$themeurl}/images/spacer.gif" width="1" height="15" class="mceSeparatorLine">\
|
||||
<img src="{$themeurl}/images/outdent.gif" title="{$lang_outdent_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Outdent\')">\
|
||||
<img src="{$themeurl}/images/indent.gif" title="{$lang_indent_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Indent\')">\
|
||||
<br>\
|
||||
<img id="{$editor_id}_bullist" src="{$themeurl}/images/bullist.gif" title="{$lang_bullist_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'InsertUnorderedList\')">\
|
||||
<img id="{$editor_id}_numlist" src="{$themeurl}/images/numlist.gif" title="{$lang_numlist_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'InsertOrderedList\')">\
|
||||
<img src="{$themeurl}/images/spacer.gif" width="1" height="15" width="20" height="20" class="mceSeparatorLine">\
|
||||
<img src="{$themeurl}/images/undo.gif" title="{$lang_undo_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Undo\')">\
|
||||
<img src="{$themeurl}/images/redo.gif" title="{$lang_redo_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Redo\')">\
|
||||
<img src="{$themeurl}/images/spacer.gif" width="1" height="15" class="mceSeparatorLine">\
|
||||
<img id="{$editor_id}_link" src="{$themeurl}/images/link.gif" title="{$lang_link_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceLink\', true)">\
|
||||
<img src="{$themeurl}/images/unlink.gif" title="{$lang_unlink_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'unlink\')">\
|
||||
<img id="{$editor_id}_image" src="{$themeurl}/images/image.gif" title="{$lang_image_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceImage\', true)">\
|
||||
<img src="{$themeurl}/images/cleanup.gif" title="{$lang_cleanup_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceCleanup\')">\
|
||||
<img src="{$themeurl}/images/help.gif" title="{$lang_help_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceHelp\')">\
|
||||
</td></tr>\
|
||||
</table>';
|
||||
|
||||
template['delta_width'] = 0;
|
||||
template['delta_height'] = -40;
|
||||
|
||||
return template;
|
||||
}
|
||||
|
||||
/**
|
||||
* Insert link template function.
|
||||
*/
|
||||
function TinyMCE_default_getInsertLinkTemplate() {
|
||||
var template = new Array();
|
||||
|
||||
template['file'] = 'link.htm';
|
||||
template['width'] = 320;
|
||||
template['height'] = 200;
|
||||
|
||||
// Language specific width and height addons
|
||||
template['width'] += tinyMCE.getLang('lang_insert_link_delta_width', 0);
|
||||
template['height'] += tinyMCE.getLang('lang_insert_link_delta_height', 0);
|
||||
|
||||
return template;
|
||||
}
|
||||
|
||||
/**
|
||||
* Insert image template function.
|
||||
*/
|
||||
function TinyMCE_default_getInsertImageTemplate() {
|
||||
var template = new Array();
|
||||
|
||||
template['file'] = 'image.htm';
|
||||
template['width'] = 360;
|
||||
template['height'] = 200;
|
||||
|
||||
// Language specific width and height addons
|
||||
template['width'] += tinyMCE.getLang('lang_insert_image_delta_width', 0);
|
||||
template['height'] += tinyMCE.getLang('lang_insert_image_delta_height', 0);
|
||||
|
||||
return template;
|
||||
}
|
||||
|
||||
function TinyMCE_default_handleNodeChange(editor_id, node) {
|
||||
// Reset old states
|
||||
tinyMCE.switchClassSticky(editor_id + '_left', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_right', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_center', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_full', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_bold', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_italic', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_underline', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_strikethrough', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_bullist', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_numlist', 'mceButtonNormal');
|
||||
|
||||
// Handle align attributes
|
||||
alignNode = node;
|
||||
breakOut = false;
|
||||
do {
|
||||
if (!alignNode.getAttribute || !alignNode.getAttribute('align'))
|
||||
continue;
|
||||
|
||||
switch (alignNode.getAttribute('align').toLowerCase()) {
|
||||
case "left":
|
||||
tinyMCE.switchClassSticky(editor_id + '_left', 'mceButtonSelected');
|
||||
breakOut = true;
|
||||
break;
|
||||
|
||||
case "right":
|
||||
tinyMCE.switchClassSticky(editor_id + '_right', 'mceButtonSelected');
|
||||
breakOut = true;
|
||||
break;
|
||||
|
||||
case "middle":
|
||||
case "center":
|
||||
tinyMCE.switchClassSticky(editor_id + '_center', 'mceButtonSelected');
|
||||
breakOut = true;
|
||||
break;
|
||||
|
||||
case "justify":
|
||||
tinyMCE.switchClassSticky(editor_id + '_full', 'mceButtonSelected');
|
||||
breakOut = true;
|
||||
break;
|
||||
}
|
||||
} while (!breakOut && (alignNode = alignNode.parentNode));
|
||||
|
||||
// Handle elements
|
||||
do {
|
||||
switch (node.nodeName.toLowerCase()) {
|
||||
case "b":
|
||||
case "strong":
|
||||
tinyMCE.switchClassSticky(editor_id + '_bold', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "i":
|
||||
case "em":
|
||||
tinyMCE.switchClassSticky(editor_id + '_italic', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "u":
|
||||
tinyMCE.switchClassSticky(editor_id + '_underline', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "strike":
|
||||
tinyMCE.switchClassSticky(editor_id + '_strikethrough', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "ul":
|
||||
tinyMCE.switchClassSticky(editor_id + '_bullist', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "ol":
|
||||
tinyMCE.switchClassSticky(editor_id + '_numlist', 'mceButtonSelected');
|
||||
break;
|
||||
}
|
||||
} while ((node = node.parentNode));
|
||||
}
|
100
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/default/editor_ui.css
vendored
Normal file
100
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/default/editor_ui.css
vendored
Normal file
@ -0,0 +1,100 @@
|
||||
.mceButtonNormal, .mceButtonOver, .mceButtonDown, .mceSeparator, .mceButtonDisabled, .mceButtonSelected {
|
||||
margin-top: 1px;
|
||||
margin-left: 1px;
|
||||
}
|
||||
|
||||
.mceButtonNormal {
|
||||
border-top: 1px solid;
|
||||
border-left: 1px solid;
|
||||
border-bottom: 1px solid;
|
||||
border-right: 1px solid;
|
||||
border-color: #F0F0EE;
|
||||
cursor: arrow;
|
||||
}
|
||||
|
||||
.mceButtonOver {
|
||||
/* border-top: 1px solid buttonhighlight;
|
||||
border-left: 1px solid buttonhighlight;
|
||||
border-bottom: 1px solid buttonshadow;
|
||||
border-right: 1px solid buttonshadow;*/
|
||||
border: 1px solid #0A246A;
|
||||
cursor: arrow;
|
||||
background-color: #B6BDD2;
|
||||
}
|
||||
|
||||
.mceButtonDown {
|
||||
/* border-bottom: 1px solid buttonhighlight;
|
||||
border-right: 1px solid buttonhighlight;
|
||||
border-top: 1px solid buttonshadow;
|
||||
border-left: 1px solid buttonshadow;*/
|
||||
cursor: arrow;
|
||||
border: 1px solid #0A246A;
|
||||
background-color: #8592B5;
|
||||
}
|
||||
|
||||
.mceButtonDisabled {
|
||||
filter:progid:DXImageTransform.Microsoft.Alpha(opacity=30);
|
||||
border-top: 1px solid;
|
||||
border-left: 1px solid;
|
||||
border-bottom: 1px solid;
|
||||
border-right: 1px solid;
|
||||
border-color: #F0F0EE;
|
||||
cursor: arrow;
|
||||
}
|
||||
|
||||
.mceSeparator {
|
||||
border-top: 1px solid buttonhighlight;
|
||||
border-left: 1px solid buttonhighlight;
|
||||
border-bottom: 1px solid buttonshadow;
|
||||
border-right: 1px solid buttonshadow;
|
||||
margin-right: 2px;
|
||||
margin-left: 2px;
|
||||
}
|
||||
|
||||
.mceSeparatorLine {
|
||||
margin:2px;
|
||||
margin-left: 4px;
|
||||
background-color: #F0F0EE;
|
||||
border-top: 1px solid buttonshadow;
|
||||
border-left: 1px solid buttonshadow;
|
||||
border-bottom: 1px solid buttonhighlight;
|
||||
border-right: 1px solid buttonhighlight;
|
||||
width: 0px;
|
||||
height: 15px;
|
||||
}
|
||||
|
||||
.mceSelectList {
|
||||
font-family: "MS Sans Serif";
|
||||
font-size: 7pt;
|
||||
font-weight: normal;
|
||||
margin-top: 2px;
|
||||
}
|
||||
|
||||
.mceLabel, .mceLabelDisabled {
|
||||
font-family: "MS Sans Serif";
|
||||
font-size: 9pt;
|
||||
}
|
||||
|
||||
.mceLabel {
|
||||
color: #000000;
|
||||
}
|
||||
|
||||
.mceLabelDisabled {
|
||||
cursor: text;
|
||||
color: #999999;
|
||||
}
|
||||
|
||||
.mceEditor {
|
||||
background: #F0F0EE;
|
||||
border: 1px solid #cccccc;
|
||||
}
|
||||
|
||||
.mceEditorArea {
|
||||
font-family: "MS Sans Serif";
|
||||
background: #FFFFFF;
|
||||
}
|
||||
|
||||
.mceToolbar {
|
||||
background: #F0F0EE;
|
||||
border-top: 1px solid #cccccc;
|
||||
}
|
57
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/default/image.htm
vendored
Normal file
57
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/default/image.htm
vendored
Normal file
@ -0,0 +1,57 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_insert_image_title}</title>
|
||||
<script language="javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script language="javascript">
|
||||
function insertImage() {
|
||||
if (window.opener) {
|
||||
var src = document.forms[0].src.value;
|
||||
var alt = document.forms[0].alt.value;
|
||||
|
||||
window.opener.tinyMCE.insertImage(src, alt);
|
||||
top.close();
|
||||
}
|
||||
}
|
||||
|
||||
function init() {
|
||||
var formObj = document.forms[0];
|
||||
|
||||
formObj.src.value = tinyMCE.getWindowArg('src');
|
||||
formObj.alt.value = tinyMCE.getWindowArg('alt');
|
||||
formObj.insert.value = tinyMCE.getLang('lang_' + tinyMCE.getWindowArg('action'), 'Insert', true);
|
||||
|
||||
window.focus();
|
||||
}
|
||||
|
||||
function cancelAction() {
|
||||
top.close();
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body onload="window.focus();init();">
|
||||
<form onsubmit="insertImage();return false;">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="100%">
|
||||
<tr>
|
||||
<td align="center" valign="middle"><table border="0" cellpadding="4" cellspacing="0">
|
||||
<tr>
|
||||
<td colspan="2" class="title">{$lang_insert_image_title}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{$lang_insert_image_src}:</td>
|
||||
<td><input name="src" type="text" id="src" value="" style="width: 200px"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{$lang_insert_image_alt}:</td>
|
||||
<td><input name="alt" type="text" id="alt" value="" style="width: 200px"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><input type="button" id="insert" name="insert" value="{$lang_insert}" onclick="insertImage();">
|
||||
</td>
|
||||
<td align="right"><input type="button" id="cancel" name="cancel" value="{$lang_cancel}" onclick="cancelAction();"></td>
|
||||
</tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
64
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/default/link.htm
vendored
Normal file
64
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/default/link.htm
vendored
Normal file
@ -0,0 +1,64 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>{$lang_insert_link_title}</title>
|
||||
<script language="javascript" src="../../tiny_mce_popup.js"></script>
|
||||
<script language="javascript">
|
||||
function init() {
|
||||
for (var i=0; i<document.forms[0].target.options.length; i++) {
|
||||
var option = document.forms[0].target.options[i];
|
||||
|
||||
if (option.value == tinyMCE.getWindowArg('target'))
|
||||
option.selected = true;
|
||||
}
|
||||
|
||||
document.forms[0].href.value = tinyMCE.getWindowArg('href');
|
||||
document.forms[0].insert.value = tinyMCE.getLang('lang_' + tinyMCE.getWindowArg('action'), 'Insert', true);
|
||||
|
||||
window.focus();
|
||||
}
|
||||
|
||||
function insertLink() {
|
||||
if (window.opener) {
|
||||
var href = document.forms[0].href.value;
|
||||
var target = document.forms[0].target.options[document.forms[0].target.selectedIndex].value;
|
||||
|
||||
window.opener.tinyMCE.insertLink(href, target);
|
||||
top.close();
|
||||
}
|
||||
}
|
||||
|
||||
function cancelAction() {
|
||||
top.close();
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body onload="init();">
|
||||
<form onsubmit="insertLink();return false;">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="100%">
|
||||
<tr>
|
||||
<td align="center" valign="middle"><table border="0" cellpadding="4" cellspacing="0">
|
||||
<tr>
|
||||
<td colspan="2" class="title">{$lang_insert_link_title}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{$lang_insert_link_url}:</td>
|
||||
<td><input name="href" type="text" id="href" value="" style="width: 200px"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{$lang_insert_link_target}:</td>
|
||||
<td><select name="target" style="width: 200px">
|
||||
<option value="_self">{$lang_insert_link_target_same}</option>
|
||||
<option value="_blank">{$lang_insert_link_target_blank}</option>
|
||||
</select></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><input type="button" id="insert" name="insert" value="{$lang_insert}" onclick="insertLink();">
|
||||
</td>
|
||||
<td align="right"><input type="button" id="cancel" name="cancel" value="{$lang_cancel}" onclick="cancelAction();"></td>
|
||||
</tr>
|
||||
</table></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
27
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/simple/editor_content.css
vendored
Normal file
27
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/simple/editor_content.css
vendored
Normal file
@ -0,0 +1,27 @@
|
||||
body {
|
||||
background-color: #FFFFFF;
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 10px;
|
||||
scrollbar-3dlight-color: #F0F0EE;
|
||||
scrollbar-arrow-color: #676662;
|
||||
scrollbar-base-color: #F0F0EE;
|
||||
scrollbar-darkshadow-color: #DDDDDD;
|
||||
scrollbar-face-color: #E0E0DD;
|
||||
scrollbar-highlight-color: #F0F0EE;
|
||||
scrollbar-shadow-color: #F0F0EE;
|
||||
scrollbar-track-color: #F5F5F5;
|
||||
}
|
||||
|
||||
td {
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 10px;
|
||||
}
|
||||
|
||||
pre {
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 10px;
|
||||
}
|
||||
|
||||
.mceVisualAid {
|
||||
border: 1px dashed #BBBBBB;
|
||||
}
|
41
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/simple/editor_popup.css
vendored
Normal file
41
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/simple/editor_popup.css
vendored
Normal file
@ -0,0 +1,41 @@
|
||||
body {
|
||||
background-color: #F0F0EE;
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 11px;
|
||||
scrollbar-3dlight-color: #F0F0EE;
|
||||
scrollbar-arrow-color: #676662;
|
||||
scrollbar-base-color: #F0F0EE;
|
||||
scrollbar-darkshadow-color: #DDDDDD;
|
||||
scrollbar-face-color: #E0E0DD;
|
||||
scrollbar-highlight-color: #F0F0EE;
|
||||
scrollbar-shadow-color: #F0F0EE;
|
||||
scrollbar-track-color: #F5F5F5;
|
||||
}
|
||||
|
||||
td {
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 11px;
|
||||
}
|
||||
|
||||
input {
|
||||
background: #FFFFFF;
|
||||
border: 1px solid #cccccc;
|
||||
}
|
||||
|
||||
td, input, select, textarea {
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 10px;
|
||||
}
|
||||
|
||||
input, select, textarea {
|
||||
border: 1px solid #808080;
|
||||
}
|
||||
|
||||
.input_noborder {
|
||||
border: 0px solid #808080;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 12px;
|
||||
font-weight: bold;
|
||||
}
|
20
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/simple/editor_template.js
vendored
Normal file
20
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/simple/editor_template.js
vendored
Normal file
@ -0,0 +1,20 @@
|
||||
function TinyMCE_simple_getEditorTemplate(){var template=new Array();template['html']='\
|
||||
<table class="mceEditor" border="0" cellpadding="0" cellspacing="0" width="{$width}" height="{$height}">\
|
||||
<tr><td align="center">\
|
||||
<span id="{$editor_id}">IFRAME</span>\
|
||||
</td></tr>\
|
||||
<tr><td class="mceToolbar" align="center" height="1">\
|
||||
<img id="{$editor_id}_bold" src="{$themeurl}/images/{$lang_bold_img}" title="{$lang_bold_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Bold\')">\
|
||||
<img id="{$editor_id}_italic" src="{$themeurl}/images/{$lang_italic_img}" title="{$lang_italic_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Italic\')">\
|
||||
<img id="{$editor_id}_underline" src="{$themeurl}/images/{$lang_underline_img}" title="{$lang_underline_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Underline\')">\
|
||||
<img id="{$editor_id}_strikethrough" src="{$themeurl}/images/strikethrough.gif" title="{$lang_striketrough_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Strikethrough\')">\
|
||||
<img src="{$themeurl}/images/spacer.gif" width="1" height="15" class="mceSeparatorLine">\
|
||||
<img src="{$themeurl}/images/undo.gif" title="{$lang_undo_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Undo\')">\
|
||||
<img src="{$themeurl}/images/redo.gif" title="{$lang_redo_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Redo\')">\
|
||||
<img src="{$themeurl}/images/spacer.gif" width="1" height="15" class="mceSeparatorLine">\
|
||||
<img src="{$themeurl}/images/cleanup.gif" title="{$lang_cleanup_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceCleanup\')">\
|
||||
<img src="{$themeurl}/images/spacer.gif" width="1" height="15" class="mceSeparatorLine">\
|
||||
<img id="{$editor_id}_bullist" src="{$themeurl}/images/bullist.gif" title="{$lang_bullist_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'InsertUnorderedList\')">\
|
||||
<img id="{$editor_id}_numlist" src="{$themeurl}/images/numlist.gif" title="{$lang_numlist_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'InsertOrderedList\')">\
|
||||
</td></tr>\
|
||||
</table>';template['delta_width']=0;template['delta_height']=-20;return template;}function TinyMCE_simple_handleNodeChange(editor_id,node){tinyMCE.switchClassSticky(editor_id+'_bold','mceButtonNormal');tinyMCE.switchClassSticky(editor_id+'_italic','mceButtonNormal');tinyMCE.switchClassSticky(editor_id+'_underline','mceButtonNormal');tinyMCE.switchClassSticky(editor_id+'_strikethrough','mceButtonNormal');tinyMCE.switchClassSticky(editor_id+'_bullist','mceButtonNormal');tinyMCE.switchClassSticky(editor_id+'_numlist','mceButtonNormal');do{switch(node.nodeName.toLowerCase()){case "b":case "strong":tinyMCE.switchClassSticky(editor_id+'_bold','mceButtonSelected');break;case "i":case "em":tinyMCE.switchClassSticky(editor_id+'_italic','mceButtonSelected');break;case "u":tinyMCE.switchClassSticky(editor_id+'_underline','mceButtonSelected');break;case "strike":tinyMCE.switchClassSticky(editor_id+'_strikethrough','mceButtonSelected');break;case "ul":tinyMCE.switchClassSticky(editor_id+'_bullist','mceButtonSelected');break;case "ol":tinyMCE.switchClassSticky(editor_id+'_numlist','mceButtonSelected');break;}}while((node=node.parentNode));}
|
70
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/simple/editor_template_src.js
vendored
Normal file
70
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/simple/editor_template_src.js
vendored
Normal file
@ -0,0 +1,70 @@
|
||||
function TinyMCE_simple_getEditorTemplate() {
|
||||
var template = new Array();
|
||||
|
||||
template['html'] = '\
|
||||
<table class="mceEditor" border="0" cellpadding="0" cellspacing="0" width="{$width}" height="{$height}">\
|
||||
<tr><td align="center">\
|
||||
<span id="{$editor_id}">IFRAME</span>\
|
||||
</td></tr>\
|
||||
<tr><td class="mceToolbar" align="center" height="1">\
|
||||
<img id="{$editor_id}_bold" src="{$themeurl}/images/{$lang_bold_img}" title="{$lang_bold_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Bold\')">\
|
||||
<img id="{$editor_id}_italic" src="{$themeurl}/images/{$lang_italic_img}" title="{$lang_italic_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Italic\')">\
|
||||
<img id="{$editor_id}_underline" src="{$themeurl}/images/{$lang_underline_img}" title="{$lang_underline_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Underline\')">\
|
||||
<img id="{$editor_id}_strikethrough" src="{$themeurl}/images/strikethrough.gif" title="{$lang_striketrough_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Strikethrough\')">\
|
||||
<img src="{$themeurl}/images/spacer.gif" width="1" height="15" class="mceSeparatorLine">\
|
||||
<img src="{$themeurl}/images/undo.gif" title="{$lang_undo_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Undo\')">\
|
||||
<img src="{$themeurl}/images/redo.gif" title="{$lang_redo_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'Redo\')">\
|
||||
<img src="{$themeurl}/images/spacer.gif" width="1" height="15" class="mceSeparatorLine">\
|
||||
<img src="{$themeurl}/images/cleanup.gif" title="{$lang_cleanup_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceCleanup\')">\
|
||||
<img src="{$themeurl}/images/spacer.gif" width="1" height="15" class="mceSeparatorLine">\
|
||||
<img id="{$editor_id}_bullist" src="{$themeurl}/images/bullist.gif" title="{$lang_bullist_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'InsertUnorderedList\')">\
|
||||
<img id="{$editor_id}_numlist" src="{$themeurl}/images/numlist.gif" title="{$lang_numlist_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');tinyMCE.execInstanceCommand(\'{$editor_id}\',\'InsertOrderedList\')">\
|
||||
</td></tr>\
|
||||
</table>';
|
||||
|
||||
template['delta_width'] = 0;
|
||||
template['delta_height'] = -20;
|
||||
|
||||
return template;
|
||||
}
|
||||
|
||||
function TinyMCE_simple_handleNodeChange(editor_id, node) {
|
||||
// Reset old states
|
||||
tinyMCE.switchClassSticky(editor_id + '_bold', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_italic', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_underline', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_strikethrough', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_bullist', 'mceButtonNormal');
|
||||
tinyMCE.switchClassSticky(editor_id + '_numlist', 'mceButtonNormal');
|
||||
|
||||
// Handle elements
|
||||
do {
|
||||
switch (node.nodeName.toLowerCase()) {
|
||||
case "b":
|
||||
case "strong":
|
||||
tinyMCE.switchClassSticky(editor_id + '_bold', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "i":
|
||||
case "em":
|
||||
tinyMCE.switchClassSticky(editor_id + '_italic', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "u":
|
||||
tinyMCE.switchClassSticky(editor_id + '_underline', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "strike":
|
||||
tinyMCE.switchClassSticky(editor_id + '_strikethrough', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "ul":
|
||||
tinyMCE.switchClassSticky(editor_id + '_bullist', 'mceButtonSelected');
|
||||
break;
|
||||
|
||||
case "ol":
|
||||
tinyMCE.switchClassSticky(editor_id + '_numlist', 'mceButtonSelected');
|
||||
break;
|
||||
}
|
||||
} while ((node = node.parentNode));
|
||||
}
|
100
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/simple/editor_ui.css
vendored
Normal file
100
phpgwapi/js/tinymce/jscripts/tiny_mce/themes/simple/editor_ui.css
vendored
Normal file
@ -0,0 +1,100 @@
|
||||
.mceButtonNormal, .mceButtonOver, .mceButtonDown, .mceSeparator, .mceButtonDisabled, .mceButtonSelected {
|
||||
margin-top: 1px;
|
||||
margin-left: 1px;
|
||||
}
|
||||
|
||||
.mceButtonNormal {
|
||||
border-top: 1px solid;
|
||||
border-left: 1px solid;
|
||||
border-bottom: 1px solid;
|
||||
border-right: 1px solid;
|
||||
border-color: #F0F0EE;
|
||||
cursor: arrow;
|
||||
}
|
||||
|
||||
.mceButtonOver {
|
||||
border: 1px solid #0A246A;
|
||||
cursor: arrow;
|
||||
background-color: #B6BDD2;
|
||||
}
|
||||
|
||||
.mceButtonDown {
|
||||
cursor: arrow;
|
||||
border: 1px solid #0A246A;
|
||||
background-color: #8592B5;
|
||||
}
|
||||
|
||||
.mceButtonSelected {
|
||||
border: 1px solid;
|
||||
border-color: #C0C0BB;
|
||||
cursor: arrow;
|
||||
}
|
||||
|
||||
.mceButtonDisabled {
|
||||
filter:progid:DXImageTransform.Microsoft.Alpha(opacity=30);
|
||||
-moz-opacity:0.3;
|
||||
opacity: 0.3;
|
||||
border-top: 1px solid;
|
||||
border-left: 1px solid;
|
||||
border-bottom: 1px solid;
|
||||
border-right: 1px solid;
|
||||
border-color: #F0F0EE;
|
||||
cursor: arrow;
|
||||
}
|
||||
|
||||
.mceSeparator {
|
||||
border-top: 1px solid buttonhighlight;
|
||||
border-left: 1px solid buttonhighlight;
|
||||
border-bottom: 1px solid buttonshadow;
|
||||
border-right: 1px solid buttonshadow;
|
||||
margin-right: 2px;
|
||||
margin-left: 2px;
|
||||
}
|
||||
|
||||
.mceSeparatorLine {
|
||||
margin:2px;
|
||||
margin-left: 4px;
|
||||
background-color: #F0F0EE;
|
||||
border-top: 1px solid buttonshadow;
|
||||
border-left: 1px solid buttonshadow;
|
||||
border-bottom: 1px solid buttonhighlight;
|
||||
border-right: 1px solid buttonhighlight;
|
||||
width: 0px;
|
||||
height: 15px;
|
||||
}
|
||||
|
||||
.mceSelectList {
|
||||
font-family: "MS Sans Serif";
|
||||
font-size: 7pt;
|
||||
font-weight: normal;
|
||||
margin-top: 2px;
|
||||
}
|
||||
|
||||
.mceLabel, .mceLabelDisabled {
|
||||
font-family: "MS Sans Serif";
|
||||
font-size: 9pt;
|
||||
}
|
||||
|
||||
.mceLabel {
|
||||
color: #000000;
|
||||
}
|
||||
|
||||
.mceLabelDisabled {
|
||||
cursor: text;
|
||||
color: #999999;
|
||||
}
|
||||
|
||||
.mceEditor {
|
||||
background: #F0F0EE;
|
||||
border: 1px solid #cccccc;
|
||||
}
|
||||
|
||||
.mceEditorArea {
|
||||
font-family: "MS Sans Serif";
|
||||
background: #FFFFFF;
|
||||
}
|
||||
|
||||
.mceToolbar {
|
||||
background: #F0F0EE;
|
||||
border-top: 1px solid #cccccc;
|
||||
}
|
Loading…
Reference in New Issue
Block a user