mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-08-11 12:20:22 +00:00
TinyMCE: update to 4.3.3. Update the QUnit tests and revert back to testing the non-minified files in /src.
Fixes #35539. git-svn-id: https://develop.svn.wordpress.org/trunk@36352 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -11,266 +11,311 @@
|
||||
/*global tinymce:true */
|
||||
|
||||
tinymce.PluginManager.add('charmap', function(editor) {
|
||||
var charmap = [
|
||||
['160', 'no-break space'],
|
||||
['173', 'soft hyphen'],
|
||||
['34', 'quotation mark'],
|
||||
// finance
|
||||
['162', 'cent sign'],
|
||||
['8364', 'euro sign'],
|
||||
['163', 'pound sign'],
|
||||
['165', 'yen sign'],
|
||||
// signs
|
||||
['169', 'copyright sign'],
|
||||
['174', 'registered sign'],
|
||||
['8482', 'trade mark sign'],
|
||||
['8240', 'per mille sign'],
|
||||
['181', 'micro sign'],
|
||||
['183', 'middle dot'],
|
||||
['8226', 'bullet'],
|
||||
['8230', 'three dot leader'],
|
||||
['8242', 'minutes / feet'],
|
||||
['8243', 'seconds / inches'],
|
||||
['167', 'section sign'],
|
||||
['182', 'paragraph sign'],
|
||||
['223', 'sharp s / ess-zed'],
|
||||
// quotations
|
||||
['8249', 'single left-pointing angle quotation mark'],
|
||||
['8250', 'single right-pointing angle quotation mark'],
|
||||
['171', 'left pointing guillemet'],
|
||||
['187', 'right pointing guillemet'],
|
||||
['8216', 'left single quotation mark'],
|
||||
['8217', 'right single quotation mark'],
|
||||
['8220', 'left double quotation mark'],
|
||||
['8221', 'right double quotation mark'],
|
||||
['8218', 'single low-9 quotation mark'],
|
||||
['8222', 'double low-9 quotation mark'],
|
||||
['60', 'less-than sign'],
|
||||
['62', 'greater-than sign'],
|
||||
['8804', 'less-than or equal to'],
|
||||
['8805', 'greater-than or equal to'],
|
||||
['8211', 'en dash'],
|
||||
['8212', 'em dash'],
|
||||
['175', 'macron'],
|
||||
['8254', 'overline'],
|
||||
['164', 'currency sign'],
|
||||
['166', 'broken bar'],
|
||||
['168', 'diaeresis'],
|
||||
['161', 'inverted exclamation mark'],
|
||||
['191', 'turned question mark'],
|
||||
['710', 'circumflex accent'],
|
||||
['732', 'small tilde'],
|
||||
['176', 'degree sign'],
|
||||
['8722', 'minus sign'],
|
||||
['177', 'plus-minus sign'],
|
||||
['247', 'division sign'],
|
||||
['8260', 'fraction slash'],
|
||||
['215', 'multiplication sign'],
|
||||
['185', 'superscript one'],
|
||||
['178', 'superscript two'],
|
||||
['179', 'superscript three'],
|
||||
['188', 'fraction one quarter'],
|
||||
['189', 'fraction one half'],
|
||||
['190', 'fraction three quarters'],
|
||||
// math / logical
|
||||
['402', 'function / florin'],
|
||||
['8747', 'integral'],
|
||||
['8721', 'n-ary sumation'],
|
||||
['8734', 'infinity'],
|
||||
['8730', 'square root'],
|
||||
['8764', 'similar to'],
|
||||
['8773', 'approximately equal to'],
|
||||
['8776', 'almost equal to'],
|
||||
['8800', 'not equal to'],
|
||||
['8801', 'identical to'],
|
||||
['8712', 'element of'],
|
||||
['8713', 'not an element of'],
|
||||
['8715', 'contains as member'],
|
||||
['8719', 'n-ary product'],
|
||||
['8743', 'logical and'],
|
||||
['8744', 'logical or'],
|
||||
['172', 'not sign'],
|
||||
['8745', 'intersection'],
|
||||
['8746', 'union'],
|
||||
['8706', 'partial differential'],
|
||||
['8704', 'for all'],
|
||||
['8707', 'there exists'],
|
||||
['8709', 'diameter'],
|
||||
['8711', 'backward difference'],
|
||||
['8727', 'asterisk operator'],
|
||||
['8733', 'proportional to'],
|
||||
['8736', 'angle'],
|
||||
// undefined
|
||||
['180', 'acute accent'],
|
||||
['184', 'cedilla'],
|
||||
['170', 'feminine ordinal indicator'],
|
||||
['186', 'masculine ordinal indicator'],
|
||||
['8224', 'dagger'],
|
||||
['8225', 'double dagger'],
|
||||
// alphabetical special chars
|
||||
['192', 'A - grave'],
|
||||
['193', 'A - acute'],
|
||||
['194', 'A - circumflex'],
|
||||
['195', 'A - tilde'],
|
||||
['196', 'A - diaeresis'],
|
||||
['197', 'A - ring above'],
|
||||
['198', 'ligature AE'],
|
||||
['199', 'C - cedilla'],
|
||||
['200', 'E - grave'],
|
||||
['201', 'E - acute'],
|
||||
['202', 'E - circumflex'],
|
||||
['203', 'E - diaeresis'],
|
||||
['204', 'I - grave'],
|
||||
['205', 'I - acute'],
|
||||
['206', 'I - circumflex'],
|
||||
['207', 'I - diaeresis'],
|
||||
['208', 'ETH'],
|
||||
['209', 'N - tilde'],
|
||||
['210', 'O - grave'],
|
||||
['211', 'O - acute'],
|
||||
['212', 'O - circumflex'],
|
||||
['213', 'O - tilde'],
|
||||
['214', 'O - diaeresis'],
|
||||
['216', 'O - slash'],
|
||||
['338', 'ligature OE'],
|
||||
['352', 'S - caron'],
|
||||
['217', 'U - grave'],
|
||||
['218', 'U - acute'],
|
||||
['219', 'U - circumflex'],
|
||||
['220', 'U - diaeresis'],
|
||||
['221', 'Y - acute'],
|
||||
['376', 'Y - diaeresis'],
|
||||
['222', 'THORN'],
|
||||
['224', 'a - grave'],
|
||||
['225', 'a - acute'],
|
||||
['226', 'a - circumflex'],
|
||||
['227', 'a - tilde'],
|
||||
['228', 'a - diaeresis'],
|
||||
['229', 'a - ring above'],
|
||||
['230', 'ligature ae'],
|
||||
['231', 'c - cedilla'],
|
||||
['232', 'e - grave'],
|
||||
['233', 'e - acute'],
|
||||
['234', 'e - circumflex'],
|
||||
['235', 'e - diaeresis'],
|
||||
['236', 'i - grave'],
|
||||
['237', 'i - acute'],
|
||||
['238', 'i - circumflex'],
|
||||
['239', 'i - diaeresis'],
|
||||
['240', 'eth'],
|
||||
['241', 'n - tilde'],
|
||||
['242', 'o - grave'],
|
||||
['243', 'o - acute'],
|
||||
['244', 'o - circumflex'],
|
||||
['245', 'o - tilde'],
|
||||
['246', 'o - diaeresis'],
|
||||
['248', 'o slash'],
|
||||
['339', 'ligature oe'],
|
||||
['353', 's - caron'],
|
||||
['249', 'u - grave'],
|
||||
['250', 'u - acute'],
|
||||
['251', 'u - circumflex'],
|
||||
['252', 'u - diaeresis'],
|
||||
['253', 'y - acute'],
|
||||
['254', 'thorn'],
|
||||
['255', 'y - diaeresis'],
|
||||
['913', 'Alpha'],
|
||||
['914', 'Beta'],
|
||||
['915', 'Gamma'],
|
||||
['916', 'Delta'],
|
||||
['917', 'Epsilon'],
|
||||
['918', 'Zeta'],
|
||||
['919', 'Eta'],
|
||||
['920', 'Theta'],
|
||||
['921', 'Iota'],
|
||||
['922', 'Kappa'],
|
||||
['923', 'Lambda'],
|
||||
['924', 'Mu'],
|
||||
['925', 'Nu'],
|
||||
['926', 'Xi'],
|
||||
['927', 'Omicron'],
|
||||
['928', 'Pi'],
|
||||
['929', 'Rho'],
|
||||
['931', 'Sigma'],
|
||||
['932', 'Tau'],
|
||||
['933', 'Upsilon'],
|
||||
['934', 'Phi'],
|
||||
['935', 'Chi'],
|
||||
['936', 'Psi'],
|
||||
['937', 'Omega'],
|
||||
['945', 'alpha'],
|
||||
['946', 'beta'],
|
||||
['947', 'gamma'],
|
||||
['948', 'delta'],
|
||||
['949', 'epsilon'],
|
||||
['950', 'zeta'],
|
||||
['951', 'eta'],
|
||||
['952', 'theta'],
|
||||
['953', 'iota'],
|
||||
['954', 'kappa'],
|
||||
['955', 'lambda'],
|
||||
['956', 'mu'],
|
||||
['957', 'nu'],
|
||||
['958', 'xi'],
|
||||
['959', 'omicron'],
|
||||
['960', 'pi'],
|
||||
['961', 'rho'],
|
||||
['962', 'final sigma'],
|
||||
['963', 'sigma'],
|
||||
['964', 'tau'],
|
||||
['965', 'upsilon'],
|
||||
['966', 'phi'],
|
||||
['967', 'chi'],
|
||||
['968', 'psi'],
|
||||
['969', 'omega'],
|
||||
// symbols
|
||||
['8501', 'alef symbol'],
|
||||
['982', 'pi symbol'],
|
||||
['8476', 'real part symbol'],
|
||||
['978', 'upsilon - hook symbol'],
|
||||
['8472', 'Weierstrass p'],
|
||||
['8465', 'imaginary part'],
|
||||
// arrows
|
||||
['8592', 'leftwards arrow'],
|
||||
['8593', 'upwards arrow'],
|
||||
['8594', 'rightwards arrow'],
|
||||
['8595', 'downwards arrow'],
|
||||
['8596', 'left right arrow'],
|
||||
['8629', 'carriage return'],
|
||||
['8656', 'leftwards double arrow'],
|
||||
['8657', 'upwards double arrow'],
|
||||
['8658', 'rightwards double arrow'],
|
||||
['8659', 'downwards double arrow'],
|
||||
['8660', 'left right double arrow'],
|
||||
['8756', 'therefore'],
|
||||
['8834', 'subset of'],
|
||||
['8835', 'superset of'],
|
||||
['8836', 'not a subset of'],
|
||||
['8838', 'subset of or equal to'],
|
||||
['8839', 'superset of or equal to'],
|
||||
['8853', 'circled plus'],
|
||||
['8855', 'circled times'],
|
||||
['8869', 'perpendicular'],
|
||||
['8901', 'dot operator'],
|
||||
['8968', 'left ceiling'],
|
||||
['8969', 'right ceiling'],
|
||||
['8970', 'left floor'],
|
||||
['8971', 'right floor'],
|
||||
['9001', 'left-pointing angle bracket'],
|
||||
['9002', 'right-pointing angle bracket'],
|
||||
['9674', 'lozenge'],
|
||||
['9824', 'black spade suit'],
|
||||
['9827', 'black club suit'],
|
||||
['9829', 'black heart suit'],
|
||||
['9830', 'black diamond suit'],
|
||||
['8194', 'en space'],
|
||||
['8195', 'em space'],
|
||||
['8201', 'thin space'],
|
||||
['8204', 'zero width non-joiner'],
|
||||
['8205', 'zero width joiner'],
|
||||
['8206', 'left-to-right mark'],
|
||||
['8207', 'right-to-left mark']
|
||||
];
|
||||
var isArray = tinymce.util.Tools.isArray;
|
||||
|
||||
function getDefaultCharMap() {
|
||||
return [
|
||||
['160', 'no-break space'],
|
||||
['173', 'soft hyphen'],
|
||||
['34', 'quotation mark'],
|
||||
// finance
|
||||
['162', 'cent sign'],
|
||||
['8364', 'euro sign'],
|
||||
['163', 'pound sign'],
|
||||
['165', 'yen sign'],
|
||||
// signs
|
||||
['169', 'copyright sign'],
|
||||
['174', 'registered sign'],
|
||||
['8482', 'trade mark sign'],
|
||||
['8240', 'per mille sign'],
|
||||
['181', 'micro sign'],
|
||||
['183', 'middle dot'],
|
||||
['8226', 'bullet'],
|
||||
['8230', 'three dot leader'],
|
||||
['8242', 'minutes / feet'],
|
||||
['8243', 'seconds / inches'],
|
||||
['167', 'section sign'],
|
||||
['182', 'paragraph sign'],
|
||||
['223', 'sharp s / ess-zed'],
|
||||
// quotations
|
||||
['8249', 'single left-pointing angle quotation mark'],
|
||||
['8250', 'single right-pointing angle quotation mark'],
|
||||
['171', 'left pointing guillemet'],
|
||||
['187', 'right pointing guillemet'],
|
||||
['8216', 'left single quotation mark'],
|
||||
['8217', 'right single quotation mark'],
|
||||
['8220', 'left double quotation mark'],
|
||||
['8221', 'right double quotation mark'],
|
||||
['8218', 'single low-9 quotation mark'],
|
||||
['8222', 'double low-9 quotation mark'],
|
||||
['60', 'less-than sign'],
|
||||
['62', 'greater-than sign'],
|
||||
['8804', 'less-than or equal to'],
|
||||
['8805', 'greater-than or equal to'],
|
||||
['8211', 'en dash'],
|
||||
['8212', 'em dash'],
|
||||
['175', 'macron'],
|
||||
['8254', 'overline'],
|
||||
['164', 'currency sign'],
|
||||
['166', 'broken bar'],
|
||||
['168', 'diaeresis'],
|
||||
['161', 'inverted exclamation mark'],
|
||||
['191', 'turned question mark'],
|
||||
['710', 'circumflex accent'],
|
||||
['732', 'small tilde'],
|
||||
['176', 'degree sign'],
|
||||
['8722', 'minus sign'],
|
||||
['177', 'plus-minus sign'],
|
||||
['247', 'division sign'],
|
||||
['8260', 'fraction slash'],
|
||||
['215', 'multiplication sign'],
|
||||
['185', 'superscript one'],
|
||||
['178', 'superscript two'],
|
||||
['179', 'superscript three'],
|
||||
['188', 'fraction one quarter'],
|
||||
['189', 'fraction one half'],
|
||||
['190', 'fraction three quarters'],
|
||||
// math / logical
|
||||
['402', 'function / florin'],
|
||||
['8747', 'integral'],
|
||||
['8721', 'n-ary sumation'],
|
||||
['8734', 'infinity'],
|
||||
['8730', 'square root'],
|
||||
['8764', 'similar to'],
|
||||
['8773', 'approximately equal to'],
|
||||
['8776', 'almost equal to'],
|
||||
['8800', 'not equal to'],
|
||||
['8801', 'identical to'],
|
||||
['8712', 'element of'],
|
||||
['8713', 'not an element of'],
|
||||
['8715', 'contains as member'],
|
||||
['8719', 'n-ary product'],
|
||||
['8743', 'logical and'],
|
||||
['8744', 'logical or'],
|
||||
['172', 'not sign'],
|
||||
['8745', 'intersection'],
|
||||
['8746', 'union'],
|
||||
['8706', 'partial differential'],
|
||||
['8704', 'for all'],
|
||||
['8707', 'there exists'],
|
||||
['8709', 'diameter'],
|
||||
['8711', 'backward difference'],
|
||||
['8727', 'asterisk operator'],
|
||||
['8733', 'proportional to'],
|
||||
['8736', 'angle'],
|
||||
// undefined
|
||||
['180', 'acute accent'],
|
||||
['184', 'cedilla'],
|
||||
['170', 'feminine ordinal indicator'],
|
||||
['186', 'masculine ordinal indicator'],
|
||||
['8224', 'dagger'],
|
||||
['8225', 'double dagger'],
|
||||
// alphabetical special chars
|
||||
['192', 'A - grave'],
|
||||
['193', 'A - acute'],
|
||||
['194', 'A - circumflex'],
|
||||
['195', 'A - tilde'],
|
||||
['196', 'A - diaeresis'],
|
||||
['197', 'A - ring above'],
|
||||
['198', 'ligature AE'],
|
||||
['199', 'C - cedilla'],
|
||||
['200', 'E - grave'],
|
||||
['201', 'E - acute'],
|
||||
['202', 'E - circumflex'],
|
||||
['203', 'E - diaeresis'],
|
||||
['204', 'I - grave'],
|
||||
['205', 'I - acute'],
|
||||
['206', 'I - circumflex'],
|
||||
['207', 'I - diaeresis'],
|
||||
['208', 'ETH'],
|
||||
['209', 'N - tilde'],
|
||||
['210', 'O - grave'],
|
||||
['211', 'O - acute'],
|
||||
['212', 'O - circumflex'],
|
||||
['213', 'O - tilde'],
|
||||
['214', 'O - diaeresis'],
|
||||
['216', 'O - slash'],
|
||||
['338', 'ligature OE'],
|
||||
['352', 'S - caron'],
|
||||
['217', 'U - grave'],
|
||||
['218', 'U - acute'],
|
||||
['219', 'U - circumflex'],
|
||||
['220', 'U - diaeresis'],
|
||||
['221', 'Y - acute'],
|
||||
['376', 'Y - diaeresis'],
|
||||
['222', 'THORN'],
|
||||
['224', 'a - grave'],
|
||||
['225', 'a - acute'],
|
||||
['226', 'a - circumflex'],
|
||||
['227', 'a - tilde'],
|
||||
['228', 'a - diaeresis'],
|
||||
['229', 'a - ring above'],
|
||||
['230', 'ligature ae'],
|
||||
['231', 'c - cedilla'],
|
||||
['232', 'e - grave'],
|
||||
['233', 'e - acute'],
|
||||
['234', 'e - circumflex'],
|
||||
['235', 'e - diaeresis'],
|
||||
['236', 'i - grave'],
|
||||
['237', 'i - acute'],
|
||||
['238', 'i - circumflex'],
|
||||
['239', 'i - diaeresis'],
|
||||
['240', 'eth'],
|
||||
['241', 'n - tilde'],
|
||||
['242', 'o - grave'],
|
||||
['243', 'o - acute'],
|
||||
['244', 'o - circumflex'],
|
||||
['245', 'o - tilde'],
|
||||
['246', 'o - diaeresis'],
|
||||
['248', 'o slash'],
|
||||
['339', 'ligature oe'],
|
||||
['353', 's - caron'],
|
||||
['249', 'u - grave'],
|
||||
['250', 'u - acute'],
|
||||
['251', 'u - circumflex'],
|
||||
['252', 'u - diaeresis'],
|
||||
['253', 'y - acute'],
|
||||
['254', 'thorn'],
|
||||
['255', 'y - diaeresis'],
|
||||
['913', 'Alpha'],
|
||||
['914', 'Beta'],
|
||||
['915', 'Gamma'],
|
||||
['916', 'Delta'],
|
||||
['917', 'Epsilon'],
|
||||
['918', 'Zeta'],
|
||||
['919', 'Eta'],
|
||||
['920', 'Theta'],
|
||||
['921', 'Iota'],
|
||||
['922', 'Kappa'],
|
||||
['923', 'Lambda'],
|
||||
['924', 'Mu'],
|
||||
['925', 'Nu'],
|
||||
['926', 'Xi'],
|
||||
['927', 'Omicron'],
|
||||
['928', 'Pi'],
|
||||
['929', 'Rho'],
|
||||
['931', 'Sigma'],
|
||||
['932', 'Tau'],
|
||||
['933', 'Upsilon'],
|
||||
['934', 'Phi'],
|
||||
['935', 'Chi'],
|
||||
['936', 'Psi'],
|
||||
['937', 'Omega'],
|
||||
['945', 'alpha'],
|
||||
['946', 'beta'],
|
||||
['947', 'gamma'],
|
||||
['948', 'delta'],
|
||||
['949', 'epsilon'],
|
||||
['950', 'zeta'],
|
||||
['951', 'eta'],
|
||||
['952', 'theta'],
|
||||
['953', 'iota'],
|
||||
['954', 'kappa'],
|
||||
['955', 'lambda'],
|
||||
['956', 'mu'],
|
||||
['957', 'nu'],
|
||||
['958', 'xi'],
|
||||
['959', 'omicron'],
|
||||
['960', 'pi'],
|
||||
['961', 'rho'],
|
||||
['962', 'final sigma'],
|
||||
['963', 'sigma'],
|
||||
['964', 'tau'],
|
||||
['965', 'upsilon'],
|
||||
['966', 'phi'],
|
||||
['967', 'chi'],
|
||||
['968', 'psi'],
|
||||
['969', 'omega'],
|
||||
// symbols
|
||||
['8501', 'alef symbol'],
|
||||
['982', 'pi symbol'],
|
||||
['8476', 'real part symbol'],
|
||||
['978', 'upsilon - hook symbol'],
|
||||
['8472', 'Weierstrass p'],
|
||||
['8465', 'imaginary part'],
|
||||
// arrows
|
||||
['8592', 'leftwards arrow'],
|
||||
['8593', 'upwards arrow'],
|
||||
['8594', 'rightwards arrow'],
|
||||
['8595', 'downwards arrow'],
|
||||
['8596', 'left right arrow'],
|
||||
['8629', 'carriage return'],
|
||||
['8656', 'leftwards double arrow'],
|
||||
['8657', 'upwards double arrow'],
|
||||
['8658', 'rightwards double arrow'],
|
||||
['8659', 'downwards double arrow'],
|
||||
['8660', 'left right double arrow'],
|
||||
['8756', 'therefore'],
|
||||
['8834', 'subset of'],
|
||||
['8835', 'superset of'],
|
||||
['8836', 'not a subset of'],
|
||||
['8838', 'subset of or equal to'],
|
||||
['8839', 'superset of or equal to'],
|
||||
['8853', 'circled plus'],
|
||||
['8855', 'circled times'],
|
||||
['8869', 'perpendicular'],
|
||||
['8901', 'dot operator'],
|
||||
['8968', 'left ceiling'],
|
||||
['8969', 'right ceiling'],
|
||||
['8970', 'left floor'],
|
||||
['8971', 'right floor'],
|
||||
['9001', 'left-pointing angle bracket'],
|
||||
['9002', 'right-pointing angle bracket'],
|
||||
['9674', 'lozenge'],
|
||||
['9824', 'black spade suit'],
|
||||
['9827', 'black club suit'],
|
||||
['9829', 'black heart suit'],
|
||||
['9830', 'black diamond suit'],
|
||||
['8194', 'en space'],
|
||||
['8195', 'em space'],
|
||||
['8201', 'thin space'],
|
||||
['8204', 'zero width non-joiner'],
|
||||
['8205', 'zero width joiner'],
|
||||
['8206', 'left-to-right mark'],
|
||||
['8207', 'right-to-left mark']
|
||||
];
|
||||
}
|
||||
|
||||
function charmapFilter(charmap) {
|
||||
return tinymce.util.Tools.grep(charmap, function(item) {
|
||||
return isArray(item) && item.length == 2;
|
||||
});
|
||||
}
|
||||
|
||||
function getCharsFromSetting(settingValue) {
|
||||
if (isArray(settingValue)) {
|
||||
return [].concat(charmapFilter(settingValue));
|
||||
}
|
||||
|
||||
if (typeof settingValue == "function") {
|
||||
return settingValue();
|
||||
}
|
||||
|
||||
return [];
|
||||
}
|
||||
|
||||
function extendCharMap(charmap) {
|
||||
var settings = editor.settings;
|
||||
|
||||
if (settings.charmap) {
|
||||
charmap = getCharsFromSetting(settings.charmap);
|
||||
}
|
||||
|
||||
if (settings.charmap_append) {
|
||||
return [].concat(charmap).concat(getCharsFromSetting(settings.charmap_append));
|
||||
}
|
||||
|
||||
return charmap;
|
||||
}
|
||||
|
||||
function getCharMap() {
|
||||
return extendCharMap(getDefaultCharMap());
|
||||
}
|
||||
|
||||
function insertChar(chr) {
|
||||
editor.fire('insertCustomChar', {chr: chr}).chr;
|
||||
editor.execCommand('mceInsertContent', false, chr);
|
||||
}
|
||||
|
||||
function showDialog() {
|
||||
var gridHtml, x, y, win;
|
||||
@@ -287,7 +332,8 @@ tinymce.PluginManager.add('charmap', function(editor) {
|
||||
|
||||
gridHtml = '<table role="presentation" cellspacing="0" class="mce-charmap"><tbody>';
|
||||
|
||||
var width = 25;
|
||||
var charmap = getCharMap();
|
||||
var width = Math.min(charmap.length, 25);
|
||||
var height = Math.ceil(charmap.length / width);
|
||||
for (y = 0; y < height; y++) {
|
||||
gridHtml += '<tr>';
|
||||
@@ -314,9 +360,10 @@ tinymce.PluginManager.add('charmap', function(editor) {
|
||||
html: gridHtml,
|
||||
onclick: function(e) {
|
||||
var target = e.target;
|
||||
|
||||
if (/^(TD|DIV)$/.test(target.nodeName)) {
|
||||
if (getParentTd(target).firstChild) {
|
||||
editor.execCommand('mceInsertContent', false, tinymce.trim(target.innerText || target.textContent));
|
||||
insertChar(tinymce.trim(target.innerText || target.textContent));
|
||||
|
||||
if (!e.ctrlKey) {
|
||||
win.close();
|
||||
@@ -395,4 +442,9 @@ tinymce.PluginManager.add('charmap', function(editor) {
|
||||
cmd: 'mceShowCharmap',
|
||||
context: 'insert'
|
||||
});
|
||||
});
|
||||
|
||||
return {
|
||||
getCharMap: getCharMap,
|
||||
insertChar: insertChar
|
||||
};
|
||||
});
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -1 +1 @@
|
||||
tinymce.PluginManager.add("colorpicker",function(a){function b(b,c){function d(a){var b=new tinymce.util.Color(a),c=b.toRgb();f.fromJSON({r:c.r,g:c.g,b:c.b,hex:b.toHex().substr(1)}),e(b.toHex())}function e(a){f.find("#preview")[0].getEl().style.background=a}var f=a.windowManager.open({title:"Color",items:{type:"container",layout:"flex",direction:"row",align:"stretch",padding:5,spacing:10,items:[{type:"colorpicker",value:c,onchange:function(){var a=this.rgb();f&&(f.find("#r").value(a.r),f.find("#g").value(a.g),f.find("#b").value(a.b),f.find("#hex").value(this.value().substr(1)),e(this.value()))}},{type:"form",padding:0,labelGap:5,defaults:{type:"textbox",size:7,value:"0",flex:1,spellcheck:!1,onchange:function(){var a,b,c=f.find("colorpicker")[0];return a=this.name(),b=this.value(),"hex"==a?(b="#"+b,d(b),void c.value(b)):(b={r:f.find("#r").value(),g:f.find("#g").value(),b:f.find("#b").value()},c.value(b),void d(b))}},items:[{name:"r",label:"R",autofocus:1},{name:"g",label:"G"},{name:"b",label:"B"},{name:"hex",label:"#",value:"000000"},{name:"preview",type:"container",border:1}]}]},onSubmit:function(){b("#"+this.toJSON().hex)}});d(c)}a.settings.color_picker_callback||(a.settings.color_picker_callback=b)});
|
||||
tinymce.PluginManager.add("colorpicker",function(e){function t(t,n){function r(e){var t=new tinymce.util.Color(e),n=t.toRgb();o.fromJSON({r:n.r,g:n.g,b:n.b,hex:t.toHex().substr(1)}),i(t.toHex())}function i(e){o.find("#preview")[0].getEl().style.background=e}var o=e.windowManager.open({title:"Color",items:{type:"container",layout:"flex",direction:"row",align:"stretch",padding:5,spacing:10,items:[{type:"colorpicker",value:n,onchange:function(){var e=this.rgb();o&&(o.find("#r").value(e.r),o.find("#g").value(e.g),o.find("#b").value(e.b),o.find("#hex").value(this.value().substr(1)),i(this.value()))}},{type:"form",padding:0,labelGap:5,defaults:{type:"textbox",size:7,value:"0",flex:1,spellcheck:!1,onchange:function(){var e,t,n=o.find("colorpicker")[0];return e=this.name(),t=this.value(),"hex"==e?(t="#"+t,r(t),void n.value(t)):(t={r:o.find("#r").value(),g:o.find("#g").value(),b:o.find("#b").value()},n.value(t),void r(t))}},items:[{name:"r",label:"R",autofocus:1},{name:"g",label:"G"},{name:"b",label:"B"},{name:"hex",label:"#",value:"000000"},{name:"preview",type:"container",border:1}]}]},onSubmit:function(){t("#"+this.toJSON().hex)}});r(n)}e.settings.color_picker_callback||(e.settings.color_picker_callback=t)});
|
||||
@@ -230,7 +230,7 @@
|
||||
settings.onPostRender = patchedPostRender;
|
||||
}
|
||||
|
||||
if ( settings.title ) {
|
||||
if (settings.title) {
|
||||
// WP
|
||||
string = (editor.settings.language || "en") + "." + settings.title;
|
||||
translated = tinymce.i18n.translate(string);
|
||||
|
||||
@@ -1 +1 @@
|
||||
tinymce.PluginManager.add("directionality",function(a){function b(b){var c,d=a.dom,e=a.selection.getSelectedBlocks();e.length&&(c=d.getAttrib(e[0],"dir"),tinymce.each(e,function(a){d.getParent(a.parentNode,"*[dir='"+b+"']",d.getRoot())||(c!=b?d.setAttrib(a,"dir",b):d.setAttrib(a,"dir",null))}),a.nodeChanged())}function c(a){var b=[];return tinymce.each("h1 h2 h3 h4 h5 h6 div p".split(" "),function(c){b.push(c+"[dir="+a+"]")}),b.join(",")}a.addCommand("mceDirectionLTR",function(){b("ltr")}),a.addCommand("mceDirectionRTL",function(){b("rtl")}),a.addButton("ltr",{title:"Left to right",cmd:"mceDirectionLTR",stateSelector:c("ltr")}),a.addButton("rtl",{title:"Right to left",cmd:"mceDirectionRTL",stateSelector:c("rtl")})});
|
||||
tinymce.PluginManager.add("directionality",function(e){function t(t){var n,r=e.dom,i=e.selection.getSelectedBlocks();i.length&&(n=r.getAttrib(i[0],"dir"),tinymce.each(i,function(e){r.getParent(e.parentNode,"*[dir='"+t+"']",r.getRoot())||(n!=t?r.setAttrib(e,"dir",t):r.setAttrib(e,"dir",null))}),e.nodeChanged())}function n(e){var t=[];return tinymce.each("h1 h2 h3 h4 h5 h6 div p".split(" "),function(n){t.push(n+"[dir="+e+"]")}),t.join(",")}e.addCommand("mceDirectionLTR",function(){t("ltr")}),e.addCommand("mceDirectionRTL",function(){t("rtl")}),e.addButton("ltr",{title:"Left to right",cmd:"mceDirectionLTR",stateSelector:n("ltr")}),e.addButton("rtl",{title:"Right to left",cmd:"mceDirectionRTL",stateSelector:n("rtl")})});
|
||||
@@ -12,7 +12,7 @@
|
||||
|
||||
tinymce.PluginManager.add('fullscreen', function(editor) {
|
||||
var fullscreenState = false, DOM = tinymce.DOM, iframeWidth, iframeHeight, resizeHandler;
|
||||
var containerWidth, containerHeight;
|
||||
var containerWidth, containerHeight, scrollPos;
|
||||
|
||||
if (editor.settings.inline) {
|
||||
return;
|
||||
@@ -37,6 +37,19 @@ tinymce.PluginManager.add('fullscreen', function(editor) {
|
||||
return {w: w, h: h};
|
||||
}
|
||||
|
||||
function getScrollPos() {
|
||||
var vp = tinymce.DOM.getViewPort();
|
||||
|
||||
return {
|
||||
x: vp.x,
|
||||
y: vp.y
|
||||
};
|
||||
}
|
||||
|
||||
function setScrollPos(pos) {
|
||||
scrollTo(pos.x, pos.y);
|
||||
}
|
||||
|
||||
function toggleFullscreen() {
|
||||
var body = document.body, documentElement = document.documentElement, editorContainerStyle;
|
||||
var editorContainer, iframe, iframeStyle;
|
||||
@@ -53,6 +66,7 @@ tinymce.PluginManager.add('fullscreen', function(editor) {
|
||||
iframeStyle = iframe.style;
|
||||
|
||||
if (fullscreenState) {
|
||||
scrollPos = getScrollPos();
|
||||
iframeWidth = iframeStyle.width;
|
||||
iframeHeight = iframeStyle.height;
|
||||
iframeStyle.width = iframeStyle.height = '100%';
|
||||
@@ -83,6 +97,7 @@ tinymce.PluginManager.add('fullscreen', function(editor) {
|
||||
DOM.removeClass(documentElement, 'mce-fullscreen');
|
||||
DOM.removeClass(editorContainer, 'mce-fullscreen');
|
||||
DOM.unbind(window, 'resize', resizeHandler);
|
||||
setScrollPos(scrollPos);
|
||||
}
|
||||
|
||||
editor.fire('FullscreenStateChanged', {state: fullscreenState});
|
||||
@@ -133,4 +148,4 @@ tinymce.PluginManager.add('fullscreen', function(editor) {
|
||||
return fullscreenState;
|
||||
}
|
||||
};
|
||||
});
|
||||
});
|
||||
|
||||
@@ -1 +1 @@
|
||||
tinymce.PluginManager.add("fullscreen",function(a){function b(){var a,b,c=window,d=document,e=d.body;return e.offsetWidth&&(a=e.offsetWidth,b=e.offsetHeight),c.innerWidth&&c.innerHeight&&(a=c.innerWidth,b=c.innerHeight),{w:a,h:b}}function c(){function c(){j.setStyle(m,"height",b().h-(l.clientHeight-m.clientHeight))}var k,l,m,n,o=document.body,p=document.documentElement;i=!i,l=a.getContainer(),k=l.style,m=a.getContentAreaContainer().firstChild,n=m.style,i?(d=n.width,e=n.height,n.width=n.height="100%",g=k.width,h=k.height,k.width=k.height="",j.addClass(o,"mce-fullscreen"),j.addClass(p,"mce-fullscreen"),j.addClass(l,"mce-fullscreen"),j.bind(window,"resize",c),c(),f=c):(n.width=d,n.height=e,g&&(k.width=g),h&&(k.height=h),j.removeClass(o,"mce-fullscreen"),j.removeClass(p,"mce-fullscreen"),j.removeClass(l,"mce-fullscreen"),j.unbind(window,"resize",f)),a.fire("FullscreenStateChanged",{state:i})}var d,e,f,g,h,i=!1,j=tinymce.DOM;return a.settings.inline?void 0:(a.on("init",function(){a.addShortcut("Meta+Alt+F","",c)}),a.on("remove",function(){f&&j.unbind(window,"resize",f)}),a.addCommand("mceFullScreen",c),a.addMenuItem("fullscreen",{text:"Fullscreen",shortcut:"Meta+Alt+F",selectable:!0,onClick:c,onPostRender:function(){var b=this;a.on("FullscreenStateChanged",function(a){b.active(a.state)})},context:"view"}),a.addButton("fullscreen",{tooltip:"Fullscreen",shortcut:"Meta+Alt+F",onClick:c,onPostRender:function(){var b=this;a.on("FullscreenStateChanged",function(a){b.active(a.state)})}}),{isFullscreen:function(){return i}})});
|
||||
tinymce.PluginManager.add("fullscreen",function(e){function t(){var e,t,n=window,r=document,i=r.body;return i.offsetWidth&&(e=i.offsetWidth,t=i.offsetHeight),n.innerWidth&&n.innerHeight&&(e=n.innerWidth,t=n.innerHeight),{w:e,h:t}}function n(){var e=tinymce.DOM.getViewPort();return{x:e.x,y:e.y}}function r(e){scrollTo(e.x,e.y)}function i(){function i(){f.setStyle(p,"height",t().h-(m.clientHeight-p.clientHeight))}var h,m,p,g,v=document.body,y=document.documentElement;d=!d,m=e.getContainer(),h=m.style,p=e.getContentAreaContainer().firstChild,g=p.style,d?(u=n(),o=g.width,a=g.height,g.width=g.height="100%",l=h.width,c=h.height,h.width=h.height="",f.addClass(v,"mce-fullscreen"),f.addClass(y,"mce-fullscreen"),f.addClass(m,"mce-fullscreen"),f.bind(window,"resize",i),i(),s=i):(g.width=o,g.height=a,l&&(h.width=l),c&&(h.height=c),f.removeClass(v,"mce-fullscreen"),f.removeClass(y,"mce-fullscreen"),f.removeClass(m,"mce-fullscreen"),f.unbind(window,"resize",s),r(u)),e.fire("FullscreenStateChanged",{state:d})}var o,a,s,l,c,u,d=!1,f=tinymce.DOM;return e.settings.inline?void 0:(e.on("init",function(){e.addShortcut("Meta+Alt+F","",i)}),e.on("remove",function(){s&&f.unbind(window,"resize",s)}),e.addCommand("mceFullScreen",i),e.addMenuItem("fullscreen",{text:"Fullscreen",shortcut:"Meta+Alt+F",selectable:!0,onClick:i,onPostRender:function(){var t=this;e.on("FullscreenStateChanged",function(e){t.active(e.state)})},context:"view"}),e.addButton("fullscreen",{tooltip:"Fullscreen",shortcut:"Meta+Alt+F",onClick:i,onPostRender:function(){var t=this;e.on("FullscreenStateChanged",function(e){t.active(e.state)})}}),{isFullscreen:function(){return d}})});
|
||||
+1
-1
@@ -1 +1 @@
|
||||
tinymce.PluginManager.add("hr",function(a){a.addCommand("InsertHorizontalRule",function(){a.execCommand("mceInsertContent",!1,"<hr />")}),a.addButton("hr",{icon:"hr",tooltip:"Horizontal line",cmd:"InsertHorizontalRule"}),a.addMenuItem("hr",{icon:"hr",text:"Horizontal line",cmd:"InsertHorizontalRule",context:"insert"})});
|
||||
tinymce.PluginManager.add("hr",function(e){e.addCommand("InsertHorizontalRule",function(){e.execCommand("mceInsertContent",!1,"<hr />")}),e.addButton("hr",{icon:"hr",tooltip:"Horizontal line",cmd:"InsertHorizontalRule"}),e.addMenuItem("hr",{icon:"hr",text:"Horizontal line",cmd:"InsertHorizontalRule",context:"insert"})});
|
||||
@@ -83,7 +83,7 @@ tinymce.PluginManager.add('image', function(editor) {
|
||||
}
|
||||
|
||||
function showDialog(imageList) {
|
||||
var win, data = {}, dom = editor.dom, imgElm = editor.selection.getNode();
|
||||
var win, data = {}, dom = editor.dom, imgElm, figureElm;
|
||||
var width, height, imageListCtrl, classListCtrl, imageDimensions = editor.settings.image_dimensions !== false;
|
||||
|
||||
function recalcSize() {
|
||||
@@ -120,6 +120,8 @@ tinymce.PluginManager.add('image', function(editor) {
|
||||
}
|
||||
|
||||
function onSubmitForm() {
|
||||
var figureElm, oldImg;
|
||||
|
||||
function waitLoad(imgElm) {
|
||||
function selectImage() {
|
||||
imgElm.onload = imgElm.onerror = null;
|
||||
@@ -150,7 +152,7 @@ tinymce.PluginManager.add('image', function(editor) {
|
||||
recalcSize();
|
||||
|
||||
data = tinymce.extend(data, win.toJSON());
|
||||
var caption = data.caption; // WP
|
||||
var wpcaption = data.wpcaption; // WP
|
||||
|
||||
if (!data.alt) {
|
||||
data.alt = '';
|
||||
@@ -181,12 +183,13 @@ tinymce.PluginManager.add('image', function(editor) {
|
||||
width: data.width,
|
||||
height: data.height,
|
||||
style: data.style,
|
||||
caption: data.caption,
|
||||
"class": data["class"]
|
||||
};
|
||||
|
||||
editor.undoManager.transact(function() {
|
||||
// WP
|
||||
var eventData = { node: imgElm, data: data, caption: caption };
|
||||
var eventData = { node: imgElm, data: data, wpcaption: wpcaption };
|
||||
|
||||
editor.fire( 'wpImageFormSubmit', { imgData: eventData } );
|
||||
|
||||
@@ -218,7 +221,42 @@ tinymce.PluginManager.add('image', function(editor) {
|
||||
dom.setAttrib(imgElm, 'id', null);
|
||||
} else {
|
||||
dom.setAttribs(imgElm, data);
|
||||
editor.editorUpload.uploadImagesAuto();
|
||||
}
|
||||
|
||||
editor.editorUpload.uploadImagesAuto();
|
||||
|
||||
if (data.caption === false) {
|
||||
if (dom.is(imgElm.parentNode, 'figure.image')) {
|
||||
figureElm = imgElm.parentNode;
|
||||
dom.insertAfter(imgElm, figureElm);
|
||||
dom.remove(figureElm);
|
||||
}
|
||||
}
|
||||
|
||||
function isTextBlock(node) {
|
||||
return editor.schema.getTextBlockElements()[node.nodeName];
|
||||
}
|
||||
|
||||
if (data.caption === true) {
|
||||
if (!dom.is(imgElm.parentNode, 'figure.image')) {
|
||||
oldImg = imgElm;
|
||||
imgElm = imgElm.cloneNode(true);
|
||||
figureElm = dom.create('figure', {'class': 'image'});
|
||||
figureElm.appendChild(imgElm);
|
||||
figureElm.appendChild(dom.create('figcaption', {contentEditable: true}, 'Caption'));
|
||||
figureElm.contentEditable = false;
|
||||
|
||||
var textBlock = dom.getParent(oldImg, isTextBlock);
|
||||
if (textBlock) {
|
||||
dom.split(textBlock, oldImg, figureElm);
|
||||
} else {
|
||||
dom.replace(figureElm, oldImg);
|
||||
}
|
||||
|
||||
editor.selection.select(figureElm);
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
waitLoad(imgElm);
|
||||
@@ -268,23 +306,32 @@ tinymce.PluginManager.add('image', function(editor) {
|
||||
}
|
||||
}
|
||||
|
||||
width = dom.getAttrib(imgElm, 'width');
|
||||
height = dom.getAttrib(imgElm, 'height');
|
||||
imgElm = editor.selection.getNode();
|
||||
figureElm = dom.getParent(imgElm, 'figure.image');
|
||||
if (figureElm) {
|
||||
imgElm = dom.select('img', figureElm)[0];
|
||||
}
|
||||
|
||||
if (imgElm && (imgElm.nodeName != 'IMG' || imgElm.getAttribute('data-mce-object') || imgElm.getAttribute('data-mce-placeholder'))) {
|
||||
imgElm = null;
|
||||
}
|
||||
|
||||
if (imgElm) {
|
||||
width = dom.getAttrib(imgElm, 'width');
|
||||
height = dom.getAttrib(imgElm, 'height');
|
||||
|
||||
if (imgElm.nodeName == 'IMG' && !imgElm.getAttribute('data-mce-object') && !imgElm.getAttribute('data-mce-placeholder')) {
|
||||
data = {
|
||||
src: dom.getAttrib(imgElm, 'src'),
|
||||
alt: dom.getAttrib(imgElm, 'alt'),
|
||||
title: dom.getAttrib(imgElm, 'title'),
|
||||
"class": dom.getAttrib(imgElm, 'class'),
|
||||
width: width,
|
||||
height: height
|
||||
height: height,
|
||||
caption: !!figureElm
|
||||
};
|
||||
|
||||
// WP
|
||||
editor.fire( 'wpLoadImageData', { imgData: { data: data, node: imgElm } } );
|
||||
} else {
|
||||
imgElm = null;
|
||||
}
|
||||
|
||||
if (imageList) {
|
||||
@@ -373,6 +420,10 @@ tinymce.PluginManager.add('image', function(editor) {
|
||||
|
||||
generalFormItems.push(classListCtrl);
|
||||
|
||||
if (editor.settings.image_caption && tinymce.Env.ceFalse) {
|
||||
generalFormItems.push({name: 'caption', type: 'checkbox', label: 'Caption'});
|
||||
}
|
||||
|
||||
// WP
|
||||
editor.fire( 'wpLoadImageForm', { data: generalFormItems } );
|
||||
|
||||
@@ -551,11 +602,40 @@ tinymce.PluginManager.add('image', function(editor) {
|
||||
}
|
||||
}
|
||||
|
||||
editor.on('preInit', function() {
|
||||
function hasImageClass(node) {
|
||||
var className = node.attr('class');
|
||||
return className && /\bimage\b/.test(className);
|
||||
}
|
||||
|
||||
function toggleContentEditableState(state) {
|
||||
return function(nodes) {
|
||||
var i = nodes.length, node;
|
||||
|
||||
function toggleContentEditable(node) {
|
||||
node.attr('contenteditable', state ? 'true' : null);
|
||||
}
|
||||
|
||||
while (i--) {
|
||||
node = nodes[i];
|
||||
|
||||
if (hasImageClass(node)) {
|
||||
node.attr('contenteditable', state ? 'false' : null);
|
||||
tinymce.each(node.getAll('figcaption'), toggleContentEditable);
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
editor.parser.addNodeFilter('figure', toggleContentEditableState(true));
|
||||
editor.serializer.addNodeFilter('figure', toggleContentEditableState(false));
|
||||
});
|
||||
|
||||
editor.addButton('image', {
|
||||
icon: 'image',
|
||||
tooltip: 'Insert/edit image',
|
||||
onclick: createImageList(showDialog),
|
||||
stateSelector: 'img:not([data-mce-object],[data-mce-placeholder])'
|
||||
stateSelector: 'img:not([data-mce-object],[data-mce-placeholder]),figure.image'
|
||||
});
|
||||
|
||||
editor.addMenuItem('image', {
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
@@ -498,7 +498,11 @@ tinymce.PluginManager.add('lists', function(editor) {
|
||||
}
|
||||
|
||||
function applyList(listName) {
|
||||
var rng = selection.getRng(true), bookmark = createBookmark(rng), listItemName = 'LI';
|
||||
var rng = selection.getRng(true), bookmark, listItemName = 'LI';
|
||||
|
||||
if (dom.getContentEditable(selection.getNode()) === "false") {
|
||||
return;
|
||||
}
|
||||
|
||||
listName = listName.toUpperCase();
|
||||
|
||||
@@ -583,6 +587,8 @@ tinymce.PluginManager.add('lists', function(editor) {
|
||||
return textBlocks;
|
||||
}
|
||||
|
||||
bookmark = createBookmark(rng);
|
||||
|
||||
tinymce.each(getSelectedTextBlocks(), function(block) {
|
||||
var listBlock, sibling;
|
||||
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
@@ -14,8 +14,9 @@
|
||||
|
||||
tinymce.PluginManager.add('media', function(editor, url) {
|
||||
var urlPatterns = [
|
||||
{regex: /youtu\.be\/([\w\-.]+)/, type: 'iframe', w: 425, h: 350, url: '//www.youtube.com/embed/$1', allowFullscreen: true},
|
||||
{regex: /youtube\.com(.+)v=([^&]+)/, type: 'iframe', w: 425, h: 350, url: '//www.youtube.com/embed/$2', allowFullscreen: true},
|
||||
{regex: /youtu\.be\/([\w\-.]+)/, type: 'iframe', w: 560, h: 314, url: '//www.youtube.com/embed/$1', allowFullscreen: true},
|
||||
{regex: /youtube\.com(.+)v=([^&]+)/, type: 'iframe', w: 560, h: 314, url: '//www.youtube.com/embed/$2', allowFullscreen: true},
|
||||
{regex: /youtube.com\/embed\/([a-z0-9\-_]+)/i, type: 'iframe', w: 560, h: 314, url: '//www.youtube.com/embed/$1', allowFullscreen: true},
|
||||
{regex: /vimeo\.com\/([0-9]+)/, type: 'iframe', w: 425, h: 350, url: '//player.vimeo.com/video/$1?title=0&byline=0&portrait=0&color=8dc7dc', allowfullscreen: true},
|
||||
{regex: /vimeo\.com\/(.*)\/([0-9]+)/, type: "iframe", w: 425, h: 350, url: "//player.vimeo.com/video/$2?title=0&byline=0", allowfullscreen: true},
|
||||
{regex: /maps\.google\.([a-z]{2,3})\/maps\/(.+)msid=(.+)/, type: 'iframe', w: 425, h: 350, url: '//maps.google.com/maps/ms?msid=$2&output=embed"', allowFullscreen: false}
|
||||
@@ -611,6 +612,86 @@ tinymce.PluginManager.add('media', function(editor, url) {
|
||||
}
|
||||
});
|
||||
|
||||
function retainAttributesAndInnerHtml(sourceNode, targetNode) {
|
||||
var attrName, attrValue, attribs, ai, innerHtml;
|
||||
|
||||
// Prefix all attributes except width, height and style since we
|
||||
// will add these to the placeholder
|
||||
attribs = sourceNode.attributes;
|
||||
ai = attribs.length;
|
||||
while (ai--) {
|
||||
attrName = attribs[ai].name;
|
||||
attrValue = attribs[ai].value;
|
||||
|
||||
if (attrName !== "width" && attrName !== "height" && attrName !== "style") {
|
||||
if (attrName == "data" || attrName == "src") {
|
||||
attrValue = editor.convertURL(attrValue, attrName);
|
||||
}
|
||||
|
||||
targetNode.attr('data-mce-p-' + attrName, attrValue);
|
||||
}
|
||||
}
|
||||
|
||||
// Place the inner HTML contents inside an escaped attribute
|
||||
// This enables us to copy/paste the fake object
|
||||
innerHtml = sourceNode.firstChild && sourceNode.firstChild.value;
|
||||
if (innerHtml) {
|
||||
targetNode.attr("data-mce-html", escape(innerHtml));
|
||||
targetNode.firstChild = null;
|
||||
}
|
||||
}
|
||||
|
||||
function createPlaceholderNode(node) {
|
||||
var placeHolder, name = node.name;
|
||||
|
||||
placeHolder = new tinymce.html.Node('img', 1);
|
||||
placeHolder.shortEnded = true;
|
||||
|
||||
retainAttributesAndInnerHtml(node, placeHolder);
|
||||
|
||||
placeHolder.attr({
|
||||
width: node.attr('width') || "300",
|
||||
height: node.attr('height') || (name == "audio" ? "30" : "150"),
|
||||
style: node.attr('style'),
|
||||
src: tinymce.Env.transparentSrc,
|
||||
"data-mce-object": name,
|
||||
"class": "mce-object mce-object-" + name
|
||||
});
|
||||
|
||||
return placeHolder;
|
||||
}
|
||||
|
||||
function createPreviewNode(node) {
|
||||
var previewWrapper, previewNode, shimNode, name = node.name;
|
||||
|
||||
previewWrapper = new tinymce.html.Node('span', 1);
|
||||
previewWrapper.attr({
|
||||
contentEditable: 'false',
|
||||
style: node.attr('style'),
|
||||
"data-mce-object": name,
|
||||
"class": "mce-preview-object mce-object-" + name
|
||||
});
|
||||
|
||||
retainAttributesAndInnerHtml(node, previewWrapper);
|
||||
|
||||
previewNode = new tinymce.html.Node(name, 1);
|
||||
previewNode.attr({
|
||||
src: node.attr('src'),
|
||||
allowfullscreen: node.attr('allowfullscreen'),
|
||||
width: node.attr('width') || "300",
|
||||
height: node.attr('height') || (name == "audio" ? "30" : "150"),
|
||||
frameborder: '0'
|
||||
});
|
||||
|
||||
shimNode = new tinymce.html.Node('span', 1);
|
||||
shimNode.attr('class', 'mce-shim');
|
||||
|
||||
previewWrapper.append(previewNode);
|
||||
previewWrapper.append(shimNode);
|
||||
|
||||
return previewWrapper;
|
||||
}
|
||||
|
||||
editor.on('preInit', function() {
|
||||
// Make sure that any messy HTML is retained inside these
|
||||
var specialElements = editor.schema.getSpecialElements();
|
||||
@@ -628,9 +709,8 @@ tinymce.PluginManager.add('media', function(editor, url) {
|
||||
});
|
||||
|
||||
// Converts iframe, video etc into placeholder images
|
||||
editor.parser.addNodeFilter('iframe,video,audio,object,embed,script', function(nodes, name) {
|
||||
var i = nodes.length, ai, node, placeHolder, attrName, attrValue, attribs, innerHtml;
|
||||
var videoScript;
|
||||
editor.parser.addNodeFilter('iframe,video,audio,object,embed,script', function(nodes) {
|
||||
var i = nodes.length, node, placeHolder, videoScript;
|
||||
|
||||
while (i--) {
|
||||
node = nodes[i];
|
||||
@@ -638,6 +718,10 @@ tinymce.PluginManager.add('media', function(editor, url) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (node.parent.attr('data-mce-object')) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (node.name == 'script') {
|
||||
videoScript = getVideoScriptMatch(node.attr('src'));
|
||||
if (!videoScript) {
|
||||
@@ -645,9 +729,6 @@ tinymce.PluginManager.add('media', function(editor, url) {
|
||||
}
|
||||
}
|
||||
|
||||
placeHolder = new tinymce.html.Node('img', 1);
|
||||
placeHolder.shortEnded = true;
|
||||
|
||||
if (videoScript) {
|
||||
if (videoScript.width) {
|
||||
node.attr('width', videoScript.width.toString());
|
||||
@@ -658,47 +739,19 @@ tinymce.PluginManager.add('media', function(editor, url) {
|
||||
}
|
||||
}
|
||||
|
||||
// Prefix all attributes except width, height and style since we
|
||||
// will add these to the placeholder
|
||||
attribs = node.attributes;
|
||||
ai = attribs.length;
|
||||
while (ai--) {
|
||||
attrName = attribs[ai].name;
|
||||
attrValue = attribs[ai].value;
|
||||
|
||||
if (attrName !== "width" && attrName !== "height" && attrName !== "style") {
|
||||
if (attrName == "data" || attrName == "src") {
|
||||
attrValue = editor.convertURL(attrValue, attrName);
|
||||
}
|
||||
|
||||
placeHolder.attr('data-mce-p-' + attrName, attrValue);
|
||||
}
|
||||
if (node.name == 'iframe' && editor.settings.media_live_embeds !== false && tinymce.Env.ceFalse) {
|
||||
placeHolder = createPreviewNode(node);
|
||||
} else {
|
||||
placeHolder = createPlaceholderNode(node);
|
||||
}
|
||||
|
||||
// Place the inner HTML contents inside an escaped attribute
|
||||
// This enables us to copy/paste the fake object
|
||||
innerHtml = node.firstChild && node.firstChild.value;
|
||||
if (innerHtml) {
|
||||
placeHolder.attr("data-mce-html", escape(innerHtml));
|
||||
placeHolder.firstChild = null;
|
||||
}
|
||||
|
||||
placeHolder.attr({
|
||||
width: node.attr('width') || "300",
|
||||
height: node.attr('height') || (name == "audio" ? "30" : "150"),
|
||||
style: node.attr('style'),
|
||||
src: tinymce.Env.transparentSrc,
|
||||
"data-mce-object": name,
|
||||
"class": "mce-object mce-object-" + name
|
||||
});
|
||||
|
||||
node.replace(placeHolder);
|
||||
}
|
||||
});
|
||||
|
||||
// Replaces placeholder images with real elements for video, object, iframe etc
|
||||
editor.serializer.addAttributeFilter('data-mce-object', function(nodes, name) {
|
||||
var i = nodes.length, node, realElm, ai, attribs, innerHtml, innerNode, realElmName;
|
||||
var i = nodes.length, node, realElm, ai, attribs, innerHtml, innerNode, realElmName, className;
|
||||
|
||||
while (i--) {
|
||||
node = nodes[i];
|
||||
@@ -711,10 +764,18 @@ tinymce.PluginManager.add('media', function(editor, url) {
|
||||
|
||||
// Add width/height to everything but audio
|
||||
if (realElmName != "audio" && realElmName != "script") {
|
||||
realElm.attr({
|
||||
width: node.attr('width'),
|
||||
height: node.attr('height')
|
||||
});
|
||||
className = node.attr('class');
|
||||
if (className && className.indexOf('mce-preview-object') !== -1) {
|
||||
realElm.attr({
|
||||
width: node.firstChild.attr('width'),
|
||||
height: node.firstChild.attr('height')
|
||||
});
|
||||
} else {
|
||||
realElm.attr({
|
||||
width: node.attr('width'),
|
||||
height: node.attr('height')
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
realElm.attr({
|
||||
@@ -778,7 +839,7 @@ tinymce.PluginManager.add('media', function(editor, url) {
|
||||
editor.addButton('media', {
|
||||
tooltip: 'Insert/edit video',
|
||||
onclick: showDialog,
|
||||
stateSelector: ['img[data-mce-object=video]', 'img[data-mce-object=iframe]']
|
||||
stateSelector: ['img[data-mce-object]', 'span[data-mce-object]']
|
||||
});
|
||||
|
||||
editor.addMenuItem('media', {
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
@@ -216,6 +216,7 @@ define("tinymce/pasteplugin/Utils", [
|
||||
/^[\s\S]*<body[^>]*>\s*|\s*<\/body[^>]*>[\s\S]*$/g, // Remove anything but the contents within the BODY element
|
||||
/<!--StartFragment-->|<!--EndFragment-->/g, // Inner fragments (tables from excel on mac)
|
||||
[/( ?)<span class="Apple-converted-space">\u00a0<\/span>( ?)/g, trimSpaces],
|
||||
/<br class="Apple-interchange-newline">/g,
|
||||
/<br>$/i // Trailing BR elements
|
||||
]);
|
||||
|
||||
@@ -264,8 +265,9 @@ define("tinymce/pasteplugin/Clipboard", [
|
||||
"tinymce/Env",
|
||||
"tinymce/dom/RangeUtils",
|
||||
"tinymce/util/VK",
|
||||
"tinymce/pasteplugin/Utils"
|
||||
], function(Env, RangeUtils, VK, Utils) {
|
||||
"tinymce/pasteplugin/Utils",
|
||||
"tinymce/util/Delay"
|
||||
], function(Env, RangeUtils, VK, Utils, Delay) {
|
||||
return function(editor) {
|
||||
var self = this, pasteBinElm, lastRng, keyboardPasteTimeStamp = 0, draggingInternally = false;
|
||||
var pasteBinDefaultContent = '%MCEPASTEBIN%', keyboardPastePlainTextState;
|
||||
@@ -724,6 +726,65 @@ define("tinymce/pasteplugin/Clipboard", [
|
||||
}
|
||||
});
|
||||
|
||||
function insertClipboardContent(clipboardContent, isKeyBoardPaste, plainTextMode) {
|
||||
var content;
|
||||
|
||||
// Grab HTML from Clipboard API or paste bin as a fallback
|
||||
if (hasContentType(clipboardContent, 'text/html')) {
|
||||
content = clipboardContent['text/html'];
|
||||
} else {
|
||||
content = getPasteBinHtml();
|
||||
|
||||
// If paste bin is empty try using plain text mode
|
||||
// since that is better than nothing right
|
||||
if (content == pasteBinDefaultContent) {
|
||||
plainTextMode = true;
|
||||
}
|
||||
}
|
||||
|
||||
content = Utils.trimHtml(content);
|
||||
|
||||
// WebKit has a nice bug where it clones the paste bin if you paste from for example notepad
|
||||
// so we need to force plain text mode in this case
|
||||
if (pasteBinElm && pasteBinElm.firstChild && pasteBinElm.firstChild.id === 'mcepastebin') {
|
||||
plainTextMode = true;
|
||||
}
|
||||
|
||||
removePasteBin();
|
||||
|
||||
// If we got nothing from clipboard API and pastebin then we could try the last resort: plain/text
|
||||
if (!content.length) {
|
||||
plainTextMode = true;
|
||||
}
|
||||
|
||||
// Grab plain text from Clipboard API or convert existing HTML to plain text
|
||||
if (plainTextMode) {
|
||||
// Use plain text contents from Clipboard API unless the HTML contains paragraphs then
|
||||
// we should convert the HTML to plain text since works better when pasting HTML/Word contents as plain text
|
||||
if (hasContentType(clipboardContent, 'text/plain') && content.indexOf('</p>') == -1) {
|
||||
content = clipboardContent['text/plain'];
|
||||
} else {
|
||||
content = Utils.innerText(content);
|
||||
}
|
||||
}
|
||||
|
||||
// If the content is the paste bin default HTML then it was
|
||||
// impossible to get the cliboard data out.
|
||||
if (content == pasteBinDefaultContent) {
|
||||
if (!isKeyBoardPaste) {
|
||||
editor.windowManager.alert('Please use Ctrl+V/Cmd+V keyboard shortcuts to paste contents.');
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
if (plainTextMode) {
|
||||
pasteText(content);
|
||||
} else {
|
||||
pasteHtml(content);
|
||||
}
|
||||
}
|
||||
|
||||
editor.on('paste', function(e) {
|
||||
// Getting content from the Clipboard can take some time
|
||||
var clipboardTimer = new Date().getTime();
|
||||
@@ -762,64 +823,15 @@ define("tinymce/pasteplugin/Clipboard", [
|
||||
clipboardContent["text/html"] = getPasteBinHtml();
|
||||
}
|
||||
|
||||
setTimeout(function() {
|
||||
var content;
|
||||
|
||||
// Grab HTML from Clipboard API or paste bin as a fallback
|
||||
if (hasContentType(clipboardContent, 'text/html')) {
|
||||
content = clipboardContent['text/html'];
|
||||
} else {
|
||||
content = getPasteBinHtml();
|
||||
|
||||
// If paste bin is empty try using plain text mode
|
||||
// since that is better than nothing right
|
||||
if (content == pasteBinDefaultContent) {
|
||||
plainTextMode = true;
|
||||
}
|
||||
}
|
||||
|
||||
content = Utils.trimHtml(content);
|
||||
|
||||
// WebKit has a nice bug where it clones the paste bin if you paste from for example notepad
|
||||
// so we need to force plain text mode in this case
|
||||
if (pasteBinElm && pasteBinElm.firstChild && pasteBinElm.firstChild.id === 'mcepastebin') {
|
||||
plainTextMode = true;
|
||||
}
|
||||
|
||||
removePasteBin();
|
||||
|
||||
// If we got nothing from clipboard API and pastebin then we could try the last resort: plain/text
|
||||
if (!content.length) {
|
||||
plainTextMode = true;
|
||||
}
|
||||
|
||||
// Grab plain text from Clipboard API or convert existing HTML to plain text
|
||||
if (plainTextMode) {
|
||||
// Use plain text contents from Clipboard API unless the HTML contains paragraphs then
|
||||
// we should convert the HTML to plain text since works better when pasting HTML/Word contents as plain text
|
||||
if (hasContentType(clipboardContent, 'text/plain') && content.indexOf('</p>') == -1) {
|
||||
content = clipboardContent['text/plain'];
|
||||
} else {
|
||||
content = Utils.innerText(content);
|
||||
}
|
||||
}
|
||||
|
||||
// If the content is the paste bin default HTML then it was
|
||||
// impossible to get the cliboard data out.
|
||||
if (content == pasteBinDefaultContent) {
|
||||
if (!isKeyBoardPaste) {
|
||||
editor.windowManager.alert('Please use Ctrl+V/Cmd+V keyboard shortcuts to paste contents.');
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
if (plainTextMode) {
|
||||
pasteText(content);
|
||||
} else {
|
||||
pasteHtml(content);
|
||||
}
|
||||
}, 0);
|
||||
// If clipboard API has HTML then use that directly
|
||||
if (hasContentType(clipboardContent, 'text/html')) {
|
||||
e.preventDefault();
|
||||
insertClipboardContent(clipboardContent, isKeyBoardPaste, plainTextMode);
|
||||
} else {
|
||||
Delay.setEditorTimeout(editor, function() {
|
||||
insertClipboardContent(clipboardContent, isKeyBoardPaste, plainTextMode);
|
||||
}, 0);
|
||||
}
|
||||
});
|
||||
|
||||
editor.on('dragstart dragend', function(e) {
|
||||
@@ -1623,10 +1635,12 @@ define("tinymce/pasteplugin/Plugin", [
|
||||
this.active(true);
|
||||
|
||||
if (!userIsInformed) {
|
||||
editor.windowManager.alert(
|
||||
'Paste is now in plain text mode. Contents will now ' +
|
||||
'be pasted as plain text until you toggle this option off.'
|
||||
);
|
||||
var message = editor.translate('Paste is now in plain text mode. Contents will now ' +
|
||||
'be pasted as plain text until you toggle this option off.');
|
||||
editor.notificationManager.open({
|
||||
text: message,
|
||||
type: 'info'
|
||||
});
|
||||
|
||||
userIsInformed = true;
|
||||
}
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
@@ -90,7 +90,7 @@ tinymce.PluginManager.add('tabfocus', function(editor) {
|
||||
if (el.id && focusEditor) {
|
||||
focusEditor.focus();
|
||||
} else {
|
||||
window.setTimeout(function() {
|
||||
tinymce.util.Delay.setTimeout(function() {
|
||||
if (!tinymce.Env.webkit) {
|
||||
window.focus();
|
||||
}
|
||||
|
||||
@@ -1 +1 @@
|
||||
tinymce.PluginManager.add("tabfocus",function(a){function b(a){9!==a.keyCode||a.ctrlKey||a.altKey||a.metaKey||a.preventDefault()}function c(b){function c(c){function f(a){return"BODY"===a.nodeName||"hidden"!=a.type&&"none"!=a.style.display&&"hidden"!=a.style.visibility&&f(a.parentNode)}function i(a){return/INPUT|TEXTAREA|BUTTON/.test(a.tagName)&&tinymce.get(b.id)&&-1!=a.tabIndex&&f(a)}if(h=d.select(":input:enabled,*[tabindex]:not(iframe)"),e(h,function(b,c){return b.id==a.id?(g=c,!1):void 0}),c>0){for(j=g+1;j<h.length;j++)if(i(h[j]))return h[j]}else for(j=g-1;j>=0;j--)if(i(h[j]))return h[j];return null}var g,h,i,j;if(!(9!==b.keyCode||b.ctrlKey||b.altKey||b.metaKey||b.isDefaultPrevented())&&(i=f(a.getParam("tab_focus",a.getParam("tabfocus_elements",":prev,:next"))),1==i.length&&(i[1]=i[0],i[0]=":prev"),h=b.shiftKey?":prev"==i[0]?c(-1):d.get(i[0]):":next"==i[1]?c(1):d.get(i[1]))){var k=tinymce.get(h.id||h.name);h.id&&k?k.focus():window.setTimeout(function(){tinymce.Env.webkit||window.focus(),h.focus()},10),b.preventDefault()}}var d=tinymce.DOM,e=tinymce.each,f=tinymce.explode;a.on("init",function(){a.inline&&tinymce.DOM.setAttrib(a.getBody(),"tabIndex",null),a.on("keyup",b),tinymce.Env.gecko?a.on("keypress keydown",c):a.on("keydown",c)})});
|
||||
tinymce.PluginManager.add("tabfocus",function(e){function t(e){9!==e.keyCode||e.ctrlKey||e.altKey||e.metaKey||e.preventDefault()}function n(t){function n(n){function o(e){return"BODY"===e.nodeName||"hidden"!=e.type&&"none"!=e.style.display&&"hidden"!=e.style.visibility&&o(e.parentNode)}function l(e){return/INPUT|TEXTAREA|BUTTON/.test(e.tagName)&&tinymce.get(t.id)&&-1!=e.tabIndex&&o(e)}if(s=r.select(":input:enabled,*[tabindex]:not(iframe)"),i(s,function(t,n){return t.id==e.id?(a=n,!1):void 0}),n>0){for(c=a+1;c<s.length;c++)if(l(s[c]))return s[c]}else for(c=a-1;c>=0;c--)if(l(s[c]))return s[c];return null}var a,s,l,c;if(!(9!==t.keyCode||t.ctrlKey||t.altKey||t.metaKey||t.isDefaultPrevented())&&(l=o(e.getParam("tab_focus",e.getParam("tabfocus_elements",":prev,:next"))),1==l.length&&(l[1]=l[0],l[0]=":prev"),s=t.shiftKey?":prev"==l[0]?n(-1):r.get(l[0]):":next"==l[1]?n(1):r.get(l[1]))){var u=tinymce.get(s.id||s.name);s.id&&u?u.focus():tinymce.util.Delay.setTimeout(function(){tinymce.Env.webkit||window.focus(),s.focus()},10),t.preventDefault()}}var r=tinymce.DOM,i=tinymce.each,o=tinymce.explode;e.on("init",function(){e.inline&&tinymce.DOM.setAttrib(e.getBody(),"tabIndex",null),e.on("keyup",t),tinymce.Env.gecko?e.on("keypress keydown",n):e.on("keydown",n)})});
|
||||
@@ -1 +1 @@
|
||||
tinymce.PluginManager.add("textcolor",function(a){function b(b){var c;return a.dom.getParents(a.selection.getStart(),function(a){var d;(d=a.style["forecolor"==b?"color":"background-color"])&&(c=d)}),c}function c(){var b,c,d=[];for(c=a.settings.textcolor_map||["000000","Black","993300","Burnt orange","333300","Dark olive","003300","Dark green","003366","Dark azure","000080","Navy Blue","333399","Indigo","333333","Very dark gray","800000","Maroon","FF6600","Orange","808000","Olive","008000","Green","008080","Teal","0000FF","Blue","666699","Grayish blue","808080","Gray","FF0000","Red","FF9900","Amber","99CC00","Yellow green","339966","Sea green","33CCCC","Turquoise","3366FF","Royal blue","800080","Purple","999999","Medium gray","FF00FF","Magenta","FFCC00","Gold","FFFF00","Yellow","00FF00","Lime","00FFFF","Aqua","00CCFF","Sky blue","993366","Red violet","FFFFFF","White","FF99CC","Pink","FFCC99","Peach","FFFF99","Light yellow","CCFFCC","Pale green","CCFFFF","Pale cyan","99CCFF","Light sky blue","CC99FF","Plum"],b=0;b<c.length;b+=2)d.push({text:c[b+1],color:"#"+c[b]});return d}function d(){function b(a,b){var c="transparent"==a;return'<td class="mce-grid-cell'+(c?" mce-colorbtn-trans":"")+'"><div id="'+n+"-"+o++ +'" data-mce-color="'+(a?a:"")+'" role="option" tabIndex="-1" style="'+(a?"background-color: "+a:"")+'" title="'+tinymce.translate(b)+'">'+(c?"×":"")+"</div></td>"}var d,e,f,g,h,k,l,m=this,n=m._id,o=0;for(d=c(),d.push({text:tinymce.translate("No color"),color:"transparent"}),f='<table class="mce-grid mce-grid-border mce-colorbutton-grid" role="list" cellspacing="0"><tbody>',g=d.length-1,k=0;j>k;k++){for(f+="<tr>",h=0;i>h;h++)l=k*i+h,l>g?f+="<td></td>":(e=d[l],f+=b(e.color,e.text));f+="</tr>"}if(a.settings.color_picker_callback){for(f+='<tr><td colspan="'+i+'" class="mce-custom-color-btn"><div id="'+n+'-c" class="mce-widget mce-btn mce-btn-small mce-btn-flat" role="button" tabindex="-1" aria-labelledby="'+n+'-c" style="width: 100%"><button type="button" role="presentation" tabindex="-1">'+tinymce.translate("Custom...")+"</button></div></td></tr>",f+="<tr>",h=0;i>h;h++)f+=b("","Custom color");f+="</tr>"}return f+="</tbody></table>"}function e(b,c){a.undoManager.transact(function(){a.focus(),a.formatter.apply(b,{value:c}),a.nodeChanged()})}function f(b){a.undoManager.transact(function(){a.focus(),a.formatter.remove(b,{value:null},null,!0),a.nodeChanged()})}function g(c){function d(a){k.hidePanel(),k.color(a),e(k.settings.format,a)}function g(){k.hidePanel(),k.resetColor(),f(k.settings.format)}function h(a,b){a.style.background=b,a.setAttribute("data-mce-color",b)}var j,k=this.parent();tinymce.DOM.getParent(c.target,".mce-custom-color-btn")&&(k.hidePanel(),a.settings.color_picker_callback.call(a,function(a){var b,c,e,f=k.panel.getEl().getElementsByTagName("table")[0];for(b=tinymce.map(f.rows[f.rows.length-1].childNodes,function(a){return a.firstChild}),e=0;e<b.length&&(c=b[e],c.getAttribute("data-mce-color"));e++);if(e==i)for(e=0;i-1>e;e++)h(b[e],b[e+1].getAttribute("data-mce-color"));h(c,a),d(a)},b(k.settings.format))),j=c.target.getAttribute("data-mce-color"),j?(this.lastId&&document.getElementById(this.lastId).setAttribute("aria-selected",!1),c.target.setAttribute("aria-selected",!0),this.lastId=c.target.id,"transparent"==j?g():d(j)):null!==j&&k.hidePanel()}function h(){var a=this;a._color?e(a.settings.format,a._color):f(a.settings.format)}var i,j;j=a.settings.textcolor_rows||5,i=a.settings.textcolor_cols||8,a.addButton("forecolor",{type:"colorbutton",tooltip:"Text color",format:"forecolor",panel:{role:"application",ariaRemember:!0,html:d,onclick:g},onclick:h}),a.addButton("backcolor",{type:"colorbutton",tooltip:"Background color",format:"hilitecolor",panel:{role:"application",ariaRemember:!0,html:d,onclick:g},onclick:h})});
|
||||
tinymce.PluginManager.add("textcolor",function(e){function t(t){var n;return e.dom.getParents(e.selection.getStart(),function(e){var r;(r=e.style["forecolor"==t?"color":"background-color"])&&(n=r)}),n}function n(){var t,n,r=[];for(n=e.settings.textcolor_map||["000000","Black","993300","Burnt orange","333300","Dark olive","003300","Dark green","003366","Dark azure","000080","Navy Blue","333399","Indigo","333333","Very dark gray","800000","Maroon","FF6600","Orange","808000","Olive","008000","Green","008080","Teal","0000FF","Blue","666699","Grayish blue","808080","Gray","FF0000","Red","FF9900","Amber","99CC00","Yellow green","339966","Sea green","33CCCC","Turquoise","3366FF","Royal blue","800080","Purple","999999","Medium gray","FF00FF","Magenta","FFCC00","Gold","FFFF00","Yellow","00FF00","Lime","00FFFF","Aqua","00CCFF","Sky blue","993366","Red violet","FFFFFF","White","FF99CC","Pink","FFCC99","Peach","FFFF99","Light yellow","CCFFCC","Pale green","CCFFFF","Pale cyan","99CCFF","Light sky blue","CC99FF","Plum"],t=0;t<n.length;t+=2)r.push({text:n[t+1],color:"#"+n[t]});return r}function r(){function t(e,t){var n="transparent"==e;return'<td class="mce-grid-cell'+(n?" mce-colorbtn-trans":"")+'"><div id="'+h+"-"+m++ +'" data-mce-color="'+(e?e:"")+'" role="option" tabIndex="-1" style="'+(e?"background-color: "+e:"")+'" title="'+tinymce.translate(t)+'">'+(n?"×":"")+"</div></td>"}var r,i,o,a,s,u,d,f=this,h=f._id,m=0;for(r=n(),r.push({text:tinymce.translate("No color"),color:"transparent"}),o='<table class="mce-grid mce-grid-border mce-colorbutton-grid" role="list" cellspacing="0"><tbody>',a=r.length-1,u=0;c>u;u++){for(o+="<tr>",s=0;l>s;s++)d=u*l+s,d>a?o+="<td></td>":(i=r[d],o+=t(i.color,i.text));o+="</tr>"}if(e.settings.color_picker_callback){for(o+='<tr><td colspan="'+l+'" class="mce-custom-color-btn"><div id="'+h+'-c" class="mce-widget mce-btn mce-btn-small mce-btn-flat" role="button" tabindex="-1" aria-labelledby="'+h+'-c" style="width: 100%"><button type="button" role="presentation" tabindex="-1">'+tinymce.translate("Custom...")+"</button></div></td></tr>",o+="<tr>",s=0;l>s;s++)o+=t("","Custom color");o+="</tr>"}return o+="</tbody></table>"}function i(t,n){e.undoManager.transact(function(){e.focus(),e.formatter.apply(t,{value:n}),e.nodeChanged()})}function o(t){e.undoManager.transact(function(){e.focus(),e.formatter.remove(t,{value:null},null,!0),e.nodeChanged()})}function a(n){function r(e){u.hidePanel(),u.color(e),i(u.settings.format,e)}function a(){u.hidePanel(),u.resetColor(),o(u.settings.format)}function s(e,t){e.style.background=t,e.setAttribute("data-mce-color",t)}var c,u=this.parent();tinymce.DOM.getParent(n.target,".mce-custom-color-btn")&&(u.hidePanel(),e.settings.color_picker_callback.call(e,function(e){var t,n,i,o=u.panel.getEl().getElementsByTagName("table")[0];for(t=tinymce.map(o.rows[o.rows.length-1].childNodes,function(e){return e.firstChild}),i=0;i<t.length&&(n=t[i],n.getAttribute("data-mce-color"));i++);if(i==l)for(i=0;l-1>i;i++)s(t[i],t[i+1].getAttribute("data-mce-color"));s(n,e),r(e)},t(u.settings.format))),c=n.target.getAttribute("data-mce-color"),c?(this.lastId&&document.getElementById(this.lastId).setAttribute("aria-selected",!1),n.target.setAttribute("aria-selected",!0),this.lastId=n.target.id,"transparent"==c?a():r(c)):null!==c&&u.hidePanel()}function s(){var e=this;e._color?i(e.settings.format,e._color):o(e.settings.format)}var l,c;c=e.settings.textcolor_rows||5,l=e.settings.textcolor_cols||8,e.addButton("forecolor",{type:"colorbutton",tooltip:"Text color",format:"forecolor",panel:{role:"application",ariaRemember:!0,html:r,onclick:a},onclick:s}),e.addButton("backcolor",{type:"colorbutton",tooltip:"Background color",format:"hilitecolor",panel:{role:"application",ariaRemember:!0,html:r,onclick:a},onclick:s})});
|
||||
@@ -583,7 +583,7 @@ tinymce.PluginManager.add( 'wpeditimage', function( editor ) {
|
||||
var captionField = {
|
||||
type: 'textbox',
|
||||
flex: 1,
|
||||
name: 'caption',
|
||||
name: 'wpcaption',
|
||||
minHeight: 60,
|
||||
multiline: true,
|
||||
scroll: true,
|
||||
@@ -609,7 +609,7 @@ tinymce.PluginManager.add( 'wpeditimage', function( editor ) {
|
||||
editor.on( 'wpImageFormSubmit', function( event ) {
|
||||
var data = event.imgData.data,
|
||||
imgNode = event.imgData.node,
|
||||
caption = event.imgData.caption,
|
||||
caption = event.imgData.wpcaption,
|
||||
captionId = '',
|
||||
captionAlign = '',
|
||||
captionWidth = '',
|
||||
@@ -792,7 +792,7 @@ tinymce.PluginManager.add( 'wpeditimage', function( editor ) {
|
||||
parent = dom.select( 'dd.wp-caption-dd', parent )[0];
|
||||
|
||||
if ( parent ) {
|
||||
data.caption = editor.serializer.serialize( parent )
|
||||
data.wpcaption = editor.serializer.serialize( parent )
|
||||
.replace( /<br[^>]*>/g, '$&\n' ).replace( /^<p>/, '' ).replace( /<\/p>$/, '' );
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1 +1 @@
|
||||
.mce-content-body .mce-reset{margin:0;padding:0;border:0;outline:0;vertical-align:top;background:0 0;text-decoration:none;color:#000;font-family:Arial;font-size:11px;text-shadow:none;float:none;position:static;width:auto;height:auto;white-space:nowrap;cursor:inherit;line-height:normal;font-weight:400;text-align:left;-webkit-tap-highlight-color:transparent;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box;direction:ltr;max-width:none}.mce-object{border:1px dotted #3A3A3A;background:#d5d5d5 url(img/object.gif) no-repeat center}.mce-pagebreak{cursor:default;display:block;border:0;width:100%;height:5px;border:1px dashed #666;margin-top:15px;page-break-before:always}@media print{.mce-pagebreak{border:0}}.mce-item-anchor{cursor:default;display:inline-block;-webkit-user-select:all;-webkit-user-modify:read-only;-moz-user-select:all;-moz-user-modify:read-only;user-select:all;user-modify:read-only;width:9px!important;height:9px!important;border:1px dotted #3A3A3A;background:#d5d5d5 url(img/anchor.gif) no-repeat center}.mce-nbsp,.mce-shy{background:#AAA}.mce-shy::after{content:'-'}hr{cursor:default}.mce-match-marker{background:#AAA;color:#fff}.mce-match-marker-selected{background:#39f;color:#fff}.mce-spellchecker-word{border-bottom:2px solid red;cursor:default}.mce-spellchecker-grammar{border-bottom:2px solid green;cursor:default}.mce-item-table,.mce-item-table td,.mce-item-table th,.mce-item-table caption{border:1px dashed #BBB}td.mce-item-selected,th.mce-item-selected{background-color:#39f!important}.mce-edit-focus{outline:1px dotted #333}
|
||||
.mce-content-body .mce-reset{margin:0;padding:0;border:0;outline:0;vertical-align:top;background:transparent;text-decoration:none;color:black;font-family:Arial;font-size:11px;text-shadow:none;float:none;position:static;width:auto;height:auto;white-space:nowrap;cursor:inherit;line-height:normal;font-weight:normal;text-align:left;-webkit-tap-highlight-color:transparent;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box;direction:ltr;max-width:none}.mce-object{border:1px dotted #3a3a3a;background:#d5d5d5 url(img/object.gif) no-repeat center}.mce-preview-object{display:inline-block;position:relative;margin:0 2px 0 2px;line-height:0;border:1px solid gray}.mce-preview-object .mce-shim{position:absolute;top:0;left:0;width:100%;height:100%;background:url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)}figure.align-left{float:left}figure.align-right{float:right}figure.image.align-center{display:table;margin-left:auto;margin-right:auto}figure.image{display:inline-block;border:1px solid gray;margin:0 2px 0 1px;background:#f5f2f0}figure.image img{margin:8px 8px 0 8px}figure.image figcaption{margin:6px 8px 6px 8px;text-align:center}.mce-preview-object[data-mce-selected] .mce-shim{display:none}.mce-pagebreak{cursor:default;display:block;border:0;width:100%;height:5px;border:1px dashed #666;margin-top:15px;page-break-before:always}@media print{.mce-pagebreak{border:0}}.mce-item-anchor{cursor:default;display:inline-block;-webkit-user-select:all;-webkit-user-modify:read-only;-moz-user-select:all;-moz-user-modify:read-only;user-select:all;user-modify:read-only;width:9px !important;height:9px !important;border:1px dotted #3a3a3a;background:#d5d5d5 url(img/anchor.gif) no-repeat center}.mce-nbsp,.mce-shy{background:#aaa}.mce-shy::after{content:'-'}hr{cursor:default}.mce-match-marker{background:#aaa;color:#fff}.mce-match-marker-selected{background:#39f;color:#fff}.mce-spellchecker-word{border-bottom:2px solid #f00;cursor:default}.mce-spellchecker-grammar{border-bottom:2px solid #008000;cursor:default}.mce-item-table,.mce-item-table td,.mce-item-table th,.mce-item-table caption{border:1px dashed #bbb}td.mce-item-selected,th.mce-item-selected{background-color:#39f !important}.mce-edit-focus{outline:1px dotted #333}.mce-content-body *[contentEditable=false] *[contentEditable=true]:focus{outline:2px solid #2d8ac7}.mce-content-body *[contentEditable=false] *[contentEditable=true]:hover{outline:2px solid #7acaff}.mce-content-body *[contentEditable=false][data-mce-selected]{outline:2px solid #2d8ac7}.mce-resize-bar-dragging{background-color:blue;opacity:.25;filter:alpha(opacity=25);zoom:1}
|
||||
@@ -1 +1 @@
|
||||
body{background-color:#FFF;color:#000;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:#DDD;scrollbar-face-color:#E0E0DD;scrollbar-highlight-color:#F0F0EE;scrollbar-shadow-color:#F0F0EE;scrollbar-track-color:#F5F5F5}td,th{font-family:Verdana,Arial,Helvetica,sans-serif;font-size:11px}.mce-content-body .mce-reset{margin:0;padding:0;border:0;outline:0;vertical-align:top;background:0 0;text-decoration:none;color:#000;font-family:Arial;font-size:11px;text-shadow:none;float:none;position:static;width:auto;height:auto;white-space:nowrap;cursor:inherit;line-height:normal;font-weight:400;text-align:left;-webkit-tap-highlight-color:transparent;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box;direction:ltr;max-width:none}.mce-object{border:1px dotted #3A3A3A;background:#d5d5d5 url(img/object.gif) no-repeat center}.mce-pagebreak{cursor:default;display:block;border:0;width:100%;height:5px;border:1px dashed #666;margin-top:15px;page-break-before:always}@media print{.mce-pagebreak{border:0}}.mce-item-anchor{cursor:default;display:inline-block;-webkit-user-select:all;-webkit-user-modify:read-only;-moz-user-select:all;-moz-user-modify:read-only;user-select:all;user-modify:read-only;width:9px!important;height:9px!important;border:1px dotted #3A3A3A;background:#d5d5d5 url(img/anchor.gif) no-repeat center}.mce-nbsp,.mce-shy{background:#AAA}.mce-shy::after{content:'-'}hr{cursor:default}.mce-match-marker{background:#AAA;color:#fff}.mce-match-marker-selected{background:#39f;color:#fff}.mce-spellchecker-word{border-bottom:2px solid red;cursor:default}.mce-spellchecker-grammar{border-bottom:2px solid green;cursor:default}.mce-item-table,.mce-item-table td,.mce-item-table th,.mce-item-table caption{border:1px dashed #BBB}td.mce-item-selected,th.mce-item-selected{background-color:#39f!important}.mce-edit-focus{outline:1px dotted #333}
|
||||
body{background-color:#fff;color:#000;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:#ddd;scrollbar-face-color:#e0e0dd;scrollbar-highlight-color:#f0f0ee;scrollbar-shadow-color:#f0f0ee;scrollbar-track-color:#f5f5f5}td,th{font-family:Verdana,Arial,Helvetica,sans-serif;font-size:11px}.mce-content-body .mce-reset{margin:0;padding:0;border:0;outline:0;vertical-align:top;background:transparent;text-decoration:none;color:black;font-family:Arial;font-size:11px;text-shadow:none;float:none;position:static;width:auto;height:auto;white-space:nowrap;cursor:inherit;line-height:normal;font-weight:normal;text-align:left;-webkit-tap-highlight-color:transparent;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box;direction:ltr;max-width:none}.mce-object{border:1px dotted #3a3a3a;background:#d5d5d5 url(img/object.gif) no-repeat center}.mce-preview-object{display:inline-block;position:relative;margin:0 2px 0 2px;line-height:0;border:1px solid gray}.mce-preview-object .mce-shim{position:absolute;top:0;left:0;width:100%;height:100%;background:url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)}figure.align-left{float:left}figure.align-right{float:right}figure.image.align-center{display:table;margin-left:auto;margin-right:auto}figure.image{display:inline-block;border:1px solid gray;margin:0 2px 0 1px;background:#f5f2f0}figure.image img{margin:8px 8px 0 8px}figure.image figcaption{margin:6px 8px 6px 8px;text-align:center}.mce-preview-object[data-mce-selected] .mce-shim{display:none}.mce-pagebreak{cursor:default;display:block;border:0;width:100%;height:5px;border:1px dashed #666;margin-top:15px;page-break-before:always}@media print{.mce-pagebreak{border:0}}.mce-item-anchor{cursor:default;display:inline-block;-webkit-user-select:all;-webkit-user-modify:read-only;-moz-user-select:all;-moz-user-modify:read-only;user-select:all;user-modify:read-only;width:9px !important;height:9px !important;border:1px dotted #3a3a3a;background:#d5d5d5 url(img/anchor.gif) no-repeat center}.mce-nbsp,.mce-shy{background:#aaa}.mce-shy::after{content:'-'}hr{cursor:default}.mce-match-marker{background:#aaa;color:#fff}.mce-match-marker-selected{background:#39f;color:#fff}.mce-spellchecker-word{border-bottom:2px solid #f00;cursor:default}.mce-spellchecker-grammar{border-bottom:2px solid #008000;cursor:default}.mce-item-table,.mce-item-table td,.mce-item-table th,.mce-item-table caption{border:1px dashed #bbb}td.mce-item-selected,th.mce-item-selected{background-color:#39f !important}.mce-edit-focus{outline:1px dotted #333}.mce-content-body *[contentEditable=false] *[contentEditable=true]:focus{outline:2px solid #2d8ac7}.mce-content-body *[contentEditable=false] *[contentEditable=true]:hover{outline:2px solid #7acaff}.mce-content-body *[contentEditable=false][data-mce-selected]{outline:2px solid #2d8ac7}.mce-resize-bar-dragging{background-color:blue;opacity:.25;filter:alpha(opacity=25);zoom:1}
|
||||
Binary file not shown.
File diff suppressed because it is too large
Load Diff
@@ -6,57 +6,58 @@
|
||||
<font id="tinymce-small" horiz-adv-x="1024">
|
||||
<font-face units-per-em="1024" ascent="960" descent="-64" />
|
||||
<missing-glyph horiz-adv-x="1024" />
|
||||
<glyph unicode=" " d="" horiz-adv-x="512" />
|
||||
<glyph unicode="" d="M960 80v591.938l-223.938 224.062h-592.062c-44.182 0-80-35.816-80-80v-736c0-44.184 35.818-80 80-80h736c44.184 0 80 35.816 80 80zM576 768h64v-192h-64v192zM704 128h-384v255.882c0.034 0.042 0.076 0.082 0.116 0.118h383.77c0.040-0.036 0.082-0.076 0.116-0.118l-0.002-255.882zM832 128h-64v256c0 35.2-28.8 64-64 64h-384c-35.2 0-64-28.8-64-64v-256h-64v640h64v-192c0-35.2 28.8-64 64-64h320c35.2 0 64 28.8 64 64v171.010l128-128.072v-490.938z" />
|
||||
<glyph unicode="" d="M850.746 717.254l-133.492 133.49c-24.888 24.892-74.054 45.256-109.254 45.256h-416c-35.2 0-64-28.8-64-64v-768c0-35.2 28.8-64 64-64h640c35.2 0 64 28.8 64 64v544c0 35.2-20.366 84.364-45.254 109.254zM805.49 672.002c6.792-6.796 13.792-19.162 18.894-32.002h-184.384v184.386c12.84-5.1 25.204-12.1 32-18.896l133.49-133.488zM831.884 64h-639.77c-0.040 0.034-0.082 0.076-0.114 0.116v767.77c0.034 0.040 0.076 0.082 0.114 0.114h383.886v-256h256v-511.884c-0.034-0.040-0.076-0.082-0.116-0.116z" />
|
||||
<glyph unicode="" d="M1024 367.542v160.916l-159.144 15.914c-8.186 30.042-20.088 58.548-35.21 84.98l104.596 127.838-113.052 113.050-127.836-104.596c-26.434 15.124-54.942 27.026-84.982 35.208l-15.914 159.148h-160.916l-15.914-159.146c-30.042-8.186-58.548-20.086-84.98-35.208l-127.838 104.594-113.050-113.050 104.596-127.836c-15.124-26.432-27.026-54.94-35.21-84.98l-159.146-15.916v-160.916l159.146-15.914c8.186-30.042 20.086-58.548 35.21-84.982l-104.596-127.836 113.048-113.048 127.838 104.596c26.432-15.124 54.94-27.028 84.98-35.21l15.916-159.148h160.916l15.914 159.144c30.042 8.186 58.548 20.088 84.982 35.21l127.836-104.596 113.048 113.048-104.596 127.836c15.124 26.434 27.028 54.942 35.21 84.98l159.148 15.92zM704 384l-128-128h-128l-128 128v128l128 128h128l128-128v-128z" />
|
||||
<glyph unicode="" d="M64 768h896v-128h-896zM64 384h896v-128h-896zM64 576h576v-128h-576zM64 192h576v-128h-576z" />
|
||||
<glyph unicode="" d="M64 768h896v-128h-896zM64 384h896v-128h-896zM256 576h512v-128h-512zM256 192h512v-128h-512z" />
|
||||
<glyph unicode="" d="M64 768h896v-128h-896zM64 384h896v-128h-896zM384 576h576v-128h-576zM384 192h576v-128h-576z" />
|
||||
<glyph unicode="" d="M64 768h896v-128h-896zM64 384h896v-128h-896zM64 576h896v-128h-896zM64 192h896v-128h-896z" />
|
||||
<glyph unicode="" d="M864.408 289.868c-46.47 46.47-106.938 68.004-161.082 62.806l-63.326 63.326 192 192c0 0 128 128 0 256l-320-320-320 320c-128-128 0-256 0-256l192-192-63.326-63.326c-54.144 5.198-114.61-16.338-161.080-62.806-74.98-74.98-85.112-186.418-22.626-248.9 62.482-62.482 173.92-52.354 248.9 22.626 46.47 46.468 68.002 106.938 62.806 161.080l63.326 63.326 63.328-63.328c-5.196-54.144 16.336-114.61 62.806-161.078 74.978-74.98 186.418-85.112 248.898-22.626 62.488 62.482 52.356 173.918-22.624 248.9zM353.124 201.422c-2.212-24.332-15.020-49.826-35.14-69.946-22.212-22.214-51.080-35.476-77.218-35.476-10.524 0-25.298 2.228-35.916 12.848-21.406 21.404-17.376 73.132 22.626 113.136 22.212 22.214 51.080 35.476 77.218 35.476 10.524 0 25.298-2.228 35.916-12.848 13.112-13.11 13.47-32.688 12.514-43.19zM512 352c-35.346 0-64 28.654-64 64s28.654 64 64 64 64-28.654 64-64-28.654-64-64-64zM819.152 108.848c-10.62-10.62-25.392-12.848-35.916-12.848-26.138 0-55.006 13.262-77.218 35.476-20.122 20.12-32.928 45.614-35.138 69.946-0.958 10.502-0.6 30.080 12.514 43.192 10.618 10.622 25.39 12.848 35.916 12.848 26.136 0 55.006-13.262 77.216-35.474 40.004-40.008 44.032-91.736 22.626-113.14z" />
|
||||
<glyph unicode="" d="M704 576v160c0 17.6-14.4 32-32 32h-160v64c0 35.2-28.8 64-64 64h-128c-35.204 0-64-28.8-64-64v-64h-160c-17.602 0-32-14.4-32-32v-512c0-17.6 14.398-32 32-32h224v-192h384l192 192v384h-192zM320 831.886c0.034 0.038 0.072 0.078 0.114 0.114h127.768c0.042-0.036 0.082-0.076 0.118-0.114v-63.886h-128v63.886zM192 640v64h384v-64h-384zM704 90.51v101.49h101.49l-101.49-101.49zM832 256h-192v-192h-256v448h448v-256z" />
|
||||
<glyph unicode="" d="M888 576h-56v256h64v64h-320v-64h64v-256h-256v256h64v64h-320v-64h64v-256h-56c-39.6 0-72-32.4-72-72v-432c0-39.6 32.4-72 72-72h240c39.6 0 72 32.4 72 72v312h128v-312c0-39.6 32.4-72 72-72h240c39.6 0 72 32.4 72 72v432c0 39.6-32.4 72-72 72zM348 64h-184c-19.8 0-36 14.4-36 32s16.2 32 36 32h184c19.8 0 36-14.4 36-32s-16.2-32-36-32zM544 448h-64c-17.6 0-32 14.4-32 32s14.4 32 32 32h64c17.6 0 32-14.4 32-32s-14.4-32-32-32zM860 64h-184c-19.8 0-36 14.4-36 32s16.2 32 36 32h184c19.8 0 36-14.4 36-32s-16.2-32-36-32z" />
|
||||
<glyph unicode="" d="M384 832h576v-128h-576zM384 512h576v-128h-576zM384 192h576v-128h-576zM128 768c0-35.346 28.654-64 64-64s64 28.654 64 64c0 35.346-28.654 64-64 64s-64-28.654-64-64zM128 448c0-35.346 28.654-64 64-64s64 28.654 64 64c0 35.346-28.654 64-64 64s-64-28.654-64-64zM128 128c0-35.346 28.654-64 64-64s64 28.654 64 64c0 35.346-28.654 64-64 64s-64-28.654-64-64z" />
|
||||
<glyph unicode="" d="M384 832h576v-128h-576zM384 512h576v-128h-576zM384 192h576v-128h-576zM320 430v146h-64v320h-128v-64h64v-256h-64v-64h128v-50l-128-60v-146h128v-64h-128v-64h128v-64h-128v-64h192v320h-128v50z" />
|
||||
<glyph unicode="" d="M64 768h896v-128h-896zM384 384h576v-128h-576zM384 576h576v-128h-576zM64 192h896v-128h-896zM64 576l224-160-224-160z" />
|
||||
<glyph unicode="" d="M64 768h896v-128h-896zM64 384h576v-128h-576zM64 576h576v-128h-576zM64 192h896v-128h-896zM960 576l-224-160 224-160z" />
|
||||
<glyph unicode="" d="M256.428 535.274c105.8 0 191.572-91.17 191.572-203.638 0-112.464-85.772-203.636-191.572-203.636-105.802 0-191.572 91.17-191.572 203.636l-0.856 29.092c0 224.93 171.54 407.272 383.144 407.272v-116.364c-73.1 0-141.826-30.26-193.516-85.204-9.954-10.578-19.034-21.834-27.224-33.656 9.784 1.64 19.806 2.498 30.024 2.498zM768.428 535.274c105.8 0 191.572-91.17 191.572-203.638 0-112.464-85.772-203.636-191.572-203.636-105.802 0-191.572 91.17-191.572 203.636l-0.856 29.092c0 224.93 171.54 407.272 383.144 407.272v-116.364c-73.1 0-141.826-30.26-193.516-85.204-9.956-10.578-19.036-21.834-27.224-33.656 9.784 1.64 19.806 2.498 30.024 2.498z" />
|
||||
<glyph unicode="" d="M704 0c59 199 134.906 455.266-256 446.096v-222.096l-336.002 336 336.002 336v-217.326c468.092 12.2 544-358.674 256-678.674z" />
|
||||
<glyph unicode="" d="M576 678.674v217.326l336.002-336-336.002-336v222.096c-390.906 9.17-315-247.096-256-446.096-288 320-212.092 690.874 256 678.674z" />
|
||||
<glyph unicode="" d="M927.274 729.784l-133.49 133.488c-21.104 21.104-49.232 32.728-79.198 32.728s-58.094-11.624-79.196-32.726l-165.492-165.49c-43.668-43.668-43.668-114.724 0-158.392l2.746-2.746 67.882 67.882-2.746 2.746c-6.132 6.132-6.132 16.494 0 22.626l165.492 165.492c4.010 4.008 8.808 4.608 11.312 4.608s7.302-0.598 11.312-4.61l133.49-133.488c6.132-6.134 6.132-16.498 0.002-22.628l-165.494-165.494c-4.008-4.008-8.806-4.608-11.31-4.608s-7.302 0.6-11.312 4.612l-2.746 2.746-67.88-67.884 2.742-2.742c21.106-21.108 49.23-32.728 79.2-32.728s58.094 11.624 79.196 32.726l165.494 165.492c43.662 43.666 43.662 114.72-0.004 158.39zM551.356 359.356l-67.882-67.882 2.746-2.746c4.008-4.008 4.61-8.806 4.61-11.31 0-2.506-0.598-7.302-4.606-11.314l-165.494-165.49c-4.010-4.010-8.81-4.61-11.314-4.61s-7.304 0.6-11.314 4.61l-133.492 133.486c-4.010 4.010-4.61 8.81-4.61 11.314s0.598 7.3 4.61 11.312l165.49 165.488c4.010 4.012 8.81 4.612 11.314 4.612s7.304-0.6 11.314-4.612l2.746-2.742 67.882 67.88-2.746 2.746c-21.104 21.104-49.23 32.726-79.196 32.726s-58.092-11.624-79.196-32.726l-165.488-165.486c-21.106-21.104-32.73-49.234-32.73-79.198s11.624-58.094 32.726-79.198l133.49-133.49c21.106-21.102 49.232-32.726 79.198-32.726s58.092 11.624 79.196 32.726l165.494 165.492c21.104 21.104 32.722 49.23 32.722 79.196s-11.624 58.094-32.726 79.196l-2.744 2.746zM352 250c-9.724 0-19.45 3.71-26.87 11.128-14.84 14.84-14.84 38.898 0 53.738l320 320c14.84 14.84 38.896 14.84 53.736 0 14.844-14.84 14.844-38.9 0-53.74l-320-320c-7.416-7.416-17.142-11.126-26.866-11.126z" />
|
||||
<glyph unicode="" d="M927.274 729.784l-133.49 133.488c-21.104 21.104-49.232 32.728-79.198 32.728s-58.094-11.624-79.196-32.726l-165.492-165.49c-43.668-43.668-43.668-114.724 0-158.392l2.746-2.746 67.882 67.882-2.746 2.746c-6.132 6.132-6.132 16.494 0 22.626l165.492 165.492c4.010 4.008 8.808 4.608 11.312 4.608s7.302-0.598 11.312-4.61l133.49-133.488c6.132-6.134 6.132-16.498 0.002-22.628l-165.494-165.494c-4.008-4.008-8.806-4.608-11.31-4.608s-7.302 0.6-11.312 4.612l-2.746 2.746-67.88-67.884 2.742-2.742c21.106-21.108 49.23-32.728 79.2-32.728s58.094 11.624 79.196 32.726l165.494 165.492c43.662 43.666 43.662 114.72-0.004 158.39zM551.356 359.356l-67.882-67.882 2.746-2.746c4.008-4.008 4.61-8.806 4.61-11.31 0-2.506-0.598-7.302-4.606-11.314l-165.494-165.49c-4.010-4.010-8.81-4.61-11.314-4.61s-7.304 0.6-11.314 4.61l-133.492 133.486c-4.010 4.010-4.61 8.81-4.61 11.314s0.598 7.3 4.61 11.312l165.49 165.488c4.010 4.012 8.81 4.612 11.314 4.612s7.304-0.6 11.314-4.612l2.746-2.742 67.882 67.88-2.746 2.746c-21.104 21.104-49.23 32.726-79.196 32.726s-58.092-11.624-79.196-32.726l-165.488-165.486c-21.106-21.104-32.73-49.234-32.73-79.198s11.624-58.094 32.726-79.198l133.49-133.49c21.106-21.102 49.232-32.726 79.198-32.726s58.092 11.624 79.196 32.726l165.494 165.492c21.104 21.104 32.722 49.23 32.722 79.196s-11.624 58.094-32.726 79.196l-2.744 2.746zM800 122c-9.724 0-19.45 3.708-26.87 11.13l-128 127.998c-14.844 14.84-14.844 38.898 0 53.738 14.84 14.844 38.896 14.844 53.736 0l128-128c14.844-14.84 14.844-38.896 0-53.736-7.416-7.422-17.142-11.13-26.866-11.13zM608 0c-17.674 0-32 14.326-32 32v128c0 17.674 14.326 32 32 32s32-14.326 32-32v-128c0-17.674-14.326-32-32-32zM928 320h-128c-17.674 0-32 14.326-32 32s14.326 32 32 32h128c17.674 0 32-14.326 32-32s-14.326-32-32-32zM224 774c9.724 0 19.45-3.708 26.87-11.13l128-128c14.842-14.84 14.842-38.898 0-53.738-14.84-14.844-38.898-14.844-53.738 0l-128 128c-14.842 14.84-14.842 38.898 0 53.738 7.418 7.422 17.144 11.13 26.868 11.13zM416 896c17.674 0 32-14.326 32-32v-128c0-17.674-14.326-32-32-32s-32 14.326-32 32v128c0 17.674 14.326 32 32 32zM96 576h128c17.674 0 32-14.326 32-32s-14.326-32-32-32h-128c-17.674 0-32 14.326-32 32s14.326 32 32 32z" />
|
||||
<glyph unicode="" d="M256 896v-896l256 256 256-256v896h-512zM704 170.51l-192 192-192-192v661.49h384v-661.49z" />
|
||||
<glyph unicode="" d="M896 832h-768c-35.2 0-64-28.8-64-64v-640c0-35.2 28.8-64 64-64h768c35.2 0 64 28.8 64 64v640c0 35.2-28.8 64-64 64zM896 128.116c-0.012-0.014-0.030-0.028-0.042-0.042l-191.958 319.926-160-128-224 288-191.968-479.916c-0.010 0.010-0.022 0.022-0.032 0.032v639.77c0.034 0.040 0.076 0.082 0.114 0.114h767.77c0.040-0.034 0.082-0.076 0.116-0.116v-639.768zM640 608c0-53.019 42.981-96 96-96s96 42.981 96 96c0 53.019-42.981 96-96 96s-96-42.981-96-96z" />
|
||||
<glyph unicode="" d="M896 832h-768c-35.2 0-64-28.8-64-64v-640c0-35.2 28.8-64 64-64h768c35.2 0 64 28.8 64 64v640c0 35.2-28.8 64-64 64zM256 128h-128v128h128v-128zM256 384h-128v128h128v-128zM256 640h-128v128h128v-128zM704 128h-384v640h384v-640zM896 128h-128v128h128v-128zM896 384h-128v128h128v-128zM896 640h-128v128h128v-128zM384 640v-384l288 192z" />
|
||||
<glyph unicode="" d="M448 256h128v-128h-128v128zM704 704c35.346 0 64-28.654 64-64v-166l-228-154h-92v64l192 128v64h-320v128h384zM512 896c-119.666 0-232.166-46.6-316.784-131.216-84.614-84.618-131.216-197.118-131.216-316.784 0-119.664 46.602-232.168 131.216-316.784 84.618-84.616 197.118-131.216 316.784-131.216 119.664 0 232.168 46.6 316.784 131.216s131.216 197.12 131.216 316.784c0 119.666-46.6 232.166-131.216 316.784-84.616 84.616-197.12 131.216-316.784 131.216z" />
|
||||
<glyph unicode="" d="M416 256l-192 192 192 192-64 64-256-256 256-256zM672 704l-64-64 192-192-192-192 64-64 256 256z" />
|
||||
<glyph unicode="" d="M77.798 655.376l81.414-50.882c50.802 81.114 128.788 143.454 221.208 174.246l-30.366 91.094c-113.748-37.898-209.728-114.626-272.256-214.458zM673.946 869.834l-30.366-91.094c92.422-30.792 170.404-93.132 221.208-174.248l81.412 50.882c-62.526 99.834-158.506 176.562-272.254 214.46zM607.974 255.992c-4.808 0-9.692 1.090-14.286 3.386l-145.688 72.844v211.778c0 17.672 14.328 32 32 32s32-14.328 32-32v-172.222l110.31-55.156c15.806-7.902 22.214-27.124 14.31-42.932-5.604-11.214-16.908-17.696-28.646-17.698zM512 768c-212.078 0-384-171.922-384-384s171.922-384 384-384c212.078 0 384 171.922 384 384s-171.922 384-384 384zM512 96c-159.058 0-288 128.942-288 288s128.942 288 288 288c159.058 0 288-128.942 288-288s-128.942-288-288-288z" />
|
||||
<glyph unicode="" d="M64 504.254c45.318 49.92 97.162 92.36 153.272 125.124 90.332 52.744 192.246 80.622 294.728 80.622 102.48 0 204.396-27.878 294.726-80.624 56.112-32.764 107.956-75.204 153.274-125.124v117.432c-33.010 28.118-68.124 53.14-104.868 74.594-105.006 61.314-223.658 93.722-343.132 93.722s-238.128-32.408-343.134-93.72c-36.742-21.454-71.856-46.478-104.866-74.596v-117.43zM512 640c-183.196 0-345.838-100.556-448-256 102.162-155.448 264.804-256 448-256s345.838 100.552 448 256c-102.162 155.444-264.804 256-448 256zM512 448c0-35.346-28.654-64-64-64s-64 28.654-64 64c0 35.348 28.654 64 64 64s64-28.652 64-64zM728.066 263.338c-67.434-39.374-140.128-59.338-216.066-59.338s-148.632 19.964-216.066 59.338c-51.554 30.104-98.616 71.31-138.114 120.662 39.498 49.35 86.56 90.558 138.116 120.66 13.276 7.752 26.758 14.74 40.426 20.982-10.512-23.742-16.362-50.008-16.362-77.642 0-106.040 85.962-192 192-192 106.040 0 192 85.96 192 192 0 27.634-5.85 53.9-16.36 77.642 13.668-6.244 27.15-13.23 40.426-20.982 51.554-30.102 98.616-71.31 138.116-120.66-39.498-49.352-86.56-90.558-138.116-120.662z" />
|
||||
<glyph unicode="" d="M651.168 676.166c-24.612 81.962-28.876 91.834-107.168 91.834h-64c-79.618 0-82.664-10.152-108.418-96 0-0.002 0-0.002-0.002-0.004l-143.998-479.996h113.636l57.6 192h226.366l57.6-192h113.63l-145.246 484.166zM437.218 512l38.4 136c10.086 33.618 36.38 30 36.38 30s26.294 3.618 36.38-30h0.004l38.4-136h-149.564z" />
|
||||
<glyph unicode="" d="M64 768v-704h896v704h-896zM384 320v128h256v-128h-256zM640 256v-128h-256v128h256zM640 640v-128h-256v128h256zM320 640v-128h-192v128h192zM128 448h192v-128h-192v128zM704 448h192v-128h-192v128zM704 512v128h192v-128h-192zM128 256h192v-128h-192v128zM704 128v128h192v-128h-192z" />
|
||||
<glyph unicode="" d="M64 512h896v-128h-896z" />
|
||||
<glyph unicode="" d="M64 192h512v-128h-512v128zM768 768h-220.558l-183.766-512h-132.288l183.762 512h-223.15v128h576v-128zM929.774 64l-129.774 129.774-129.774-129.774-62.226 62.226 129.774 129.774-129.774 129.774 62.226 62.226 129.774-129.774 129.774 129.774 62.226-62.226-129.774-129.774 129.774-129.774-62.226-62.226z" />
|
||||
<glyph unicode="" d="M768 50v-50h128v-64h-192v146l128 60v50h-128v64h192v-146zM676 704h-136l-188-188-188 188h-136l256-256-256-256h136l188 188 188-188h136l-256 256z" />
|
||||
<glyph unicode="" d="M768 754v-50h128v-64h-192v146l128 60v50h-128v64h192v-146zM676 704h-136l-188-188-188 188h-136l256-256-256-256h136l188 188 188-188h136l-256 256z" />
|
||||
<glyph unicode="" d="M704 128v37.004c151.348 61.628 256 193.82 256 346.996 0 212.078-200.576 384-448 384s-448-171.922-448-384c0-153.176 104.654-285.368 256-346.996v-37.004h-192l-64 96v-224h320v222.812c-100.9 51.362-170.666 161.54-170.666 289.188 0 176.732 133.718 320 298.666 320s298.666-143.268 298.666-320c0-127.648-69.766-237.826-170.666-289.188v-222.812h320v224l-64-96h-192z" />
|
||||
<glyph unicode="" d="M512 820c99.366 0 192.782-38.694 263.042-108.956s108.958-163.678 108.958-263.044-38.696-192.782-108.958-263.042-163.676-108.958-263.042-108.958-192.782 38.696-263.044 108.958-108.956 163.676-108.956 263.042 38.694 192.782 108.956 263.044 163.678 108.956 263.044 108.956zM512 896c-247.424 0-448-200.576-448-448s200.576-448 448-448 448 200.576 448 448-200.576 448-448 448v0zM320 576c0-35.346 28.654-64 64-64s64 28.654 64 64c0 35.346-28.654 64-64 64s-64-28.654-64-64zM576 576c0-35.346 28.654-64 64-64s64 28.654 64 64c0 35.346-28.654 64-64 64s-64-28.654-64-64zM512 304c-101.84 0-192.56 36.874-251.166 94.328 23.126-117.608 126.778-206.328 251.166-206.328s228.040 88.72 251.168 206.328c-58.608-57.454-149.328-94.328-251.168-94.328z" />
|
||||
<glyph unicode="" d="M256 832h512v-128h-512v128zM896 640h-768c-35.2 0-64-28.8-64-64v-256c0-35.2 28.796-64 64-64h128v-192h512v192h128c35.2 0 64 28.8 64 64v256c0 35.2-28.8 64-64 64zM704 128h-384v256h384v-256zM910.4 544c0-25.626-20.774-46.4-46.398-46.4s-46.402 20.774-46.402 46.4 20.778 46.4 46.402 46.4c25.626 0 46.398-20.774 46.398-46.4z" />
|
||||
<glyph unicode="" d="M480 576l-192 192 128 128h-352v-352l128 128 192-192zM640 480l192 192 128-128v352h-352l128-128-192-192zM544 320l192-192-128-128h352v352l-128-128-192 192zM384 416l-192-192-128 128v-352h352l-128 128 192 192z" />
|
||||
<glyph unicode="" d="M960 832v64h-192c-35.202 0-64-28.8-64-64v-320c0-15.856 5.858-30.402 15.496-41.614l-303.496-260.386-142 148-82-70 224-288 416 448h128v64h-192v320h192zM256 448h64v384c0 35.2-28.8 64-64 64h-128c-35.2 0-64-28.8-64-64v-384h64v192h128v-192zM128 704v128h128v-128h-128zM640 512v96c0 35.2-8.8 64-44 64 35.2 0 44 28.8 44 64v96c0 35.2-28.8 64-64 64h-192v-448h192c35.2 0 64 28.8 64 64zM448 832h128v-128h-128v128zM448 640h128v-128h-128v128z" />
|
||||
<glyph unicode="" d="M448 448h-128v128h128v128h128v-128h128v-128h-128v-128h-128v128zM960 384v-320h-896v320h128v-192h640v192h128z" />
|
||||
<glyph unicode="" d="M512 576h128v-64h-128zM512 192h128v-64h-128zM576 384h128v-64h-128zM768 384v-192h-64v-64h128v256zM384 384h128v-64h-128zM320 192h128v-64h-128zM320 576h128v-64h-128zM192 768v-256h64v192h64v64zM704 512h128v256h-64v-192h-64zM64 896v-896h896v896h-896zM896 64h-768v768h768v-768zM192 384v-256h64v192h64v64zM576 768h128v-64h-128zM384 768h128v-64h-128z" />
|
||||
<glyph unicode="" d="M816 896l16-384h-640l16 384h32l16-320h512l16 320h32zM208 0l-16 320h640l-16-320h-32l-16 256h-512l-16-256h-32zM64 448h128v-64h-128zM256 448h128v-64h-128zM448 448h128v-64h-128zM640 448h128v-64h-128zM832 448h128v-64h-128z" />
|
||||
<glyph unicode="" d="M576 896c247.424 0 448-200.576 448-448s-200.576-448-448-448v96c94.024 0 182.418 36.614 248.902 103.098s103.098 154.878 103.098 248.902c0 94.022-36.614 182.418-103.098 248.902s-154.878 103.098-248.902 103.098c-94.022 0-182.418-36.614-248.902-103.098-51.14-51.138-84.582-115.246-97.306-184.902h186.208l-224-256-224 256h164.57c31.060 217.102 217.738 384 443.43 384zM768 512v-128h-256v320h128v-192z" />
|
||||
<glyph unicode="" d="M625.442 465.818c48.074 38.15 78.558 94.856 78.558 158.182 0 114.876-100.29 208-224 208h-224v-768h288c123.712 0 224 93.124 224 208 0 88.196-59.118 163.562-142.558 193.818zM384 656c0 26.51 21.49 48 48 48h67.204c42.414 0 76.796-42.98 76.796-96s-34.382-96-76.796-96h-115.204v144zM547.2 192h-115.2c-26.51 0-48 21.49-48 48v144h163.2c42.418 0 76.8-42.98 76.8-96s-34.382-96-76.8-96z" />
|
||||
<glyph unicode="" d="M832 832v-64h-144l-256-640h144v-64h-448v64h144l256 640h-144v64h448z" />
|
||||
<glyph unicode="" d="M192 128h576v-64h-576v64zM640 832v-384c0-31.312-14.7-61.624-41.39-85.352-30.942-27.502-73.068-42.648-118.61-42.648-45.544 0-87.668 15.146-118.608 42.648-26.692 23.728-41.392 54.040-41.392 85.352v384h-128v-384c0-141.382 128.942-256 288-256s288 114.618 288 256v384h-128z" />
|
||||
<glyph unicode="" d="M960 448h-265.876c-50.078 35.42-114.43 54.86-182.124 54.86-89.206 0-164.572 50.242-164.572 109.712s75.366 109.714 164.572 109.714c75.058 0 140.308-35.576 159.12-82.286h113.016c-7.93 50.644-37.58 97.968-84.058 132.826-50.88 38.16-117.676 59.174-188.078 59.174-70.404 0-137.196-21.014-188.074-59.174-54.788-41.090-86.212-99.502-86.212-160.254s31.424-119.164 86.212-160.254c1.956-1.466 3.942-2.898 5.946-4.316h-265.872v-64h512.532c58.208-17.106 100.042-56.27 100.042-100.572 0-59.468-75.368-109.71-164.572-109.71-75.060 0-140.308 35.574-159.118 82.286h-113.016c7.93-50.64 37.582-97.968 84.060-132.826 50.876-38.164 117.668-59.18 188.072-59.18 70.402 0 137.198 21.016 188.074 59.174 54.79 41.090 86.208 99.502 86.208 160.254 0 35.298-10.654 69.792-30.294 100.572h204.012v64z" />
|
||||
<glyph unicode="" d="M384 832c-123.712 0-224-100.288-224-224s100.288-224 224-224v-320h128v640h64v-640h128v640h128v128h-448z" />
|
||||
<glyph unicode="" d="M448 832c-123.712 0-224-100.288-224-224s100.288-224 224-224v-320h128v640h64v-640h128v640h128v128h-448zM64 64l224 192-224 192z" />
|
||||
<glyph unicode="" d="M320 832c-123.712 0-224-100.288-224-224s100.288-224 224-224v-320h128v640h64v-640h128v640h128v128h-448zM960 448l-224-192 224-192z" />
|
||||
<glyph unicode="" d="M832 640h-192v64l-192 192h-384v-704h384v-192h576v448l-192 192zM832 549.49l101.49-101.49h-101.49v101.49zM448 805.49l101.49-101.49h-101.49v101.49zM128 832h256v-192h192v-384h-448v576zM960 64h-448v128h128v384h128v-192h192v-320z" />
|
||||
<glyph unicode="" d="M768 704h64v-64h-64zM640 576h64v-64h-64zM640 448h64v-64h-64zM640 320h64v-64h-64zM512 448h64v-64h-64zM512 320h64v-64h-64zM384 320h64v-64h-64zM768 576h64v-64h-64zM768 448h64v-64h-64zM768 320h64v-64h-64zM768 192h64v-64h-64zM640 192h64v-64h-64zM512 192h64v-64h-64zM384 192h64v-64h-64zM256 192h64v-64h-64z" />
|
||||
<glyph unicode="" d="M928 832h-416l-32 64h-352l-64-128h896zM840.34 256h87.66l32 448h-896l64-640h356.080c-104.882 37.776-180.080 138.266-180.080 256 0 149.982 122.018 272 272 272 149.98 0 272-122.018 272-272 0-21.678-2.622-43.15-7.66-64zM874.996 110.25l-134.496 110.692c17.454 28.922 27.5 62.814 27.5 99.058 0 106.040-85.96 192-192 192s-192-85.96-192-192 85.96-192 192-192c36.244 0 70.138 10.046 99.058 27.5l110.692-134.496c22.962-26.678 62.118-28.14 87.006-3.252l5.492 5.492c24.888 24.888 23.426 64.044-3.252 87.006zM576 196c-68.484 0-124 55.516-124 124s55.516 124 124 124 124-55.516 124-124-55.516-124-124-124z" />
|
||||
<glyph unicode="" d="M704 576v160c0 17.6-14.4 32-32 32h-160v64c0 35.2-28.8 64-64 64h-128c-35.204 0-64-28.8-64-64v-64h-160c-17.602 0-32-14.4-32-32v-512c0-17.6 14.398-32 32-32h224v-192h576v576h-192zM320 831.886c0.034 0.038 0.072 0.078 0.114 0.114h127.768c0.042-0.036 0.082-0.076 0.118-0.114v-63.886h-128v63.886zM192 640v64h384v-64h-384zM832 64h-448v448h448v-448zM448 448v-128h32l32 64h64v-192h-48v-64h160v64h-48v192h64l32-64h32v128z" />
|
||||
<glyph unicode=" " horiz-adv-x="512" d="" />
|
||||
<glyph unicode="" glyph-name="save" d="M960 80v591.938l-223.938 224.062h-592.062c-44.182 0-80-35.816-80-80v-736c0-44.184 35.818-80 80-80h736c44.184 0 80 35.816 80 80zM576 768h64v-192h-64v192zM704 128h-384v255.882c0.034 0.042 0.076 0.082 0.116 0.118h383.77c0.040-0.036 0.082-0.076 0.116-0.118l-0.002-255.882zM832 128h-64v256c0 35.2-28.8 64-64 64h-384c-35.2 0-64-28.8-64-64v-256h-64v640h64v-192c0-35.2 28.8-64 64-64h320c35.2 0 64 28.8 64 64v171.010l128-128.072v-490.938z" />
|
||||
<glyph unicode="" glyph-name="newdocument" d="M850.746 717.254l-133.492 133.49c-24.888 24.892-74.054 45.256-109.254 45.256h-416c-35.2 0-64-28.8-64-64v-768c0-35.2 28.8-64 64-64h640c35.2 0 64 28.8 64 64v544c0 35.2-20.366 84.364-45.254 109.254zM805.49 672.002c6.792-6.796 13.792-19.162 18.894-32.002h-184.384v184.386c12.84-5.1 25.204-12.1 32-18.896l133.49-133.488zM831.884 64h-639.77c-0.040 0.034-0.082 0.076-0.114 0.116v767.77c0.034 0.040 0.076 0.082 0.114 0.114h383.886v-256h256v-511.884c-0.034-0.040-0.076-0.082-0.116-0.116z" />
|
||||
<glyph unicode="" glyph-name="fullpage" d="M1024 367.542v160.916l-159.144 15.914c-8.186 30.042-20.088 58.548-35.21 84.98l104.596 127.838-113.052 113.050-127.836-104.596c-26.434 15.124-54.942 27.026-84.982 35.208l-15.914 159.148h-160.916l-15.914-159.146c-30.042-8.186-58.548-20.086-84.98-35.208l-127.838 104.594-113.050-113.050 104.596-127.836c-15.124-26.432-27.026-54.94-35.21-84.98l-159.146-15.916v-160.916l159.146-15.914c8.186-30.042 20.086-58.548 35.21-84.982l-104.596-127.836 113.048-113.048 127.838 104.596c26.432-15.124 54.94-27.028 84.98-35.21l15.916-159.148h160.916l15.914 159.144c30.042 8.186 58.548 20.088 84.982 35.21l127.836-104.596 113.048 113.048-104.596 127.836c15.124 26.434 27.028 54.942 35.21 84.98l159.148 15.92zM704 384l-128-128h-128l-128 128v128l128 128h128l128-128v-128z" />
|
||||
<glyph unicode="" glyph-name="alignleft" d="M64 768h896v-128h-896zM64 384h896v-128h-896zM64 576h576v-128h-576zM64 192h576v-128h-576z" />
|
||||
<glyph unicode="" glyph-name="aligncenter" d="M64 768h896v-128h-896zM64 384h896v-128h-896zM256 576h512v-128h-512zM256 192h512v-128h-512z" />
|
||||
<glyph unicode="" glyph-name="alignright" d="M64 768h896v-128h-896zM64 384h896v-128h-896zM384 576h576v-128h-576zM384 192h576v-128h-576z" />
|
||||
<glyph unicode="" glyph-name="alignjustify" d="M64 768h896v-128h-896zM64 384h896v-128h-896zM64 576h896v-128h-896zM64 192h896v-128h-896z" />
|
||||
<glyph unicode="" glyph-name="cut" d="M864.408 289.868c-46.47 46.47-106.938 68.004-161.082 62.806l-63.326 63.326 192 192c0 0 128 128 0 256l-320-320-320 320c-128-128 0-256 0-256l192-192-63.326-63.326c-54.144 5.198-114.61-16.338-161.080-62.806-74.98-74.98-85.112-186.418-22.626-248.9 62.482-62.482 173.92-52.354 248.9 22.626 46.47 46.468 68.002 106.938 62.806 161.080l63.326 63.326 63.328-63.328c-5.196-54.144 16.336-114.61 62.806-161.078 74.978-74.98 186.418-85.112 248.898-22.626 62.488 62.482 52.356 173.918-22.624 248.9zM353.124 201.422c-2.212-24.332-15.020-49.826-35.14-69.946-22.212-22.214-51.080-35.476-77.218-35.476-10.524 0-25.298 2.228-35.916 12.848-21.406 21.404-17.376 73.132 22.626 113.136 22.212 22.214 51.080 35.476 77.218 35.476 10.524 0 25.298-2.228 35.916-12.848 13.112-13.11 13.47-32.688 12.514-43.19zM512 352c-35.346 0-64 28.654-64 64s28.654 64 64 64 64-28.654 64-64-28.654-64-64-64zM819.152 108.848c-10.62-10.62-25.392-12.848-35.916-12.848-26.138 0-55.006 13.262-77.218 35.476-20.122 20.12-32.928 45.614-35.138 69.946-0.958 10.502-0.6 30.080 12.514 43.192 10.618 10.622 25.39 12.848 35.916 12.848 26.136 0 55.006-13.262 77.216-35.474 40.004-40.008 44.032-91.736 22.626-113.14z" />
|
||||
<glyph unicode="" glyph-name="paste" d="M704 576v160c0 17.6-14.4 32-32 32h-160v64c0 35.2-28.8 64-64 64h-128c-35.204 0-64-28.8-64-64v-64h-160c-17.602 0-32-14.4-32-32v-512c0-17.6 14.398-32 32-32h224v-192h384l192 192v384h-192zM320 831.886c0.034 0.038 0.072 0.078 0.114 0.114h127.768c0.042-0.036 0.082-0.076 0.118-0.114v-63.886h-128v63.886zM192 640v64h384v-64h-384zM704 90.51v101.49h101.49l-101.49-101.49zM832 256h-192v-192h-256v448h448v-256z" />
|
||||
<glyph unicode="" glyph-name="searchreplace" d="M888 576h-56v256h64v64h-320v-64h64v-256h-256v256h64v64h-320v-64h64v-256h-56c-39.6 0-72-32.4-72-72v-432c0-39.6 32.4-72 72-72h240c39.6 0 72 32.4 72 72v312h128v-312c0-39.6 32.4-72 72-72h240c39.6 0 72 32.4 72 72v432c0 39.6-32.4 72-72 72zM348 64h-184c-19.8 0-36 14.4-36 32s16.2 32 36 32h184c19.8 0 36-14.4 36-32s-16.2-32-36-32zM544 448h-64c-17.6 0-32 14.4-32 32s14.4 32 32 32h64c17.6 0 32-14.4 32-32s-14.4-32-32-32zM860 64h-184c-19.8 0-36 14.4-36 32s16.2 32 36 32h184c19.8 0 36-14.4 36-32s-16.2-32-36-32z" />
|
||||
<glyph unicode="" glyph-name="bullist" d="M384 832h576v-128h-576zM384 512h576v-128h-576zM384 192h576v-128h-576zM128 768c0-35.346 28.654-64 64-64s64 28.654 64 64c0 35.346-28.654 64-64 64s-64-28.654-64-64zM128 448c0-35.346 28.654-64 64-64s64 28.654 64 64c0 35.346-28.654 64-64 64s-64-28.654-64-64zM128 128c0-35.346 28.654-64 64-64s64 28.654 64 64c0 35.346-28.654 64-64 64s-64-28.654-64-64z" />
|
||||
<glyph unicode="" glyph-name="numlist" d="M384 832h576v-128h-576zM384 512h576v-128h-576zM384 192h576v-128h-576zM320 430v146h-64v320h-128v-64h64v-256h-64v-64h128v-50l-128-60v-146h128v-64h-128v-64h128v-64h-128v-64h192v320h-128v50z" />
|
||||
<glyph unicode="" glyph-name="indent" d="M64 768h896v-128h-896zM384 384h576v-128h-576zM384 576h576v-128h-576zM64 192h896v-128h-896zM64 576l224-160-224-160z" />
|
||||
<glyph unicode="" glyph-name="outdent" d="M64 768h896v-128h-896zM64 384h576v-128h-576zM64 576h576v-128h-576zM64 192h896v-128h-896zM960 576l-224-160 224-160z" />
|
||||
<glyph unicode="" glyph-name="blockquote" d="M256.428 535.274c105.8 0 191.572-91.17 191.572-203.638 0-112.464-85.772-203.636-191.572-203.636-105.802 0-191.572 91.17-191.572 203.636l-0.856 29.092c0 224.93 171.54 407.272 383.144 407.272v-116.364c-73.1 0-141.826-30.26-193.516-85.204-9.954-10.578-19.034-21.834-27.224-33.656 9.784 1.64 19.806 2.498 30.024 2.498zM768.428 535.274c105.8 0 191.572-91.17 191.572-203.638 0-112.464-85.772-203.636-191.572-203.636-105.802 0-191.572 91.17-191.572 203.636l-0.856 29.092c0 224.93 171.54 407.272 383.144 407.272v-116.364c-73.1 0-141.826-30.26-193.516-85.204-9.956-10.578-19.036-21.834-27.224-33.656 9.784 1.64 19.806 2.498 30.024 2.498z" />
|
||||
<glyph unicode="" glyph-name="undo" d="M704 0c59 199 134.906 455.266-256 446.096v-222.096l-336.002 336 336.002 336v-217.326c468.092 12.2 544-358.674 256-678.674z" />
|
||||
<glyph unicode="" glyph-name="redo" d="M576 678.674v217.326l336.002-336-336.002-336v222.096c-390.906 9.17-315-247.096-256-446.096-288 320-212.092 690.874 256 678.674z" />
|
||||
<glyph unicode="" glyph-name="unlink" d="M927.274 729.784l-133.49 133.488c-21.104 21.104-49.232 32.728-79.198 32.728s-58.094-11.624-79.196-32.726l-165.492-165.49c-43.668-43.668-43.668-114.724 0-158.392l2.746-2.746 67.882 67.882-2.746 2.746c-6.132 6.132-6.132 16.494 0 22.626l165.492 165.492c4.010 4.008 8.808 4.608 11.312 4.608s7.302-0.598 11.312-4.61l133.49-133.488c6.132-6.134 6.132-16.498 0.002-22.628l-165.494-165.494c-4.008-4.008-8.806-4.608-11.31-4.608s-7.302 0.6-11.312 4.612l-2.746 2.746-67.88-67.884 2.742-2.742c21.106-21.108 49.23-32.728 79.2-32.728s58.094 11.624 79.196 32.726l165.494 165.492c43.662 43.666 43.662 114.72-0.004 158.39zM551.356 359.356l-67.882-67.882 2.746-2.746c4.008-4.008 4.61-8.806 4.61-11.31 0-2.506-0.598-7.302-4.606-11.314l-165.494-165.49c-4.010-4.010-8.81-4.61-11.314-4.61s-7.304 0.6-11.314 4.61l-133.492 133.486c-4.010 4.010-4.61 8.81-4.61 11.314s0.598 7.3 4.61 11.312l165.49 165.488c4.010 4.012 8.81 4.612 11.314 4.612s7.304-0.6 11.314-4.612l2.746-2.742 67.882 67.88-2.746 2.746c-21.104 21.104-49.23 32.726-79.196 32.726s-58.092-11.624-79.196-32.726l-165.488-165.486c-21.106-21.104-32.73-49.234-32.73-79.198s11.624-58.094 32.726-79.198l133.49-133.49c21.106-21.102 49.232-32.726 79.198-32.726s58.092 11.624 79.196 32.726l165.494 165.492c21.104 21.104 32.722 49.23 32.722 79.196s-11.624 58.094-32.726 79.196l-2.744 2.746zM352 250c-9.724 0-19.45 3.71-26.87 11.128-14.84 14.84-14.84 38.898 0 53.738l320 320c14.84 14.84 38.896 14.84 53.736 0 14.844-14.84 14.844-38.9 0-53.74l-320-320c-7.416-7.416-17.142-11.126-26.866-11.126z" />
|
||||
<glyph unicode="" glyph-name="link" d="M927.274 729.784l-133.49 133.488c-21.104 21.104-49.232 32.728-79.198 32.728s-58.094-11.624-79.196-32.726l-165.492-165.49c-43.668-43.668-43.668-114.724 0-158.392l2.746-2.746 67.882 67.882-2.746 2.746c-6.132 6.132-6.132 16.494 0 22.626l165.492 165.492c4.010 4.008 8.808 4.608 11.312 4.608s7.302-0.598 11.312-4.61l133.49-133.488c6.132-6.134 6.132-16.498 0.002-22.628l-165.494-165.494c-4.008-4.008-8.806-4.608-11.31-4.608s-7.302 0.6-11.312 4.612l-2.746 2.746-67.88-67.884 2.742-2.742c21.106-21.108 49.23-32.728 79.2-32.728s58.094 11.624 79.196 32.726l165.494 165.492c43.662 43.666 43.662 114.72-0.004 158.39zM551.356 359.356l-67.882-67.882 2.746-2.746c4.008-4.008 4.61-8.806 4.61-11.31 0-2.506-0.598-7.302-4.606-11.314l-165.494-165.49c-4.010-4.010-8.81-4.61-11.314-4.61s-7.304 0.6-11.314 4.61l-133.492 133.486c-4.010 4.010-4.61 8.81-4.61 11.314s0.598 7.3 4.61 11.312l165.49 165.488c4.010 4.012 8.81 4.612 11.314 4.612s7.304-0.6 11.314-4.612l2.746-2.742 67.882 67.88-2.746 2.746c-21.104 21.104-49.23 32.726-79.196 32.726s-58.092-11.624-79.196-32.726l-165.488-165.486c-21.106-21.104-32.73-49.234-32.73-79.198s11.624-58.094 32.726-79.198l133.49-133.49c21.106-21.102 49.232-32.726 79.198-32.726s58.092 11.624 79.196 32.726l165.494 165.492c21.104 21.104 32.722 49.23 32.722 79.196s-11.624 58.094-32.726 79.196l-2.744 2.746zM800 122c-9.724 0-19.45 3.708-26.87 11.13l-128 127.998c-14.844 14.84-14.844 38.898 0 53.738 14.84 14.844 38.896 14.844 53.736 0l128-128c14.844-14.84 14.844-38.896 0-53.736-7.416-7.422-17.142-11.13-26.866-11.13zM608 0c-17.674 0-32 14.326-32 32v128c0 17.674 14.326 32 32 32s32-14.326 32-32v-128c0-17.674-14.326-32-32-32zM928 320h-128c-17.674 0-32 14.326-32 32s14.326 32 32 32h128c17.674 0 32-14.326 32-32s-14.326-32-32-32zM224 774c9.724 0 19.45-3.708 26.87-11.13l128-128c14.842-14.84 14.842-38.898 0-53.738-14.84-14.844-38.898-14.844-53.738 0l-128 128c-14.842 14.84-14.842 38.898 0 53.738 7.418 7.422 17.144 11.13 26.868 11.13zM416 896c17.674 0 32-14.326 32-32v-128c0-17.674-14.326-32-32-32s-32 14.326-32 32v128c0 17.674 14.326 32 32 32zM96 576h128c17.674 0 32-14.326 32-32s-14.326-32-32-32h-128c-17.674 0-32 14.326-32 32s14.326 32 32 32z" />
|
||||
<glyph unicode="" glyph-name="bookmark" d="M256 896v-896l256 256 256-256v896h-512zM704 170.51l-192 192-192-192v661.49h384v-661.49z" />
|
||||
<glyph unicode="" glyph-name="image" d="M896 832h-768c-35.2 0-64-28.8-64-64v-640c0-35.2 28.8-64 64-64h768c35.2 0 64 28.8 64 64v640c0 35.2-28.8 64-64 64zM896 128.116c-0.012-0.014-0.030-0.028-0.042-0.042l-191.958 319.926-160-128-224 288-191.968-479.916c-0.010 0.010-0.022 0.022-0.032 0.032v639.77c0.034 0.040 0.076 0.082 0.114 0.114h767.77c0.040-0.034 0.082-0.076 0.116-0.116v-639.768zM640 608c0-53.019 42.981-96 96-96s96 42.981 96 96c0 53.019-42.981 96-96 96s-96-42.981-96-96z" />
|
||||
<glyph unicode="" glyph-name="media" d="M896 832h-768c-35.2 0-64-28.8-64-64v-640c0-35.2 28.8-64 64-64h768c35.2 0 64 28.8 64 64v640c0 35.2-28.8 64-64 64zM256 128h-128v128h128v-128zM256 384h-128v128h128v-128zM256 640h-128v128h128v-128zM704 128h-384v640h384v-640zM896 128h-128v128h128v-128zM896 384h-128v128h128v-128zM896 640h-128v128h128v-128zM384 640v-384l288 192z" />
|
||||
<glyph unicode="" glyph-name="help" d="M448 256h128v-128h-128v128zM704 704c35.346 0 64-28.654 64-64v-166l-228-154h-92v64l192 128v64h-320v128h384zM512 896c-119.666 0-232.166-46.6-316.784-131.216-84.614-84.618-131.216-197.118-131.216-316.784 0-119.664 46.602-232.168 131.216-316.784 84.618-84.616 197.118-131.216 316.784-131.216 119.664 0 232.168 46.6 316.784 131.216s131.216 197.12 131.216 316.784c0 119.666-46.6 232.166-131.216 316.784-84.616 84.616-197.12 131.216-316.784 131.216z" />
|
||||
<glyph unicode="" glyph-name="code" d="M416 256l-192 192 192 192-64 64-256-256 256-256zM672 704l-64-64 192-192-192-192 64-64 256 256z" />
|
||||
<glyph unicode="" glyph-name="insertdatetime" d="M77.798 655.376l81.414-50.882c50.802 81.114 128.788 143.454 221.208 174.246l-30.366 91.094c-113.748-37.898-209.728-114.626-272.256-214.458zM673.946 869.834l-30.366-91.094c92.422-30.792 170.404-93.132 221.208-174.248l81.412 50.882c-62.526 99.834-158.506 176.562-272.254 214.46zM607.974 255.992c-4.808 0-9.692 1.090-14.286 3.386l-145.688 72.844v211.778c0 17.672 14.328 32 32 32s32-14.328 32-32v-172.222l110.31-55.156c15.806-7.902 22.214-27.124 14.31-42.932-5.604-11.214-16.908-17.696-28.646-17.698zM512 768c-212.078 0-384-171.922-384-384s171.922-384 384-384c212.078 0 384 171.922 384 384s-171.922 384-384 384zM512 96c-159.058 0-288 128.942-288 288s128.942 288 288 288c159.058 0 288-128.942 288-288s-128.942-288-288-288z" />
|
||||
<glyph unicode="" glyph-name="preview" d="M64 504.254c45.318 49.92 97.162 92.36 153.272 125.124 90.332 52.744 192.246 80.622 294.728 80.622 102.48 0 204.396-27.878 294.726-80.624 56.112-32.764 107.956-75.204 153.274-125.124v117.432c-33.010 28.118-68.124 53.14-104.868 74.594-105.006 61.314-223.658 93.722-343.132 93.722s-238.128-32.408-343.134-93.72c-36.742-21.454-71.856-46.478-104.866-74.596v-117.43zM512 640c-183.196 0-345.838-100.556-448-256 102.162-155.448 264.804-256 448-256s345.838 100.552 448 256c-102.162 155.444-264.804 256-448 256zM512 448c0-35.346-28.654-64-64-64s-64 28.654-64 64c0 35.348 28.654 64 64 64s64-28.652 64-64zM728.066 263.338c-67.434-39.374-140.128-59.338-216.066-59.338s-148.632 19.964-216.066 59.338c-51.554 30.104-98.616 71.31-138.114 120.662 39.498 49.35 86.56 90.558 138.116 120.66 13.276 7.752 26.758 14.74 40.426 20.982-10.512-23.742-16.362-50.008-16.362-77.642 0-106.040 85.962-192 192-192 106.040 0 192 85.96 192 192 0 27.634-5.85 53.9-16.36 77.642 13.668-6.244 27.15-13.23 40.426-20.982 51.554-30.102 98.616-71.31 138.116-120.66-39.498-49.352-86.56-90.558-138.116-120.662z" />
|
||||
<glyph unicode="" glyph-name="forecolor" d="M651.168 676.166c-24.612 81.962-28.876 91.834-107.168 91.834h-64c-79.618 0-82.664-10.152-108.418-96 0-0.002 0-0.002-0.002-0.004l-143.998-479.996h113.636l57.6 192h226.366l57.6-192h113.63l-145.246 484.166zM437.218 512l38.4 136c10.086 33.618 36.38 30 36.38 30s26.294 3.618 36.38-30h0.004l38.4-136h-149.564z" />
|
||||
<glyph unicode="" glyph-name="table" d="M64 768v-704h896v704h-896zM384 320v128h256v-128h-256zM640 256v-128h-256v128h256zM640 640v-128h-256v128h256zM320 640v-128h-192v128h192zM128 448h192v-128h-192v128zM704 448h192v-128h-192v128zM704 512v128h192v-128h-192zM128 256h192v-128h-192v128zM704 128v128h192v-128h-192z" />
|
||||
<glyph unicode="" glyph-name="hr" d="M64 512h896v-128h-896z" />
|
||||
<glyph unicode="" glyph-name="removefromat" d="M64 192h512v-128h-512v128zM768 768h-220.558l-183.766-512h-132.288l183.762 512h-223.15v128h576v-128zM929.774 64l-129.774 129.774-129.774-129.774-62.226 62.226 129.774 129.774-129.774 129.774 62.226 62.226 129.774-129.774 129.774 129.774 62.226-62.226-129.774-129.774 129.774-129.774-62.226-62.226z" />
|
||||
<glyph unicode="" glyph-name="subscript" d="M768 50v-50h128v-64h-192v146l128 60v50h-128v64h192v-146zM676 704h-136l-188-188-188 188h-136l256-256-256-256h136l188 188 188-188h136l-256 256z" />
|
||||
<glyph unicode="" glyph-name="superscript" d="M768 754v-50h128v-64h-192v146l128 60v50h-128v64h192v-146zM676 704h-136l-188-188-188 188h-136l256-256-256-256h136l188 188 188-188h136l-256 256z" />
|
||||
<glyph unicode="" glyph-name="charmap" d="M704 128v37.004c151.348 61.628 256 193.82 256 346.996 0 212.078-200.576 384-448 384s-448-171.922-448-384c0-153.176 104.654-285.368 256-346.996v-37.004h-192l-64 96v-224h320v222.812c-100.9 51.362-170.666 161.54-170.666 289.188 0 176.732 133.718 320 298.666 320s298.666-143.268 298.666-320c0-127.648-69.766-237.826-170.666-289.188v-222.812h320v224l-64-96h-192z" />
|
||||
<glyph unicode="" glyph-name="emoticons" d="M512 820c99.366 0 192.782-38.694 263.042-108.956s108.958-163.678 108.958-263.044-38.696-192.782-108.958-263.042-163.676-108.958-263.042-108.958-192.782 38.696-263.044 108.958-108.956 163.676-108.956 263.042 38.694 192.782 108.956 263.044 163.678 108.956 263.044 108.956zM512 896c-247.424 0-448-200.576-448-448s200.576-448 448-448 448 200.576 448 448-200.576 448-448 448v0zM320 576c0-35.346 28.654-64 64-64s64 28.654 64 64c0 35.346-28.654 64-64 64s-64-28.654-64-64zM576 576c0-35.346 28.654-64 64-64s64 28.654 64 64c0 35.346-28.654 64-64 64s-64-28.654-64-64zM512 304c-101.84 0-192.56 36.874-251.166 94.328 23.126-117.608 126.778-206.328 251.166-206.328s228.040 88.72 251.168 206.328c-58.608-57.454-149.328-94.328-251.168-94.328z" />
|
||||
<glyph unicode="" glyph-name="print" d="M256 832h512v-128h-512v128zM896 640h-768c-35.2 0-64-28.8-64-64v-256c0-35.2 28.796-64 64-64h128v-192h512v192h128c35.2 0 64 28.8 64 64v256c0 35.2-28.8 64-64 64zM704 128h-384v256h384v-256zM910.4 544c0-25.626-20.774-46.4-46.398-46.4s-46.402 20.774-46.402 46.4 20.778 46.4 46.402 46.4c25.626 0 46.398-20.774 46.398-46.4z" />
|
||||
<glyph unicode="" glyph-name="fullscreen" d="M480 576l-192 192 128 128h-352v-352l128 128 192-192zM640 480l192 192 128-128v352h-352l128-128-192-192zM544 320l192-192-128-128h352v352l-128-128-192 192zM384 416l-192-192-128 128v-352h352l-128 128 192 192z" />
|
||||
<glyph unicode="" glyph-name="spellcheck" d="M960 832v64h-192c-35.202 0-64-28.8-64-64v-320c0-15.856 5.858-30.402 15.496-41.614l-303.496-260.386-142 148-82-70 224-288 416 448h128v64h-192v320h192zM256 448h64v384c0 35.2-28.8 64-64 64h-128c-35.2 0-64-28.8-64-64v-384h64v192h128v-192zM128 704v128h128v-128h-128zM640 512v96c0 35.2-8.8 64-44 64 35.2 0 44 28.8 44 64v96c0 35.2-28.8 64-64 64h-192v-448h192c35.2 0 64 28.8 64 64zM448 832h128v-128h-128v128zM448 640h128v-128h-128v128z" />
|
||||
<glyph unicode="" glyph-name="nonbreaking" d="M448 448h-128v128h128v128h128v-128h128v-128h-128v-128h-128v128zM960 384v-320h-896v320h128v-192h640v192h128z" />
|
||||
<glyph unicode="" glyph-name="template" d="M512 576h128v-64h-128zM512 192h128v-64h-128zM576 384h128v-64h-128zM768 384v-192h-64v-64h128v256zM384 384h128v-64h-128zM320 192h128v-64h-128zM320 576h128v-64h-128zM192 768v-256h64v192h64v64zM704 512h128v256h-64v-192h-64zM64 896v-896h896v896h-896zM896 64h-768v768h768v-768zM192 384v-256h64v192h64v64zM576 768h128v-64h-128zM384 768h128v-64h-128z" />
|
||||
<glyph unicode="" glyph-name="pagebreak" d="M816 896l16-384h-640l16 384h32l16-320h512l16 320h32zM208 0l-16 320h640l-16-320h-32l-16 256h-512l-16-256h-32zM64 448h128v-64h-128zM256 448h128v-64h-128zM448 448h128v-64h-128zM640 448h128v-64h-128zM832 448h128v-64h-128z" />
|
||||
<glyph unicode="" glyph-name="restoredraft" d="M576 896c247.424 0 448-200.576 448-448s-200.576-448-448-448v96c94.024 0 182.418 36.614 248.902 103.098s103.098 154.878 103.098 248.902c0 94.022-36.614 182.418-103.098 248.902s-154.878 103.098-248.902 103.098c-94.022 0-182.418-36.614-248.902-103.098-51.14-51.138-84.582-115.246-97.306-184.902h186.208l-224-256-224 256h164.57c31.060 217.102 217.738 384 443.43 384zM768 512v-128h-256v320h128v-192z" />
|
||||
<glyph unicode="" glyph-name="bold" d="M625.442 465.818c48.074 38.15 78.558 94.856 78.558 158.182 0 114.876-100.29 208-224 208h-224v-768h288c123.712 0 224 93.124 224 208 0 88.196-59.118 163.562-142.558 193.818zM384 656c0 26.51 21.49 48 48 48h67.204c42.414 0 76.796-42.98 76.796-96s-34.382-96-76.796-96h-115.204v144zM547.2 192h-115.2c-26.51 0-48 21.49-48 48v144h163.2c42.418 0 76.8-42.98 76.8-96s-34.382-96-76.8-96z" />
|
||||
<glyph unicode="" glyph-name="italic" d="M832 832v-64h-144l-256-640h144v-64h-448v64h144l256 640h-144v64h448z" />
|
||||
<glyph unicode="" glyph-name="underline" d="M192 128h576v-64h-576v64zM640 832v-384c0-31.312-14.7-61.624-41.39-85.352-30.942-27.502-73.068-42.648-118.61-42.648-45.544 0-87.668 15.146-118.608 42.648-26.692 23.728-41.392 54.040-41.392 85.352v384h-128v-384c0-141.382 128.942-256 288-256s288 114.618 288 256v384h-128z" />
|
||||
<glyph unicode="" glyph-name="strikethrough" d="M960 448h-265.876c-50.078 35.42-114.43 54.86-182.124 54.86-89.206 0-164.572 50.242-164.572 109.712s75.366 109.714 164.572 109.714c75.058 0 140.308-35.576 159.12-82.286h113.016c-7.93 50.644-37.58 97.968-84.058 132.826-50.88 38.16-117.676 59.174-188.078 59.174-70.404 0-137.196-21.014-188.074-59.174-54.788-41.090-86.212-99.502-86.212-160.254s31.424-119.164 86.212-160.254c1.956-1.466 3.942-2.898 5.946-4.316h-265.872v-64h512.532c58.208-17.106 100.042-56.27 100.042-100.572 0-59.468-75.368-109.71-164.572-109.71-75.060 0-140.308 35.574-159.118 82.286h-113.016c7.93-50.64 37.582-97.968 84.060-132.826 50.876-38.164 117.668-59.18 188.072-59.18 70.402 0 137.198 21.016 188.074 59.174 54.79 41.090 86.208 99.502 86.208 160.254 0 35.298-10.654 69.792-30.294 100.572h204.012v64z" />
|
||||
<glyph unicode="" glyph-name="visualchars" d="M384 832c-123.712 0-224-100.288-224-224s100.288-224 224-224v-320h128v640h64v-640h128v640h128v128h-448z" />
|
||||
<glyph unicode="" glyph-name="ltr" d="M448 832c-123.712 0-224-100.288-224-224s100.288-224 224-224v-320h128v640h64v-640h128v640h128v128h-448zM64 64l224 192-224 192z" />
|
||||
<glyph unicode="" glyph-name="rtl" d="M320 832c-123.712 0-224-100.288-224-224s100.288-224 224-224v-320h128v640h64v-640h128v640h128v128h-448zM960 448l-224-192 224-192z" />
|
||||
<glyph unicode="" glyph-name="copy" d="M832 640h-192v64l-192 192h-384v-704h384v-192h576v448l-192 192zM832 549.49l101.49-101.49h-101.49v101.49zM448 805.49l101.49-101.49h-101.49v101.49zM128 832h256v-192h192v-384h-448v576zM960 64h-448v128h128v384h128v-192h192v-320z" />
|
||||
<glyph unicode="" glyph-name="resize" d="M768 704h64v-64h-64zM640 576h64v-64h-64zM640 448h64v-64h-64zM640 320h64v-64h-64zM512 448h64v-64h-64zM512 320h64v-64h-64zM384 320h64v-64h-64zM768 576h64v-64h-64zM768 448h64v-64h-64zM768 320h64v-64h-64zM768 192h64v-64h-64zM640 192h64v-64h-64zM512 192h64v-64h-64zM384 192h64v-64h-64zM256 192h64v-64h-64z" />
|
||||
<glyph unicode="" glyph-name="browse" d="M928 832h-416l-32 64h-352l-64-128h896zM840.34 256h87.66l32 448h-896l64-640h356.080c-104.882 37.776-180.080 138.266-180.080 256 0 149.982 122.018 272 272 272 149.98 0 272-122.018 272-272 0-21.678-2.622-43.15-7.66-64zM874.996 110.25l-134.496 110.692c17.454 28.922 27.5 62.814 27.5 99.058 0 106.040-85.96 192-192 192s-192-85.96-192-192 85.96-192 192-192c36.244 0 70.138 10.046 99.058 27.5l110.692-134.496c22.962-26.678 62.118-28.14 87.006-3.252l5.492 5.492c24.888 24.888 23.426 64.044-3.252 87.006zM576 196c-68.484 0-124 55.516-124 124s55.516 124 124 124 124-55.516 124-124-55.516-124-124-124z" />
|
||||
<glyph unicode="" glyph-name="pastetext" d="M704 576v160c0 17.6-14.4 32-32 32h-160v64c0 35.2-28.8 64-64 64h-128c-35.204 0-64-28.8-64-64v-64h-160c-17.602 0-32-14.4-32-32v-512c0-17.6 14.398-32 32-32h224v-192h576v576h-192zM320 831.886c0.034 0.038 0.072 0.078 0.114 0.114h127.768c0.042-0.036 0.082-0.076 0.118-0.114v-63.886h-128v63.886zM192 640v64h384v-64h-384zM832 64h-448v448h448v-448zM448 448v-128h32l32 64h64v-192h-48v-64h160v64h-48v192h64l32-64h32v128z" />
|
||||
<glyph unicode="" glyph-name="codesample" d="M200.015 577.994v103.994c0 43.077 34.919 77.997 77.997 77.997h26v103.994h-26c-100.51 0-181.991-81.481-181.991-181.991v-103.994c0-43.077-34.919-77.997-77.997-77.997h-26v-103.994h26c43.077 0 77.997-34.919 77.997-77.997v-103.994c0-100.509 81.481-181.991 181.991-181.991h26v103.994h-26c-43.077 0-77.997 34.919-77.997 77.997v103.994c0 50.927-20.928 96.961-54.642 129.994 33.714 33.032 54.642 79.065 54.642 129.994zM823.985 577.994v103.994c0 43.077-34.919 77.997-77.997 77.997h-26v103.994h26c100.509 0 181.991-81.481 181.991-181.991v-103.994c0-43.077 34.919-77.997 77.997-77.997h26v-103.994h-26c-43.077 0-77.997-34.919-77.997-77.997v-103.994c0-100.509-81.482-181.991-181.991-181.991h-26v103.994h26c43.077 0 77.997 34.919 77.997 77.997v103.994c0 50.927 20.928 96.961 54.642 129.994-33.714 33.032-54.642 79.065-54.642 129.994zM615.997 603.277c0-57.435-46.56-103.994-103.994-103.994s-103.994 46.56-103.994 103.994c0 57.435 46.56 103.994 103.994 103.994s103.994-46.56 103.994-103.994zM512 448.717c-57.435 0-103.994-46.56-103.994-103.994 0-55.841 26-100.107 105.747-103.875-23.715-33.413-59.437-46.608-105.747-50.94v-61.747c0 0 207.991-18.144 207.991 216.561-0.202 57.437-46.56 103.996-103.994 103.996z" />
|
||||
</font></defs></svg>
|
||||
|
Before Width: | Height: | Size: 22 KiB After Width: | Height: | Size: 24 KiB |
Binary file not shown.
Binary file not shown.
Binary file not shown.
File diff suppressed because it is too large
Load Diff
@@ -6,78 +6,93 @@
|
||||
<font id="tinymce" horiz-adv-x="1024">
|
||||
<font-face units-per-em="1024" ascent="960" descent="-64" />
|
||||
<missing-glyph horiz-adv-x="1024" />
|
||||
<glyph unicode=" " d="" horiz-adv-x="512" />
|
||||
<glyph unicode="" d="M896 960h-896v-1024h1024v896l-128 128zM512 832h128v-256h-128v256zM896 64h-768v768h64v-320h576v320h74.978l53.022-53.018v-714.982z" />
|
||||
<glyph unicode="" d="M903.432 760.57l-142.864 142.862c-31.112 31.112-92.568 56.568-136.568 56.568h-480c-44 0-80-36-80-80v-864c0-44 36-80 80-80h736c44 0 80 36 80 80v608c0 44-25.456 105.458-56.568 136.57zM858.178 715.314c3.13-3.13 6.25-6.974 9.28-11.314h-163.458v163.456c4.34-3.030 8.184-6.15 11.314-9.28l142.864-142.862zM896 16c0-8.672-7.328-16-16-16h-736c-8.672 0-16 7.328-16 16v864c0 8.672 7.328 16 16 16h480c4.832 0 10.254-0.61 16-1.704v-254.296h254.296c1.094-5.746 1.704-11.166 1.704-16v-608z" />
|
||||
<glyph unicode="" d="M1024 367.542v160.916l-159.144 15.914c-8.186 30.042-20.088 58.548-35.21 84.98l104.596 127.838-113.052 113.050-127.836-104.596c-26.434 15.124-54.942 27.026-84.982 35.208l-15.914 159.148h-160.916l-15.914-159.146c-30.042-8.186-58.548-20.086-84.98-35.208l-127.838 104.594-113.050-113.050 104.596-127.836c-15.124-26.432-27.026-54.94-35.21-84.98l-159.146-15.916v-160.916l159.146-15.914c8.186-30.042 20.086-58.548 35.21-84.982l-104.596-127.836 113.048-113.048 127.838 104.596c26.432-15.124 54.94-27.028 84.98-35.21l15.916-159.148h160.916l15.914 159.144c30.042 8.186 58.548 20.088 84.982 35.21l127.836-104.596 113.048 113.048-104.596 127.836c15.124 26.434 27.028 54.942 35.21 84.98l159.148 15.92zM704 384l-128-128h-128l-128 128v128l128 128h128l128-128v-128z" />
|
||||
<glyph unicode="" d="M0 896h1024v-128h-1024zM0 704h640v-128h-640zM0 320h640v-128h-640zM0 512h1024v-128h-1024zM0 128h1024v-128h-1024z" />
|
||||
<glyph unicode="" d="M0 896h1024v-128h-1024zM192 704h640v-128h-640zM192 320h640v-128h-640zM0 512h1024v-128h-1024zM0 128h1024v-128h-1024z" />
|
||||
<glyph unicode="" d="M0 896h1024v-128h-1024zM384 704h640v-128h-640zM384 320h640v-128h-640zM0 512h1024v-128h-1024zM0 128h1024v-128h-1024z" />
|
||||
<glyph unicode="" d="M0 896h1024v-128h-1024zM0 704h1024v-128h-1024zM0 512h1024v-128h-1024zM0 320h1024v-128h-1024zM0 128h1024v-128h-1024z" />
|
||||
<glyph unicode="" d="M890.774 250.846c-45.654 45.556-103.728 69.072-157.946 69.072h-29.112l-63.904 64.008 255.62 256.038c63.904 64.010 63.904 192.028 0 256.038l-383.43-384.056-383.432 384.054c-63.904-64.008-63.904-192.028 0-256.038l255.622-256.034-63.906-64.008h-29.114c-54.22 0-112.292-23.518-157.948-69.076-81.622-81.442-92.65-202.484-24.63-270.35 29.97-29.902 70.288-44.494 112.996-44.494 54.216 0 112.29 23.514 157.946 69.072 53.584 53.464 76.742 124 67.084 185.348l65.384 65.488 65.376-65.488c-9.656-61.348 13.506-131.882 67.084-185.348 45.662-45.558 103.732-69.072 157.948-69.072 42.708 0 83.024 14.592 112.994 44.496 68.020 67.866 56.988 188.908-24.632 270.35zM353.024 114.462c-7.698-17.882-19.010-34.346-33.626-48.926-14.636-14.604-31.172-25.918-49.148-33.624-16.132-6.916-32.96-10.568-48.662-10.568-15.146 0-36.612 3.402-52.862 19.612-16.136 16.104-19.52 37.318-19.52 52.288 0 15.542 3.642 32.21 10.526 48.212 7.7 17.884 19.014 34.346 33.626 48.926 14.634 14.606 31.172 25.914 49.15 33.624 16.134 6.914 32.96 10.568 48.664 10.568 15.146 0 36.612-3.4 52.858-19.614 16.134-16.098 19.522-37.316 19.522-52.284 0.002-15.542-3.638-32.216-10.528-48.214zM512.004 293.404c-49.914 0-90.376 40.532-90.376 90.526 0 49.992 40.462 90.52 90.376 90.52s90.372-40.528 90.372-90.52c0-49.998-40.46-90.526-90.372-90.526zM855.272 40.958c-16.248-16.208-37.712-19.612-52.86-19.612-15.704 0-32.53 3.652-48.666 10.568-17.972 7.706-34.508 19.020-49.142 33.624-14.614 14.58-25.926 31.042-33.626 48.926-6.886 15.998-10.526 32.672-10.526 48.212 0 14.966 3.384 36.188 19.52 52.286 16.246 16.208 37.712 19.614 52.86 19.614 15.7 0 32.53-3.654 48.66-10.568 17.978-7.708 34.516-19.018 49.15-33.624 14.61-14.58 25.924-31.042 33.626-48.926 6.884-15.998 10.526-32.67 10.526-48.212-0.002-14.97-3.39-36.186-19.522-52.288z" />
|
||||
<glyph unicode="" d="M832 640v160c0 17.6-14.4 32-32 32h-224v64c0 35.2-28.8 64-64 64h-128c-35.204 0-64-28.8-64-64v-64h-224c-17.602 0-32-14.4-32-32v-640c0-17.6 14.398-32 32-32h288v-192h448l192 192v512h-192zM384 895.886c0.034 0.038 0.072 0.078 0.114 0.114h127.768c0.042-0.036 0.082-0.076 0.118-0.114v-63.886h-128v63.886zM192 704v64h512v-64h-512zM832 26.51v101.49h101.49l-101.49-101.49zM960 192h-192v-192h-320v576h512v-384z" />
|
||||
<glyph unicode="" d="M64 960h384v-64h-384zM576 960h384v-64h-384zM952 640h-56v256h-256v-256h-256v256h-256v-256h-56c-39.6 0-72-32.4-72-72v-560c0-39.6 32.4-72 72-72h304c39.6 0 72 32.4 72 72v376h128v-376c0-39.6 32.4-72 72-72h304c39.6 0 72 32.4 72 72v560c0 39.6-32.4 72-72 72zM348 0h-248c-19.8 0-36 14.4-36 32s16.2 32 36 32h248c19.8 0 36-14.4 36-32s-16.2-32-36-32zM544 448h-64c-17.6 0-32 14.4-32 32s14.4 32 32 32h64c17.6 0 32-14.4 32-32s-14.4-32-32-32zM924 0h-248c-19.8 0-36 14.4-36 32s16.2 32 36 32h248c19.8 0 36-14.4 36-32s-16.2-32-36-32z" />
|
||||
<glyph unicode="" d="M384 896h640v-128h-640v128zM384 512h640v-128h-640v128zM384 128h640v-128h-640v128zM0 832c0 70.692 57.308 128 128 128s128-57.308 128-128c0-70.692-57.308-128-128-128s-128 57.308-128 128zM0 448c0 70.692 57.308 128 128 128s128-57.308 128-128c0-70.692-57.308-128-128-128s-128 57.308-128 128zM0 64c0 70.692 57.308 128 128 128s128-57.308 128-128c0-70.692-57.308-128-128-128s-128 57.308-128 128z" />
|
||||
<glyph unicode="" d="M384 128h640v-128h-640zM384 512h640v-128h-640zM384 896h640v-128h-640zM192 960v-256h-64v192h-64v64zM128 434v-50h128v-64h-192v146l128 60v50h-128v64h192v-146zM256 256v-320h-192v64h128v64h-128v64h128v64h-128v64z" />
|
||||
<glyph unicode="" d="M0 896h1024v-128h-1024zM384 704h640v-128h-640zM384 512h640v-128h-640zM384 320h640v-128h-640zM0 128h1024v-128h-1024zM0 256v384l256-192z" />
|
||||
<glyph unicode="" d="M0 896h1024v-128h-1024zM384 704h640v-128h-640zM384 512h640v-128h-640zM384 320h640v-128h-640zM0 128h1024v-128h-1024zM256 640v-384l-256 192z" />
|
||||
<glyph unicode="" d="M225 512c123.712 0 224-100.29 224-224 0-123.712-100.288-224-224-224s-224 100.288-224 224l-1 32c0 247.424 200.576 448 448 448v-128c-85.474 0-165.834-33.286-226.274-93.726-11.634-11.636-22.252-24.016-31.83-37.020 11.438 1.8 23.16 2.746 35.104 2.746zM801 512c123.71 0 224-100.29 224-224 0-123.712-100.29-224-224-224s-224 100.288-224 224l-1 32c0 247.424 200.576 448 448 448v-128c-85.474 0-165.834-33.286-226.274-93.726-11.636-11.636-22.254-24.016-31.832-37.020 11.44 1.8 23.16 2.746 35.106 2.746z" />
|
||||
<glyph unicode="" d="M761.862-64c113.726 206.032 132.888 520.306-313.862 509.824v-253.824l-384 384 384 384v-248.372c534.962 13.942 594.57-472.214 313.862-775.628z" />
|
||||
<glyph unicode="" d="M576 711.628v248.372l384-384-384-384v253.824c-446.75 10.482-427.588-303.792-313.86-509.824-280.712 303.414-221.1 789.57 313.86 775.628z" />
|
||||
<glyph unicode="" d="M320 256c17.6-17.6 47.274-16.726 65.942 1.942l316.118 316.116c18.668 18.668 19.54 48.342 1.94 65.942s-47.274 16.726-65.942-1.942l-316.116-316.116c-18.668-18.668-19.542-48.342-1.942-65.942zM476.888 284.888c4.56-9.050 6.99-19.16 6.99-29.696 0-17.616-6.744-34.060-18.992-46.308l-163.382-163.382c-12.248-12.248-28.694-18.992-46.308-18.992s-34.060 6.744-46.308 18.992l-99.382 99.382c-12.248 12.248-18.992 28.694-18.992 46.308s6.744 34.060 18.992 46.308l163.382 163.382c12.248 12.248 28.694 18.994 46.308 18.994 10.536 0 20.644-2.43 29.696-6.99l65.338 65.338c-27.87 21.41-61.44 32.16-95.034 32.16-39.986 0-79.972-15.166-110.308-45.502l-163.382-163.382c-60.67-60.67-60.67-159.948 0-220.618l99.382-99.382c30.334-30.332 70.32-45.5 110.306-45.5 39.988 0 79.974 15.168 110.308 45.502l163.382 163.382c55.82 55.82 60.238 144.298 13.344 205.344l-65.34-65.34zM978.498 815.116l-99.382 99.382c-30.334 30.336-70.32 45.502-110.308 45.502-39.986 0-79.972-15.166-110.308-45.502l-163.382-163.382c-55.82-55.82-60.238-144.298-13.342-205.342l65.338 65.34c-4.558 9.050-6.988 19.16-6.988 29.694 0 17.616 6.744 34.060 18.992 46.308l163.382 163.382c12.248 12.248 28.694 18.994 46.308 18.994s34.060-6.746 46.308-18.994l99.382-99.382c12.248-12.248 18.992-28.694 18.992-46.308s-6.744-34.060-18.992-46.308l-163.382-163.382c-12.248-12.248-28.694-18.992-46.308-18.992-10.536 0-20.644 2.43-29.696 6.99l-65.338-65.338c27.872-21.41 61.44-32.16 95.034-32.16 39.988 0 79.974 15.168 110.308 45.502l163.382 163.382c60.67 60.666 60.67 159.944 0 220.614z" />
|
||||
<glyph unicode="" d="M476.888 284.886c4.56-9.048 6.99-19.158 6.99-29.696 0-17.616-6.744-34.058-18.992-46.308l-163.38-163.38c-12.248-12.248-28.696-18.992-46.308-18.992s-34.060 6.744-46.308 18.992l-99.38 99.38c-12.248 12.25-18.992 28.696-18.992 46.308s6.744 34.060 18.992 46.308l163.38 163.382c12.248 12.246 28.696 18.992 46.308 18.992 10.538 0 20.644-2.43 29.696-6.988l65.338 65.336c-27.87 21.41-61.44 32.16-95.034 32.16-39.986 0-79.972-15.166-110.308-45.502l-163.38-163.382c-60.67-60.67-60.67-159.95 0-220.618l99.38-99.382c30.334-30.332 70.32-45.5 110.306-45.5 39.988 0 79.974 15.168 110.308 45.502l163.38 163.38c55.82 55.82 60.238 144.298 13.344 205.346l-65.34-65.338zM978.496 815.116l-99.38 99.382c-30.334 30.336-70.32 45.502-110.308 45.502-39.986 0-79.97-15.166-110.306-45.502l-163.382-163.382c-55.82-55.82-60.238-144.298-13.342-205.342l65.338 65.34c-4.558 9.050-6.988 19.16-6.988 29.694 0 17.616 6.744 34.060 18.992 46.308l163.382 163.382c12.246 12.248 28.694 18.994 46.306 18.994 17.616 0 34.060-6.746 46.308-18.994l99.38-99.382c12.248-12.248 18.992-28.694 18.992-46.308s-6.744-34.060-18.992-46.308l-163.38-163.382c-12.248-12.248-28.694-18.992-46.308-18.992-10.536 0-20.644 2.43-29.696 6.99l-65.338-65.338c27.872-21.41 61.44-32.16 95.034-32.16 39.988 0 79.974 15.168 110.308 45.504l163.38 163.38c60.672 60.666 60.672 159.944 0 220.614zM233.368 681.376l-191.994 191.994 45.256 45.256 191.994-191.994zM384 960h64v-192h-64zM0 576h192v-64h-192zM790.632 214.624l191.996-191.996-45.256-45.256-191.996 191.996zM576 128h64v-192h-64zM832 384h192v-64h-192z" />
|
||||
<glyph unicode="" d="M192 960v-1024l320 320 320-320v1024h-640zM768 90.51l-256 256-256-256v805.49h512v-805.49z" />
|
||||
<glyph unicode="" d="M0 832v-832h1024v832h-1024zM960 64h-896v704h896v-704zM704 608c0 53.019 42.981 96 96 96s96-42.981 96-96c0-53.019-42.981-96-96-96s-96 42.981-96 96zM896 128h-768l192 512 256-320 128 96z" />
|
||||
<glyph unicode="" d="M0 832v-768h1024v768h-1024zM192 128h-128v128h128v-128zM192 384h-128v128h128v-128zM192 640h-128v128h128v-128zM768 128h-512v640h512v-640zM960 128h-128v128h128v-128zM960 384h-128v128h128v-128zM960 640h-128v128h128v-128zM384 640v-384l256 192z" />
|
||||
<glyph unicode="" d="M448 256h128v-128h-128zM704 704c35.346 0 64-28.654 64-64v-192l-192-128h-128v64l192 128v64h-320v128h384zM512 864c-111.118 0-215.584-43.272-294.156-121.844s-121.844-183.038-121.844-294.156c0-111.118 43.272-215.584 121.844-294.156s183.038-121.844 294.156-121.844c111.118 0 215.584 43.272 294.156 121.844s121.844 183.038 121.844 294.156c0 111.118-43.272 215.584-121.844 294.156s-183.038 121.844-294.156 121.844zM512 960v0c282.77 0 512-229.23 512-512s-229.23-512-512-512c-282.77 0-512 229.23-512 512s229.23 512 512 512z" />
|
||||
<glyph unicode="" d="M320 704l-256-256 256-256h128l-256 256 256 256zM704 704h-128l256-256-256-256h128l256 256z" />
|
||||
<glyph unicode="" d="M512 768c-212.076 0-384-171.922-384-384s171.922-384 384-384c212.074 0 384 171.922 384 384s-171.926 384-384 384zM715.644 180.354c-54.392-54.396-126.716-84.354-203.644-84.354s-149.25 29.958-203.646 84.354c-54.396 54.394-84.354 126.718-84.354 203.646s29.958 149.25 84.354 203.646c54.396 54.396 126.718 84.354 203.646 84.354s149.252-29.958 203.642-84.354c54.402-54.396 84.358-126.718 84.358-203.646s-29.958-149.252-84.356-203.646zM325.93 756.138l-42.94 85.878c-98.874-49.536-179.47-130.132-229.006-229.008l85.876-42.94c40.248 80.336 105.732 145.822 186.070 186.070zM884.134 570.070l85.878 42.938c-49.532 98.876-130.126 179.472-229.004 229.008l-42.944-85.878c80.338-40.248 145.824-105.732 186.070-186.068zM512 576h-64v-192c0-10.11 4.7-19.11 12.022-24.972l-0.012-0.016 160-128 39.976 49.976-147.986 118.39v176.622z" />
|
||||
<glyph unicode="" d="M512 640c-209.368 0-395.244-100.556-512-256 116.756-155.446 302.632-256 512-256s395.244 100.554 512 256c-116.756 155.444-302.632 256-512 256zM448 512c35.346 0 64-28.654 64-64s-28.654-64-64-64-64 28.654-64 64 28.654 64 64 64zM773.616 254.704c-39.648-20.258-81.652-35.862-124.846-46.376-44.488-10.836-90.502-16.328-136.77-16.328-46.266 0-92.282 5.492-136.768 16.324-43.194 10.518-85.198 26.122-124.846 46.376-63.020 32.202-120.222 76.41-167.64 129.298 47.418 52.888 104.62 97.1 167.64 129.298 32.336 16.522 66.242 29.946 101.082 40.040-19.888-30.242-31.468-66.434-31.468-105.336 0-106.040 85.962-192 192-192s192 85.96 192 192c0 38.902-11.582 75.094-31.466 105.34 34.838-10.096 68.744-23.52 101.082-40.042 63.022-32.198 120.218-76.408 167.638-129.298-47.42-52.886-104.618-97.1-167.638-129.296zM860.918 716.278c-108.72 55.554-226.112 83.722-348.918 83.722s-240.198-28.168-348.918-83.722c-58.772-30.032-113.732-67.904-163.082-112.076v-109.206c55.338 58.566 120.694 107.754 192.194 144.29 99.62 50.904 207.218 76.714 319.806 76.714s220.186-25.81 319.804-76.716c71.502-36.536 136.858-85.724 192.196-144.29v109.206c-49.35 44.174-104.308 82.046-163.082 112.078z" />
|
||||
<glyph unicode="" d="M322.018 128l57.6 192h264.764l57.6-192h113.632l-191.996 640h-223.236l-192-640h113.636zM475.618 640h72.764l57.6-192h-187.964l57.6 192z" />
|
||||
<glyph unicode="" d="M0 896v-896h1024v896h-1024zM384 320v192h256v-192h-256zM640 256v-192h-256v192h256zM640 768v-192h-256v192h256zM320 768v-192h-256v192h256zM64 512h256v-192h-256v192zM704 512h256v-192h-256v192zM704 576v192h256v-192h-256zM64 256h256v-192h-256v192zM704 64v192h256v-192h-256z" />
|
||||
<glyph unicode="" d="M0 512h1024v-128h-1024z" />
|
||||
<glyph unicode="" d="M0 64h576v-128h-576zM192 960h704v-128h-704zM277.388 128l204.688 784.164 123.85-32.328-196.25-751.836zM929.774-64l-129.774 129.774-129.774-129.774-62.226 62.226 129.774 129.774-129.774 129.774 62.226 62.226 129.774-129.774 129.774 129.774 62.226-62.226-129.774-129.774 129.774-129.774z" />
|
||||
<glyph unicode="" d="M768 50v-50h128v-64h-192v146l128 60v50h-128v64h192v-146zM676 704h-136l-188-188-188 188h-136l256-256-256-256h136l188 188 188-188h136l-256 256z" />
|
||||
<glyph unicode="" d="M768 754v-50h128v-64h-192v146l128 60v50h-128v64h192v-146zM676 704h-136l-188-188-188 188h-136l256-256-256-256h136l188 188 188-188h136l-256 256z" />
|
||||
<glyph unicode="" d="M704 64h256l64 128v-256h-384v214.214c131.112 56.484 224 197.162 224 361.786 0 214.432-157.598 382.266-352 382.266-194.406 0-352-167.832-352-382.266 0-164.624 92.886-305.302 224-361.786v-214.214h-384v256l64-128h256v32.59c-187.63 66.46-320 227.402-320 415.41 0 247.424 229.23 448 512 448s512-200.576 512-448c0-188.008-132.37-348.95-320-415.41v-32.59z" />
|
||||
<glyph unicode="" d="M512 960c-282.77 0-512-229.228-512-512 0-282.77 229.228-512 512-512 282.77 0 512 229.23 512 512 0 282.772-229.23 512-512 512zM512 16c-238.586 0-432 193.412-432 432 0 238.586 193.414 432 432 432 238.59 0 432-193.414 432-432 0-238.588-193.41-432-432-432zM384 640c0-35.346-28.654-64-64-64s-64 28.654-64 64 28.654 64 64 64 64-28.654 64-64zM768 640c0-35.346-28.652-64-64-64s-64 28.654-64 64 28.652 64 64 64 64-28.654 64-64zM512 308c141.074 0 262.688 57.532 318.462 123.192-20.872-171.22-156.288-303.192-318.462-303.192-162.118 0-297.498 132.026-318.444 303.168 55.786-65.646 177.386-123.168 318.444-123.168z" />
|
||||
<glyph unicode="" d="M256 896h512v-128h-512zM960 704h-896c-35.2 0-64-28.8-64-64v-320c0-35.2 28.796-64 64-64h192v-256h512v256h192c35.2 0 64 28.8 64 64v320c0 35.2-28.8 64-64 64zM704 64h-384v320h384v-320zM974.4 608c0-25.626-20.774-46.4-46.398-46.4-25.626 0-46.402 20.774-46.402 46.4s20.776 46.4 46.402 46.4c25.626 0 46.398-20.774 46.398-46.4z" />
|
||||
<glyph unicode="" d="M1024 960v-384l-138.26 138.26-212-212-107.48 107.48 212 212-138.26 138.26zM245.74 821.74l212-212-107.48-107.48-212 212-138.26-138.26v384h384zM885.74 181.74l138.26 138.26v-384h-384l138.26 138.26-212 212 107.48 107.48zM457.74 286.26l-212-212 138.26-138.26h-384v384l138.26-138.26 212 212z" />
|
||||
<glyph unicode="" d="M128 704h128v-192h64v384c0 35.2-28.8 64-64 64h-128c-35.2 0-64-28.8-64-64v-384h64v192zM128 896h128v-128h-128v128zM960 896v64h-192c-35.202 0-64-28.8-64-64v-320c0-35.2 28.798-64 64-64h192v64h-192v320h192zM640 800v96c0 35.2-28.8 64-64 64h-192v-448h192c35.2 0 64 28.8 64 64v96c0 35.2-8.8 64-44 64 35.2 0 44 28.8 44 64zM576 576h-128v128h128v-128zM576 768h-128v128h128v-128zM832 384l-416-448-224 288 82 70 142-148 352 302z" />
|
||||
<glyph unicode="" d="M448 384h-192v128h192v192h128v-192h192v-128h-192v-192h-128zM1024 320v-384h-1024v384h128v-256h768v256z" />
|
||||
<glyph unicode="" d="M384 768h128v-64h-128zM576 768h128v-64h-128zM896 768v-256h-192v64h128v128h-64v64zM320 576h128v-64h-128zM512 576h128v-64h-128zM192 704v-128h64v-64h-128v256h192v-64zM384 384h128v-64h-128zM576 384h128v-64h-128zM896 384v-256h-192v64h128v128h-64v64zM320 192h128v-64h-128zM512 192h128v-64h-128zM192 320v-128h64v-64h-128v256h192v-64zM960 896h-896v-896h896v896zM1024 960v0-1024h-1024v1024h1024z" />
|
||||
<glyph unicode="" d="M0 448h128v-64h-128zM192 448h192v-64h-192zM448 448h128v-64h-128zM640 448h192v-64h-192zM896 448h128v-64h-128zM880 960l16-448h-768l16 448h32l16-384h640l16 384zM144-64l-16 384h768l-16-384h-32l-16 320h-640l-16-320z" />
|
||||
<glyph unicode="" d="M576 896c247.424 0 448-200.576 448-448s-200.576-448-448-448v96c94.024 0 182.418 36.614 248.902 103.098s103.098 154.878 103.098 248.902c0 94.022-36.614 182.418-103.098 248.902s-154.878 103.098-248.902 103.098c-94.022 0-182.418-36.614-248.902-103.098-51.14-51.138-84.582-115.246-97.306-184.902h186.208l-224-256-224 256h164.57c31.060 217.102 217.738 384 443.43 384zM768 512v-128h-256v320h128v-192z" />
|
||||
<glyph unicode="" d="M707.88 475.348c37.498 44.542 60.12 102.008 60.12 164.652 0 141.16-114.842 256-256 256h-320v-896h384c141.158 0 256 114.842 256 256 0 92.956-49.798 174.496-124.12 219.348zM384 768h101.5c55.968 0 101.5-57.42 101.5-128s-45.532-128-101.5-128h-101.5v256zM543 128h-159v256h159c58.45 0 106-57.42 106-128s-47.55-128-106-128z" />
|
||||
<glyph unicode="" d="M896 896v-64h-128l-320-768h128v-64h-448v64h128l320 768h-128v64z" />
|
||||
<glyph unicode="" d="M704 896h128v-416c0-159.058-143.268-288-320-288-176.73 0-320 128.942-320 288v416h128v-416c0-40.166 18.238-78.704 51.354-108.506 36.896-33.204 86.846-51.494 140.646-51.494s103.75 18.29 140.646 51.494c33.116 29.802 51.354 68.34 51.354 108.506v416zM192 128h640v-128h-640z" />
|
||||
<glyph unicode="" d="M731.42 442.964c63.92-47.938 100.58-116.086 100.58-186.964s-36.66-139.026-100.58-186.964c-59.358-44.518-137.284-69.036-219.42-69.036-82.138 0-160.062 24.518-219.42 69.036-63.92 47.938-100.58 116.086-100.58 186.964h128c0-69.382 87.926-128 192-128s192 58.618 192 128c0 69.382-87.926 128-192 128-82.138 0-160.062 24.518-219.42 69.036-63.92 47.94-100.58 116.086-100.58 186.964s36.66 139.024 100.58 186.964c59.358 44.518 137.282 69.036 219.42 69.036 82.136 0 160.062-24.518 219.42-69.036 63.92-47.94 100.58-116.086 100.58-186.964h-128c0 69.382-87.926 128-192 128s-192-58.618-192-128c0-69.382 87.926-128 192-128 82.136 0 160.062-24.518 219.42-69.036zM0 448h1024v-64h-1024z" />
|
||||
<glyph unicode="" d="M384 896h512v-128h-128v-768h-128v768h-128v-768h-128v448c-123.712 0-224 100.288-224 224s100.288 224 224 224z" />
|
||||
<glyph unicode="" d="M448 896h512v-128h-128v-768h-128v768h-128v-768h-128v448c-123.712 0-224 100.288-224 224s100.288 224 224 224zM64 512l256-224-256-224z" />
|
||||
<glyph unicode="" d="M256 896h512v-128h-128v-768h-128v768h-128v-768h-128v448c-123.712 0-224 100.288-224 224s100.288 224 224 224zM960 64l-256 224 256 224z" />
|
||||
<glyph unicode="" d="M832 704h-192v64l-192 192h-448v-768h384v-256h640v576l-192 192zM832 613.49l101.49-101.49h-101.49v101.49zM448 869.49l101.49-101.49h-101.49v101.49zM64 896h320v-192h192v-448h-512v640zM960 0h-512v192h192v448h128v-192h192v-448z" />
|
||||
<glyph unicode="" d="M768 704h64v-64h-64zM640 576h64v-64h-64zM640 448h64v-64h-64zM640 320h64v-64h-64zM512 448h64v-64h-64zM512 320h64v-64h-64zM384 320h64v-64h-64zM768 576h64v-64h-64zM768 448h64v-64h-64zM768 320h64v-64h-64zM768 192h64v-64h-64zM640 192h64v-64h-64zM512 192h64v-64h-64zM384 192h64v-64h-64zM256 192h64v-64h-64z" />
|
||||
<glyph unicode="" d="M128 416l288-288 480 480-128 128-352-352-160 160z" />
|
||||
<glyph unicode="" d="M928 832h-416l-32 64h-352l-64-128h896zM904.34 256h74.86l44.8 448h-1024l64-640h484.080c-104.882 37.776-180.080 138.266-180.080 256 0 149.982 122.018 272 272 272 149.98 0 272-122.018 272-272 0-21.678-2.622-43.15-7.66-64zM1002.996 46.25l-198.496 174.692c17.454 28.92 27.5 62.814 27.5 99.058 0 106.040-85.96 192-192 192s-192-85.96-192-192 85.96-192 192-192c36.244 0 70.138 10.046 99.058 27.5l174.692-198.496c22.962-26.678 62.118-28.14 87.006-3.252l5.492 5.492c24.888 24.888 23.426 64.044-3.252 87.006zM640 196c-68.484 0-124 55.516-124 124s55.516 124 124 124 124-55.516 124-124-55.516-124-124-124z" />
|
||||
<glyph unicode="" d="M512 448v-128h32l32 64h64v-256h-48v-64h224v64h-48v256h64l32-64h32v128zM832 640v160c0 17.6-14.4 32-32 32h-224v64c0 35.2-28.8 64-64 64h-128c-35.204 0-64-28.8-64-64v-64h-224c-17.602 0-32-14.4-32-32v-640c0-17.6 14.398-32 32-32h288v-192h640v704h-192zM384 895.886c0.034 0.038 0.072 0.078 0.114 0.114h127.768c0.042-0.036 0.082-0.076 0.118-0.114v-63.886h-128v63.886zM192 704v64h512v-64h-512zM960 0h-512v576h512v-576z" />
|
||||
<glyph unicode="" d="M483.2 320l-147.2 336c-9.6 25.6-19.2 44.8-25.6 54.4s-16 12.8-25.6 12.8c-16 0-25.6-3.2-28.8-3.2v70.4c9.6 6.4 25.6 6.4 38.4 9.6 32 0 57.6-6.4 73.6-22.4 6.4-6.4 12.8-16 19.2-25.6 6.4-12.8 12.8-25.6 16-41.6l121.6-291.2 150.4 371.2h92.8l-198.4-470.4v-224h-86.4v224zM0 960v-1024h1024v1024h-1024zM960 0h-896v896h896v-896z" />
|
||||
<glyph unicode="" d="M627.2 80h-579.2v396.8h579.2v-396.8zM553.6 406.4h-435.2v-256h435.2v256zM259.2 732.8c176 176 457.6 176 633.6 0s176-457.6 0-633.6c-121.6-121.6-297.6-160-454.4-108.8 121.6-28.8 262.4 9.6 361.6 108.8 150.4 150.4 160 384 22.4 521.6-121.6 121.6-320 128-470.4 19.2l86.4-86.4-294.4-22.4 22.4 294.4 92.8-92.8z" />
|
||||
<glyph unicode="" d="M892.8-22.4l-89.6 89.6c-70.4-80-172.8-131.2-288-131.2-208 0-380.8 166.4-384 377.6 0 0 0 0 0 0 0 3.2 0 3.2 0 6.4s0 3.2 0 6.4v0c0 0 0 0 0 3.2 0 0 0 3.2 0 3.2 3.2 105.6 48 211.2 105.6 304l-192 192 44.8 44.8 182.4-182.4c0 0 0 0 0 0l569.6-569.6c0 0 0 0 0 0l99.2-99.2-48-44.8zM896 326.4c0 0 0 0 0 0 0 3.2 0 6.4 0 6.4-9.6 316.8-384 627.2-384 627.2s-108.8-89.6-208-220.8l70.4-70.4c6.4 9.6 16 22.4 22.4 32 41.6 51.2 83.2 96 115.2 128v0c32-32 73.6-76.8 115.2-128 108.8-137.6 169.6-265.6 172.8-371.2 0 0 0-3.2 0-3.2v0 0c0-3.2 0-3.2 0-6.4s0-3.2 0-3.2v0 0c0-22.4-3.2-41.6-9.6-64l76.8-76.8c16 41.6 28.8 89.6 28.8 137.6 0 0 0 0 0 0 0 3.2 0 3.2 0 6.4s0 3.2 0 6.4z" />
|
||||
<glyph unicode="" d="M768 416v-352h-640v640h352l128 128h-512c-52.8 0-96-43.2-96-96v-704c0-52.8 43.2-96 96-96h704c52.798 0 96 43.2 96 96v512l-128-128zM864 960l-608-608v-160h160l608 608c0 96-64 160-160 160zM416 320l-48 48 480 480 48-48-480-480z" />
|
||||
<glyph unicode="" d="M864.626 486.838c-65.754 183.44-205.11 348.15-352.626 473.162-147.516-125.012-286.87-289.722-352.626-473.162-40.664-113.436-44.682-236.562 12.584-345.4 65.846-125.14 198.632-205.438 340.042-205.438s274.196 80.298 340.040 205.44c57.27 108.838 53.25 231.962 12.586 345.398zM738.764 201.044c-43.802-83.252-132.812-137.044-226.764-137.044-55.12 0-108.524 18.536-152.112 50.652 13.242-1.724 26.632-2.652 40.112-2.652 117.426 0 228.668 67.214 283.402 171.242 44.878 85.292 40.978 173.848 23.882 244.338 14.558-28.15 26.906-56.198 36.848-83.932 22.606-63.062 40.024-156.34-5.368-242.604z" />
|
||||
<glyph unicode="" d="M704 896c-247.424 0-448-200.576-448-448h-224l288-288 288 288h-224c0 176.73 143.27 320 320 320 176.732 0 320-143.27 320-320 0-176.732-143.268-320-320-320v-128c247.424 0 448 200.576 448 448s-200.576 448-448 448z" horiz-adv-x="1152" />
|
||||
<glyph unicode="" d="M448 896c247.424 0 448-200.576 448-448h224l-288-288-288 288h224c0 176.73-143.27 320-320 320-176.732 0-320-143.27-320-320 0-176.732 143.268-320 320-320v-128c-247.424 0-448 200.576-448 448s200.576 448 448 448z" horiz-adv-x="1152" />
|
||||
<glyph unicode="" d="M0 576h1024v384zM1024 0v384h-1024z" />
|
||||
<glyph unicode="" d="M576 960v-1024h384zM0-64h384v1024z" />
|
||||
<glyph unicode="" d="M992.262 88.604l-242.552 206.294c-25.074 22.566-51.89 32.926-73.552 31.926 57.256 67.068 91.842 154.078 91.842 249.176 0 212.078-171.922 384-384 384-212.076 0-384-171.922-384-384s171.922-384 384-384c95.098 0 182.108 34.586 249.176 91.844-1-21.662 9.36-48.478 31.926-73.552l206.294-242.552c35.322-39.246 93.022-42.554 128.22-7.356s31.892 92.898-7.354 128.22zM384 320c-141.384 0-256 114.616-256 256s114.616 256 256 256 256-114.616 256-256-114.614-256-256-256zM448 768h-128v-128h-128v-128h128v-128h128v128h128v128h-128z" />
|
||||
<glyph unicode="" d="M992.262 88.604l-242.552 206.294c-25.074 22.566-51.89 32.926-73.552 31.926 57.256 67.068 91.842 154.078 91.842 249.176 0 212.078-171.922 384-384 384-212.076 0-384-171.922-384-384s171.922-384 384-384c95.098 0 182.108 34.586 249.176 91.844-1-21.662 9.36-48.478 31.926-73.552l206.294-242.552c35.322-39.246 93.022-42.554 128.22-7.356s31.892 92.898-7.354 128.22zM384 320c-141.384 0-256 114.616-256 256s114.616 256 256 256 256-114.616 256-256-114.614-256-256-256zM192 640h384v-128h-384z" />
|
||||
<glyph unicode="" d="M768 832h-512l-256-256 512-576 512 576-256 256zM512 181.334v2.666h-2.37l-14.222 16h16.592v16h-30.814l-14.222 16h45.036v16h-59.258l-14.222 16h73.48v16h-87.704l-14.222 16h101.926v16h-116.148l-14.222 16h130.37v16h-144.592l-14.222 16h158.814v16h-173.038l-14.222 16h187.26v16h-201.482l-14.222 16h215.704v16h-229.926l-14.222 16h244.148v16h-258.372l-14.222 16h272.594v16h-286.816l-14.222 16h301.038v16h-315.26l-14.222 16h329.482v16h-343.706l-7.344 8.262 139.072 139.072h211.978v-3.334h215.314l16-16h-231.314v-16h247.314l16-16h-263.314v-16h279.314l16-16h-295.314v-16h311.314l16-16h-327.314v-16h343.312l7.738-7.738-351.050-394.928z" />
|
||||
<glyph unicode="" d="M64 768h896v-192h-896zM64 512h896v-192h-896zM64 256h896v-192h-896z" />
|
||||
<glyph unicode="" d="M512 128c35.346 0 64-28.654 64-64v-64c0-35.346-28.654-64-64-64s-64 28.654-64 64v64c0 35.346 28.654 64 64 64zM512 768c-35.346 0-64 28.654-64 64v64c0 35.346 28.654 64 64 64s64-28.654 64-64v-64c0-35.346-28.654-64-64-64zM960 512c35.346 0 64-28.654 64-64s-28.654-64-64-64h-64c-35.348 0-64 28.654-64 64s28.652 64 64 64h64zM192 448c0-35.346-28.654-64-64-64h-64c-35.346 0-64 28.654-64 64s28.654 64 64 64h64c35.346 0 64-28.654 64-64zM828.784 221.726l45.256-45.258c24.992-24.99 24.992-65.516 0-90.508-24.994-24.992-65.518-24.992-90.51 0l-45.256 45.256c-24.992 24.99-24.992 65.516 0 90.51 24.994 24.992 65.518 24.992 90.51 0zM195.216 674.274l-45.256 45.256c-24.994 24.994-24.994 65.516 0 90.51s65.516 24.994 90.51 0l45.256-45.256c24.994-24.994 24.994-65.516 0-90.51s-65.516-24.994-90.51 0zM828.784 674.274c-24.992-24.992-65.516-24.992-90.51 0-24.992 24.994-24.992 65.516 0 90.51l45.256 45.254c24.992 24.994 65.516 24.994 90.51 0 24.992-24.994 24.992-65.516 0-90.51l-45.256-45.254zM195.216 221.726c24.992 24.992 65.518 24.992 90.508 0 24.994-24.994 24.994-65.52 0-90.51l-45.254-45.256c-24.994-24.992-65.516-24.992-90.51 0s-24.994 65.518 0 90.508l45.256 45.258zM512 704c-141.384 0-256-114.616-256-256 0-141.382 114.616-256 256-256 141.382 0 256 114.618 256 256 0 141.384-114.616 256-256 256zM512 288c-88.366 0-160 71.634-160 160s71.634 160 160 160 160-71.634 160-160-71.634-160-160-160z" />
|
||||
<glyph unicode="" d="M715.812 895.52c-60.25 34.784-124.618 55.904-189.572 64.48 122.936-160.082 144.768-384.762 37.574-570.42-107.2-185.67-312.688-279.112-512.788-252.68 39.898-51.958 90.376-97.146 150.628-131.934 245.908-141.974 560.37-57.72 702.344 188.198 141.988 245.924 57.732 560.372-188.186 702.356z" />
|
||||
<glyph unicode="" d="M512 960c-282.77 0-512-229.23-512-512s229.23-512 512-512 512 229.23 512 512-229.23 512-512 512zM128 448c0 212.078 171.922 384 384 384v-768c-212.078 0-384 171.922-384 384z" />
|
||||
<glyph unicode="" d="M893.254 738.746l-90.508 90.508-290.746-290.744-290.746 290.744-90.508-90.506 290.746-290.748-290.746-290.746 90.508-90.508 290.746 290.746 290.746-290.746 90.508 90.51-290.744 290.744z" />
|
||||
<glyph unicode="" d="M672-64l192 192-320 320 320 320-192 192-512-512z" />
|
||||
<glyph unicode="" d="M0 896v-384c0-35.346 28.654-64 64-64s64 28.654 64 64v229.488l677.488-677.488h-229.488c-35.346 0-64-28.652-64-64 0-35.346 28.654-64 64-64h384c35.346 0 64 28.654 64 64v384c0 35.348-28.654 64-64 64s-64-28.652-64-64v-229.488l-677.488 677.488h229.488c35.346 0 64 28.654 64 64s-28.652 64-64 64h-384c-35.346 0-64-28.654-64-64z" />
|
||||
<glyph unicode="" d="M832 704l192 192-64 64-192-192h-448v192h-128v-192h-192v-128h192v-512h512v-192h128v192h192v128h-192v448zM320 640h320l-320-320v320zM384 256l320 320v-320h-320z" />
|
||||
<glyph unicode=" " horiz-adv-x="512" d="" />
|
||||
<glyph unicode="" glyph-name="save" d="M896 960h-896v-1024h1024v896l-128 128zM512 832h128v-256h-128v256zM896 64h-768v768h64v-320h576v320h74.978l53.022-53.018v-714.982z" />
|
||||
<glyph unicode="" glyph-name="newdocument" d="M903.432 760.57l-142.864 142.862c-31.112 31.112-92.568 56.568-136.568 56.568h-480c-44 0-80-36-80-80v-864c0-44 36-80 80-80h736c44 0 80 36 80 80v608c0 44-25.456 105.458-56.568 136.57zM858.178 715.314c3.13-3.13 6.25-6.974 9.28-11.314h-163.458v163.456c4.34-3.030 8.184-6.15 11.314-9.28l142.864-142.862zM896 16c0-8.672-7.328-16-16-16h-736c-8.672 0-16 7.328-16 16v864c0 8.672 7.328 16 16 16h480c4.832 0 10.254-0.61 16-1.704v-254.296h254.296c1.094-5.746 1.704-11.166 1.704-16v-608z" />
|
||||
<glyph unicode="" glyph-name="fullpage" d="M1024 367.542v160.916l-159.144 15.914c-8.186 30.042-20.088 58.548-35.21 84.98l104.596 127.838-113.052 113.050-127.836-104.596c-26.434 15.124-54.942 27.026-84.982 35.208l-15.914 159.148h-160.916l-15.914-159.146c-30.042-8.186-58.548-20.086-84.98-35.208l-127.838 104.594-113.050-113.050 104.596-127.836c-15.124-26.432-27.026-54.94-35.21-84.98l-159.146-15.916v-160.916l159.146-15.914c8.186-30.042 20.086-58.548 35.21-84.982l-104.596-127.836 113.048-113.048 127.838 104.596c26.432-15.124 54.94-27.028 84.98-35.21l15.916-159.148h160.916l15.914 159.144c30.042 8.186 58.548 20.088 84.982 35.21l127.836-104.596 113.048 113.048-104.596 127.836c15.124 26.434 27.028 54.942 35.21 84.98l159.148 15.92zM704 384l-128-128h-128l-128 128v128l128 128h128l128-128v-128z" />
|
||||
<glyph unicode="" glyph-name="alignleft" d="M0 896h1024v-128h-1024zM0 704h640v-128h-640zM0 320h640v-128h-640zM0 512h1024v-128h-1024zM0 128h1024v-128h-1024z" />
|
||||
<glyph unicode="" glyph-name="aligncenter" d="M0 896h1024v-128h-1024zM192 704h640v-128h-640zM192 320h640v-128h-640zM0 512h1024v-128h-1024zM0 128h1024v-128h-1024z" />
|
||||
<glyph unicode="" glyph-name="alignright" d="M0 896h1024v-128h-1024zM384 704h640v-128h-640zM384 320h640v-128h-640zM0 512h1024v-128h-1024zM0 128h1024v-128h-1024z" />
|
||||
<glyph unicode="" glyph-name="alignjustify" d="M0 896h1024v-128h-1024zM0 704h1024v-128h-1024zM0 512h1024v-128h-1024zM0 320h1024v-128h-1024zM0 128h1024v-128h-1024z" />
|
||||
<glyph unicode="" glyph-name="cut" d="M890.774 250.846c-45.654 45.556-103.728 69.072-157.946 69.072h-29.112l-63.904 64.008 255.62 256.038c63.904 64.010 63.904 192.028 0 256.038l-383.43-384.056-383.432 384.054c-63.904-64.008-63.904-192.028 0-256.038l255.622-256.034-63.906-64.008h-29.114c-54.22 0-112.292-23.518-157.948-69.076-81.622-81.442-92.65-202.484-24.63-270.35 29.97-29.902 70.288-44.494 112.996-44.494 54.216 0 112.29 23.514 157.946 69.072 53.584 53.464 76.742 124 67.084 185.348l65.384 65.488 65.376-65.488c-9.656-61.348 13.506-131.882 67.084-185.348 45.662-45.558 103.732-69.072 157.948-69.072 42.708 0 83.024 14.592 112.994 44.496 68.020 67.866 56.988 188.908-24.632 270.35zM353.024 114.462c-7.698-17.882-19.010-34.346-33.626-48.926-14.636-14.604-31.172-25.918-49.148-33.624-16.132-6.916-32.96-10.568-48.662-10.568-15.146 0-36.612 3.402-52.862 19.612-16.136 16.104-19.52 37.318-19.52 52.288 0 15.542 3.642 32.21 10.526 48.212 7.7 17.884 19.014 34.346 33.626 48.926 14.634 14.606 31.172 25.914 49.15 33.624 16.134 6.914 32.96 10.568 48.664 10.568 15.146 0 36.612-3.4 52.858-19.614 16.134-16.098 19.522-37.316 19.522-52.284 0.002-15.542-3.638-32.216-10.528-48.214zM512.004 293.404c-49.914 0-90.376 40.532-90.376 90.526 0 49.992 40.462 90.52 90.376 90.52s90.372-40.528 90.372-90.52c0-49.998-40.46-90.526-90.372-90.526zM855.272 40.958c-16.248-16.208-37.712-19.612-52.86-19.612-15.704 0-32.53 3.652-48.666 10.568-17.972 7.706-34.508 19.020-49.142 33.624-14.614 14.58-25.926 31.042-33.626 48.926-6.886 15.998-10.526 32.672-10.526 48.212 0 14.966 3.384 36.188 19.52 52.286 16.246 16.208 37.712 19.614 52.86 19.614 15.7 0 32.53-3.654 48.66-10.568 17.978-7.708 34.516-19.018 49.15-33.624 14.61-14.58 25.924-31.042 33.626-48.926 6.884-15.998 10.526-32.67 10.526-48.212-0.002-14.97-3.39-36.186-19.522-52.288z" />
|
||||
<glyph unicode="" glyph-name="paste" d="M832 640v160c0 17.6-14.4 32-32 32h-224v64c0 35.2-28.8 64-64 64h-128c-35.204 0-64-28.8-64-64v-64h-224c-17.602 0-32-14.4-32-32v-640c0-17.6 14.398-32 32-32h288v-192h448l192 192v512h-192zM384 895.886c0.034 0.038 0.072 0.078 0.114 0.114h127.768c0.042-0.036 0.082-0.076 0.118-0.114v-63.886h-128v63.886zM192 704v64h512v-64h-512zM832 26.51v101.49h101.49l-101.49-101.49zM960 192h-192v-192h-320v576h512v-384z" />
|
||||
<glyph unicode="" glyph-name="searchreplace" d="M64 960h384v-64h-384zM576 960h384v-64h-384zM952 640h-56v256h-256v-256h-256v256h-256v-256h-56c-39.6 0-72-32.4-72-72v-560c0-39.6 32.4-72 72-72h304c39.6 0 72 32.4 72 72v376h128v-376c0-39.6 32.4-72 72-72h304c39.6 0 72 32.4 72 72v560c0 39.6-32.4 72-72 72zM348 0h-248c-19.8 0-36 14.4-36 32s16.2 32 36 32h248c19.8 0 36-14.4 36-32s-16.2-32-36-32zM544 448h-64c-17.6 0-32 14.4-32 32s14.4 32 32 32h64c17.6 0 32-14.4 32-32s-14.4-32-32-32zM924 0h-248c-19.8 0-36 14.4-36 32s16.2 32 36 32h248c19.8 0 36-14.4 36-32s-16.2-32-36-32z" />
|
||||
<glyph unicode="" glyph-name="bullist" d="M384 896h640v-128h-640v128zM384 512h640v-128h-640v128zM384 128h640v-128h-640v128zM0 832c0 70.692 57.308 128 128 128s128-57.308 128-128c0-70.692-57.308-128-128-128s-128 57.308-128 128zM0 448c0 70.692 57.308 128 128 128s128-57.308 128-128c0-70.692-57.308-128-128-128s-128 57.308-128 128zM0 64c0 70.692 57.308 128 128 128s128-57.308 128-128c0-70.692-57.308-128-128-128s-128 57.308-128 128z" />
|
||||
<glyph unicode="" glyph-name="numlist" d="M384 128h640v-128h-640zM384 512h640v-128h-640zM384 896h640v-128h-640zM192 960v-256h-64v192h-64v64zM128 434v-50h128v-64h-192v146l128 60v50h-128v64h192v-146zM256 256v-320h-192v64h128v64h-128v64h128v64h-128v64z" />
|
||||
<glyph unicode="" glyph-name="indent" d="M0 896h1024v-128h-1024zM384 704h640v-128h-640zM384 512h640v-128h-640zM384 320h640v-128h-640zM0 128h1024v-128h-1024zM0 256v384l256-192z" />
|
||||
<glyph unicode="" glyph-name="outdent" d="M0 896h1024v-128h-1024zM384 704h640v-128h-640zM384 512h640v-128h-640zM384 320h640v-128h-640zM0 128h1024v-128h-1024zM256 640v-384l-256 192z" />
|
||||
<glyph unicode="" glyph-name="blockquote" d="M225 512c123.712 0 224-100.29 224-224 0-123.712-100.288-224-224-224s-224 100.288-224 224l-1 32c0 247.424 200.576 448 448 448v-128c-85.474 0-165.834-33.286-226.274-93.726-11.634-11.636-22.252-24.016-31.83-37.020 11.438 1.8 23.16 2.746 35.104 2.746zM801 512c123.71 0 224-100.29 224-224 0-123.712-100.29-224-224-224s-224 100.288-224 224l-1 32c0 247.424 200.576 448 448 448v-128c-85.474 0-165.834-33.286-226.274-93.726-11.636-11.636-22.254-24.016-31.832-37.020 11.44 1.8 23.16 2.746 35.106 2.746z" />
|
||||
<glyph unicode="" glyph-name="undo" d="M761.862-64c113.726 206.032 132.888 520.306-313.862 509.824v-253.824l-384 384 384 384v-248.372c534.962 13.942 594.57-472.214 313.862-775.628z" />
|
||||
<glyph unicode="" glyph-name="redo" d="M576 711.628v248.372l384-384-384-384v253.824c-446.75 10.482-427.588-303.792-313.86-509.824-280.712 303.414-221.1 789.57 313.86 775.628z" />
|
||||
<glyph unicode="" glyph-name="link" d="M320 256c17.6-17.6 47.274-16.726 65.942 1.942l316.118 316.116c18.668 18.668 19.54 48.342 1.94 65.942s-47.274 16.726-65.942-1.942l-316.116-316.116c-18.668-18.668-19.542-48.342-1.942-65.942zM476.888 284.888c4.56-9.050 6.99-19.16 6.99-29.696 0-17.616-6.744-34.060-18.992-46.308l-163.382-163.382c-12.248-12.248-28.694-18.992-46.308-18.992s-34.060 6.744-46.308 18.992l-99.382 99.382c-12.248 12.248-18.992 28.694-18.992 46.308s6.744 34.060 18.992 46.308l163.382 163.382c12.248 12.248 28.694 18.994 46.308 18.994 10.536 0 20.644-2.43 29.696-6.99l65.338 65.338c-27.87 21.41-61.44 32.16-95.034 32.16-39.986 0-79.972-15.166-110.308-45.502l-163.382-163.382c-60.67-60.67-60.67-159.948 0-220.618l99.382-99.382c30.334-30.332 70.32-45.5 110.306-45.5 39.988 0 79.974 15.168 110.308 45.502l163.382 163.382c55.82 55.82 60.238 144.298 13.344 205.344l-65.34-65.34zM978.498 815.116l-99.382 99.382c-30.334 30.336-70.32 45.502-110.308 45.502-39.986 0-79.972-15.166-110.308-45.502l-163.382-163.382c-55.82-55.82-60.238-144.298-13.342-205.342l65.338 65.34c-4.558 9.050-6.988 19.16-6.988 29.694 0 17.616 6.744 34.060 18.992 46.308l163.382 163.382c12.248 12.248 28.694 18.994 46.308 18.994s34.060-6.746 46.308-18.994l99.382-99.382c12.248-12.248 18.992-28.694 18.992-46.308s-6.744-34.060-18.992-46.308l-163.382-163.382c-12.248-12.248-28.694-18.992-46.308-18.992-10.536 0-20.644 2.43-29.696 6.99l-65.338-65.338c27.872-21.41 61.44-32.16 95.034-32.16 39.988 0 79.974 15.168 110.308 45.502l163.382 163.382c60.67 60.666 60.67 159.944 0 220.614z" />
|
||||
<glyph unicode="" glyph-name="unlink" d="M476.888 284.886c4.56-9.048 6.99-19.158 6.99-29.696 0-17.616-6.744-34.058-18.992-46.308l-163.38-163.38c-12.248-12.248-28.696-18.992-46.308-18.992s-34.060 6.744-46.308 18.992l-99.38 99.38c-12.248 12.25-18.992 28.696-18.992 46.308s6.744 34.060 18.992 46.308l163.38 163.382c12.248 12.246 28.696 18.992 46.308 18.992 10.538 0 20.644-2.43 29.696-6.988l65.338 65.336c-27.87 21.41-61.44 32.16-95.034 32.16-39.986 0-79.972-15.166-110.308-45.502l-163.38-163.382c-60.67-60.67-60.67-159.95 0-220.618l99.38-99.382c30.334-30.332 70.32-45.5 110.306-45.5 39.988 0 79.974 15.168 110.308 45.502l163.38 163.38c55.82 55.82 60.238 144.298 13.344 205.346l-65.34-65.338zM978.496 815.116l-99.38 99.382c-30.334 30.336-70.32 45.502-110.308 45.502-39.986 0-79.97-15.166-110.306-45.502l-163.382-163.382c-55.82-55.82-60.238-144.298-13.342-205.342l65.338 65.34c-4.558 9.050-6.988 19.16-6.988 29.694 0 17.616 6.744 34.060 18.992 46.308l163.382 163.382c12.246 12.248 28.694 18.994 46.306 18.994 17.616 0 34.060-6.746 46.308-18.994l99.38-99.382c12.248-12.248 18.992-28.694 18.992-46.308s-6.744-34.060-18.992-46.308l-163.38-163.382c-12.248-12.248-28.694-18.992-46.308-18.992-10.536 0-20.644 2.43-29.696 6.99l-65.338-65.338c27.872-21.41 61.44-32.16 95.034-32.16 39.988 0 79.974 15.168 110.308 45.504l163.38 163.38c60.672 60.666 60.672 159.944 0 220.614zM233.368 681.376l-191.994 191.994 45.256 45.256 191.994-191.994zM384 960h64v-192h-64zM0 576h192v-64h-192zM790.632 214.624l191.996-191.996-45.256-45.256-191.996 191.996zM576 128h64v-192h-64zM832 384h192v-64h-192z" />
|
||||
<glyph unicode="" glyph-name="anchor" d="M192 960v-1024l320 320 320-320v1024h-640zM768 90.51l-256 256-256-256v805.49h512v-805.49z" />
|
||||
<glyph unicode="" glyph-name="image" d="M0 832v-832h1024v832h-1024zM960 64h-896v704h896v-704zM704 608c0 53.019 42.981 96 96 96s96-42.981 96-96c0-53.019-42.981-96-96-96s-96 42.981-96 96zM896 128h-768l192 512 256-320 128 96z" />
|
||||
<glyph unicode="" glyph-name="media" d="M0 832v-768h1024v768h-1024zM192 128h-128v128h128v-128zM192 384h-128v128h128v-128zM192 640h-128v128h128v-128zM768 128h-512v640h512v-640zM960 128h-128v128h128v-128zM960 384h-128v128h128v-128zM960 640h-128v128h128v-128zM384 640v-384l256 192z" />
|
||||
<glyph unicode="" glyph-name="help" d="M448 256h128v-128h-128zM704 704c35.346 0 64-28.654 64-64v-192l-192-128h-128v64l192 128v64h-320v128h384zM512 864c-111.118 0-215.584-43.272-294.156-121.844s-121.844-183.038-121.844-294.156c0-111.118 43.272-215.584 121.844-294.156s183.038-121.844 294.156-121.844c111.118 0 215.584 43.272 294.156 121.844s121.844 183.038 121.844 294.156c0 111.118-43.272 215.584-121.844 294.156s-183.038 121.844-294.156 121.844zM512 960v0c282.77 0 512-229.23 512-512s-229.23-512-512-512c-282.77 0-512 229.23-512 512s229.23 512 512 512z" />
|
||||
<glyph unicode="" glyph-name="code" d="M320 704l-256-256 256-256h128l-256 256 256 256zM704 704h-128l256-256-256-256h128l256 256z" />
|
||||
<glyph unicode="" glyph-name="inserttime" d="M512 768c-212.076 0-384-171.922-384-384s171.922-384 384-384c212.074 0 384 171.922 384 384s-171.926 384-384 384zM715.644 180.354c-54.392-54.396-126.716-84.354-203.644-84.354s-149.25 29.958-203.646 84.354c-54.396 54.394-84.354 126.718-84.354 203.646s29.958 149.25 84.354 203.646c54.396 54.396 126.718 84.354 203.646 84.354s149.252-29.958 203.642-84.354c54.402-54.396 84.358-126.718 84.358-203.646s-29.958-149.252-84.356-203.646zM325.93 756.138l-42.94 85.878c-98.874-49.536-179.47-130.132-229.006-229.008l85.876-42.94c40.248 80.336 105.732 145.822 186.070 186.070zM884.134 570.070l85.878 42.938c-49.532 98.876-130.126 179.472-229.004 229.008l-42.944-85.878c80.338-40.248 145.824-105.732 186.070-186.068zM512 576h-64v-192c0-10.11 4.7-19.11 12.022-24.972l-0.012-0.016 160-128 39.976 49.976-147.986 118.39v176.622z" />
|
||||
<glyph unicode="" glyph-name="preview" d="M512 640c-209.368 0-395.244-100.556-512-256 116.756-155.446 302.632-256 512-256s395.244 100.554 512 256c-116.756 155.444-302.632 256-512 256zM448 512c35.346 0 64-28.654 64-64s-28.654-64-64-64-64 28.654-64 64 28.654 64 64 64zM773.616 254.704c-39.648-20.258-81.652-35.862-124.846-46.376-44.488-10.836-90.502-16.328-136.77-16.328-46.266 0-92.282 5.492-136.768 16.324-43.194 10.518-85.198 26.122-124.846 46.376-63.020 32.202-120.222 76.41-167.64 129.298 47.418 52.888 104.62 97.1 167.64 129.298 32.336 16.522 66.242 29.946 101.082 40.040-19.888-30.242-31.468-66.434-31.468-105.336 0-106.040 85.962-192 192-192s192 85.96 192 192c0 38.902-11.582 75.094-31.466 105.34 34.838-10.096 68.744-23.52 101.082-40.042 63.022-32.198 120.218-76.408 167.638-129.298-47.42-52.886-104.618-97.1-167.638-129.296zM860.918 716.278c-108.72 55.554-226.112 83.722-348.918 83.722s-240.198-28.168-348.918-83.722c-58.772-30.032-113.732-67.904-163.082-112.076v-109.206c55.338 58.566 120.694 107.754 192.194 144.29 99.62 50.904 207.218 76.714 319.806 76.714s220.186-25.81 319.804-76.716c71.502-36.536 136.858-85.724 192.196-144.29v109.206c-49.35 44.174-104.308 82.046-163.082 112.078z" />
|
||||
<glyph unicode="" glyph-name="forecolor" d="M322.018 128l57.6 192h264.764l57.6-192h113.632l-191.996 640h-223.236l-192-640h113.636zM475.618 640h72.764l57.6-192h-187.964l57.6 192z" />
|
||||
<glyph unicode="" glyph-name="table" d="M0 896v-896h1024v896h-1024zM384 320v192h256v-192h-256zM640 256v-192h-256v192h256zM640 768v-192h-256v192h256zM320 768v-192h-256v192h256zM64 512h256v-192h-256v192zM704 512h256v-192h-256v192zM704 576v192h256v-192h-256zM64 256h256v-192h-256v192zM704 64v192h256v-192h-256z" />
|
||||
<glyph unicode="" glyph-name="hr" d="M0 512h1024v-128h-1024z" />
|
||||
<glyph unicode="" glyph-name="removeformat" d="M0 64h576v-128h-576zM192 960h704v-128h-704zM277.388 128l204.688 784.164 123.85-32.328-196.25-751.836zM929.774-64l-129.774 129.774-129.774-129.774-62.226 62.226 129.774 129.774-129.774 129.774 62.226 62.226 129.774-129.774 129.774 129.774 62.226-62.226-129.774-129.774 129.774-129.774z" />
|
||||
<glyph unicode="" glyph-name="sub" d="M768 50v-50h128v-64h-192v146l128 60v50h-128v64h192v-146zM676 704h-136l-188-188-188 188h-136l256-256-256-256h136l188 188 188-188h136l-256 256z" />
|
||||
<glyph unicode="" glyph-name="sup" d="M768 754v-50h128v-64h-192v146l128 60v50h-128v64h192v-146zM676 704h-136l-188-188-188 188h-136l256-256-256-256h136l188 188 188-188h136l-256 256z" />
|
||||
<glyph unicode="" glyph-name="charmap" d="M704 64h256l64 128v-256h-384v214.214c131.112 56.484 224 197.162 224 361.786 0 214.432-157.598 382.266-352 382.266-194.406 0-352-167.832-352-382.266 0-164.624 92.886-305.302 224-361.786v-214.214h-384v256l64-128h256v32.59c-187.63 66.46-320 227.402-320 415.41 0 247.424 229.23 448 512 448s512-200.576 512-448c0-188.008-132.37-348.95-320-415.41v-32.59z" />
|
||||
<glyph unicode="" glyph-name="emoticons" d="M512 960c-282.77 0-512-229.228-512-512 0-282.77 229.228-512 512-512 282.77 0 512 229.23 512 512 0 282.772-229.23 512-512 512zM512 16c-238.586 0-432 193.412-432 432 0 238.586 193.414 432 432 432 238.59 0 432-193.414 432-432 0-238.588-193.41-432-432-432zM384 640c0-35.346-28.654-64-64-64s-64 28.654-64 64 28.654 64 64 64 64-28.654 64-64zM768 640c0-35.346-28.652-64-64-64s-64 28.654-64 64 28.652 64 64 64 64-28.654 64-64zM512 308c141.074 0 262.688 57.532 318.462 123.192-20.872-171.22-156.288-303.192-318.462-303.192-162.118 0-297.498 132.026-318.444 303.168 55.786-65.646 177.386-123.168 318.444-123.168z" />
|
||||
<glyph unicode="" glyph-name="print" d="M256 896h512v-128h-512zM960 704h-896c-35.2 0-64-28.8-64-64v-320c0-35.2 28.796-64 64-64h192v-256h512v256h192c35.2 0 64 28.8 64 64v320c0 35.2-28.8 64-64 64zM704 64h-384v320h384v-320zM974.4 608c0-25.626-20.774-46.4-46.398-46.4-25.626 0-46.402 20.774-46.402 46.4s20.776 46.4 46.402 46.4c25.626 0 46.398-20.774 46.398-46.4z" />
|
||||
<glyph unicode="" glyph-name="fullscreen" d="M1024 960v-384l-138.26 138.26-212-212-107.48 107.48 212 212-138.26 138.26zM245.74 821.74l212-212-107.48-107.48-212 212-138.26-138.26v384h384zM885.74 181.74l138.26 138.26v-384h-384l138.26 138.26-212 212 107.48 107.48zM457.74 286.26l-212-212 138.26-138.26h-384v384l138.26-138.26 212 212z" />
|
||||
<glyph unicode="" glyph-name="spellchecker" d="M128 704h128v-192h64v384c0 35.2-28.8 64-64 64h-128c-35.2 0-64-28.8-64-64v-384h64v192zM128 896h128v-128h-128v128zM960 896v64h-192c-35.202 0-64-28.8-64-64v-320c0-35.2 28.798-64 64-64h192v64h-192v320h192zM640 800v96c0 35.2-28.8 64-64 64h-192v-448h192c35.2 0 64 28.8 64 64v96c0 35.2-8.8 64-44 64 35.2 0 44 28.8 44 64zM576 576h-128v128h128v-128zM576 768h-128v128h128v-128zM832 384l-416-448-224 288 82 70 142-148 352 302z" />
|
||||
<glyph unicode="" glyph-name="nonbreaking" d="M448 384h-192v128h192v192h128v-192h192v-128h-192v-192h-128zM1024 320v-384h-1024v384h128v-256h768v256z" />
|
||||
<glyph unicode="" glyph-name="template" d="M384 768h128v-64h-128zM576 768h128v-64h-128zM896 768v-256h-192v64h128v128h-64v64zM320 576h128v-64h-128zM512 576h128v-64h-128zM192 704v-128h64v-64h-128v256h192v-64zM384 384h128v-64h-128zM576 384h128v-64h-128zM896 384v-256h-192v64h128v128h-64v64zM320 192h128v-64h-128zM512 192h128v-64h-128zM192 320v-128h64v-64h-128v256h192v-64zM960 896h-896v-896h896v896zM1024 960v0-1024h-1024v1024h1024z" />
|
||||
<glyph unicode="" glyph-name="pagebreak" d="M0 448h128v-64h-128zM192 448h192v-64h-192zM448 448h128v-64h-128zM640 448h192v-64h-192zM896 448h128v-64h-128zM880 960l16-448h-768l16 448h32l16-384h640l16 384zM144-64l-16 384h768l-16-384h-32l-16 320h-640l-16-320z" />
|
||||
<glyph unicode="" glyph-name="restoredraft" d="M576 896c247.424 0 448-200.576 448-448s-200.576-448-448-448v96c94.024 0 182.418 36.614 248.902 103.098s103.098 154.878 103.098 248.902c0 94.022-36.614 182.418-103.098 248.902s-154.878 103.098-248.902 103.098c-94.022 0-182.418-36.614-248.902-103.098-51.14-51.138-84.582-115.246-97.306-184.902h186.208l-224-256-224 256h164.57c31.060 217.102 217.738 384 443.43 384zM768 512v-128h-256v320h128v-192z" />
|
||||
<glyph unicode="" glyph-name="bold" d="M707.88 475.348c37.498 44.542 60.12 102.008 60.12 164.652 0 141.16-114.842 256-256 256h-320v-896h384c141.158 0 256 114.842 256 256 0 92.956-49.798 174.496-124.12 219.348zM384 768h101.5c55.968 0 101.5-57.42 101.5-128s-45.532-128-101.5-128h-101.5v256zM543 128h-159v256h159c58.45 0 106-57.42 106-128s-47.55-128-106-128z" />
|
||||
<glyph unicode="" glyph-name="italic" d="M896 896v-64h-128l-320-768h128v-64h-448v64h128l320 768h-128v64z" />
|
||||
<glyph unicode="" glyph-name="underline" d="M704 896h128v-416c0-159.058-143.268-288-320-288-176.73 0-320 128.942-320 288v416h128v-416c0-40.166 18.238-78.704 51.354-108.506 36.896-33.204 86.846-51.494 140.646-51.494s103.75 18.29 140.646 51.494c33.116 29.802 51.354 68.34 51.354 108.506v416zM192 128h640v-128h-640z" />
|
||||
<glyph unicode="" glyph-name="strikethrough" d="M731.42 442.964c63.92-47.938 100.58-116.086 100.58-186.964s-36.66-139.026-100.58-186.964c-59.358-44.518-137.284-69.036-219.42-69.036-82.138 0-160.062 24.518-219.42 69.036-63.92 47.938-100.58 116.086-100.58 186.964h128c0-69.382 87.926-128 192-128s192 58.618 192 128c0 69.382-87.926 128-192 128-82.138 0-160.062 24.518-219.42 69.036-63.92 47.94-100.58 116.086-100.58 186.964s36.66 139.024 100.58 186.964c59.358 44.518 137.282 69.036 219.42 69.036 82.136 0 160.062-24.518 219.42-69.036 63.92-47.94 100.58-116.086 100.58-186.964h-128c0 69.382-87.926 128-192 128s-192-58.618-192-128c0-69.382 87.926-128 192-128 82.136 0 160.062-24.518 219.42-69.036zM0 448h1024v-64h-1024z" />
|
||||
<glyph unicode="" glyph-name="visualchars" d="M384 896h512v-128h-128v-768h-128v768h-128v-768h-128v448c-123.712 0-224 100.288-224 224s100.288 224 224 224z" />
|
||||
<glyph unicode="" glyph-name="ltr" d="M448 896h512v-128h-128v-768h-128v768h-128v-768h-128v448c-123.712 0-224 100.288-224 224s100.288 224 224 224zM64 512l256-224-256-224z" />
|
||||
<glyph unicode="" glyph-name="rtl" d="M256 896h512v-128h-128v-768h-128v768h-128v-768h-128v448c-123.712 0-224 100.288-224 224s100.288 224 224 224zM960 64l-256 224 256 224z" />
|
||||
<glyph unicode="" glyph-name="copy" d="M832 704h-192v64l-192 192h-448v-768h384v-256h640v576l-192 192zM832 613.49l101.49-101.49h-101.49v101.49zM448 869.49l101.49-101.49h-101.49v101.49zM64 896h320v-192h192v-448h-512v640zM960 0h-512v192h192v448h128v-192h192v-448z" />
|
||||
<glyph unicode="" glyph-name="resize" d="M768 704h64v-64h-64zM640 576h64v-64h-64zM640 448h64v-64h-64zM640 320h64v-64h-64zM512 448h64v-64h-64zM512 320h64v-64h-64zM384 320h64v-64h-64zM768 576h64v-64h-64zM768 448h64v-64h-64zM768 320h64v-64h-64zM768 192h64v-64h-64zM640 192h64v-64h-64zM512 192h64v-64h-64zM384 192h64v-64h-64zM256 192h64v-64h-64z" />
|
||||
<glyph unicode="" glyph-name="checkbox" d="M128 416l288-288 480 480-128 128-352-352-160 160z" />
|
||||
<glyph unicode="" glyph-name="browse" d="M928 832h-416l-32 64h-352l-64-128h896zM904.34 256h74.86l44.8 448h-1024l64-640h484.080c-104.882 37.776-180.080 138.266-180.080 256 0 149.982 122.018 272 272 272 149.98 0 272-122.018 272-272 0-21.678-2.622-43.15-7.66-64zM1002.996 46.25l-198.496 174.692c17.454 28.92 27.5 62.814 27.5 99.058 0 106.040-85.96 192-192 192s-192-85.96-192-192 85.96-192 192-192c36.244 0 70.138 10.046 99.058 27.5l174.692-198.496c22.962-26.678 62.118-28.14 87.006-3.252l5.492 5.492c24.888 24.888 23.426 64.044-3.252 87.006zM640 196c-68.484 0-124 55.516-124 124s55.516 124 124 124 124-55.516 124-124-55.516-124-124-124z" />
|
||||
<glyph unicode="" glyph-name="pastetext" d="M512 448v-128h32l32 64h64v-256h-48v-64h224v64h-48v256h64l32-64h32v128zM832 640v160c0 17.6-14.4 32-32 32h-224v64c0 35.2-28.8 64-64 64h-128c-35.204 0-64-28.8-64-64v-64h-224c-17.602 0-32-14.4-32-32v-640c0-17.6 14.398-32 32-32h288v-192h640v704h-192zM384 895.886c0.034 0.038 0.072 0.078 0.114 0.114h127.768c0.042-0.036 0.082-0.076 0.118-0.114v-63.886h-128v63.886zM192 704v64h512v-64h-512zM960 0h-512v576h512v-576z" />
|
||||
<glyph unicode="" glyph-name="gamma" d="M483.2 320l-147.2 336c-9.6 25.6-19.2 44.8-25.6 54.4s-16 12.8-25.6 12.8c-16 0-25.6-3.2-28.8-3.2v70.4c9.6 6.4 25.6 6.4 38.4 9.6 32 0 57.6-6.4 73.6-22.4 6.4-6.4 12.8-16 19.2-25.6 6.4-12.8 12.8-25.6 16-41.6l121.6-291.2 150.4 371.2h92.8l-198.4-470.4v-224h-86.4v224zM0 960v-1024h1024v1024h-1024zM960 0h-896v896h896v-896z" />
|
||||
<glyph unicode="" glyph-name="orientation" d="M627.2 80h-579.2v396.8h579.2v-396.8zM553.6 406.4h-435.2v-256h435.2v256zM259.2 732.8c176 176 457.6 176 633.6 0s176-457.6 0-633.6c-121.6-121.6-297.6-160-454.4-108.8 121.6-28.8 262.4 9.6 361.6 108.8 150.4 150.4 160 384 22.4 521.6-121.6 121.6-320 128-470.4 19.2l86.4-86.4-294.4-22.4 22.4 294.4 92.8-92.8z" />
|
||||
<glyph unicode="" glyph-name="invert" d="M892.8-22.4l-89.6 89.6c-70.4-80-172.8-131.2-288-131.2-208 0-380.8 166.4-384 377.6 0 0 0 0 0 0 0 3.2 0 3.2 0 6.4s0 3.2 0 6.4v0c0 0 0 0 0 3.2 0 0 0 3.2 0 3.2 3.2 105.6 48 211.2 105.6 304l-192 192 44.8 44.8 182.4-182.4c0 0 0 0 0 0l569.6-569.6c0 0 0 0 0 0l99.2-99.2-48-44.8zM896 326.4c0 0 0 0 0 0 0 3.2 0 6.4 0 6.4-9.6 316.8-384 627.2-384 627.2s-108.8-89.6-208-220.8l70.4-70.4c6.4 9.6 16 22.4 22.4 32 41.6 51.2 83.2 96 115.2 128v0c32-32 73.6-76.8 115.2-128 108.8-137.6 169.6-265.6 172.8-371.2 0 0 0-3.2 0-3.2v0 0c0-3.2 0-3.2 0-6.4s0-3.2 0-3.2v0 0c0-22.4-3.2-41.6-9.6-64l76.8-76.8c16 41.6 28.8 89.6 28.8 137.6 0 0 0 0 0 0 0 3.2 0 3.2 0 6.4s0 3.2 0 6.4z" />
|
||||
<glyph unicode="" glyph-name="codesample" d="M199.995 578.002v104.002c0 43.078 34.923 78.001 78.001 78.001h26v104.002h-26c-100.518 0-182.003-81.485-182.003-182.003v-104.002c0-43.078-34.923-78.001-78.001-78.001h-26v-104.002h26c43.078 0 78.001-34.923 78.001-78.001v-104.002c0-100.515 81.485-182.003 182.003-182.003h26v104.002h-26c-43.078 0-78.001 34.923-78.001 78.001v104.002c0 50.931-20.928 96.966-54.646 130.002 33.716 33.036 54.646 79.072 54.646 130.002zM824.005 578.002v104.002c0 43.078-34.923 78.001-78.001 78.001h-26v104.002h26c100.515 0 182.003-81.485 182.003-182.003v-104.002c0-43.078 34.923-78.001 78.001-78.001h26v-104.002h-26c-43.078 0-78.001-34.923-78.001-78.001v-104.002c0-100.515-81.488-182.003-182.003-182.003h-26v104.002h26c43.078 0 78.001 34.923 78.001 78.001v104.002c0 50.931 20.928 96.966 54.646 130.002-33.716 33.036-54.646 79.072-54.646 130.002zM616.002 603.285c0-57.439-46.562-104.002-104.002-104.002s-104.002 46.562-104.002 104.002c0 57.439 46.562 104.002 104.002 104.002s104.002-46.562 104.002-104.002zM512 448.717c-57.439 0-104.002-46.562-104.002-104.002 0-55.845 26-100.115 105.752-103.88-23.719-33.417-59.441-46.612-105.752-50.944v-61.751c0 0 208.003-18.144 208.003 216.577-0.202 57.441-46.56 104.004-104.002 104.004z" />
|
||||
<glyph unicode="" glyph-name="tablerowprops" d="M0 896v-896h1024v896h-1024zM640 256v-192h-256v192h256zM640 768v-192h-256v192h256zM320 768v-192h-256v192h256zM704 576v192h256v-192h-256zM64 256h256v-192h-256v192zM704 64v192h256v-192h-256z" />
|
||||
<glyph unicode="" glyph-name="tablecellprops" d="M0 896v-896h1024v896h-1024zM640 256v-192h-256v192h256zM640 768v-192h-256v192h256zM320 768v-192h-256v192h256zM64 512h256v-192h-256v192zM704 512h256v-192h-256v192zM704 576v192h256v-192h-256zM64 256h256v-192h-256v192zM704 64v192h256v-192h-256z" />
|
||||
<glyph unicode="" glyph-name="table2" d="M0 896v-832h1024v832h-1024zM320 128h-256v192h256v-192zM320 384h-256v192h256v-192zM640 128h-256v192h256v-192zM640 384h-256v192h256v-192zM960 128h-256v192h256v-192zM960 384h-256v192h256v-192zM960 640h-896v192h896v-192z" />
|
||||
<glyph unicode="" glyph-name="tablemergecells" d="M0 896v-896h1024v896h-1024zM384 64v448h576v-448h-576zM640 768v-192h-256v192h256zM320 768v-192h-256v192h256zM64 512h256v-192h-256v192zM704 576v192h256v-192h-256zM64 256h256v-192h-256v192z" />
|
||||
<glyph unicode="" glyph-name="tableinsertcolbefore" d="M320 188.8v182.4h-182.4v89.6h182.4v182.4h86.4v-182.4h185.6v-89.6h-185.6v-182.4zM0 896v-896h1024v896h-1024zM640 64h-576v704h576v-704zM960 64h-256v192h256v-192zM960 320h-256v192h256v-192zM960 576h-256v192h256v-192z" />
|
||||
<glyph unicode="" glyph-name="tableinsertcolafter" d="M704 643.2v-182.4h182.4v-89.6h-182.4v-182.4h-86.4v182.4h-185.6v89.6h185.6v182.4zM0 896v-896h1024v896h-1024zM320 64h-256v192h256v-192zM320 320h-256v192h256v-192zM320 576h-256v192h256v-192zM960 64h-576v704h576v-704z" />
|
||||
<glyph unicode="" glyph-name="tableinsertrowbefore" d="M691.2 508.8h-144v-144h-70.4v144h-144v67.2h144v144h70.4v-144h144zM0 896v-896h1024v896h-1024zM320 64h-256v192h256v-192zM640 64h-256v192h256v-192zM960 64h-256v192h256v-192zM960 316.8h-896v451.2h896v-451.2z" />
|
||||
<glyph unicode="" glyph-name="tableinsertrowafter" d="M332.8 323.2h144v144h70.4v-144h144v-67.2h-144v-144h-70.4v144h-144zM0 896v-896h1024v896h-1024zM384 768h256v-192h-256v192zM64 768h256v-192h-256v192zM960 64h-896v451.2h896v-451.2zM960 576h-256v192h256v-192z" />
|
||||
<glyph unicode="" glyph-name="tablesplitcells" d="M0 896v-896h1024v896h-1024zM384 768h256v-192h-256v192zM320 64h-256v192h256v-192zM320 320h-256v192h256v-192zM320 576h-256v192h256v-192zM960 64h-576v448h576v-448zM960 576h-256v192h256v-192zM864 156.8l-60.8-60.8-131.2 131.2-131.2-131.2-60.8 60.8 131.2 131.2-131.2 131.2 60.8 60.8 131.2-131.2 131.2 131.2 60.8-60.8-131.2-131.2z" />
|
||||
<glyph unicode="" glyph-name="tabledelete" d="M0 896h1024v-896h-1024v896zM60.8 768v-704h899.2v704h-899.2zM809.6 211.2l-96-96-204.8 204.8-204.8-204.8-96 96 204.8 204.8-204.8 204.8 96 96 204.8-204.8 204.8 204.8 96-96-204.8-204.8z" />
|
||||
<glyph unicode="" glyph-name="tableleftheader" d="M0 896v-832h1024v832h-1024zM640 128h-256v192h256v-192zM640 384h-256v192h256v-192zM640 640h-256v192h256v-192zM960 128h-256v192h256v-192zM960 384h-256v192h256v-192zM960 640h-256v192h256v-192z" />
|
||||
<glyph unicode="" glyph-name="tabletopheader" d="M0 896v-832h1024v832h-1024zM320 128h-256v192h256v-192zM320 384h-256v192h256v-192zM640 128h-256v192h256v-192zM640 384h-256v192h256v-192zM960 128h-256v192h256v-192zM960 384h-256v192h256v-192z" />
|
||||
<glyph unicode="" glyph-name="tabledeleterow" d="M886.4 572.8l-156.8-156.8 160-160-76.8-76.8-160 160-156.8-156.8-76.8 73.6 160 160-163.2 163.2 76.8 76.8 163.2-163.2 156.8 156.8 73.6-76.8zM0 896v-896h1024v896h-1024zM960 576h-22.4l-64-64h86.4v-192h-89.6l64-64h25.6v-192h-896v192h310.4l64 64h-374.4v192h371.2l-64 64h-307.2v192h896v-192z" />
|
||||
<glyph unicode="" glyph-name="tabledeletecol" d="M320 499.2l64-64v-12.8l-64-64v140.8zM640 422.4l64-64v137.6l-64-64v-9.6zM1024 896v-896h-1024v896h1024zM960 768h-256v-51.2l-12.8 12.8-51.2-51.2v89.6h-256v-89.6l-51.2 51.2-12.8-12.8v51.2h-256v-704h256v118.4l35.2-35.2 28.8 28.8v-115.2h256v115.2l48-48 16 16v-83.2h256v707.2zM672 662.4l-156.8-156.8-163.2 163.2-76.8-76.8 163.2-163.2-156.8-156.8 76.8-76.8 156.8 156.8 160-160 76.8 76.8-160 160 156.8 156.8-76.8 76.8z" />
|
||||
<glyph unicode="" glyph-name="editimage" d="M768 416v-352h-640v640h352l128 128h-512c-52.8 0-96-43.2-96-96v-704c0-52.8 43.2-96 96-96h704c52.798 0 96 43.2 96 96v512l-128-128zM864 960l-608-608v-160h160l608 608c0 96-64 160-160 160zM416 320l-48 48 480 480 48-48-480-480z" />
|
||||
<glyph unicode="" glyph-name="drop" d="M864.626 486.838c-65.754 183.44-205.11 348.15-352.626 473.162-147.516-125.012-286.87-289.722-352.626-473.162-40.664-113.436-44.682-236.562 12.584-345.4 65.846-125.14 198.632-205.438 340.042-205.438s274.196 80.298 340.040 205.44c57.27 108.838 53.25 231.962 12.586 345.398zM738.764 201.044c-43.802-83.252-132.812-137.044-226.764-137.044-55.12 0-108.524 18.536-152.112 50.652 13.242-1.724 26.632-2.652 40.112-2.652 117.426 0 228.668 67.214 283.402 171.242 44.878 85.292 40.978 173.848 23.882 244.338 14.558-28.15 26.906-56.198 36.848-83.932 22.606-63.062 40.024-156.34-5.368-242.604z" />
|
||||
<glyph unicode="" glyph-name="rotateleft" d="M607.998 831.986c-212.070 0-383.986-171.916-383.986-383.986h-191.994l246.848-246.848 246.848 246.848h-191.994c0 151.478 122.798 274.276 274.276 274.276 151.48 0 274.276-122.798 274.276-274.276 0-151.48-122.796-274.276-274.276-274.276v-109.71c212.070 0 383.986 171.916 383.986 383.986s-171.916 383.986-383.986 383.986z" />
|
||||
<glyph unicode="" glyph-name="rotateright" d="M416.002 831.986c212.070 0 383.986-171.916 383.986-383.986h191.994l-246.848-246.848-246.848 246.848h191.994c0 151.478-122.798 274.276-274.276 274.276-151.48 0-274.276-122.798-274.276-274.276 0-151.48 122.796-274.276 274.276-274.276v-109.71c-212.070 0-383.986 171.916-383.986 383.986s171.916 383.986 383.986 383.986z" />
|
||||
<glyph unicode="" glyph-name="flipv" d="M0 576h1024v384zM1024 0v384h-1024z" />
|
||||
<glyph unicode="" glyph-name="fliph" d="M576 960v-1024h384zM0-64h384v1024z" />
|
||||
<glyph unicode="" glyph-name="zoomin" d="M992.262 88.604l-242.552 206.294c-25.074 22.566-51.89 32.926-73.552 31.926 57.256 67.068 91.842 154.078 91.842 249.176 0 212.078-171.922 384-384 384-212.076 0-384-171.922-384-384s171.922-384 384-384c95.098 0 182.108 34.586 249.176 91.844-1-21.662 9.36-48.478 31.926-73.552l206.294-242.552c35.322-39.246 93.022-42.554 128.22-7.356s31.892 92.898-7.354 128.22zM384 320c-141.384 0-256 114.616-256 256s114.616 256 256 256 256-114.616 256-256-114.614-256-256-256zM448 768h-128v-128h-128v-128h128v-128h128v128h128v128h-128z" />
|
||||
<glyph unicode="" glyph-name="zoomout" d="M992.262 88.604l-242.552 206.294c-25.074 22.566-51.89 32.926-73.552 31.926 57.256 67.068 91.842 154.078 91.842 249.176 0 212.078-171.922 384-384 384-212.076 0-384-171.922-384-384s171.922-384 384-384c95.098 0 182.108 34.586 249.176 91.844-1-21.662 9.36-48.478 31.926-73.552l206.294-242.552c35.322-39.246 93.022-42.554 128.22-7.356s31.892 92.898-7.354 128.22zM384 320c-141.384 0-256 114.616-256 256s114.616 256 256 256 256-114.616 256-256-114.614-256-256-256zM192 640h384v-128h-384z" />
|
||||
<glyph unicode="" glyph-name="sharpen" d="M768 832h-512l-256-256 512-576 512 576-256 256zM512 181.334v2.666h-2.37l-14.222 16h16.592v16h-30.814l-14.222 16h45.036v16h-59.258l-14.222 16h73.48v16h-87.704l-14.222 16h101.926v16h-116.148l-14.222 16h130.37v16h-144.592l-14.222 16h158.814v16h-173.038l-14.222 16h187.26v16h-201.482l-14.222 16h215.704v16h-229.926l-14.222 16h244.148v16h-258.372l-14.222 16h272.594v16h-286.816l-14.222 16h301.038v16h-315.26l-14.222 16h329.482v16h-343.706l-7.344 8.262 139.072 139.072h211.978v-3.334h215.314l16-16h-231.314v-16h247.314l16-16h-263.314v-16h279.314l16-16h-295.314v-16h311.314l16-16h-327.314v-16h343.312l7.738-7.738-351.050-394.928z" />
|
||||
<glyph unicode="" glyph-name="options" d="M64 768h896v-192h-896zM64 512h896v-192h-896zM64 256h896v-192h-896z" />
|
||||
<glyph unicode="" glyph-name="sun" d="M512 128c35.346 0 64-28.654 64-64v-64c0-35.346-28.654-64-64-64s-64 28.654-64 64v64c0 35.346 28.654 64 64 64zM512 768c-35.346 0-64 28.654-64 64v64c0 35.346 28.654 64 64 64s64-28.654 64-64v-64c0-35.346-28.654-64-64-64zM960 512c35.346 0 64-28.654 64-64s-28.654-64-64-64h-64c-35.348 0-64 28.654-64 64s28.652 64 64 64h64zM192 448c0-35.346-28.654-64-64-64h-64c-35.346 0-64 28.654-64 64s28.654 64 64 64h64c35.346 0 64-28.654 64-64zM828.784 221.726l45.256-45.258c24.992-24.99 24.992-65.516 0-90.508-24.994-24.992-65.518-24.992-90.51 0l-45.256 45.256c-24.992 24.99-24.992 65.516 0 90.51 24.994 24.992 65.518 24.992 90.51 0zM195.216 674.274l-45.256 45.256c-24.994 24.994-24.994 65.516 0 90.51s65.516 24.994 90.51 0l45.256-45.256c24.994-24.994 24.994-65.516 0-90.51s-65.516-24.994-90.51 0zM828.784 674.274c-24.992-24.992-65.516-24.992-90.51 0-24.992 24.994-24.992 65.516 0 90.51l45.256 45.254c24.992 24.994 65.516 24.994 90.51 0 24.992-24.994 24.992-65.516 0-90.51l-45.256-45.254zM195.216 221.726c24.992 24.992 65.518 24.992 90.508 0 24.994-24.994 24.994-65.52 0-90.51l-45.254-45.256c-24.994-24.992-65.516-24.992-90.51 0s-24.994 65.518 0 90.508l45.256 45.258zM512 704c-141.384 0-256-114.616-256-256 0-141.382 114.616-256 256-256 141.382 0 256 114.618 256 256 0 141.384-114.616 256-256 256zM512 288c-88.366 0-160 71.634-160 160s71.634 160 160 160 160-71.634 160-160-71.634-160-160-160z" />
|
||||
<glyph unicode="" glyph-name="moon" d="M715.812 895.52c-60.25 34.784-124.618 55.904-189.572 64.48 122.936-160.082 144.768-384.762 37.574-570.42-107.2-185.67-312.688-279.112-512.788-252.68 39.898-51.958 90.376-97.146 150.628-131.934 245.908-141.974 560.37-57.72 702.344 188.198 141.988 245.924 57.732 560.372-188.186 702.356z" />
|
||||
<glyph unicode="" glyph-name="contrast" d="M512 960c-282.77 0-512-229.23-512-512s229.23-512 512-512 512 229.23 512 512-229.23 512-512 512zM128 448c0 212.078 171.922 384 384 384v-768c-212.078 0-384 171.922-384 384z" />
|
||||
<glyph unicode="" glyph-name="cross2" d="M893.254 738.746l-90.508 90.508-290.746-290.744-290.746 290.744-90.508-90.506 290.746-290.748-290.746-290.746 90.508-90.508 290.746 290.746 290.746-290.746 90.508 90.51-290.744 290.744z" />
|
||||
<glyph unicode="" glyph-name="arrowleft" d="M672-64l192 192-320 320 320 320-192 192-512-512z" />
|
||||
<glyph unicode="" glyph-name="arrow-resize2" d="M0 896v-384c0-35.346 28.654-64 64-64s64 28.654 64 64v229.488l677.488-677.488h-229.488c-35.346 0-64-28.652-64-64 0-35.346 28.654-64 64-64h384c35.346 0 64 28.654 64 64v384c0 35.348-28.654 64-64 64s-64-28.652-64-64v-229.488l-677.488 677.488h229.488c35.346 0 64 28.654 64 64s-28.652 64-64 64h-384c-35.346 0-64-28.654-64-64z" />
|
||||
<glyph unicode="" glyph-name="crop" d="M832 704l192 192-64 64-192-192h-448v192h-128v-192h-192v-128h192v-512h512v-192h128v192h192v128h-192v448zM320 640h320l-320-320v320zM384 256l320 320v-320h-320z" />
|
||||
</font></defs></svg>
|
||||
|
Before Width: | Height: | Size: 29 KiB After Width: | Height: | Size: 36 KiB |
Binary file not shown.
Binary file not shown.
File diff suppressed because one or more lines are too long
+1
-1
File diff suppressed because one or more lines are too long
@@ -12,7 +12,7 @@
|
||||
|
||||
tinymce.ThemeManager.add('modern', function(editor) {
|
||||
var self = this, settings = editor.settings, Factory = tinymce.ui.Factory,
|
||||
each = tinymce.each, DOM = tinymce.DOM, Rect = tinymce.ui.Rect, FloatPanel = tinymce.ui.FloatPanel;
|
||||
each = tinymce.each, DOM = tinymce.DOM, Rect = tinymce.geom.Rect, FloatPanel = tinymce.ui.FloatPanel;
|
||||
|
||||
// Default menus
|
||||
var defaultMenus = {
|
||||
@@ -416,13 +416,18 @@ tinymce.ThemeManager.add('modern', function(editor) {
|
||||
panelRect = tinymce.DOM.getRect(panel.getEl());
|
||||
contentAreaRect = tinymce.DOM.getRect(editor.getContentAreaContainer() || editor.getBody());
|
||||
|
||||
// We need to use these instead of the rect values since the style
|
||||
// size properites might not be the same as the real size for a table
|
||||
elementRect.w = match.element.clientWidth;
|
||||
elementRect.h = match.element.clientHeight;
|
||||
|
||||
if (!editor.inline) {
|
||||
contentAreaRect.w = editor.getDoc().documentElement.offsetWidth;
|
||||
}
|
||||
|
||||
// Inflate the elementRect so it doesn't get placed above resize handles
|
||||
if (editor.selection.controlSelection.isResizable(match.element)) {
|
||||
elementRect = Rect.inflate(elementRect, 0, 7);
|
||||
elementRect = Rect.inflate(elementRect, 0, 8);
|
||||
}
|
||||
|
||||
relPos = Rect.findBestRelativePosition(panelRect, elementRect, contentAreaRect, testPositions);
|
||||
@@ -471,11 +476,7 @@ tinymce.ThemeManager.add('modern', function(editor) {
|
||||
}
|
||||
}
|
||||
|
||||
if (window.requestAnimationFrame) {
|
||||
window.requestAnimationFrame(execute);
|
||||
} else {
|
||||
execute();
|
||||
}
|
||||
tinymce.util.Delay.requestAnimationFrame(execute);
|
||||
}
|
||||
|
||||
function bindScrollEvent() {
|
||||
@@ -545,22 +546,24 @@ tinymce.ThemeManager.add('modern', function(editor) {
|
||||
return null;
|
||||
}
|
||||
|
||||
editor.on('click keyup', function() {
|
||||
// Needs to be delayed to avoid Chrome img focus out bug
|
||||
window.setTimeout(function() {
|
||||
var match;
|
||||
editor.on('click keyup setContent', function(e) {
|
||||
// Only act on partial inserts
|
||||
if (e.type == 'setcontent' && !e.selection) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (editor.removed) {
|
||||
return;
|
||||
}
|
||||
// Needs to be delayed to avoid Chrome img focus out bug
|
||||
tinymce.util.Delay.setEditorTimeout(editor, function() {
|
||||
var match;
|
||||
|
||||
match = findFrontMostMatch(editor.selection.getNode());
|
||||
if (match) {
|
||||
hideAllContextToolbars();
|
||||
showContextToolbar(match);
|
||||
} else {
|
||||
hideAllContextToolbars();
|
||||
}
|
||||
}, 0);
|
||||
});
|
||||
});
|
||||
|
||||
editor.on('blur hide', hideAllContextToolbars);
|
||||
@@ -721,6 +724,16 @@ tinymce.ThemeManager.add('modern', function(editor) {
|
||||
function renderIframeUI(args) {
|
||||
var panel, resizeHandleCtrl, startSize;
|
||||
|
||||
function switchMode() {
|
||||
return function(e) {
|
||||
if (e.mode == 'readonly') {
|
||||
panel.find('*').disabled(true);
|
||||
} else {
|
||||
panel.find('*').disabled(false);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
if (args.skinUiCss) {
|
||||
tinymce.DOM.loadCSS(args.skinUiCss);
|
||||
}
|
||||
@@ -777,6 +790,7 @@ tinymce.ThemeManager.add('modern', function(editor) {
|
||||
}
|
||||
|
||||
editor.fire('BeforeRenderUI');
|
||||
editor.on('SwitchMode', switchMode());
|
||||
panel.renderBefore(args.targetNode).reflow();
|
||||
|
||||
if (settings.width) {
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
+5537
-1026
File diff suppressed because it is too large
Load Diff
+13
-12
File diff suppressed because one or more lines are too long
@@ -18,7 +18,7 @@ $wp_db_version = 36180;
|
||||
*
|
||||
* @global string $tinymce_version
|
||||
*/
|
||||
$tinymce_version = '4208-20151113';
|
||||
$tinymce_version = '4303-20160119';
|
||||
|
||||
/**
|
||||
* Holds the required PHP version
|
||||
|
||||
@@ -1,543 +1,48 @@
|
||||
/**
|
||||
* plugin.js
|
||||
*
|
||||
* Copyright, Moxiecode Systems AB
|
||||
* Released under LGPL License.
|
||||
* Copyright (c) 1999-2015 Ephox Corp. All rights reserved
|
||||
*
|
||||
* License: http://www.tinymce.com/license
|
||||
* Contributing: http://www.tinymce.com/contributing
|
||||
*/
|
||||
|
||||
/*jshint loopfunc:true */
|
||||
/*eslint no-loop-func:0 */
|
||||
/*global tinymce:true */
|
||||
|
||||
tinymce.PluginManager.add('noneditable', function(editor) {
|
||||
var TreeWalker = tinymce.dom.TreeWalker;
|
||||
var externalName = 'contenteditable', internalName = 'data-mce-' + externalName;
|
||||
var VK = tinymce.util.VK;
|
||||
var editClass, nonEditClass, nonEditableRegExps, contentEditableAttrName = 'contenteditable';
|
||||
|
||||
// Returns the content editable state of a node "true/false" or null
|
||||
function getContentEditable(node) {
|
||||
var contentEditable;
|
||||
|
||||
// Ignore non elements
|
||||
if (node.nodeType === 1) {
|
||||
// Check for fake content editable
|
||||
contentEditable = node.getAttribute(internalName);
|
||||
if (contentEditable && contentEditable !== "inherit") {
|
||||
return contentEditable;
|
||||
}
|
||||
|
||||
// Check for real content editable
|
||||
contentEditable = node.contentEditable;
|
||||
if (contentEditable !== "inherit") {
|
||||
return contentEditable;
|
||||
}
|
||||
}
|
||||
|
||||
return null;
|
||||
function hasClass(checkClassName) {
|
||||
return function(node) {
|
||||
return (" " + node.attr("class") + " ").indexOf(checkClassName) !== -1;
|
||||
};
|
||||
}
|
||||
|
||||
// Returns the noneditable parent or null if there is a editable before it or if it wasn't found
|
||||
function getNonEditableParent(node) {
|
||||
var state;
|
||||
|
||||
while (node) {
|
||||
state = getContentEditable(node);
|
||||
if (state) {
|
||||
return state === "false" ? node : null;
|
||||
}
|
||||
|
||||
node = node.parentNode;
|
||||
}
|
||||
}
|
||||
|
||||
function handleContentEditableSelection() {
|
||||
var dom = editor.dom, selection = editor.selection, caretContainerId = 'mce_noneditablecaret', invisibleChar = '\uFEFF';
|
||||
|
||||
// Get caret container parent for the specified node
|
||||
function getParentCaretContainer(node) {
|
||||
while (node) {
|
||||
if (node.id === caretContainerId) {
|
||||
return node;
|
||||
}
|
||||
|
||||
node = node.parentNode;
|
||||
}
|
||||
}
|
||||
|
||||
// Finds the first text node in the specified node
|
||||
function findFirstTextNode(node) {
|
||||
var walker;
|
||||
|
||||
if (node) {
|
||||
walker = new TreeWalker(node, node);
|
||||
|
||||
for (node = walker.current(); node; node = walker.next()) {
|
||||
if (node.nodeType === 3) {
|
||||
return node;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Insert caret container before/after target or expand selection to include block
|
||||
function insertCaretContainerOrExpandToBlock(target, before) {
|
||||
var caretContainer, rng;
|
||||
|
||||
// Select block
|
||||
if (getContentEditable(target) === "false") {
|
||||
if (dom.isBlock(target)) {
|
||||
selection.select(target);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
rng = dom.createRng();
|
||||
|
||||
if (getContentEditable(target) === "true") {
|
||||
if (!target.firstChild) {
|
||||
target.appendChild(editor.getDoc().createTextNode('\u00a0'));
|
||||
}
|
||||
|
||||
target = target.firstChild;
|
||||
before = true;
|
||||
}
|
||||
|
||||
/*
|
||||
caretContainer = dom.create('span', {
|
||||
id: caretContainerId,
|
||||
'data-mce-bogus': true,
|
||||
style:'border: 1px solid red'
|
||||
}, invisibleChar);
|
||||
*/
|
||||
|
||||
caretContainer = dom.create('span', {id: caretContainerId, 'data-mce-bogus': true}, invisibleChar);
|
||||
|
||||
if (before) {
|
||||
target.parentNode.insertBefore(caretContainer, target);
|
||||
} else {
|
||||
dom.insertAfter(caretContainer, target);
|
||||
}
|
||||
|
||||
rng.setStart(caretContainer.firstChild, 1);
|
||||
rng.collapse(true);
|
||||
selection.setRng(rng);
|
||||
|
||||
return caretContainer;
|
||||
}
|
||||
|
||||
// Removes any caret container
|
||||
function removeCaretContainer(caretContainer) {
|
||||
var rng, child, lastContainer;
|
||||
|
||||
if (caretContainer) {
|
||||
rng = selection.getRng(true);
|
||||
rng.setStartBefore(caretContainer);
|
||||
rng.setEndBefore(caretContainer);
|
||||
|
||||
child = findFirstTextNode(caretContainer);
|
||||
if (child && child.nodeValue.charAt(0) == invisibleChar) {
|
||||
child = child.deleteData(0, 1);
|
||||
}
|
||||
|
||||
dom.remove(caretContainer, true);
|
||||
|
||||
selection.setRng(rng);
|
||||
} else {
|
||||
while ((caretContainer = dom.get(caretContainerId)) && caretContainer !== lastContainer) {
|
||||
child = findFirstTextNode(caretContainer);
|
||||
if (child && child.nodeValue.charAt(0) == invisibleChar) {
|
||||
child = child.deleteData(0, 1);
|
||||
}
|
||||
|
||||
dom.remove(caretContainer, true);
|
||||
|
||||
lastContainer = caretContainer;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Modifies the selection to include contentEditable false elements or insert caret containers
|
||||
function moveSelection() {
|
||||
var nonEditableStart, nonEditableEnd, isCollapsed, rng, element;
|
||||
|
||||
// Checks if there is any contents to the left/right side of caret returns the noneditable element or
|
||||
// any editable element if it finds one inside
|
||||
function hasSideContent(element, left) {
|
||||
var container, offset, walker, node, len;
|
||||
|
||||
container = rng.startContainer;
|
||||
offset = rng.startOffset;
|
||||
|
||||
// If endpoint is in middle of text node then expand to beginning/end of element
|
||||
if (container.nodeType == 3) {
|
||||
len = container.nodeValue.length;
|
||||
if ((offset > 0 && offset < len) || (left ? offset == len : offset === 0)) {
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
// Can we resolve the node by index
|
||||
if (offset < container.childNodes.length) {
|
||||
// Browser represents caret position as the offset at the start of an element. When moving right
|
||||
// this is the element we are moving into so we consider our container to be child node at offset-1
|
||||
var pos = !left && offset > 0 ? offset - 1 : offset;
|
||||
container = container.childNodes[pos];
|
||||
if (container.hasChildNodes()) {
|
||||
container = container.firstChild;
|
||||
}
|
||||
} else {
|
||||
// If not then the caret is at the last position in it's container and the caret container
|
||||
// should be inserted after the noneditable element
|
||||
return !left ? element : null;
|
||||
}
|
||||
}
|
||||
|
||||
// Walk left/right to look for contents
|
||||
walker = new TreeWalker(container, element);
|
||||
while ((node = walker[left ? 'prev' : 'next']())) {
|
||||
if (node.nodeType === 3 && node.nodeValue.length > 0) {
|
||||
return;
|
||||
} else if (getContentEditable(node) === "true") {
|
||||
// Found contentEditable=true element return this one to we can move the caret inside it
|
||||
return node;
|
||||
}
|
||||
}
|
||||
|
||||
return element;
|
||||
}
|
||||
|
||||
// Remove any existing caret containers
|
||||
removeCaretContainer();
|
||||
|
||||
// Get noneditable start/end elements
|
||||
isCollapsed = selection.isCollapsed();
|
||||
nonEditableStart = getNonEditableParent(selection.getStart());
|
||||
nonEditableEnd = getNonEditableParent(selection.getEnd());
|
||||
|
||||
// Is any fo the range endpoints noneditable
|
||||
if (nonEditableStart || nonEditableEnd) {
|
||||
rng = selection.getRng(true);
|
||||
|
||||
// If it's a caret selection then look left/right to see if we need to move the caret out side or expand
|
||||
if (isCollapsed) {
|
||||
nonEditableStart = nonEditableStart || nonEditableEnd;
|
||||
|
||||
if ((element = hasSideContent(nonEditableStart, true))) {
|
||||
// We have no contents to the left of the caret then insert a caret container before the noneditable element
|
||||
insertCaretContainerOrExpandToBlock(element, true);
|
||||
} else if ((element = hasSideContent(nonEditableStart, false))) {
|
||||
// We have no contents to the right of the caret then insert a caret container after the noneditable element
|
||||
insertCaretContainerOrExpandToBlock(element, false);
|
||||
} else {
|
||||
// We are in the middle of a noneditable so expand to select it
|
||||
selection.select(nonEditableStart);
|
||||
}
|
||||
} else {
|
||||
rng = selection.getRng(true);
|
||||
|
||||
// Expand selection to include start non editable element
|
||||
if (nonEditableStart) {
|
||||
rng.setStartBefore(nonEditableStart);
|
||||
}
|
||||
|
||||
// Expand selection to include end non editable element
|
||||
if (nonEditableEnd) {
|
||||
rng.setEndAfter(nonEditableEnd);
|
||||
}
|
||||
|
||||
selection.setRng(rng);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function handleKey(e) {
|
||||
var keyCode = e.keyCode, nonEditableParent, caretContainer, startElement, endElement;
|
||||
|
||||
function getNonEmptyTextNodeSibling(node, prev) {
|
||||
while ((node = node[prev ? 'previousSibling' : 'nextSibling'])) {
|
||||
if (node.nodeType !== 3 || node.nodeValue.length > 0) {
|
||||
return node;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function positionCaretOnElement(element, start) {
|
||||
selection.select(element);
|
||||
selection.collapse(start);
|
||||
}
|
||||
|
||||
function canDelete(backspace) {
|
||||
var rng, container, offset, nonEditableParent;
|
||||
|
||||
function removeNodeIfNotParent(node) {
|
||||
var parent = container;
|
||||
|
||||
while (parent) {
|
||||
if (parent === node) {
|
||||
return;
|
||||
}
|
||||
|
||||
parent = parent.parentNode;
|
||||
}
|
||||
|
||||
dom.remove(node);
|
||||
moveSelection();
|
||||
}
|
||||
|
||||
function isNextPrevTreeNodeNonEditable() {
|
||||
var node, walker, nonEmptyElements = editor.schema.getNonEmptyElements();
|
||||
|
||||
walker = new tinymce.dom.TreeWalker(container, editor.getBody());
|
||||
while ((node = (backspace ? walker.prev() : walker.next()))) {
|
||||
// Found IMG/INPUT etc
|
||||
if (nonEmptyElements[node.nodeName.toLowerCase()]) {
|
||||
break;
|
||||
}
|
||||
|
||||
// Found text node with contents
|
||||
if (node.nodeType === 3 && tinymce.trim(node.nodeValue).length > 0) {
|
||||
break;
|
||||
}
|
||||
|
||||
// Found non editable node
|
||||
if (getContentEditable(node) === "false") {
|
||||
removeNodeIfNotParent(node);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
// Check if the content node is within a non editable parent
|
||||
if (getNonEditableParent(node)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
if (selection.isCollapsed()) {
|
||||
rng = selection.getRng(true);
|
||||
container = rng.startContainer;
|
||||
offset = rng.startOffset;
|
||||
container = getParentCaretContainer(container) || container;
|
||||
|
||||
// Is in noneditable parent
|
||||
if ((nonEditableParent = getNonEditableParent(container))) {
|
||||
removeNodeIfNotParent(nonEditableParent);
|
||||
return false;
|
||||
}
|
||||
|
||||
// Check if the caret is in the middle of a text node
|
||||
if (container.nodeType == 3 && (backspace ? offset > 0 : offset < container.nodeValue.length)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
// Resolve container index
|
||||
if (container.nodeType == 1) {
|
||||
container = container.childNodes[offset] || container;
|
||||
}
|
||||
|
||||
// Check if previous or next tree node is non editable then block the event
|
||||
if (isNextPrevTreeNodeNonEditable()) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
moveSelection();
|
||||
|
||||
startElement = selection.getStart();
|
||||
endElement = selection.getEnd();
|
||||
|
||||
// Disable all key presses in contentEditable=false except delete or backspace
|
||||
nonEditableParent = getNonEditableParent(startElement) || getNonEditableParent(endElement);
|
||||
var currentNode = editor.selection.getNode();
|
||||
|
||||
var isDirectionKey = keyCode == VK.LEFT || keyCode == VK.RIGHT || keyCode == VK.UP || keyCode == VK.DOWN;
|
||||
var left = keyCode == VK.LEFT || keyCode == VK.UP;
|
||||
|
||||
if (nonEditableParent && (keyCode < 112 || keyCode > 124) && keyCode != VK.DELETE && keyCode != VK.BACKSPACE) {
|
||||
|
||||
// Is Ctrl+c, Ctrl+v or Ctrl+x then use default browser behavior
|
||||
if ((tinymce.isMac ? e.metaKey : e.ctrlKey) && (keyCode == 67 || keyCode == 88 || keyCode == 86)) {
|
||||
return;
|
||||
}
|
||||
|
||||
e.preventDefault();
|
||||
|
||||
// Arrow left/right select the element and collapse left/right
|
||||
if (isDirectionKey) {
|
||||
|
||||
// If a block element find previous or next element to position the caret
|
||||
if (editor.dom.isBlock(nonEditableParent)) {
|
||||
var targetElement = left ? nonEditableParent.previousSibling : nonEditableParent.nextSibling;
|
||||
|
||||
// Handling for edge-cases:
|
||||
// - two nonEditables in a row -> no way to get between them
|
||||
// - nonEditable as the first/last element -> no way to get before/behind it
|
||||
if (!targetElement || targetElement && getContentEditable(targetElement) === 'false') {
|
||||
var p = dom.create('p', null, ' ');
|
||||
p.className = 'mceTmpParagraph';
|
||||
|
||||
var insertElement = left ? nonEditableParent : targetElement;
|
||||
|
||||
if (insertElement && insertElement.parentNode) {
|
||||
insertElement.parentNode.insertBefore(p, insertElement);
|
||||
} else if (!targetElement && !left) {
|
||||
nonEditableParent.parentNode.appendChild(p);
|
||||
}
|
||||
|
||||
targetElement = p;
|
||||
}
|
||||
|
||||
var walker = new TreeWalker(targetElement, targetElement);
|
||||
var caretElement = left ? walker.prev() : walker.next();
|
||||
|
||||
positionCaretOnElement(caretElement, !left);
|
||||
} else {
|
||||
positionCaretOnElement(nonEditableParent, left);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
// Is arrow left/right, backspace or delete
|
||||
if (isDirectionKey || keyCode == VK.BACKSPACE || keyCode == VK.DELETE) {
|
||||
caretContainer = getParentCaretContainer(startElement);
|
||||
|
||||
if (caretContainer) {
|
||||
// Arrow left or backspace
|
||||
if (keyCode == VK.LEFT || keyCode == VK.BACKSPACE) {
|
||||
nonEditableParent = getNonEmptyTextNodeSibling(caretContainer, true);
|
||||
|
||||
if (nonEditableParent && getContentEditable(nonEditableParent) === "false") {
|
||||
e.preventDefault();
|
||||
|
||||
if (keyCode == VK.LEFT) {
|
||||
positionCaretOnElement(nonEditableParent, true);
|
||||
} else {
|
||||
dom.remove(nonEditableParent);
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
removeCaretContainer(caretContainer);
|
||||
}
|
||||
}
|
||||
|
||||
// Arrow right or delete
|
||||
if (keyCode == VK.RIGHT || keyCode == VK.DELETE) {
|
||||
nonEditableParent = getNonEmptyTextNodeSibling(caretContainer, true);
|
||||
|
||||
if (nonEditableParent && getContentEditable(nonEditableParent) === "false") {
|
||||
e.preventDefault();
|
||||
|
||||
if (keyCode == VK.RIGHT) {
|
||||
positionCaretOnElement(nonEditableParent, false);
|
||||
} else {
|
||||
dom.remove(nonEditableParent);
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
removeCaretContainer(caretContainer);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
|
||||
if (isDirectionKey) {
|
||||
// Removal of separator paragraphs between two nonEditables
|
||||
// and before/after a nonEditable as the first/last element
|
||||
if (currentNode && currentNode.className.indexOf('mceTmpParagraph') !== -1 &&
|
||||
currentNode[left ? 'previousSibling' : 'nextSibling']) {
|
||||
var jumpTarget = currentNode[left ? 'previousSibling' : 'nextSibling'];
|
||||
|
||||
// current node is still empty and a separator -> remove it
|
||||
// else: remove the separator class, as it now includes content
|
||||
if (currentNode.innerHTML === ' ' || currentNode.innerHTML === '' || currentNode.innerHTML === ' ') {
|
||||
dom.remove(currentNode);
|
||||
} else {
|
||||
currentNode.className = currentNode.className.replace('mceTmpParagraph', '');
|
||||
}
|
||||
|
||||
positionCaretOnElement(jumpTarget, !left);
|
||||
}
|
||||
}
|
||||
|
||||
var rng = selection.getRng(true);
|
||||
var container = rng.endContainer;
|
||||
|
||||
// FIX: If end of node is selected, check wether next sibling is nonEditable to correctly remove it
|
||||
// (else would break for more complex nonEditables, their content would get moved to the current node)
|
||||
if (dom.isBlock(container) && dom.isBlock(container.nextSibling) && rng.endOffset == 1 && keyCode == VK.DELETE) {
|
||||
nonEditableParent = getNonEditableParent(container.nextSibling);
|
||||
}
|
||||
|
||||
// correctly remove block-level nonEditable domNode on delete/backspace
|
||||
if (nonEditableParent && (keyCode == VK.DELETE || keyCode == VK.BACKSPACE) && dom.isBlock(nonEditableParent)) {
|
||||
e.preventDefault();
|
||||
dom.remove(nonEditableParent);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if ((keyCode == VK.BACKSPACE || keyCode == VK.DELETE) && !canDelete(keyCode == VK.BACKSPACE)) {
|
||||
e.preventDefault();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
editor.on('mousedown', function(e) {
|
||||
var node = editor.selection.getNode();
|
||||
|
||||
// Also remove separator lines when clicking on another node
|
||||
if (node && node.className.indexOf('mceTmpParagraph') !== -1 && node !== e.target) {
|
||||
// current node is still empty and a separator -> remove it
|
||||
// else: remove the separator class, as it now includes content
|
||||
if (node.innerHTML === ' ' || node.innerHTML === '' || node.innerHTML === ' ') {
|
||||
dom.remove(node);
|
||||
} else {
|
||||
node.className = node.className.replace('mceTmpParagraph', '');
|
||||
}
|
||||
}
|
||||
|
||||
if (getContentEditable(node) === "false" && node == e.target) {
|
||||
// Expand selection on mouse down we can't block the default event since it's used for drag/drop
|
||||
moveSelection();
|
||||
}
|
||||
});
|
||||
|
||||
editor.on('mouseup', moveSelection);
|
||||
|
||||
editor.on('keydown', handleKey);
|
||||
}
|
||||
|
||||
var editClass, nonEditClass, nonEditableRegExps;
|
||||
|
||||
// Converts configured regexps to noneditable span items
|
||||
function convertRegExpsToNonEditable(e) {
|
||||
var i = nonEditableRegExps.length, content = e.content, cls = tinymce.trim(nonEditClass);
|
||||
|
||||
function replaceMatchWithSpan(match) {
|
||||
var args = arguments, index = args[args.length - 2];
|
||||
|
||||
// Is value inside an attribute then don't replace
|
||||
if (index > 0 && content.charAt(index - 1) == '"') {
|
||||
return match;
|
||||
}
|
||||
|
||||
return (
|
||||
'<span class="' + cls + '" data-mce-content="' + editor.dom.encode(args[0]) + '">' +
|
||||
editor.dom.encode(typeof args[1] === "string" ? args[1] : args[0]) + '</span>'
|
||||
);
|
||||
}
|
||||
|
||||
// Don't replace the variables when raw is used for example on undo/redo
|
||||
if (e.format == "raw") {
|
||||
return;
|
||||
}
|
||||
|
||||
while (i--) {
|
||||
content = content.replace(nonEditableRegExps[i], function(match) {
|
||||
var args = arguments, index = args[args.length - 2];
|
||||
|
||||
// Is value inside an attribute then don't replace
|
||||
if (index > 0 && content.charAt(index - 1) == '"') {
|
||||
return match;
|
||||
}
|
||||
|
||||
return (
|
||||
'<span class="' + cls + '" data-mce-content="' + editor.dom.encode(args[0]) + '">' +
|
||||
editor.dom.encode(typeof args[1] === "string" ? args[1] : args[0]) + '</span>'
|
||||
);
|
||||
});
|
||||
content = content.replace(nonEditableRegExps[i], replaceMatchWithSpan);
|
||||
}
|
||||
|
||||
e.content = content;
|
||||
@@ -546,69 +51,51 @@ tinymce.PluginManager.add('noneditable', function(editor) {
|
||||
editClass = " " + tinymce.trim(editor.getParam("noneditable_editable_class", "mceEditable")) + " ";
|
||||
nonEditClass = " " + tinymce.trim(editor.getParam("noneditable_noneditable_class", "mceNonEditable")) + " ";
|
||||
|
||||
// Setup noneditable regexps array
|
||||
var hasEditClass = hasClass(editClass);
|
||||
var hasNonEditClass = hasClass(nonEditClass);
|
||||
|
||||
nonEditableRegExps = editor.getParam("noneditable_regexp");
|
||||
if (nonEditableRegExps && !nonEditableRegExps.length) {
|
||||
nonEditableRegExps = [nonEditableRegExps];
|
||||
}
|
||||
|
||||
editor.on('PreInit', function() {
|
||||
handleContentEditableSelection();
|
||||
|
||||
if (nonEditableRegExps) {
|
||||
editor.on('BeforeSetContent', convertRegExpsToNonEditable);
|
||||
}
|
||||
|
||||
// Apply contentEditable true/false on elements with the noneditable/editable classes
|
||||
editor.parser.addAttributeFilter('class', function(nodes) {
|
||||
var i = nodes.length, className, node;
|
||||
|
||||
while (i--) {
|
||||
node = nodes[i];
|
||||
className = " " + node.attr("class") + " ";
|
||||
|
||||
if (className.indexOf(editClass) !== -1) {
|
||||
node.attr(internalName, "true");
|
||||
} else if (className.indexOf(nonEditClass) !== -1) {
|
||||
node.attr(internalName, "false");
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
// Remove internal name
|
||||
editor.serializer.addAttributeFilter(internalName, function(nodes) {
|
||||
var i = nodes.length, node;
|
||||
|
||||
while (i--) {
|
||||
node = nodes[i];
|
||||
|
||||
if (hasEditClass(node)) {
|
||||
node.attr(contentEditableAttrName, "true");
|
||||
} else if (hasNonEditClass(node)) {
|
||||
node.attr(contentEditableAttrName, "false");
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
editor.serializer.addAttributeFilter(contentEditableAttrName, function(nodes) {
|
||||
var i = nodes.length, node;
|
||||
|
||||
while (i--) {
|
||||
node = nodes[i];
|
||||
if (!hasEditClass(node) && !hasNonEditClass(node)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (nonEditableRegExps && node.attr('data-mce-content')) {
|
||||
node.name = "#text";
|
||||
node.type = 3;
|
||||
node.raw = true;
|
||||
node.value = node.attr('data-mce-content');
|
||||
} else {
|
||||
node.attr(externalName, null);
|
||||
node.attr(internalName, null);
|
||||
node.attr(contentEditableAttrName, null);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
// Convert external name into internal name
|
||||
editor.parser.addAttributeFilter(externalName, function(nodes) {
|
||||
var i = nodes.length, node;
|
||||
|
||||
while (i--) {
|
||||
node = nodes[i];
|
||||
node.attr(internalName, node.attr(externalName));
|
||||
node.attr(externalName, null);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
editor.on('drop', function(e) {
|
||||
if (getNonEditableParent(e.target)) {
|
||||
e.preventDefault();
|
||||
}
|
||||
});
|
||||
});
|
||||
File diff suppressed because one or more lines are too long
@@ -20,7 +20,7 @@
|
||||
<script src="../../../src/wp-includes/js/jquery/jquery.js"></script>
|
||||
<script src="js/module_loader.js"></script>
|
||||
<script src="js/qunit/qunit.js"></script>
|
||||
<script src="../../../build/wp-includes/js/tinymce/tinymce.min.js"></script>
|
||||
<script src="js/tinymce_loader.js"></script>
|
||||
<!--<script src="../js/tinymce/classes/jquery.tinymce.js"></script> -->
|
||||
<script src="js/utils.js"></script>
|
||||
<script src="js/init.js"></script>
|
||||
@@ -28,20 +28,34 @@
|
||||
<!-- tinymce.data.* -->
|
||||
<script src="tinymce/data/ObservableObject.js"></script>
|
||||
|
||||
<!-- tinymce.caret.* -->
|
||||
<script src="tinymce/caret/CaretBookmark.js"></script>
|
||||
<script src="tinymce/caret/CaretCandidate.js"></script>
|
||||
<script src="tinymce/caret/CaretContainer.js"></script>
|
||||
<script src="tinymce/caret/CaretPosition.js"></script>
|
||||
<script src="tinymce/caret/CaretUtils.js"></script>
|
||||
<script src="tinymce/caret/CaretWalker.js"></script>
|
||||
<script src="tinymce/caret/FakeCaret.js"></script>
|
||||
<script src="tinymce/caret/LineUtils.js"></script>
|
||||
<script src="tinymce/caret/LineWalker.js"></script>
|
||||
|
||||
<!-- tinymce.geom.* -->
|
||||
<script src="tinymce/geom/Rect.js"></script>
|
||||
<script src="tinymce/geom/ClientRect.js"></script>
|
||||
|
||||
<!-- tinymce.file.* -->
|
||||
<script src="tinymce/file/Conversions.js"></script>
|
||||
<script src="tinymce/file/ImageScanner.js"></script>
|
||||
|
||||
<script>
|
||||
var wpPlugins = 'charmap colorpicker hr lists media paste tabfocus textcolor ' +
|
||||
'fullscreen wordpress wpautoresize wpeditimage wpgallery wplink wpdialogs wpview';
|
||||
|
||||
getUserSetting = setUserSetting = function() {}
|
||||
</script>
|
||||
<!-- tinymce.text.* -->
|
||||
<script src="tinymce/text/ExtendingChar.js"></script>
|
||||
<script src="tinymce/text/Zwsp.js"></script>
|
||||
|
||||
<!-- tinymce.dom.* -->
|
||||
<script src="tinymce/dom/NodeType.js"></script>
|
||||
<script src="tinymce/dom/DomQuery.js"></script>
|
||||
<script src="tinymce/dom/DOMUtils.js"></script>
|
||||
<script src="tinymce/dom/Dimensions.js"></script>
|
||||
<script src="tinymce/dom/EventUtils.js"></script>
|
||||
<script src="tinymce/dom/Range.js"></script>
|
||||
<script src="tinymce/dom/Selection.js"></script>
|
||||
@@ -88,6 +102,8 @@
|
||||
<script src="tinymce/util/URI.js"></script>
|
||||
<script src="tinymce/util/XHR.js"></script>
|
||||
<script src="tinymce/util/I18n.js"></script>
|
||||
<script src="tinymce/util/Fun.js"></script>
|
||||
<script src="tinymce/util/Delay.js"></script>
|
||||
|
||||
<!-- tinymce.* -->
|
||||
<script src="tinymce/AddOnManager.js"></script>
|
||||
@@ -102,9 +118,11 @@
|
||||
<script src="tinymce/Formatter_remove.js"></script>
|
||||
<script src="tinymce/Shortcuts.js"></script>
|
||||
<script src="tinymce/UndoManager.js"></script>
|
||||
<script src="tinymce/SelectionOverrides.js"></script>
|
||||
|
||||
<!-- tinymce.plugins.* -->
|
||||
<!--<script src="plugins/autolink.js"></script>-->
|
||||
<script src="plugins/charmap.js"></script>
|
||||
<!--<script src="plugins/autosave.js"></script>-->
|
||||
<!--<script src="plugins/fullpage.js"></script>-->
|
||||
<script src="plugins/image.js"></script>
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
module = privateModules[ids[i]] || resolve(ids[i]);
|
||||
|
||||
if (!module) {
|
||||
throw 'module definition dependecy not found: ' + ids[i];
|
||||
throw 'module definition dependency not found: ' + ids[i];
|
||||
}
|
||||
|
||||
defs.push(module);
|
||||
|
||||
@@ -1,17 +1,7 @@
|
||||
// Edited for WordPress
|
||||
(function() {
|
||||
var baseURL;
|
||||
// Edited for WordPres
|
||||
document.write('<script src="../../../src/wp-includes/js/tinymce/tinymce.js"></script>');
|
||||
|
||||
// Get base where the tinymce script is located
|
||||
var scripts = document.getElementsByTagName('script');
|
||||
for ( var i = 0; i < scripts.length; i++ ) {
|
||||
var src = scripts[i].src;
|
||||
var wpPlugins = 'charmap colorpicker hr lists media paste tabfocus textcolor ' +
|
||||
'fullscreen wordpress wpautoresize wpeditimage wpgallery wplink wpdialogs wpview';
|
||||
|
||||
if ( /tinymce_loader\.js/.test( src ) ) {
|
||||
baseURL = src.substring( 0, src.indexOf('/tests/qunit/') );
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
document.write('<script src="' + baseURL + '/src/wp-includes/js/tinymce/tinymce.min.js"></script>');
|
||||
})();
|
||||
getUserSetting = setUserSetting = function() {}
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
function fontFace(face) {
|
||||
if (tinymce.isOpera) {
|
||||
return "'" + face + "'";
|
||||
} else {
|
||||
return face;
|
||||
}
|
||||
|
||||
return face;
|
||||
}
|
||||
|
||||
function findContainer(selector) {
|
||||
@@ -55,6 +55,52 @@
|
||||
editor.selection.setRng(rng);
|
||||
}
|
||||
|
||||
function assertRange(actual, expected) {
|
||||
deepEqual({
|
||||
startContainer: actual.startContainer,
|
||||
startOffset: actual.startOffset,
|
||||
endContainer: actual.endContainer,
|
||||
endOffset: actual.endOffset
|
||||
}, {
|
||||
startContainer: expected.startContainer,
|
||||
startOffset: expected.startOffset,
|
||||
endContainer: expected.endContainer,
|
||||
endOffset: expected.endOffset
|
||||
});
|
||||
}
|
||||
|
||||
function createRange(startContainer, startOffset, endContainer, endOffset) {
|
||||
var rng = tinymce.DOM.createRng();
|
||||
|
||||
rng.setStart(startContainer, startOffset);
|
||||
|
||||
if (endContainer) {
|
||||
rng.setEnd(endContainer, endOffset);
|
||||
}
|
||||
|
||||
return rng;
|
||||
}
|
||||
|
||||
function assertCaretPosition(actual, expected, message) {
|
||||
if (expected === null) {
|
||||
strictEqual(actual, expected, message || 'Expected null.');
|
||||
return;
|
||||
}
|
||||
|
||||
if (actual === null) {
|
||||
strictEqual(actual, expected, message || 'Didn\'t expect null.');
|
||||
return;
|
||||
}
|
||||
|
||||
deepEqual({
|
||||
container: actual.container(),
|
||||
offset: actual.offset()
|
||||
}, {
|
||||
container: expected.container(),
|
||||
offset: expected.offset()
|
||||
}, message);
|
||||
}
|
||||
|
||||
function trimContent(content) {
|
||||
return content.replace(/^<p> <\/p>\n?/, '').replace(/\n?<p> <\/p>$/, '');
|
||||
}
|
||||
@@ -131,11 +177,11 @@
|
||||
|
||||
// TODO: Replace this with the new event logic in 3.5
|
||||
function type(chr) {
|
||||
var editor = tinymce.activeEditor, keyCode, charCode, evt, startElm, rng, startContainer, startOffset, textNode;
|
||||
var editor = tinymce.activeEditor, keyCode, charCode, evt, startElm, rng, offset;
|
||||
|
||||
function charCodeToKeyCode(charCode) {
|
||||
var lookup = {
|
||||
'0': 48, '1': 49, '2': 50, '3': 51, '4': 52, '5': 53, '6': 54, '7': 55, '8': 56, '9': 57,'a': 65, 'b': 66, 'c': 67,
|
||||
'0': 48, '1': 49, '2': 50, '3': 51, '4': 52, '5': 53, '6': 54, '7': 55, '8': 56, '9': 57, 'a': 65, 'b': 66, 'c': 67,
|
||||
'd': 68, 'e': 69, 'f': 70, 'g': 71, 'h': 72, 'i': 73, 'j': 74, 'k': 75, 'l': 76, 'm': 77, 'n': 78, 'o': 79, 'p': 80, 'q': 81,
|
||||
'r': 82, 's': 83, 't': 84, 'u': 85, 'v': 86, 'w': 87, 'x': 88, 'y': 89, ' ': 32, ',': 188, '-': 189, '.': 190, '/': 191, '\\': 220,
|
||||
'[': 219, ']': 221, '\'': 222, ';': 186, '=': 187, ')': 41
|
||||
@@ -149,10 +195,10 @@
|
||||
}
|
||||
|
||||
// Numeric keyCode
|
||||
if (typeof(chr) == "number") {
|
||||
if (typeof chr == "number") {
|
||||
charCode = chr;
|
||||
keyCode = charCodeToKeyCode(charCode);
|
||||
} else if (typeof(chr) == "string") {
|
||||
} else if (typeof chr == "string") {
|
||||
// String value
|
||||
if (chr == '\b') {
|
||||
keyCode = 8;
|
||||
@@ -195,40 +241,44 @@
|
||||
rng.execCommand('Delete', false, null);
|
||||
} else {
|
||||
rng = editor.selection.getRng();
|
||||
startContainer = rng.startContainer;
|
||||
|
||||
if (startContainer.nodeType == 1 && rng.collapsed) {
|
||||
var nodes = rng.startContainer.childNodes;
|
||||
startContainer = nodes[nodes.length - 1];
|
||||
}
|
||||
if (rng.collapsed) {
|
||||
if (rng.startContainer.nodeType == 1) {
|
||||
var nodes = rng.startContainer.childNodes, lastNode = nodes[nodes.length - 1];
|
||||
|
||||
// If caret is at <p>abc|</p> and after the abc text node then move it to the end of the text node
|
||||
// Expand the range to include the last char <p>ab[c]</p> since IE 11 doesn't delete otherwise
|
||||
if ( rng.collapsed && startContainer && startContainer.nodeType == 3 && startContainer.data.length > 0) {
|
||||
rng.setStart(startContainer, startContainer.data.length - 1);
|
||||
rng.setEnd(startContainer, startContainer.data.length);
|
||||
editor.selection.setRng(rng);
|
||||
// If caret is at <p>abc|</p> and after the abc text node then move it to the end of the text node
|
||||
// Expand the range to include the last char <p>ab[c]</p> since IE 11 doesn't delete otherwise
|
||||
if (rng.startOffset >= nodes.length - 1 && lastNode && lastNode.nodeType == 3 && lastNode.data.length > 0) {
|
||||
rng.setStart(lastNode, lastNode.data.length - 1);
|
||||
rng.setEnd(lastNode, lastNode.data.length);
|
||||
editor.selection.setRng(rng);
|
||||
}
|
||||
} else if (rng.startContainer.nodeType == 3) {
|
||||
// If caret is at <p>abc|</p> and after the abc text node then move it to the end of the text node
|
||||
// Expand the range to include the last char <p>ab[c]</p> since IE 11 doesn't delete otherwise
|
||||
offset = rng.startOffset;
|
||||
if (offset > 0) {
|
||||
rng.setStart(rng.startContainer, offset - 1);
|
||||
rng.setEnd(rng.startContainer, offset);
|
||||
editor.selection.setRng(rng);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
editor.getDoc().execCommand('Delete', false, null);
|
||||
}
|
||||
} else if (typeof(chr) == 'string') {
|
||||
} else if (typeof chr == 'string') {
|
||||
rng = editor.selection.getRng(true);
|
||||
|
||||
if (rng.startContainer.nodeType == 3 && rng.collapsed) {
|
||||
// `insertData` may alter the range.
|
||||
startContainer = rng.startContainer;
|
||||
startOffset = rng.startOffset;
|
||||
rng.startContainer.insertData( rng.startOffset, chr );
|
||||
rng.setStart( startContainer, startOffset + 1 );
|
||||
rng.startContainer.insertData(rng.startOffset, chr);
|
||||
rng.setStart(rng.startContainer, rng.startOffset + 1);
|
||||
rng.collapse(true);
|
||||
editor.selection.setRng(rng);
|
||||
} else {
|
||||
textNode = editor.getDoc().createTextNode(chr);
|
||||
rng.insertNode(textNode);
|
||||
rng.setStart(textNode, 1);
|
||||
rng.deleteContents();
|
||||
rng.insertNode(editor.getDoc().createTextNode(chr));
|
||||
}
|
||||
|
||||
rng.collapse(true);
|
||||
editor.selection.setRng(rng);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -324,6 +374,20 @@
|
||||
return editor.windowManager.windows[editor.windowManager.windows.length - 1];
|
||||
}
|
||||
|
||||
function pressKey(evt) {
|
||||
var dom = editor.dom, target = editor.selection.getNode();
|
||||
|
||||
if (typeof evt == "number") {
|
||||
evt = {keyCode: evt};
|
||||
}
|
||||
|
||||
evt = tinymce.extend({keyCode: 37}, evt);
|
||||
|
||||
dom.fire(target, 'keydown', evt);
|
||||
dom.fire(target, 'keypress', evt);
|
||||
dom.fire(target, 'keyup', evt);
|
||||
}
|
||||
|
||||
function pressArrowKey(evt) {
|
||||
var dom = editor.dom, target = editor.selection.getNode();
|
||||
|
||||
@@ -415,11 +479,15 @@
|
||||
resetScroll: resetScroll,
|
||||
nearlyEqualRects: nearlyEqualRects,
|
||||
getFrontmostWindow: getFrontmostWindow,
|
||||
pressKey: pressKey,
|
||||
pressArrowKey: pressArrowKey,
|
||||
pressEnter: pressEnter,
|
||||
trimBrsOnIE: trimBrsOnIE,
|
||||
patch: patch,
|
||||
unpatch: unpatch,
|
||||
triggerElementChange: triggerElementChange
|
||||
triggerElementChange: triggerElementChange,
|
||||
createRange: createRange,
|
||||
assertRange: assertRange,
|
||||
assertCaretPosition: assertCaretPosition
|
||||
};
|
||||
})();
|
||||
|
||||
@@ -0,0 +1,91 @@
|
||||
ModuleLoader.require([
|
||||
], function() {
|
||||
module("tinymce.plugins.CharMap", {
|
||||
setupModule: function() {
|
||||
QUnit.stop();
|
||||
|
||||
tinymce.init({
|
||||
selector: "textarea",
|
||||
plugins: "charmap",
|
||||
add_unload_trigger: false,
|
||||
init_instance_callback: function(ed) {
|
||||
window.editor = ed;
|
||||
QUnit.start();
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
test('Replace characters by array', function() {
|
||||
editor.settings.charmap = [
|
||||
[65, 'Latin A'],
|
||||
[66, 'Latin B']
|
||||
];
|
||||
|
||||
deepEqual(editor.plugins.charmap.getCharMap(), [
|
||||
[65, 'Latin A'],
|
||||
[66, 'Latin B']
|
||||
]);
|
||||
});
|
||||
|
||||
test('Replace characters by function', function() {
|
||||
editor.settings.charmap = function() {
|
||||
return [
|
||||
[65, 'Latin A fun'],
|
||||
[66, 'Latin B fun']
|
||||
];
|
||||
};
|
||||
|
||||
deepEqual(editor.plugins.charmap.getCharMap(), [
|
||||
[65, 'Latin A fun'],
|
||||
[66, 'Latin B fun']
|
||||
]);
|
||||
});
|
||||
|
||||
test('Append characters by array', function() {
|
||||
editor.settings.charmap = [
|
||||
[67, 'Latin C']
|
||||
];
|
||||
|
||||
editor.settings.charmap_append = [
|
||||
[65, 'Latin A'],
|
||||
[66, 'Latin B']
|
||||
];
|
||||
|
||||
deepEqual(editor.plugins.charmap.getCharMap(), [
|
||||
[67, 'Latin C'],
|
||||
[65, 'Latin A'],
|
||||
[66, 'Latin B']
|
||||
]);
|
||||
});
|
||||
|
||||
test('Append characters by function', function() {
|
||||
editor.settings.charmap = [
|
||||
[67, 'Latin C']
|
||||
];
|
||||
|
||||
editor.settings.charmap_append = function() {
|
||||
return [
|
||||
[65, 'Latin A fun'],
|
||||
[66, 'Latin B fun']
|
||||
];
|
||||
};
|
||||
|
||||
deepEqual(editor.plugins.charmap.getCharMap(), [
|
||||
[67, 'Latin C'],
|
||||
[65, 'Latin A fun'],
|
||||
[66, 'Latin B fun']
|
||||
]);
|
||||
});
|
||||
|
||||
test('Insert character', function() {
|
||||
var lastEvt;
|
||||
|
||||
editor.on('insertCustomChar', function(e) {
|
||||
lastEvt = e;
|
||||
});
|
||||
|
||||
editor.plugins.charmap.insertChar('A');
|
||||
equal(lastEvt.chr, 'A');
|
||||
});
|
||||
});
|
||||
@@ -23,6 +23,7 @@
|
||||
delete editor.settings.image_class_list;
|
||||
delete editor.settings.document_base_url;
|
||||
delete editor.settings.image_advtab;
|
||||
delete editor.settings.image_caption;
|
||||
|
||||
var win = Utils.getFrontmostWindow();
|
||||
|
||||
@@ -90,45 +91,90 @@
|
||||
);
|
||||
});
|
||||
|
||||
test('All image dialog ui options on empty editor', function() {
|
||||
editor.settings.image_list = [
|
||||
{title: 'link1', value: 'link1'},
|
||||
{title: 'link2', value: 'link2'}
|
||||
];
|
||||
if (tinymce.Env.ceFalse) {
|
||||
test('All image dialog ui options on empty editor', function() {
|
||||
editor.settings.image_caption = true;
|
||||
editor.settings.image_list = [
|
||||
{title: 'link1', value: 'link1'},
|
||||
{title: 'link2', value: 'link2'}
|
||||
];
|
||||
|
||||
editor.settings.image_class_list = [
|
||||
{title: 'class1', value: 'class1'},
|
||||
{title: 'class2', value: 'class2'}
|
||||
];
|
||||
editor.settings.image_class_list = [
|
||||
{title: 'class1', value: 'class1'},
|
||||
{title: 'class2', value: 'class2'}
|
||||
];
|
||||
|
||||
editor.setContent('');
|
||||
editor.execCommand('mceImage', true);
|
||||
editor.setContent('');
|
||||
editor.execCommand('mceImage', true);
|
||||
|
||||
deepEqual(Utils.getFrontmostWindow().toJSON(), {
|
||||
"alt": "",
|
||||
"class": "class1",
|
||||
"constrain": true,
|
||||
"height": "",
|
||||
"src": "",
|
||||
"width": ""
|
||||
deepEqual(Utils.getFrontmostWindow().toJSON(), {
|
||||
"alt": "",
|
||||
"class": "class1",
|
||||
"constrain": true,
|
||||
"caption": false,
|
||||
"height": "",
|
||||
"src": "",
|
||||
"width": ""
|
||||
});
|
||||
|
||||
fillAndSubmitWindowForm({
|
||||
"alt": "alt",
|
||||
"class": "class1",
|
||||
"constrain": true,
|
||||
"caption": true,
|
||||
"height": "200",
|
||||
"src": "src",
|
||||
"width": "100"
|
||||
});
|
||||
|
||||
equal(
|
||||
cleanHtml(editor.getContent()),
|
||||
'<figure class="image"><img class="class1" src="src" alt="alt" width="100" height="200" /><figcaption>caption</figcaption></figure>'
|
||||
);
|
||||
});
|
||||
} else {
|
||||
test('All image dialog ui options on empty editor (old IE)', function() {
|
||||
editor.settings.image_caption = true;
|
||||
editor.settings.image_list = [
|
||||
{title: 'link1', value: 'link1'},
|
||||
{title: 'link2', value: 'link2'}
|
||||
];
|
||||
|
||||
fillAndSubmitWindowForm({
|
||||
"alt": "alt",
|
||||
"class": "class1",
|
||||
"constrain": true,
|
||||
"height": "200",
|
||||
"src": "src",
|
||||
"width": "100"
|
||||
editor.settings.image_class_list = [
|
||||
{title: 'class1', value: 'class1'},
|
||||
{title: 'class2', value: 'class2'}
|
||||
];
|
||||
|
||||
editor.setContent('');
|
||||
editor.execCommand('mceImage', true);
|
||||
|
||||
deepEqual(Utils.getFrontmostWindow().toJSON(), {
|
||||
"alt": "",
|
||||
"class": "class1",
|
||||
"constrain": true,
|
||||
"height": "",
|
||||
"src": "",
|
||||
"width": ""
|
||||
});
|
||||
|
||||
fillAndSubmitWindowForm({
|
||||
"alt": "alt",
|
||||
"class": "class1",
|
||||
"constrain": true,
|
||||
"caption": true,
|
||||
"height": "200",
|
||||
"src": "src",
|
||||
"width": "100"
|
||||
});
|
||||
|
||||
equal(
|
||||
cleanHtml(editor.getContent()),
|
||||
'<p><img class="class1" src="src" alt="alt" width="100" height="200" /></p>'
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
equal(
|
||||
cleanHtml(editor.getContent()),
|
||||
'<p><img class="class1" src="src" alt="alt" width="100" height="200" /></p>'
|
||||
);
|
||||
});
|
||||
|
||||
test("Image recognizes relative src url and prepends relative image_prepend_url setting.", function () {
|
||||
test("Image recognizes relative src url and prepends relative image_prepend_url setting.", function() {
|
||||
var win, elementId, element;
|
||||
|
||||
editor.settings.image_prepend_url = 'testing/images/';
|
||||
@@ -154,11 +200,9 @@
|
||||
cleanHtml(editor.getContent()),
|
||||
'<p><img src="' + editor.settings.image_prepend_url + 'src" alt="alt" /></p>'
|
||||
);
|
||||
});
|
||||
|
||||
|
||||
});
|
||||
|
||||
test("Image recognizes relative src url and prepends absolute image_prepend_url setting.", function () {
|
||||
test("Image recognizes relative src url and prepends absolute image_prepend_url setting.", function() {
|
||||
var win, elementId, element;
|
||||
|
||||
editor.settings.image_prepend_url = 'http://localhost/images/';
|
||||
@@ -184,7 +228,7 @@
|
||||
cleanHtml(editor.getContent()),
|
||||
'<p><img src="' + editor.settings.image_prepend_url + 'src" alt="alt" /></p>'
|
||||
);
|
||||
});
|
||||
});
|
||||
|
||||
test('Advanced image dialog border option on empty editor', function(){
|
||||
editor.settings.image_advtab = true;
|
||||
@@ -322,7 +366,7 @@
|
||||
"alt": "alt",
|
||||
"border": "10",
|
||||
"src": "src",
|
||||
"style": "border-width: 15px;",
|
||||
"style": "border-width: 15px;"
|
||||
});
|
||||
|
||||
equal(
|
||||
|
||||
@@ -10,13 +10,13 @@ module("tinymce.plugins.Lists", {
|
||||
QUnit.started = true;
|
||||
}
|
||||
} else {
|
||||
setTimeout(wait, 0);
|
||||
tinymce.util.Delay.setTimeout(wait, 0);
|
||||
}
|
||||
}
|
||||
|
||||
tinymce.init({
|
||||
selector: '#elm1',
|
||||
plugins: wpPlugins,
|
||||
plugins: "lists",
|
||||
add_unload_trigger: false,
|
||||
skin: false,
|
||||
indent: false,
|
||||
|
||||
@@ -6,7 +6,8 @@ module("tinymce.plugins.Media", {
|
||||
selector: "textarea",
|
||||
add_unload_trigger: false,
|
||||
skin: false,
|
||||
plugins: wpPlugins,
|
||||
plugins: 'media',
|
||||
live_embeds: false,
|
||||
document_base_url: '/tinymce/tinymce/trunk/tests/',
|
||||
extended_valid_elements: 'script[src|type]',
|
||||
media_scripts: [
|
||||
@@ -22,6 +23,7 @@ module("tinymce.plugins.Media", {
|
||||
|
||||
teardown: function() {
|
||||
delete editor.settings.media_filter_html;
|
||||
delete editor.settings.media_live_embeds;
|
||||
}
|
||||
});
|
||||
|
||||
@@ -34,6 +36,8 @@ function fillAndSubmitWindowForm(data) {
|
||||
}
|
||||
|
||||
test('Default media dialog on empty editor', function() {
|
||||
editor.settings.media_live_embeds = false;
|
||||
|
||||
editor.setContent('');
|
||||
editor.plugins.media.showDialog();
|
||||
|
||||
@@ -53,7 +57,7 @@ test('Default media dialog on empty editor', function() {
|
||||
|
||||
equal(
|
||||
editor.getContent(),
|
||||
'<p><iframe src=\"//www.youtube.com/embed/dQw4w9WgXcQ\" width=\"425\" height=\"350\" allowfullscreen=\"allowfullscreen\"></iframe></p>'
|
||||
'<p><iframe src=\"//www.youtube.com/embed/dQw4w9WgXcQ\" width=\"560\" height=\"314\" allowfullscreen=\"allowfullscreen\"></iframe></p>'
|
||||
);
|
||||
});
|
||||
|
||||
@@ -165,8 +169,8 @@ test("Resize complex object", function() {
|
||||
|
||||
test("Media script elements", function() {
|
||||
editor.setContent(
|
||||
'<script src="http://media1.tinymce.com/123456"></sc'+'ript>' +
|
||||
'<script src="http://media2.tinymce.com/123456"></sc'+'ript>'
|
||||
'<script src="http://media1.tinymce.com/123456"></sc' + 'ript>' +
|
||||
'<script src="http://media2.tinymce.com/123456"></sc' + 'ript>'
|
||||
);
|
||||
|
||||
equal(editor.getBody().getElementsByTagName('img')[0].className, 'mce-object mce-object-script');
|
||||
@@ -178,8 +182,8 @@ test("Media script elements", function() {
|
||||
|
||||
equal(editor.getContent(),
|
||||
'<p>\n' +
|
||||
'<script src="http://media1.tinymce.com/123456" type="text/javascript"></sc'+'ript>\n' +
|
||||
'<script src="http://media2.tinymce.com/123456" type="text/javascript"></sc'+'ript>\n' +
|
||||
'<script src="http://media1.tinymce.com/123456" type="text/javascript"></sc' + 'ript>\n' +
|
||||
'<script src="http://media2.tinymce.com/123456" type="text/javascript"></sc' + 'ript>\n' +
|
||||
'</p>'
|
||||
);
|
||||
});
|
||||
|
||||
@@ -9,7 +9,6 @@ module("tinymce.plugins.Noneditable", {
|
||||
indent: false,
|
||||
noneditable_regexp: [/\{[^\}]+\}/g],
|
||||
plugins: 'noneditable',
|
||||
forced_root_block: '',
|
||||
convert_fonts_to_spans: false,
|
||||
entities: 'raw',
|
||||
valid_styles: {
|
||||
@@ -24,184 +23,23 @@ module("tinymce.plugins.Noneditable", {
|
||||
});
|
||||
|
||||
// Ignore on IE 7, 8 this is a known bug not worth fixing
|
||||
if (!tinymce.Env.ie || tinymce.Env.ie > 8) {
|
||||
test('expand to noneditable (start)', function() {
|
||||
editor.setContent('<p><span class="mceNonEditable">no</span>yes</p>');
|
||||
|
||||
var rng = editor.dom.createRng();
|
||||
rng.setStart(editor.getBody().firstChild.firstChild.firstChild, 1);
|
||||
rng.setEnd(editor.getBody().firstChild.lastChild, 1);
|
||||
editor.selection.setRng(rng);
|
||||
|
||||
editor.dom.fire(editor.getBody(), 'mouseup');
|
||||
rng = Utils.normalizeRng(editor.selection.getRng(true));
|
||||
|
||||
equal(rng.startContainer.nodeName, 'P');
|
||||
equal(rng.startOffset, 0);
|
||||
equal(rng.endContainer.nodeName, '#text');
|
||||
equal(rng.endOffset, 1);
|
||||
if (tinymce.Env.ceFalse) {
|
||||
test('noneditable class', function() {
|
||||
editor.setContent('<p><span class="mceNonEditable">abc</span></p>');
|
||||
equal(editor.dom.select('span')[0].contentEditable, "false");
|
||||
});
|
||||
|
||||
test('expand to noneditable (end)', function() {
|
||||
editor.setContent('<p>yes<span class="mceNonEditable">no</span></p>');
|
||||
|
||||
var rng = editor.dom.createRng();
|
||||
rng.setStart(editor.getBody().firstChild.firstChild, 1);
|
||||
rng.setEnd(editor.getBody().firstChild.lastChild.firstChild, 1);
|
||||
editor.selection.setRng(rng);
|
||||
|
||||
editor.dom.fire(editor.getBody(), 'mouseup');
|
||||
rng = Utils.normalizeRng(editor.selection.getRng(true));
|
||||
|
||||
equal(rng.startContainer.nodeName, '#text');
|
||||
equal(rng.startOffset, 1);
|
||||
equal(rng.endContainer.nodeName, 'P');
|
||||
equal(rng.endOffset, 2);
|
||||
test('editable class', function() {
|
||||
editor.setContent('<p><span class="mceEditable">abc</span></p>');
|
||||
equal(editor.dom.select('span')[0].contentEditable, "true");
|
||||
});
|
||||
|
||||
test('expand to noneditable (start/end)', function() {
|
||||
editor.setContent('<p>yes<span class="mceNonEditable">noedit</span>yes</p>');
|
||||
test('noneditable regexp', function() {
|
||||
editor.setContent('<p>{test1}{test2}</p>');
|
||||
|
||||
var rng = editor.dom.createRng();
|
||||
rng.setStart(editor.dom.select('span')[0].firstChild, 1);
|
||||
rng.setEnd(editor.dom.select('span')[0].firstChild, 2);
|
||||
editor.selection.setRng(rng);
|
||||
|
||||
editor.dom.fire(editor.getBody(), 'mouseup');
|
||||
rng = Utils.normalizeRng(editor.selection.getRng(true));
|
||||
|
||||
equal(rng.startContainer.nodeName, 'P');
|
||||
equal(rng.startOffset, 1);
|
||||
equal(rng.endContainer.nodeName, 'P');
|
||||
equal(rng.endOffset, 2);
|
||||
equal(editor.dom.select('span').length, 2);
|
||||
equal(editor.dom.select('span')[0].contentEditable, "false");
|
||||
equal(editor.dom.select('span')[1].contentEditable, "false");
|
||||
equal(editor.getContent(), '<p>{test1}{test2}</p>');
|
||||
});
|
||||
|
||||
test('type after non editable', function() {
|
||||
editor.setContent('<p><span class="mceNonEditable">no</span>yes</p>');
|
||||
|
||||
var rng = editor.dom.createRng();
|
||||
rng.setStart(editor.dom.select('span')[0].firstChild, 2);
|
||||
rng.setEnd(editor.dom.select('span')[0].firstChild, 2);
|
||||
editor.selection.setRng(rng);
|
||||
|
||||
Utils.type('X');
|
||||
rng = Utils.normalizeRng(editor.selection.getRng(true));
|
||||
|
||||
equal(rng.startContainer.getAttribute('data-mce-bogus'), 'true');
|
||||
equal(rng.startContainer.nodeName, 'SPAN');
|
||||
equal(rng.startOffset, 1);
|
||||
equal(rng.endContainer.nodeName, 'SPAN');
|
||||
equal(rng.endOffset, 1);
|
||||
equal(editor.getContent(), '<p><span class="mceNonEditable">no</span>Xyes</p>');
|
||||
});
|
||||
}
|
||||
|
||||
test('type between non editable', function() {
|
||||
editor.setContent('<p><span class="mceNonEditable">no</span><span class="mceNonEditable">no</span></p>');
|
||||
|
||||
var rng = editor.dom.createRng();
|
||||
rng.setStart(editor.dom.select('span')[0].firstChild, 2);
|
||||
rng.setEnd(editor.dom.select('span')[0].firstChild, 2);
|
||||
editor.selection.setRng(rng);
|
||||
|
||||
Utils.type('X');
|
||||
rng = Utils.normalizeRng(editor.selection.getRng(true));
|
||||
|
||||
equal(rng.startContainer.getAttribute('data-mce-bogus'), 'true');
|
||||
equal(rng.startContainer.nodeName, 'SPAN');
|
||||
equal(rng.startOffset, 1);
|
||||
equal(rng.endContainer.nodeName, 'SPAN');
|
||||
equal(rng.endOffset, 1);
|
||||
equal(editor.getContent(), '<p><span class="mceNonEditable">no</span>X<span class="mceNonEditable">no</span></p>');
|
||||
});
|
||||
|
||||
test('type after last non editable', function() {
|
||||
editor.setContent('<p><span class="mceNonEditable">no</span></p>');
|
||||
|
||||
var rng = editor.dom.createRng();
|
||||
rng.setStart(editor.dom.select('span')[0].firstChild, 2);
|
||||
rng.setEnd(editor.dom.select('span')[0].firstChild, 2);
|
||||
editor.selection.setRng(rng);
|
||||
|
||||
Utils.type('X');
|
||||
rng = Utils.normalizeRng(editor.selection.getRng(true));
|
||||
|
||||
equal(rng.startContainer.getAttribute('data-mce-bogus'), 'true');
|
||||
equal(rng.startContainer.nodeName, 'SPAN');
|
||||
equal(rng.startOffset, 1);
|
||||
equal(rng.endContainer.nodeName, 'SPAN');
|
||||
equal(rng.endOffset, 1);
|
||||
equal(editor.getContent(), '<p><span class="mceNonEditable">no</span>X</p>');
|
||||
});
|
||||
|
||||
// Ignore on IE 7, 8 this is a known bug not worth fixing
|
||||
if (!tinymce.Env.ie || tinymce.Env.ie > 8) {
|
||||
test('escape noneditable inline element (left)', function() {
|
||||
editor.setContent('<p>no <span class="mceNonEditable">yes</span> no</p><p class="mceNonEditable">no</p>');
|
||||
|
||||
var rng = editor.dom.createRng();
|
||||
rng.selectNode(editor.dom.select('span')[0]);
|
||||
editor.selection.setRng(rng);
|
||||
|
||||
Utils.type({keyCode: 37});
|
||||
rng = Utils.normalizeRng(editor.selection.getRng(true));
|
||||
equal(rng.startContainer.nodeName, 'P');
|
||||
equal(rng.collapsed, true);
|
||||
});
|
||||
}
|
||||
|
||||
test('escape noneditable inline element (right)', function() {
|
||||
editor.setContent('<p>no <span class="mceNonEditable">yes</span> no</p><p class="mceNonEditable">no</p>');
|
||||
|
||||
var rng = editor.dom.createRng();
|
||||
rng.selectNode(editor.dom.select('span')[0]);
|
||||
editor.selection.setRng(rng);
|
||||
|
||||
Utils.type({keyCode: 39});
|
||||
rng = Utils.normalizeRng(editor.selection.getRng(true));
|
||||
|
||||
equal(rng.startContainer.nodeName, 'P');
|
||||
equal(editor.dom.nodeIndex(rng.startContainer), 0);
|
||||
equal(rng.collapsed, true);
|
||||
});
|
||||
|
||||
test('escape noneditable block element (left)', function(){
|
||||
editor.setContent('<p>yes</p><p class="mceNonEditable">no</p><p>yes</p>');
|
||||
|
||||
var rng = editor.dom.createRng();
|
||||
rng.selectNode(editor.dom.select('p')[1]);
|
||||
editor.selection.setRng(rng);
|
||||
|
||||
Utils.type({keyCode: 37});
|
||||
rng = Utils.normalizeRng(editor.selection.getRng(true));
|
||||
|
||||
equal(rng.startContainer.nodeName, "P");
|
||||
equal(editor.dom.nodeIndex(rng.startContainer), 0);
|
||||
equal(rng.startOffset, 1);
|
||||
equal(rng.collapsed, true);
|
||||
|
||||
});
|
||||
|
||||
test('escape noneditable block element (right)', function(){
|
||||
editor.setContent('<p>yes</p><p class="mceNonEditable">no</p><p>yes</p>');
|
||||
|
||||
var rng = editor.dom.createRng();
|
||||
rng.selectNode(editor.dom.select('p')[1]);
|
||||
editor.selection.setRng(rng);
|
||||
|
||||
Utils.type({keyCode: 39});
|
||||
rng = Utils.normalizeRng(editor.selection.getRng(true));
|
||||
|
||||
equal(rng.startContainer.nodeName, "P");
|
||||
equal(editor.dom.nodeIndex(rng.startContainer), 2);
|
||||
equal(rng.startOffset, 0);
|
||||
equal(rng.collapsed, true);
|
||||
|
||||
});
|
||||
|
||||
test('noneditable regexp', function() {
|
||||
editor.setContent('<p>{test1}{test2}</p>');
|
||||
|
||||
equal(editor.dom.select('span').length, 2);
|
||||
equal(editor.getContent(), '<p>{test1}{test2}</p>');
|
||||
});
|
||||
}
|
||||
@@ -7,8 +7,7 @@ module("tinymce.plugins.Paste", {
|
||||
add_unload_trigger: false,
|
||||
skin: false,
|
||||
indent: false,
|
||||
plugins: wpPlugins,
|
||||
wp_paste_filters: false,
|
||||
plugins: 'paste',
|
||||
setup: function(ed) {
|
||||
ed.on('NodeChange', false);
|
||||
},
|
||||
@@ -311,7 +310,7 @@ test("Paste Word retain bold/italic styles to elements", function() {
|
||||
)
|
||||
});
|
||||
|
||||
equal(editor.getContent(), '<p><b>bold</b><i>italic</i><b><i>bold + italic</i></b><b><span style="color: red;">bold + color</span></b></p>');
|
||||
equal(editor.getContent(), '<p><strong>bold</strong><em>italic</em><strong><em>bold + italic</em></strong><strong><span style="color: red;">bold + color</span></strong></p>');
|
||||
});
|
||||
|
||||
test('paste track changes comment', function() {
|
||||
@@ -713,14 +712,14 @@ if (tinymce.Env.webkit) {
|
||||
editor.execCommand('mceInsertClipboardContent', false, {content: '<span style="font-size:42px; text-indent: 10px">Test</span>'});
|
||||
equal(editor.getContent(), '<p><span style="font-size: 42px;">Test</span></p>');
|
||||
});
|
||||
/* WP set to always remove font-family on WebKit with a filtering callback.
|
||||
|
||||
test('paste webkit remove runtime styles (font-family)', function() {
|
||||
editor.settings.paste_webkit_styles = 'font-family';
|
||||
editor.setContent('');
|
||||
editor.execCommand('mceInsertClipboardContent', false, {content: '<span style="font-family:Arial; text-indent: 10px">Test</span>'});
|
||||
equal(editor.getContent(), '<p><span style="font-family: Arial;">Test</span></p>');
|
||||
});
|
||||
WP end */
|
||||
|
||||
test('paste webkit remove runtime styles font-family allowed but not specified', function() {
|
||||
editor.settings.paste_webkit_styles = 'font-family';
|
||||
editor.setContent('');
|
||||
|
||||
@@ -13,7 +13,7 @@ module("tinymce.plugins.SearchReplace", {
|
||||
valid_elements: 'b,i',
|
||||
init_instance_callback : function(ed) {
|
||||
window.editor = ed;
|
||||
window.setTimeout(function() {
|
||||
tinymce.util.Delay.setTimeout(function() {
|
||||
QUnit.start();
|
||||
}, 0);
|
||||
}
|
||||
|
||||
@@ -603,4 +603,399 @@
|
||||
'<table><tbody><tr><td> </td><td><p>a</p></td></tr></tbody></table><p>x</p>'
|
||||
);
|
||||
});
|
||||
|
||||
var testResizeTable1 = '<table style="width: 426px"><tbody>' +
|
||||
'<tr><td style="height: 20px; width: 200px;" colspan="2" data-mce-style="height: 20px; width: 200px;">A1</td><td style="height: 20px; width: 100px;" data-mce-style="height: 20px; width: 100px;">A2</td><td style="height: 20px; width: 100px;" data-mce-style="height: 20px; width: 100px;">A3</td></tr>' +
|
||||
'<tr><td style="height: 20px; width: 100px;" data-mce-style="height: 20px; width: 100px;">B1</td><td style="height: 20px; width: 200px;" colspan="2" data-mce-style="height: 20px; width: 200px;">B2</td><td style="height: 20px; width: 100px;" data-mce-style="height: 20px; width: 100px;">B3</td></tr>' +
|
||||
'<tr><td style="height: 20px; width: 100px;" data-mce-style="height: 20px; width: 100px;">C1</td><td style="height: 20px; width: 100px;" data-mce-style="height: 20px; width: 100px;">C2</td><td style="height: 20px; width: 200px;" colspan="2" data-mce-style="height: 20px; width: 200px;">C3</td></tr>' +
|
||||
'<tr><td style="height: 20px; width: 400px;" colspan="4" data-mce-style="height: 20px; width: 400px;">D1</td></tr></tbody></table>';
|
||||
|
||||
var testResizeTable2 = '<table border="1"><tbody>' +
|
||||
'<tr><th style="height: 20px; width: 20px;" data-mce-style="height: 20px; width: 20px;">A0</th><th style="height: 20px; width: 20px;" data-mce-style="height: 20px; width: 20px;">A1</th><th style="height: 20px; width: 20px;" data-mce-style="height: 20px; width: 20px;">A2</th>' +
|
||||
'<th style="height: 20px; width: 40px;" data-mce-style="height: 20px; width: 40px;">A3</th><th style="height: 20px; width: 10px;" data-mce-style="height: 20px; width: 10px;">A4</th></tr><tr><td style="height: 20px; width: 20px;" data-mce-style="height: 20px; width: 20px;">B0</td><td style="height: 20px; width: 20px; "' +
|
||||
'data-mce-style="height: 20px; width: 20px;">B1</td><td style="height: 20px; width: 20px;" data-mce-style="height: 20px; width: 20px;">B2</td><td style="height: 20px; width: 40px;" data-mce-style="height: 20px; width: 40px;">B3</td><td style="height: 40px; width: 10px;" rowspan="2" data-mce-style="height: 20px; width: 10px;">' +
|
||||
'B3</td></tr><tr><td style="height: 20px; width: 20px;" data-mce-style="height: 20px; width: 20px;">C0</td><td style="height: 20px; width: 20px;" data-mce-style="height: 20px; width: 20px;">C1</td><td style="height: 20px; width: 20px;" data-mce-style="height: 20px; width: 20px;">C2</td><td style="height: 20px; width: 40px;" ' +
|
||||
'data-mce-style="height: 20px; width: 40px;">C3</td></tr></tbody></table>';
|
||||
|
||||
var testResizeTable3 = '<div style=\"display: block; width: 400px;\"><table style=\"border-collapse: collapse; border: 1px solid black;\" width=\"100%\" cellspacing=\"0\" cellpadding=\"0\"><tbody><tr><td rowspan=\"2\" width=\"25%\"> a</td><td width=\"25%\"> b</td><td width=\"25%\"> </td>' +
|
||||
'<td width=\"25%\"> c</td></tr><tr><td width=\"25%\"> d</td><td width=\"25%\"> </td><td rowspan=\"2\" width=\"25%\"> e</td></tr><tr><td width=\"25%\"> f</td><td width=\"25%\"> g</td><td width=\"25%\"> </td></tr><tr><td width=\"25%\"> h</td><td width=\"25%\"> i</td><td width=\"25%\"> </td><td width=\"25%\">j </td></tr></tbody></table></div>';
|
||||
|
||||
var testResizeTable4 = (
|
||||
'<table>' +
|
||||
'<tbody>' +
|
||||
'<tr>' +
|
||||
'<td>a</td>' +
|
||||
'<td>b</td>' +
|
||||
'</tr>' +
|
||||
'<tr>' +
|
||||
'<td>a</td>' +
|
||||
'<td>b</td>' +
|
||||
'<td>c</td>' +
|
||||
'</tr>' +
|
||||
'<tr>' +
|
||||
'<td>a</td>' +
|
||||
'</tr>' +
|
||||
'<tr>' +
|
||||
'<td>a</td>' +
|
||||
'<td>b</td>' +
|
||||
'<td colspan="2">c</td>' +
|
||||
'</tr>' +
|
||||
'</tbody>' +
|
||||
'</table>'
|
||||
);
|
||||
|
||||
test("Is Pixel/Percentage Based Width", function() {
|
||||
var pixelWidths = ['125px', '200px', '300em'];
|
||||
var percentageWidths = ['25%', '30%', '100%'];
|
||||
var i, pixelBasedSize, percentBasedSize;
|
||||
|
||||
for (i = 0; i < pixelWidths.length; i++) {
|
||||
pixelBasedSize = editor.plugins.table.resizeBars.isPixelBasedSize(pixelWidths[i]);
|
||||
deepEqual(pixelBasedSize, true);
|
||||
percentBasedSize = editor.plugins.table.resizeBars.isPercentageBasedSize(pixelWidths[i]);
|
||||
deepEqual(percentBasedSize, false);
|
||||
}
|
||||
for (i = 0; i < percentageWidths.length; i++) {
|
||||
pixelBasedSize = editor.plugins.table.resizeBars.isPixelBasedSize(percentageWidths[i]);
|
||||
deepEqual(pixelBasedSize, false);
|
||||
percentBasedSize = editor.plugins.table.resizeBars.isPercentageBasedSize(percentageWidths[i]);
|
||||
deepEqual(percentBasedSize, true);
|
||||
}
|
||||
});
|
||||
|
||||
test("Get widths/heights", function() {
|
||||
editor.setContent(testResizeTable1);
|
||||
|
||||
var table = editor.dom.select('table')[0];
|
||||
var details = editor.plugins.table.resizeBars.getTableDetails(table);
|
||||
var tableGrid = editor.plugins.table.resizeBars.getTableGrid(details);
|
||||
|
||||
deepEqual(
|
||||
editor.plugins.table.resizeBars.getWidths(tableGrid, false, table),
|
||||
[100, 100, 100, 100]
|
||||
);
|
||||
|
||||
deepEqual(
|
||||
editor.plugins.table.resizeBars.getPixelHeights(tableGrid),
|
||||
[20, 20, 20, 20]
|
||||
);
|
||||
|
||||
editor.setContent(testResizeTable2);
|
||||
|
||||
table = editor.dom.select('table')[0];
|
||||
details = editor.plugins.table.resizeBars.getTableDetails(table);
|
||||
tableGrid = editor.plugins.table.resizeBars.getTableGrid(details);
|
||||
|
||||
deepEqual(
|
||||
editor.plugins.table.resizeBars.getWidths(tableGrid, false, table),
|
||||
[20, 20, 20, 40, 10]
|
||||
);
|
||||
|
||||
deepEqual(
|
||||
editor.plugins.table.resizeBars.getPixelHeights(tableGrid),
|
||||
[20, 20, 20]
|
||||
);
|
||||
|
||||
editor.setContent(testResizeTable3);
|
||||
|
||||
table = editor.dom.select('table')[0];
|
||||
details = editor.plugins.table.resizeBars.getTableDetails(table);
|
||||
tableGrid = editor.plugins.table.resizeBars.getTableGrid(details);
|
||||
|
||||
deepEqual(
|
||||
editor.plugins.table.resizeBars.getWidths(tableGrid, true, table),
|
||||
[25, 25, 25, 25]
|
||||
);
|
||||
});
|
||||
|
||||
test("Draw bars/clear bars", function() {
|
||||
editor.setContent(testResizeTable1);
|
||||
|
||||
var table = editor.dom.select('table')[0];
|
||||
|
||||
editor.plugins.table.resizeBars.drawBars(table);
|
||||
|
||||
equal(editor.dom.select('.mce-resize-bar-row').length,
|
||||
4);
|
||||
|
||||
equal(editor.dom.select('.mce-resize-bar-col').length,
|
||||
4);
|
||||
|
||||
editor.plugins.table.resizeBars.clearBars();
|
||||
|
||||
equal(editor.dom.select('.mce-resize-bar-row').length,
|
||||
0);
|
||||
|
||||
equal(editor.dom.select('.mce-resize-bar-col').length,
|
||||
0);
|
||||
});
|
||||
|
||||
test("Draw bars/clear bars on invalid table", function() {
|
||||
editor.setContent(testResizeTable4);
|
||||
|
||||
var table = editor.dom.select('table')[0];
|
||||
|
||||
editor.plugins.table.resizeBars.drawBars(table);
|
||||
|
||||
equal(editor.dom.select('.mce-resize-bar-row').length,
|
||||
4);
|
||||
|
||||
equal(editor.dom.select('.mce-resize-bar-col').length,
|
||||
4);
|
||||
|
||||
editor.plugins.table.resizeBars.clearBars();
|
||||
|
||||
equal(editor.dom.select('.mce-resize-bar-row').length,
|
||||
0);
|
||||
|
||||
equal(editor.dom.select('.mce-resize-bar-col').length,
|
||||
0);
|
||||
});
|
||||
|
||||
test("Determine deltas", function() {
|
||||
var deltas = editor.plugins.table.resizeBars.determineDeltas([100, 100, 100, 100], 0, 50, 10, false);
|
||||
|
||||
deepEqual(deltas, [50, -50, 0, 0]);
|
||||
|
||||
deltas = editor.plugins.table.resizeBars.determineDeltas([100, 100, 100, 100], 1, 50, 10, false);
|
||||
|
||||
deepEqual(deltas, [0, 50, -50, 0]);
|
||||
|
||||
deltas = editor.plugins.table.resizeBars.determineDeltas([100, 100, 100, 100], 2, 50, 10, false);
|
||||
|
||||
deepEqual(deltas, [0, 0, 50, -50]);
|
||||
|
||||
deltas = editor.plugins.table.resizeBars.determineDeltas([100, 100, 100, 100], 3, 50, 10, false);
|
||||
|
||||
deepEqual(deltas, [0, 0, 0, 50]);
|
||||
|
||||
deltas = editor.plugins.table.resizeBars.determineDeltas([50], 0, 5, 10, true);
|
||||
|
||||
deepEqual(deltas, [50]); // 50 + 50 = 100, one column, percent case
|
||||
|
||||
deltas = editor.plugins.table.resizeBars.determineDeltas([25, 25, 25, 25], 1, 5, 10, true);
|
||||
|
||||
deepEqual(deltas, [0, 5, -5, 0]);
|
||||
});
|
||||
|
||||
test("Adjust width", function() {
|
||||
editor.setContent(testResizeTable1);
|
||||
|
||||
var table = editor.dom.select('table')[0];
|
||||
|
||||
editor.plugins.table.resizeBars.adjustWidth(table, 50, 0);
|
||||
|
||||
equal(editor.getContent(),
|
||||
'<table style=\"width: 426px;\">' +
|
||||
'<tbody>' +
|
||||
'<tr>' +
|
||||
'<td style=\"width: 200px; height: 20px;\" colspan=\"2\">A1</td>' +
|
||||
'<td style=\"width: 100px; height: 20px;\">A2</td>' +
|
||||
'<td style=\"width: 100px; height: 20px;\">A3</td>' +
|
||||
'</tr>' +
|
||||
'<tr>' +
|
||||
'<td style=\"width: 150px; height: 20px;\">B1</td>' +
|
||||
'<td style=\"width: 150px; height: 20px;\" colspan=\"2\">B2</td>' +
|
||||
'<td style=\"width: 100px; height: 20px;\">B3</td>' +
|
||||
'</tr>' +
|
||||
'<tr>' +
|
||||
'<td style=\"width: 150px; height: 20px;\">C1</td>' +
|
||||
'<td style=\"width: 50px; height: 20px;\">C2</td>' +
|
||||
'<td style=\"width: 200px; height: 20px;\" colspan=\"2\">C3</td>' +
|
||||
'</tr>' +
|
||||
'<tr>' +
|
||||
'<td style=\"width: 400px; height: 20px;\" colspan=\"4\">D1</td>' +
|
||||
'</tr>' +
|
||||
'</tbody>' +
|
||||
'</table>');
|
||||
|
||||
editor.setContent(testResizeTable1);
|
||||
|
||||
table = editor.dom.select('table')[0];
|
||||
|
||||
editor.plugins.table.resizeBars.adjustWidth(table, 50, 1);
|
||||
|
||||
equal(editor.getContent(),
|
||||
'<table style=\"width: 426px;\">' +
|
||||
'<tbody>' +
|
||||
'<tr>' +
|
||||
'<td style=\"width: 250px; height: 20px;\" colspan=\"2\">A1</td>' +
|
||||
'<td style=\"width: 50px; height: 20px;\">A2</td>' +
|
||||
'<td style=\"width: 100px; height: 20px;\">A3</td>' +
|
||||
'</tr>' +
|
||||
'<tr>' +
|
||||
'<td style=\"width: 100px; height: 20px;\">B1</td>' +
|
||||
'<td style=\"width: 200px; height: 20px;\" colspan=\"2\">B2</td>' +
|
||||
'<td style=\"width: 100px; height: 20px;\">B3</td>' +
|
||||
'</tr>' +
|
||||
'<tr>' +
|
||||
'<td style=\"width: 100px; height: 20px;\">C1</td>' +
|
||||
'<td style=\"width: 150px; height: 20px;\">C2</td>' +
|
||||
'<td style=\"width: 150px; height: 20px;\" colspan=\"2\">C3</td>' +
|
||||
'</tr>' +
|
||||
'<tr>' +
|
||||
'<td style=\"width: 400px; height: 20px;\" colspan=\"4\">D1</td>' +
|
||||
'</tr>' +
|
||||
'</tbody>' +
|
||||
'</table>');
|
||||
|
||||
editor.setContent(testResizeTable1);
|
||||
|
||||
table = editor.dom.select('table')[0];
|
||||
|
||||
editor.plugins.table.resizeBars.adjustWidth(table, 50, 2);
|
||||
|
||||
equal(editor.getContent(),
|
||||
'<table style=\"width: 426px;\">' +
|
||||
'<tbody>' +
|
||||
'<tr>' +
|
||||
'<td style=\"width: 200px; height: 20px;\" colspan=\"2\">A1</td>' +
|
||||
'<td style=\"width: 150px; height: 20px;\">A2</td>' +
|
||||
'<td style=\"width: 50px; height: 20px;\">A3</td>' +
|
||||
'</tr>' +
|
||||
'<tr>' +
|
||||
'<td style=\"width: 100px; height: 20px;\">B1</td>' +
|
||||
'<td style=\"width: 250px; height: 20px;\" colspan=\"2\">B2</td>' +
|
||||
'<td style=\"width: 50px; height: 20px;\">B3</td>' +
|
||||
'</tr>' +
|
||||
'<tr>' +
|
||||
'<td style=\"width: 100px; height: 20px;\">C1</td>' +
|
||||
'<td style=\"width: 100px; height: 20px;\">C2</td>' +
|
||||
'<td style=\"width: 200px; height: 20px;\" colspan=\"2\">C3</td>' +
|
||||
'</tr>' +
|
||||
'<tr>' +
|
||||
'<td style=\"width: 400px; height: 20px;\" colspan=\"4\">D1</td>' +
|
||||
'</tr>' +
|
||||
'</tbody>' +
|
||||
'</table>');
|
||||
|
||||
editor.setContent(testResizeTable1);
|
||||
|
||||
table = editor.dom.select('table')[0];
|
||||
|
||||
editor.plugins.table.resizeBars.adjustWidth(table, 50, 3);
|
||||
|
||||
equal(editor.getContent(),
|
||||
'<table style=\"width: 476px;\">' +
|
||||
'<tbody>' +
|
||||
'<tr>' +
|
||||
'<td style=\"width: 200px; height: 20px;\" colspan=\"2\">A1</td>' +
|
||||
'<td style=\"width: 100px; height: 20px;\">A2</td>' +
|
||||
'<td style=\"width: 150px; height: 20px;\">A3</td>' +
|
||||
'</tr>' +
|
||||
'<tr>' +
|
||||
'<td style=\"width: 100px; height: 20px;\">B1</td>' +
|
||||
'<td style=\"width: 200px; height: 20px;\" colspan=\"2\">B2</td>' +
|
||||
'<td style=\"width: 150px; height: 20px;\">B3</td>' +
|
||||
'</tr>' +
|
||||
'<tr>' +
|
||||
'<td style=\"width: 100px; height: 20px;\">C1</td>' +
|
||||
'<td style=\"width: 100px; height: 20px;\">C2</td>' +
|
||||
'<td style=\"width: 250px; height: 20px;\" colspan=\"2\">C3</td>' +
|
||||
'</tr>' +
|
||||
'<tr>' +
|
||||
'<td style=\"width: 450px; height: 20px;\" colspan=\"4\">D1</td>' +
|
||||
'</tr>' +
|
||||
'</tbody>' +
|
||||
'</table>');
|
||||
});
|
||||
|
||||
test("Adjust height", function() {
|
||||
editor.setContent(testResizeTable2);
|
||||
|
||||
var table = editor.dom.select('table')[0];
|
||||
|
||||
editor.plugins.table.resizeBars.adjustHeight(table, 50, 0);
|
||||
|
||||
equal(editor.getContent(),
|
||||
'<table border=\"1\">' +
|
||||
'<tbody>' +
|
||||
'<tr style=\"height: 70px;\">' +
|
||||
'<th style=\"width: 20px; height: 70px;\">A0</th>' +
|
||||
'<th style=\"width: 20px; height: 70px;\">A1</th>' +
|
||||
'<th style=\"width: 20px; height: 70px;\">A2</th>' +
|
||||
'<th style=\"width: 40px; height: 70px;\">A3</th>' +
|
||||
'<th style=\"width: 10px; height: 70px;\">A4</th>' +
|
||||
'</tr>' +
|
||||
'<tr style=\"height: 20px;\">' +
|
||||
'<td style=\"width: 20px; height: 20px;\">B0</td>' +
|
||||
'<td style=\"width: 20px; height: 20px;\">B1</td>' +
|
||||
'<td style=\"width: 20px; height: 20px;\">B2</td>' +
|
||||
'<td style=\"width: 40px; height: 20px;\">B3</td>' +
|
||||
'<td style=\"width: 10px; height: 40px;\" rowspan=\"2\">B3</td>' +
|
||||
'</tr>' +
|
||||
'<tr style=\"height: 20px;\">' +
|
||||
'<td style=\"width: 20px; height: 20px;\">C0</td>' +
|
||||
'<td style=\"width: 20px; height: 20px;\">C1</td>' +
|
||||
'<td style=\"width: 20px; height: 20px;\">C2</td>' +
|
||||
'<td style=\"width: 40px; height: 20px;\">C3</td>' +
|
||||
'</tr>' +
|
||||
'</tbody>' +
|
||||
'</table>');
|
||||
|
||||
editor.setContent(testResizeTable2);
|
||||
|
||||
table = editor.dom.select('table')[0];
|
||||
|
||||
editor.plugins.table.resizeBars.adjustHeight(table, 50, 1);
|
||||
|
||||
equal(editor.getContent(),
|
||||
'<table border=\"1\">' +
|
||||
'<tbody>' +
|
||||
'<tr style=\"height: 20px;\">' +
|
||||
'<th style=\"width: 20px; height: 20px;\">A0</th>' +
|
||||
'<th style=\"width: 20px; height: 20px;\">A1</th>' +
|
||||
'<th style=\"width: 20px; height: 20px;\">A2</th>' +
|
||||
'<th style=\"width: 40px; height: 20px;\">A3</th>' +
|
||||
'<th style=\"width: 10px; height: 20px;\">A4</th>' +
|
||||
'</tr>' +
|
||||
'<tr style=\"height: 70px;\">' +
|
||||
'<td style=\"width: 20px; height: 70px;\">B0</td>' +
|
||||
'<td style=\"width: 20px; height: 70px;\">B1</td>' +
|
||||
'<td style=\"width: 20px; height: 70px;\">B2</td>' +
|
||||
'<td style=\"width: 40px; height: 70px;\">B3</td>' +
|
||||
'<td style=\"width: 10px; height: 90px;\" rowspan=\"2\">B3</td>' +
|
||||
'</tr>' +
|
||||
'<tr style=\"height: 20px;\">' +
|
||||
'<td style=\"width: 20px; height: 20px;\">C0</td>' +
|
||||
'<td style=\"width: 20px; height: 20px;\">C1</td>' +
|
||||
'<td style=\"width: 20px; height: 20px;\">C2</td>' +
|
||||
'<td style=\"width: 40px; height: 20px;\">C3</td>' +
|
||||
'</tr>' +
|
||||
'</tbody>' +
|
||||
'</table>');
|
||||
|
||||
editor.setContent(testResizeTable2);
|
||||
|
||||
table = editor.dom.select('table')[0];
|
||||
|
||||
editor.plugins.table.resizeBars.adjustHeight(table, 50, 2);
|
||||
|
||||
equal(editor.getContent(),
|
||||
'<table border=\"1\">' +
|
||||
'<tbody>' +
|
||||
'<tr style=\"height: 20px;\">' +
|
||||
'<th style=\"width: 20px; height: 20px;\">A0</th>' +
|
||||
'<th style=\"width: 20px; height: 20px;\">A1</th>' +
|
||||
'<th style=\"width: 20px; height: 20px;\">A2</th>' +
|
||||
'<th style=\"width: 40px; height: 20px;\">A3</th>' +
|
||||
'<th style=\"width: 10px; height: 20px;\">A4</th>' +
|
||||
'</tr>' +
|
||||
'<tr style=\"height: 20px;\">' +
|
||||
'<td style=\"width: 20px; height: 20px;\">B0</td>' +
|
||||
'<td style=\"width: 20px; height: 20px;\">B1</td>' +
|
||||
'<td style=\"width: 20px; height: 20px;\">B2</td>' +
|
||||
'<td style=\"width: 40px; height: 20px;\">B3</td>' +
|
||||
'<td style=\"width: 10px; height: 90px;\" rowspan=\"2\">B3</td>' +
|
||||
'</tr>' +
|
||||
'<tr style=\"height: 70px;\">' +
|
||||
'<td style=\"width: 20px; height: 70px;\">C0</td>' +
|
||||
'<td style=\"width: 20px; height: 70px;\">C1</td>' +
|
||||
'<td style=\"width: 20px; height: 70px;\">C2</td>' +
|
||||
'<td style=\"width: 40px; height: 70px;\">C3</td>' +
|
||||
'</tr>' +
|
||||
'</tbody>' +
|
||||
'</table>');
|
||||
|
||||
});
|
||||
})();
|
||||
|
||||
@@ -5,7 +5,6 @@ module("tinymce.Editor", {
|
||||
|
||||
tinymce.init({
|
||||
selector: "#elm1",
|
||||
plugins: wpPlugins,
|
||||
add_unload_trigger: false,
|
||||
disable_nodechange: true,
|
||||
skin: false,
|
||||
@@ -27,7 +26,6 @@ module("tinymce.Editor", {
|
||||
|
||||
tinymce.init({
|
||||
selector: "#elm2",
|
||||
plugins: wpPlugins,
|
||||
add_unload_trigger: false,
|
||||
disable_nodechange: true,
|
||||
skin: false,
|
||||
@@ -309,7 +307,6 @@ asyncTest('remove editor', function() {
|
||||
|
||||
tinymce.init({
|
||||
selector: "#elmx",
|
||||
plugins: wpPlugins,
|
||||
add_unload_trigger: false,
|
||||
disable_nodechange: true,
|
||||
skin: false,
|
||||
@@ -404,18 +401,20 @@ test('addQueryStateHandler', function() {
|
||||
});
|
||||
|
||||
test('Block script execution', function() {
|
||||
editor.setContent('<script></script><script type="x"></script><script type="mce-x"></script>');
|
||||
editor.setContent('<script></script><script type="x"></script><script type="mce-x"></script><p>x</p>');
|
||||
equal(
|
||||
Utils.cleanHtml(editor.getBody().innerHTML),
|
||||
'<script type="mce-no/type"></script>' +
|
||||
'<script type="mce-x"></script>' +
|
||||
'<script type="mce-x"></script>'
|
||||
'<script type="mce-x"></script>' +
|
||||
'<p>x</p>'
|
||||
);
|
||||
equal(
|
||||
editor.getContent(),
|
||||
'<script></script>' +
|
||||
'<script type="x"></script>' +
|
||||
'<script type="x"></script>'
|
||||
'<script type="x"></script>' +
|
||||
'<p>x</p>'
|
||||
);
|
||||
});
|
||||
|
||||
@@ -437,4 +436,50 @@ test('addQueryValueHandler', function() {
|
||||
currentValue = "b";
|
||||
ok(editor.queryCommandValue("CustomCommand2"), "b");
|
||||
ok(lastScope === editor, "Scope is not editor");
|
||||
});
|
||||
|
||||
test('setDirty/isDirty', function() {
|
||||
var lastArgs = null;
|
||||
|
||||
editor.on('dirty', function(e) {
|
||||
lastArgs = e;
|
||||
});
|
||||
|
||||
editor.setDirty(false);
|
||||
strictEqual(lastArgs, null);
|
||||
strictEqual(editor.isDirty(), false);
|
||||
|
||||
editor.setDirty(true);
|
||||
strictEqual(lastArgs.type, 'dirty');
|
||||
strictEqual(editor.isDirty(), true);
|
||||
|
||||
lastArgs = null;
|
||||
editor.setDirty(true);
|
||||
strictEqual(lastArgs, null);
|
||||
strictEqual(editor.isDirty(), true);
|
||||
|
||||
editor.setDirty(false);
|
||||
strictEqual(lastArgs, null);
|
||||
strictEqual(editor.isDirty(), false);
|
||||
});
|
||||
|
||||
test('setMode', function() {
|
||||
var clickCount = 0;
|
||||
|
||||
editor.on('click', function() {
|
||||
clickCount++;
|
||||
});
|
||||
|
||||
editor.dom.fire(editor.getBody(), 'click');
|
||||
equal(clickCount, 1);
|
||||
|
||||
editor.setMode('readonly');
|
||||
equal(editor.theme.panel.find('button:last')[2].disabled(), true);
|
||||
editor.dom.fire(editor.getBody(), 'click');
|
||||
equal(clickCount, 1);
|
||||
|
||||
editor.setMode('design');
|
||||
editor.dom.fire(editor.getBody(), 'click');
|
||||
equal(editor.theme.panel.find('button:last')[2].disabled(), false);
|
||||
equal(clickCount, 2);
|
||||
});
|
||||
@@ -4,7 +4,6 @@ module("tinymce.EditorCommands", {
|
||||
|
||||
tinymce.init({
|
||||
selector: "textarea",
|
||||
plugins: wpPlugins,
|
||||
add_unload_trigger: false,
|
||||
disable_nodechange: true,
|
||||
indent: false,
|
||||
@@ -249,7 +248,7 @@ test('mceInsertContent - forced root block', function() {
|
||||
|
||||
// Forced root block
|
||||
editor.getBody().innerHTML = '';
|
||||
editor.execCommand('mceInsertContent', false, 'test<strong>123</strong><!-- a -->'); // WP: use <strong> instead of <b>
|
||||
editor.execCommand('mceInsertContent', false, 'test<b>123</b><!-- a -->');
|
||||
// Opera adds an extra paragraph since it adds a BR at the end of the contents pass though this for now since it's an minority browser
|
||||
equal(editor.getContent().replace(/<p>\u00a0<\/p>/g, ''), '<p>test<strong>123</strong></p><!-- a -->');
|
||||
});
|
||||
@@ -260,7 +259,7 @@ test('mceInsertContent - mixed inline content inside td', function() {
|
||||
// Forced root block
|
||||
editor.getBody().innerHTML = '<table><tr><td>X</td></tr></table>';
|
||||
Utils.setSelection('td', 0, 'td', 0);
|
||||
editor.execCommand('mceInsertContent', false, 'test<strong>123</strong><!-- a -->'); // WP: use <strong> instead of <b>
|
||||
editor.execCommand('mceInsertContent', false, 'test<b>123</b><!-- a -->');
|
||||
equal(editor.getContent(), '<table><tbody><tr><td>test<strong>123</strong><!-- a -->X</td></tr></tbody></table>');
|
||||
});
|
||||
|
||||
@@ -480,18 +479,18 @@ test('Formatting commands (alignInline)', function() {
|
||||
|
||||
editor.setContent('<img src="tinymce/ui/img/raster.gif" />');
|
||||
editor.selection.select(editor.dom.select('img')[0]);
|
||||
editor.execCommand('JustifyLeft'); // WP use classes
|
||||
equal(editor.getContent(), '<p><img class="alignleft" src="tinymce/ui/img/raster.gif" alt="" /></p>');
|
||||
editor.execCommand('JustifyLeft');
|
||||
equal(editor.getContent(), '<p><img style="float: left;" src="tinymce/ui/img/raster.gif" alt="" /></p>');
|
||||
|
||||
editor.setContent('<img src="tinymce/ui/img/raster.gif" />');
|
||||
editor.selection.select(editor.dom.select('img')[0]);
|
||||
editor.execCommand('JustifyCenter'); // WP use classes
|
||||
equal(editor.getContent(), '<p><img class="aligncenter" src="tinymce/ui/img/raster.gif" alt="" /></p>');
|
||||
editor.execCommand('JustifyCenter');
|
||||
equal(editor.getContent(), '<p><img style="margin-right: auto; margin-left: auto; display: block;" src="tinymce/ui/img/raster.gif" alt="" /></p>');
|
||||
|
||||
editor.setContent('<img src="tinymce/ui/img/raster.gif" />');
|
||||
editor.selection.select(editor.dom.select('img')[0]);
|
||||
editor.execCommand('JustifyRight'); // WP use classes
|
||||
equal(editor.getContent(), '<p><img class="alignright" src="tinymce/ui/img/raster.gif" alt="" /></p>');
|
||||
editor.execCommand('JustifyRight');
|
||||
equal(editor.getContent(), '<p><img style="float: right;" src="tinymce/ui/img/raster.gif" alt="" /></p>');
|
||||
});
|
||||
|
||||
test('mceBlockQuote', function() {
|
||||
|
||||
@@ -4,7 +4,6 @@ module("tinymce.EditorManager", {
|
||||
|
||||
tinymce.init({
|
||||
selector: "textarea",
|
||||
plugins: wpPlugins,
|
||||
add_unload_trigger: false,
|
||||
disable_nodechange: true,
|
||||
skin: false,
|
||||
@@ -56,7 +55,7 @@ asyncTest('Externally destroyed editor', function() {
|
||||
tinymce.init({
|
||||
selector: "textarea",
|
||||
init_instance_callback: function(editor1) {
|
||||
setTimeout(function() {
|
||||
tinymce.util.Delay.setTimeout(function() {
|
||||
// Destroy the editor by setting innerHTML common ajax pattern
|
||||
document.getElementById('view').innerHTML = '<textarea id="' + editor1.id + '"></textarea>';
|
||||
|
||||
@@ -83,7 +82,7 @@ asyncTest('Init/remove on same id', function() {
|
||||
tinymce.init({
|
||||
selector: "#view textarea",
|
||||
init_instance_callback: function() {
|
||||
window.setTimeout(function() {
|
||||
tinymce.util.Delay.setTimeout(function() {
|
||||
QUnit.start();
|
||||
|
||||
strictEqual(tinymce.get().length, 2);
|
||||
|
||||
@@ -51,6 +51,7 @@ ModuleLoader.require([
|
||||
teardown: function() {
|
||||
editor.editorUpload.destroy();
|
||||
editor.settings.automatic_uploads = false;
|
||||
delete editor.settings.images_dataimg_filter;
|
||||
}
|
||||
});
|
||||
|
||||
@@ -134,7 +135,7 @@ ModuleLoader.require([
|
||||
|
||||
editor.settings.images_upload_handler = function(data, success) {
|
||||
uploadCount++;
|
||||
success();
|
||||
success('url');
|
||||
};
|
||||
|
||||
editor.uploadImages(done);
|
||||
@@ -152,7 +153,31 @@ ModuleLoader.require([
|
||||
|
||||
editor.settings.images_upload_handler = function(data, success) {
|
||||
uploadCount++;
|
||||
success();
|
||||
success('url');
|
||||
};
|
||||
|
||||
editor.uploadImages(done);
|
||||
});
|
||||
|
||||
asyncTest('Don\'t upload filtered image', function() {
|
||||
var uploadCount = 0;
|
||||
|
||||
function done() {
|
||||
QUnit.start();
|
||||
equal(uploadCount, 0, 'Should not upload.');
|
||||
}
|
||||
|
||||
editor.getBody().innerHTML = (
|
||||
'<img src="' + testBlobDataUri + '" data-skip="1">'
|
||||
);
|
||||
|
||||
editor.settings.images_dataimg_filter = function(img) {
|
||||
return !img.hasAttribute('data-skip');
|
||||
};
|
||||
|
||||
editor.settings.images_upload_handler = function(data, success) {
|
||||
uploadCount++;
|
||||
success('url');
|
||||
};
|
||||
|
||||
editor.uploadImages(done);
|
||||
|
||||
@@ -4,7 +4,6 @@ module("tinymce.EnterKey", {
|
||||
|
||||
tinymce.init({
|
||||
selector: "textarea",
|
||||
plugins: wpPlugins,
|
||||
add_unload_trigger: false,
|
||||
disable_nodechange: true,
|
||||
indent: false,
|
||||
|
||||
@@ -5,7 +5,6 @@ module("tinymce.ForceBlocks", {
|
||||
|
||||
tinymce.init({
|
||||
selector: "textarea",
|
||||
plugins: wpPlugins,
|
||||
add_unload_trigger: false,
|
||||
indent: false,
|
||||
skin: false,
|
||||
|
||||
@@ -5,7 +5,6 @@ module("tinymce.Formatter - Apply", {
|
||||
|
||||
tinymce.init({
|
||||
selector: "#elm1",
|
||||
plugins: wpPlugins,
|
||||
external_plugins: { noneditable: '../../../../tests/qunit/editor/external-plugins/noneditable/plugin.min.js' }, // WP
|
||||
add_unload_trigger: false,
|
||||
skin: false,
|
||||
@@ -29,7 +28,6 @@ module("tinymce.Formatter - Apply", {
|
||||
|
||||
tinymce.init({
|
||||
selector: "#elm2",
|
||||
plugins: wpPlugins,
|
||||
inline: true,
|
||||
add_unload_trigger: false,
|
||||
skin: false,
|
||||
@@ -1099,7 +1097,7 @@ test("Applying formats in lists", function() {
|
||||
test("Applying formats on a list including child nodes", function(){
|
||||
editor.formatter.register('format', {inline: 'strong'});
|
||||
editor.setContent('<ol><li>a</li><li>b<ul><li>c</li><li>d<br /><ol><li>e</li><li>f</li></ol></li></ul></li><li>g</li></ol>');
|
||||
rng = editor.dom.createRng();
|
||||
var rng = editor.dom.createRng();
|
||||
rng.setStart(editor.dom.select('li')[0].firstChild, 0);
|
||||
rng.setEnd(editor.dom.select('li')[6].firstChild, 1);
|
||||
editor.selection.setRng(rng);
|
||||
@@ -1449,7 +1447,7 @@ test('format inline on contentEditable: false block', function() {
|
||||
editor.setContent('<p>abc</p><p contenteditable="false">def</p>');
|
||||
Utils.setSelection('p:nth-child(2)', 0, 'p:nth-child(2)', 3);
|
||||
editor.formatter.apply('format');
|
||||
equal(editor.getContent(), '<p>abc</p><p>def</p>', 'Text is not bold');
|
||||
equal(editor.getContent(), '<p>abc</p><p contenteditable="false">def</p>', 'Text is not bold');
|
||||
});
|
||||
|
||||
test('format block on contentEditable: false block', function() {
|
||||
@@ -1459,7 +1457,7 @@ test('format block on contentEditable: false block', function() {
|
||||
editor.setContent('<p>abc</p><p contenteditable="false">def</p>');
|
||||
Utils.setSelection('p:nth-child(2)', 0, 'p:nth-child(2)', 3);
|
||||
editor.formatter.apply('format');
|
||||
equal(editor.getContent(), '<p>abc</p><p>def</p>', 'P is not h1');
|
||||
equal(editor.getContent(), '<p>abc</p><p contenteditable="false">def</p>', 'P is not h1');
|
||||
});
|
||||
|
||||
test('contentEditable: false on start and contentEditable: true on end', function() {
|
||||
@@ -1469,7 +1467,7 @@ test('contentEditable: false on start and contentEditable: true on end', functio
|
||||
editor.setContent('<p>abc</p><p contenteditable="false">def</p><p>ghi</p>');
|
||||
Utils.setSelection('p:nth-child(2)', 0, 'p:nth-child(3)', 3);
|
||||
editor.formatter.apply('format');
|
||||
equal(editor.getContent(), '<p>abc</p><p>def</p><p><b>ghi</b></p>', 'Text in last paragraph is bold');
|
||||
equal(editor.getContent(), '<p>abc</p><p contenteditable="false">def</p><p><b>ghi</b></p>', 'Text in last paragraph is bold');
|
||||
});
|
||||
|
||||
test('contentEditable: true on start and contentEditable: false on end', function() {
|
||||
@@ -1479,7 +1477,7 @@ test('contentEditable: true on start and contentEditable: false on end', functio
|
||||
editor.setContent('<p>abc</p><p contenteditable="false">def</p>');
|
||||
Utils.setSelection('p:nth-child(1)', 0, 'p:nth-child(2)', 3);
|
||||
editor.formatter.apply('format');
|
||||
equal(editor.getContent(), '<p><b>abc</b></p><p>def</p>', 'Text in first paragraph is bold');
|
||||
equal(editor.getContent(), '<p><b>abc</b></p><p contenteditable="false">def</p>', 'Text in first paragraph is bold');
|
||||
});
|
||||
|
||||
test('contentEditable: true inside contentEditable: false', function() {
|
||||
@@ -1489,7 +1487,7 @@ test('contentEditable: true inside contentEditable: false', function() {
|
||||
editor.setContent('<p>abc</p><p contenteditable="false"><span contenteditable="true">def</span></p>');
|
||||
Utils.setSelection('span', 0, 'span', 3);
|
||||
editor.formatter.apply('format');
|
||||
equal(editor.getContent(), '<p>abc</p><p><span><b>def</b></span></p>', 'Text is bold');
|
||||
equal(editor.getContent(), '<p>abc</p><p contenteditable="false"><span contenteditable="true"><b>def</b></span></p>', 'Text is bold');
|
||||
});
|
||||
|
||||
test('Del element wrapping blocks', function() {
|
||||
|
||||
@@ -5,7 +5,6 @@ module("tinymce.Formatter - Check", {
|
||||
|
||||
tinymce.init({
|
||||
selector: "#elm1",
|
||||
plugins: wpPlugins,
|
||||
add_unload_trigger: false,
|
||||
extended_valid_elements: 'b,i,span[style|contenteditable]',
|
||||
skin: false,
|
||||
@@ -24,7 +23,6 @@ module("tinymce.Formatter - Check", {
|
||||
|
||||
tinymce.init({
|
||||
selector: "#elm2",
|
||||
plugins: wpPlugins,
|
||||
inline: true,
|
||||
add_unload_trigger: false,
|
||||
indent: false,
|
||||
|
||||
@@ -5,7 +5,6 @@ module("tinymce.Formatter - Remove", {
|
||||
|
||||
tinymce.init({
|
||||
selector: "textarea",
|
||||
plugins: wpPlugins,
|
||||
external_plugins: { noneditable: '../../../../tests/qunit/editor/external-plugins/noneditable/plugin.min.js' }, // WP
|
||||
indent: false,
|
||||
add_unload_trigger: false,
|
||||
@@ -331,6 +330,11 @@ test('Caret format on second word in table cell', function() {
|
||||
});
|
||||
|
||||
test('contentEditable: false on start and contentEditable: true on end', function() {
|
||||
if (tinymce.Env.ie) {
|
||||
ok("Skipped since IE doesn't support selection of parts of a cE=false element", true);
|
||||
return;
|
||||
}
|
||||
|
||||
editor.formatter.register('format', {inline: 'b'});
|
||||
editor.setContent('<p>abc</p><p contenteditable="false"><b>def</b></p><p><b>ghj</b></p>');
|
||||
var rng = editor.dom.createRng();
|
||||
@@ -338,7 +342,7 @@ test('contentEditable: false on start and contentEditable: true on end', functio
|
||||
rng.setEnd(editor.dom.select('b')[1].firstChild, 3);
|
||||
editor.selection.setRng(rng);
|
||||
editor.formatter.remove('format');
|
||||
equal(editor.getContent(), '<p>abc</p><p><b>def</b></p><p>ghj</p>', 'Text in last paragraph is not bold');
|
||||
equal(editor.getContent(), '<p>abc</p><p contenteditable="false"><b>def</b></p><p>ghj</p>', 'Text in last paragraph is not bold');
|
||||
});
|
||||
|
||||
test('contentEditable: true on start and contentEditable: false on end', function() {
|
||||
@@ -346,7 +350,7 @@ test('contentEditable: true on start and contentEditable: false on end', functio
|
||||
editor.setContent('<p>abc</p><p><b>def</b></p><p contenteditable="false"><b>ghj</b></p>');
|
||||
Utils.setSelection('p:nth-child(2) b', 0, 'p:last b', 3);
|
||||
editor.formatter.remove('format');
|
||||
equal(editor.getContent(), '<p>abc</p><p>def</p><p><b>ghj</b></p>', 'Text in first paragraph is not bold');
|
||||
equal(editor.getContent(), '<p>abc</p><p>def</p><p contenteditable="false"><b>ghj</b></p>', 'Text in first paragraph is not bold');
|
||||
});
|
||||
|
||||
test('contentEditable: true inside contentEditable: false', function() {
|
||||
@@ -354,7 +358,7 @@ test('contentEditable: true inside contentEditable: false', function() {
|
||||
editor.setContent('<p>abc</p><p contenteditable="false"><span contenteditable="true"><b>def</b></span></p>');
|
||||
Utils.setSelection('b', 0, 'b', 3);
|
||||
editor.formatter.remove('format');
|
||||
equal(editor.getContent(), '<p>abc</p><p><span>def</span></p>', 'Text is not bold');
|
||||
equal(editor.getContent(), '<p>abc</p><p contenteditable="false"><span contenteditable="true">def</span></p>', 'Text is not bold');
|
||||
});
|
||||
|
||||
test('remove format block on contentEditable: false block', function() {
|
||||
@@ -362,7 +366,7 @@ test('remove format block on contentEditable: false block', function() {
|
||||
editor.setContent('<p>abc</p><h1 contenteditable="false">def</h1>');
|
||||
Utils.setSelection('h1:nth-child(2)', 0, 'h1:nth-child(2)', 3);
|
||||
editor.formatter.remove('format');
|
||||
equal(editor.getContent(), '<p>abc</p><h1>def</h1>', 'H1 is still not h1');
|
||||
equal(editor.getContent(), '<p>abc</p><h1 contenteditable="false">def</h1>', 'H1 is still not h1');
|
||||
});
|
||||
|
||||
test('remove format on del using removeformat format', function() {
|
||||
|
||||
@@ -0,0 +1,167 @@
|
||||
ModuleLoader.require([
|
||||
"tinymce/caret/CaretPosition",
|
||||
"tinymce/caret/CaretContainer",
|
||||
"tinymce/util/VK"
|
||||
], function(CaretPosition, CaretContainer, VK) {
|
||||
module("tinymce.SelectionOverrides", {
|
||||
setupModule: function() {
|
||||
QUnit.stop();
|
||||
|
||||
tinymce.init({
|
||||
selector: "textarea",
|
||||
add_unload_trigger: false,
|
||||
disable_nodechange: true,
|
||||
skin: false,
|
||||
entities: 'raw',
|
||||
indent: false,
|
||||
init_instance_callback: function(ed) {
|
||||
window.editor = ed;
|
||||
QUnit.start();
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
function pressKey(key) {
|
||||
return function() {
|
||||
Utils.pressKey({keyCode: key});
|
||||
};
|
||||
}
|
||||
|
||||
function exitPreTest(arrow, offset, expectedContent) {
|
||||
return function() {
|
||||
editor.setContent('<pre>abc</pre>');
|
||||
|
||||
Utils.setSelection('pre', 1);
|
||||
arrow();
|
||||
equal(editor.getContent(), '<pre>abc</pre>');
|
||||
equal(editor.selection.getNode().nodeName, 'PRE');
|
||||
|
||||
Utils.setSelection('pre', offset);
|
||||
arrow();
|
||||
equal(editor.getContent(), expectedContent);
|
||||
equal(editor.selection.getNode().nodeName, 'P');
|
||||
};
|
||||
}
|
||||
|
||||
var leftArrow = pressKey(VK.LEFT);
|
||||
var rightArrow = pressKey(VK.RIGHT);
|
||||
var backspace = pressKey(VK.BACKSPACE);
|
||||
var forwardDelete = pressKey(VK.DELETE);
|
||||
var upArrow = pressKey(VK.UP);
|
||||
var downArrow = pressKey(VK.DOWN);
|
||||
|
||||
test('left/right over cE=false inline', function() {
|
||||
editor.setContent('<span contenteditable="false">1</span>');
|
||||
editor.selection.select(editor.$('span')[0]);
|
||||
|
||||
leftArrow();
|
||||
equal(editor.getContent(), '<p><span contenteditable="false">1</span></p>');
|
||||
equal(CaretContainer.isCaretContainerInline(editor.selection.getRng().startContainer), true);
|
||||
equal(editor.selection.getRng().startContainer, editor.$('p')[0].firstChild);
|
||||
|
||||
rightArrow();
|
||||
equal(editor.getContent(), '<p><span contenteditable="false">1</span></p>');
|
||||
equal(editor.selection.getNode(), editor.$('span')[0]);
|
||||
|
||||
rightArrow();
|
||||
equal(editor.getContent(), '<p><span contenteditable="false">1</span></p>');
|
||||
equal(CaretContainer.isCaretContainerInline(editor.selection.getRng().startContainer), true);
|
||||
equal(editor.selection.getRng().startContainer, editor.$('p')[0].lastChild);
|
||||
});
|
||||
|
||||
test('left/right over cE=false block', function() {
|
||||
editor.setContent('<p contenteditable="false">1</p>');
|
||||
editor.selection.select(editor.$('p')[0]);
|
||||
|
||||
leftArrow();
|
||||
equal(editor.getContent(), '<p contenteditable="false">1</p>');
|
||||
equal(CaretContainer.isCaretContainerBlock(editor.selection.getRng().startContainer), true);
|
||||
|
||||
rightArrow();
|
||||
equal(editor.getContent(), '<p contenteditable="false">1</p>');
|
||||
equal(editor.selection.getNode(), editor.$('p')[0]);
|
||||
|
||||
rightArrow();
|
||||
equal(editor.getContent(), '<p contenteditable="false">1</p>');
|
||||
equal(CaretContainer.isCaretContainerBlock(editor.selection.getRng().startContainer), true);
|
||||
});
|
||||
|
||||
test('left before cE=false block and type', function() {
|
||||
editor.setContent('<p contenteditable="false">1</p>');
|
||||
editor.selection.select(editor.$('p')[0]);
|
||||
|
||||
leftArrow();
|
||||
Utils.type('a');
|
||||
equal(editor.getContent(), '<p>a</p><p contenteditable="false">1</p>');
|
||||
equal(CaretContainer.isCaretContainerBlock(editor.selection.getRng().startContainer.parentNode), false);
|
||||
});
|
||||
|
||||
test('right after cE=false block and type', function() {
|
||||
editor.setContent('<p contenteditable="false">1</p>');
|
||||
editor.selection.select(editor.$('p')[0]);
|
||||
|
||||
rightArrow();
|
||||
Utils.type('a');
|
||||
equal(editor.getContent(), '<p contenteditable="false">1</p><p>a</p>');
|
||||
equal(CaretContainer.isCaretContainerBlock(editor.selection.getRng().startContainer.parentNode), false);
|
||||
});
|
||||
|
||||
test('up from P to inline cE=false', function() {
|
||||
editor.setContent('<p>a<span contentEditable="false">1</span></p><p>abc</p>');
|
||||
Utils.setSelection('p:last', 3);
|
||||
|
||||
upArrow();
|
||||
equal(CaretContainer.isCaretContainerInline(editor.$('p:first')[0].lastChild), true);
|
||||
});
|
||||
|
||||
test('down from P to inline cE=false', function() {
|
||||
editor.setContent('<p>abc</p><p>a<span contentEditable="false">1</span></p>');
|
||||
Utils.setSelection('p:first', 3);
|
||||
|
||||
downArrow();
|
||||
equal(CaretContainer.isCaretContainerInline(editor.$('p:last')[0].lastChild), true);
|
||||
});
|
||||
|
||||
test('backspace on selected cE=false block', function() {
|
||||
editor.setContent('<p contenteditable="false">1</p>');
|
||||
editor.selection.select(editor.$('p')[0]);
|
||||
|
||||
backspace();
|
||||
equal(editor.getContent(), '');
|
||||
equal(editor.selection.getRng().startContainer, editor.$('p')[0]);
|
||||
});
|
||||
|
||||
test('backspace after cE=false block', function() {
|
||||
editor.setContent('<p contenteditable="false">1</p>');
|
||||
editor.selection.select(editor.$('p')[0]);
|
||||
|
||||
rightArrow();
|
||||
backspace();
|
||||
equal(editor.getContent(), '');
|
||||
equal(editor.selection.getRng().startContainer, editor.$('p')[0]);
|
||||
});
|
||||
|
||||
test('delete on selected cE=false block', function() {
|
||||
editor.setContent('<p contenteditable="false">1</p>');
|
||||
editor.selection.select(editor.$('p')[0]);
|
||||
|
||||
forwardDelete();
|
||||
equal(editor.getContent(), '');
|
||||
equal(editor.selection.getRng().startContainer, editor.$('p')[0]);
|
||||
});
|
||||
|
||||
test('delete inside nested cE=true block element', function() {
|
||||
editor.setContent('<div contenteditable="false">1<div contenteditable="true">2</div>3</div>');
|
||||
Utils.setSelection('div div', 1);
|
||||
|
||||
Utils.type('\b');
|
||||
equal(Utils.cleanHtml(editor.getBody().innerHTML), '<div contenteditable="false">1<div contenteditable="true"><br data-mce-bogus="1"></div>3</div>');
|
||||
equal(editor.selection.getRng().startContainer, editor.$('div div')[0]);
|
||||
});
|
||||
|
||||
test('exit pre block (up)', exitPreTest(upArrow, 0, '<p>\u00a0</p><pre>abc</pre>'));
|
||||
test('exit pre block (left)', exitPreTest(leftArrow, 0, '<p>\u00a0</p><pre>abc</pre>'));
|
||||
test('exit pre block (down)', exitPreTest(downArrow, 3, '<pre>abc</pre><p>\u00a0</p>'));
|
||||
test('exit pre block (right)', exitPreTest(rightArrow, 3, '<pre>abc</pre><p>\u00a0</p>'));
|
||||
});
|
||||
@@ -4,7 +4,6 @@ module("tinymce.Shortcuts", {
|
||||
|
||||
tinymce.init({
|
||||
selector: "textarea",
|
||||
plugins: wpPlugins,
|
||||
add_unload_trigger: false,
|
||||
disable_nodechange: true,
|
||||
indent: false,
|
||||
|
||||
@@ -4,7 +4,6 @@ module("tinymce.UndoManager", {
|
||||
|
||||
tinymce.init({
|
||||
selector: "textarea",
|
||||
plugins: wpPlugins,
|
||||
add_unload_trigger: false,
|
||||
skin: false,
|
||||
init_instance_callback: function(ed) {
|
||||
@@ -368,7 +367,7 @@ test('BeforeAddUndo event', function() {
|
||||
|
||||
test('Dirty state type letter', function() {
|
||||
editor.undoManager.clear();
|
||||
editor.isNotDirty = true;
|
||||
editor.setDirty(false);
|
||||
editor.setContent("<p>a</p>");
|
||||
Utils.setSelection('p', 1);
|
||||
|
||||
@@ -380,7 +379,7 @@ test('Dirty state type letter', function() {
|
||||
|
||||
test('Dirty state type shift+letter', function() {
|
||||
editor.undoManager.clear();
|
||||
editor.isNotDirty = true;
|
||||
editor.setDirty(false);
|
||||
editor.setContent("<p>a</p>");
|
||||
Utils.setSelection('p', 1);
|
||||
|
||||
@@ -392,7 +391,7 @@ test('Dirty state type shift+letter', function() {
|
||||
|
||||
test('Dirty state type AltGr+letter', function() {
|
||||
editor.undoManager.clear();
|
||||
editor.isNotDirty = true;
|
||||
editor.setDirty(false);
|
||||
editor.setContent("<p>a</p>");
|
||||
Utils.setSelection('p', 1);
|
||||
|
||||
|
||||
@@ -0,0 +1,137 @@
|
||||
ModuleLoader.require([
|
||||
'tinymce/caret/CaretBookmark',
|
||||
'tinymce/caret/CaretPosition'
|
||||
], function(CaretBookmark, CaretPosition) {
|
||||
var assertCaretPosition = Utils.assertCaretPosition;
|
||||
|
||||
module('tinymce.caret.CaretBookmark');
|
||||
|
||||
function getRoot() {
|
||||
return document.getElementById('view');
|
||||
}
|
||||
|
||||
function setupHtml(html) {
|
||||
getRoot().innerHTML = html;
|
||||
}
|
||||
|
||||
function createTextPos(textNode, offset) {
|
||||
return new CaretPosition(textNode, offset);
|
||||
}
|
||||
|
||||
test('create element index', function() {
|
||||
setupHtml('<b></b><i></i><b></b>');
|
||||
equal(CaretBookmark.create(getRoot(), CaretPosition.before(getRoot().childNodes[0])), 'b[0],before');
|
||||
equal(CaretBookmark.create(getRoot(), CaretPosition.before(getRoot().childNodes[1])), 'i[0],before');
|
||||
equal(CaretBookmark.create(getRoot(), CaretPosition.before(getRoot().childNodes[2])), 'b[1],before');
|
||||
equal(CaretBookmark.create(getRoot(), CaretPosition.after(getRoot().childNodes[2])), 'b[1],after');
|
||||
});
|
||||
|
||||
test('create text index', function() {
|
||||
setupHtml('a<b></b>b<b></b>ccc');
|
||||
equal(CaretBookmark.create(getRoot(), createTextPos(getRoot().childNodes[0], 0)), 'text()[0],0');
|
||||
equal(CaretBookmark.create(getRoot(), createTextPos(getRoot().childNodes[2], 1)), 'text()[1],1');
|
||||
equal(CaretBookmark.create(getRoot(), createTextPos(getRoot().childNodes[4], 3)), 'text()[2],3');
|
||||
});
|
||||
|
||||
test('create text index on fragmented text nodes', function() {
|
||||
setupHtml('a');
|
||||
getRoot().appendChild(document.createTextNode('b'));
|
||||
getRoot().appendChild(document.createTextNode('c'));
|
||||
getRoot().appendChild(document.createElement('b'));
|
||||
getRoot().appendChild(document.createTextNode('d'));
|
||||
getRoot().appendChild(document.createTextNode('e'));
|
||||
|
||||
equal(getRoot().childNodes.length, 6);
|
||||
equal(CaretBookmark.create(getRoot(), createTextPos(getRoot().childNodes[0], 0)), 'text()[0],0');
|
||||
equal(CaretBookmark.create(getRoot(), createTextPos(getRoot().childNodes[1], 0)), 'text()[0],1');
|
||||
equal(CaretBookmark.create(getRoot(), createTextPos(getRoot().childNodes[2], 0)), 'text()[0],2');
|
||||
equal(CaretBookmark.create(getRoot(), createTextPos(getRoot().childNodes[4], 0)), 'text()[1],0');
|
||||
equal(CaretBookmark.create(getRoot(), createTextPos(getRoot().childNodes[5], 0)), 'text()[1],1');
|
||||
});
|
||||
|
||||
test('create br element index', function() {
|
||||
setupHtml('<p><br data-mce-bogus="1"></p><p><br></p>');
|
||||
equal(CaretBookmark.create(getRoot(), CaretPosition.before(getRoot().firstChild.firstChild)), 'p[0]/br[0],before');
|
||||
equal(CaretBookmark.create(getRoot(), CaretPosition.before(getRoot().lastChild.firstChild)), 'p[1]/br[0],before');
|
||||
});
|
||||
|
||||
test('create deep element index', function() {
|
||||
setupHtml('<p><span>a</span><span><b id="a"></b><b id="b"></b><b id="c"></b></span></p>');
|
||||
equal(CaretBookmark.create(getRoot(), CaretPosition.before(document.getElementById('a'))), 'p[0]/span[1]/b[0],before');
|
||||
equal(CaretBookmark.create(getRoot(), CaretPosition.before(document.getElementById('b'))), 'p[0]/span[1]/b[1],before');
|
||||
equal(CaretBookmark.create(getRoot(), CaretPosition.before(document.getElementById('c'))), 'p[0]/span[1]/b[2],before');
|
||||
equal(CaretBookmark.create(getRoot(), CaretPosition.after(document.getElementById('c'))), 'p[0]/span[1]/b[2],after');
|
||||
});
|
||||
|
||||
test('create deep text index', function() {
|
||||
setupHtml('<p><span>a</span><span id="x">a<b></b>b<b></b>ccc</span></p>');
|
||||
equal(CaretBookmark.create(getRoot(), createTextPos(document.getElementById('x').childNodes[0], 0)), 'p[0]/span[1]/text()[0],0');
|
||||
equal(CaretBookmark.create(getRoot(), createTextPos(document.getElementById('x').childNodes[2], 1)), 'p[0]/span[1]/text()[1],1');
|
||||
equal(CaretBookmark.create(getRoot(), createTextPos(document.getElementById('x').childNodes[4], 3)), 'p[0]/span[1]/text()[2],3');
|
||||
});
|
||||
|
||||
test('create element index from bogus', function() {
|
||||
setupHtml('<b></b><span data-mce-bogus="1"><b></b><span data-mce-bogus="1"><b></b><b></b></span></span>');
|
||||
equal(CaretBookmark.create(getRoot(), CaretPosition.before(getRoot().lastChild.lastChild.childNodes[1])), 'b[3],before');
|
||||
});
|
||||
|
||||
test('resolve element index', function() {
|
||||
setupHtml('<b></b><i></i><b></b>');
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'b[0],before'), CaretPosition.before(getRoot().childNodes[0]));
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'b[1],before'), CaretPosition.before(getRoot().childNodes[2]));
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'b[1],after'), CaretPosition.after(getRoot().childNodes[2]));
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'i[0],before'), CaretPosition.before(getRoot().childNodes[1]));
|
||||
});
|
||||
|
||||
test('resolve odd element names', function() {
|
||||
setupHtml('<h-2X>abc</h-2X>');
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'h-2X[0]/text()[0],2'), createTextPos(getRoot().childNodes[0].firstChild, 2));
|
||||
});
|
||||
|
||||
test('resolve deep element index', function() {
|
||||
setupHtml('<p><span>a</span><span><b id="a"></b><b id="b"></b><b id="c"></b></span></p>');
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'p[0]/span[1]/b[0],before'), CaretPosition.before(document.getElementById('a')));
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'p[0]/span[1]/b[1],before'), CaretPosition.before(document.getElementById('b')));
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'p[0]/span[1]/b[2],before'), CaretPosition.before(document.getElementById('c')));
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'p[0]/span[1]/b[2],after'), CaretPosition.after(document.getElementById('c')));
|
||||
});
|
||||
|
||||
test('resolve text index', function() {
|
||||
setupHtml('a<b></b>b<b></b>ccc');
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'text()[0],0'), createTextPos(getRoot().childNodes[0], 0));
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'text()[1],1'), createTextPos(getRoot().childNodes[2], 1));
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'text()[2],3'), createTextPos(getRoot().childNodes[4], 3));
|
||||
});
|
||||
|
||||
test('resolve text index on fragmented text nodes', function() {
|
||||
setupHtml('a');
|
||||
getRoot().appendChild(document.createTextNode('b'));
|
||||
getRoot().appendChild(document.createTextNode('c'));
|
||||
getRoot().appendChild(document.createElement('b'));
|
||||
getRoot().appendChild(document.createTextNode('d'));
|
||||
getRoot().appendChild(document.createTextNode('e'));
|
||||
|
||||
equal(getRoot().childNodes.length, 6);
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'text()[0],0'), createTextPos(getRoot().childNodes[0], 0));
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'text()[0],1'), createTextPos(getRoot().childNodes[0], 1));
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'text()[0],2'), createTextPos(getRoot().childNodes[1], 1));
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'text()[0],3'), createTextPos(getRoot().childNodes[2], 1));
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'text()[0],4'), createTextPos(getRoot().childNodes[2], 1));
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'text()[1],0'), createTextPos(getRoot().childNodes[4], 0));
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'text()[1],1'), createTextPos(getRoot().childNodes[4], 1));
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'text()[1],2'), createTextPos(getRoot().childNodes[5], 1));
|
||||
});
|
||||
|
||||
test('resolve text index with to high offset', function() {
|
||||
setupHtml('abc');
|
||||
assertCaretPosition(CaretBookmark.resolve(getRoot(), 'text()[0],10'), createTextPos(getRoot().childNodes[0], 3));
|
||||
});
|
||||
|
||||
test('resolve invalid paths', function() {
|
||||
setupHtml('<b><i></i></b>');
|
||||
equal(CaretBookmark.resolve(getRoot(), 'x[0]/y[1]/z[2]'), null);
|
||||
equal(CaretBookmark.resolve(getRoot(), 'b[0]/i[2]'), null);
|
||||
equal(CaretBookmark.resolve(getRoot(), 'x'), null);
|
||||
equal(CaretBookmark.resolve(getRoot(), null), null);
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,63 @@
|
||||
ModuleLoader.require([
|
||||
"tinymce/Env",
|
||||
"tinymce/caret/CaretCandidate",
|
||||
"tinymce/dom/DomQuery",
|
||||
"tinymce/text/Zwsp"
|
||||
], function(Env, CaretCandidate, $, Zwsp) {
|
||||
module("tinymce.caret.CaretCandidate");
|
||||
|
||||
if (!Env.ceFalse) {
|
||||
return;
|
||||
}
|
||||
|
||||
function getRoot() {
|
||||
return document.getElementById('view');
|
||||
}
|
||||
|
||||
function setupHtml(html) {
|
||||
getRoot().innerHTML = html;
|
||||
}
|
||||
|
||||
test('isCaretCandidate', function() {
|
||||
$.each("img input textarea hr table iframe video audio object".split(' '), function(index, name) {
|
||||
equal(CaretCandidate.isCaretCandidate(document.createElement(name)), true);
|
||||
});
|
||||
|
||||
equal(CaretCandidate.isCaretCandidate(document.createTextNode('text')), true);
|
||||
equal(CaretCandidate.isCaretCandidate($('<span contentEditable="false"></span>')[0]), true);
|
||||
equal(CaretCandidate.isCaretCandidate($('<div contentEditable="false"></div>')[0]), true);
|
||||
equal(CaretCandidate.isCaretCandidate($('<table><tr><td>X</td></tr></table>')[0]), true);
|
||||
equal(CaretCandidate.isCaretCandidate($('<span contentEditable="true"></span>')[0]), false);
|
||||
equal(CaretCandidate.isCaretCandidate($('<span></span>')[0]), false);
|
||||
equal(CaretCandidate.isCaretCandidate(document.createComment('text')), false);
|
||||
equal(CaretCandidate.isCaretCandidate($('<span data-mce-caret="1"></span>')[0]), false);
|
||||
equal(CaretCandidate.isCaretCandidate(document.createTextNode(Zwsp.ZWSP)), false);
|
||||
});
|
||||
|
||||
test('isInEditable', function() {
|
||||
setupHtml('abc<span contentEditable="true"><b><span contentEditable="false">X</span></b></span>');
|
||||
equal(CaretCandidate.isInEditable($('span span', getRoot())[0].firstChild, getRoot()), false);
|
||||
equal(CaretCandidate.isInEditable($('span span', getRoot())[0], getRoot()), true);
|
||||
equal(CaretCandidate.isInEditable($('span', getRoot())[0], getRoot()), true);
|
||||
equal(CaretCandidate.isInEditable(getRoot().firstChild, getRoot()), true);
|
||||
});
|
||||
|
||||
test('isAtomic', function() {
|
||||
$.each(["img", "input", "textarea", "hr"], function(index, name) {
|
||||
equal(CaretCandidate.isAtomic(document.createElement(name)), true);
|
||||
});
|
||||
|
||||
equal(CaretCandidate.isAtomic(document.createTextNode('text')), false);
|
||||
equal(CaretCandidate.isAtomic($('<table><tr><td>X</td></tr></table>')[0]), false);
|
||||
equal(CaretCandidate.isAtomic($('<span contentEditable="false">X</span>')[0]), true);
|
||||
equal(CaretCandidate.isAtomic($('<span contentEditable="false">X<span contentEditable="true">Y</span>Z</span>')[0]), false);
|
||||
});
|
||||
|
||||
test('isEditableCaretCandidate', function() {
|
||||
setupHtml('abc<b>xx</b><span contentEditable="false"><span contentEditable="false">X</span></span>');
|
||||
equal(CaretCandidate.isEditableCaretCandidate(getRoot().firstChild, getRoot()), true);
|
||||
equal(CaretCandidate.isEditableCaretCandidate($('b', getRoot())[0]), false);
|
||||
equal(CaretCandidate.isEditableCaretCandidate($('span', getRoot())[0]), true);
|
||||
equal(CaretCandidate.isEditableCaretCandidate($('span span', getRoot())[0]), false);
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,114 @@
|
||||
ModuleLoader.require([
|
||||
"tinymce/Env",
|
||||
"tinymce/caret/CaretContainer",
|
||||
"tinymce/dom/DomQuery",
|
||||
"tinymce/text/Zwsp"
|
||||
], function(Env, CaretContainer, $, Zwsp) {
|
||||
module("tinymce.caret.CaretContainer");
|
||||
|
||||
if (!Env.ceFalse) {
|
||||
return;
|
||||
}
|
||||
|
||||
function setViewHtml(html) {
|
||||
getRoot().innerHTML = html;
|
||||
}
|
||||
|
||||
function getRoot() {
|
||||
return document.getElementById('view');
|
||||
}
|
||||
|
||||
test('isCaretContainer', function() {
|
||||
equal(CaretContainer.isCaretContainer(document.createTextNode('text')), false);
|
||||
equal(CaretContainer.isCaretContainer($('<span></span>')[0]), false);
|
||||
equal(CaretContainer.isCaretContainer($('<span data-mce-caret="1"></span>')[0]), true);
|
||||
equal(CaretContainer.isCaretContainer($('<span data-mce-caret="1">x</span>')[0].firstChild), true);
|
||||
equal(CaretContainer.isCaretContainer(document.createTextNode(Zwsp.ZWSP)), true);
|
||||
});
|
||||
|
||||
test('isCaretContainerBlock', function() {
|
||||
equal(CaretContainer.isCaretContainerBlock(document.createTextNode('text')), false);
|
||||
equal(CaretContainer.isCaretContainerBlock($('<span></span>')[0]), false);
|
||||
equal(CaretContainer.isCaretContainerBlock($('<span data-mce-caret="1"></span>')[0]), true);
|
||||
equal(CaretContainer.isCaretContainerBlock($('<span data-mce-caret="1">a</span>')[0].firstChild), true);
|
||||
equal(CaretContainer.isCaretContainerBlock(document.createTextNode(Zwsp.ZWSP)), false);
|
||||
});
|
||||
|
||||
test('isCaretContainerInline', function() {
|
||||
equal(CaretContainer.isCaretContainerInline(document.createTextNode('text')), false);
|
||||
equal(CaretContainer.isCaretContainerInline($('<span></span>')[0]), false);
|
||||
equal(CaretContainer.isCaretContainerInline($('<span data-mce-caret="1"></span>')[0]), false);
|
||||
equal(CaretContainer.isCaretContainerInline($('<span data-mce-caret="1">a</span>')[0].firstChild), false);
|
||||
equal(CaretContainer.isCaretContainerInline(document.createTextNode(Zwsp.ZWSP)), true);
|
||||
});
|
||||
|
||||
test('insertInline before element', function() {
|
||||
setViewHtml('<span contentEditable="false">1</span>');
|
||||
equal(CaretContainer.insertInline(getRoot().firstChild, true), getRoot().firstChild);
|
||||
equal(CaretContainer.isCaretContainerInline(getRoot().firstChild), true);
|
||||
});
|
||||
|
||||
test('insertInline after element', function() {
|
||||
setViewHtml('<span contentEditable="false">1</span>');
|
||||
equal(CaretContainer.insertInline(getRoot().firstChild, false), getRoot().lastChild);
|
||||
equal(CaretContainer.isCaretContainerInline(getRoot().lastChild), true);
|
||||
});
|
||||
|
||||
test('insertInline between elements', function() {
|
||||
setViewHtml('<span contentEditable="false">1</span><span contentEditable="false">1</span>');
|
||||
equal(CaretContainer.insertBlock('p', getRoot().lastChild, true), getRoot().childNodes[1]);
|
||||
equal(CaretContainer.isCaretContainerBlock(getRoot().childNodes[1]), true);
|
||||
});
|
||||
|
||||
test('insertInline before element with ZWSP', function() {
|
||||
setViewHtml('abc' + Zwsp.ZWSP + '<span contentEditable="false">1</span>');
|
||||
equal(CaretContainer.insertInline(getRoot().lastChild, true), getRoot().childNodes[1]);
|
||||
equal(CaretContainer.isCaretContainerInline(getRoot().firstChild), false);
|
||||
equal(CaretContainer.isCaretContainerInline(getRoot().childNodes[1]), true);
|
||||
});
|
||||
|
||||
test('insertInline after element with ZWSP', function() {
|
||||
setViewHtml('<span contentEditable="false">1</span>' + Zwsp.ZWSP + 'abc');
|
||||
equal(CaretContainer.insertInline(getRoot().firstChild, false), getRoot().childNodes[1]);
|
||||
equal(CaretContainer.isCaretContainerInline(getRoot().lastChild), false);
|
||||
equal(CaretContainer.isCaretContainerInline(getRoot().childNodes[1]), true);
|
||||
});
|
||||
|
||||
test('insertBlock before element', function() {
|
||||
setViewHtml('<span contentEditable="false">1</span>');
|
||||
equal(CaretContainer.insertBlock('p', getRoot().firstChild, true), getRoot().firstChild);
|
||||
equal(CaretContainer.isCaretContainerBlock(getRoot().firstChild), true);
|
||||
});
|
||||
|
||||
test('insertBlock after element', function() {
|
||||
setViewHtml('<span contentEditable="false">1</span>');
|
||||
equal(CaretContainer.insertBlock('p', getRoot().firstChild, false), getRoot().lastChild);
|
||||
equal(CaretContainer.isCaretContainerBlock(getRoot().lastChild), true);
|
||||
});
|
||||
|
||||
test('insertBlock between elements', function() {
|
||||
setViewHtml('<span contentEditable="false">1</span><span contentEditable="false">1</span>');
|
||||
equal(CaretContainer.insertInline(getRoot().lastChild, true), getRoot().childNodes[1]);
|
||||
equal(CaretContainer.isCaretContainerInline(getRoot().childNodes[1]), true);
|
||||
});
|
||||
|
||||
test('remove', function() {
|
||||
setViewHtml('<span contentEditable="false">1</span>');
|
||||
|
||||
CaretContainer.insertInline(getRoot().firstChild, true);
|
||||
equal(CaretContainer.isCaretContainerInline(getRoot().firstChild), true);
|
||||
|
||||
CaretContainer.remove(getRoot().firstChild);
|
||||
equal(CaretContainer.isCaretContainerInline(getRoot().firstChild), false);
|
||||
});
|
||||
|
||||
test('startsWithCaretContainer', function() {
|
||||
setViewHtml(Zwsp.ZWSP + 'abc');
|
||||
equal(CaretContainer.startsWithCaretContainer(getRoot().firstChild), true);
|
||||
});
|
||||
|
||||
test('endsWithCaretContainer', function() {
|
||||
setViewHtml('abc' + Zwsp.ZWSP);
|
||||
equal(CaretContainer.endsWithCaretContainer(getRoot().firstChild), true);
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,173 @@
|
||||
ModuleLoader.require([
|
||||
"tinymce/Env",
|
||||
"tinymce/caret/CaretPosition"
|
||||
], function(Env, CaretPosition) {
|
||||
module("tinymce.caret.CaretPosition");
|
||||
|
||||
if (!Env.ceFalse) {
|
||||
return;
|
||||
}
|
||||
|
||||
var createRange = Utils.createRange,
|
||||
assertCaretPosition = Utils.assertCaretPosition,
|
||||
assertRange = Utils.assertRange;
|
||||
|
||||
function getRoot() {
|
||||
return document.getElementById('view');
|
||||
}
|
||||
|
||||
function setupHtml(html) {
|
||||
tinymce.$(getRoot()).empty();
|
||||
getRoot().innerHTML = html;
|
||||
}
|
||||
|
||||
test('Constructor', function() {
|
||||
setupHtml('abc');
|
||||
strictEqual(new CaretPosition(getRoot(), 0).container(), getRoot());
|
||||
strictEqual(new CaretPosition(getRoot(), 1).offset(), 1);
|
||||
strictEqual(new CaretPosition(getRoot().firstChild, 0).container(), getRoot().firstChild);
|
||||
strictEqual(new CaretPosition(getRoot().firstChild, 1).offset(), 1);
|
||||
});
|
||||
|
||||
test('fromRangeStart', function() {
|
||||
setupHtml('abc');
|
||||
assertCaretPosition(CaretPosition.fromRangeStart(createRange(getRoot(), 0)), new CaretPosition(getRoot(), 0));
|
||||
assertCaretPosition(CaretPosition.fromRangeStart(createRange(getRoot(), 1)), new CaretPosition(getRoot(), 1));
|
||||
assertCaretPosition(CaretPosition.fromRangeStart(createRange(getRoot().firstChild, 1)), new CaretPosition(getRoot().firstChild, 1));
|
||||
});
|
||||
|
||||
test('fromRangeEnd', function() {
|
||||
setupHtml('abc');
|
||||
assertCaretPosition(CaretPosition.fromRangeEnd(createRange(getRoot(), 0, getRoot(), 1)), new CaretPosition(getRoot(), 1));
|
||||
assertCaretPosition(CaretPosition.fromRangeEnd(createRange(getRoot().firstChild, 0, getRoot().firstChild, 1)), new CaretPosition(getRoot().firstChild, 1));
|
||||
});
|
||||
|
||||
test('after', function() {
|
||||
setupHtml('abc<b>123</b>');
|
||||
assertCaretPosition(CaretPosition.after(getRoot().firstChild), new CaretPosition(getRoot(), 1));
|
||||
assertCaretPosition(CaretPosition.after(getRoot().lastChild), new CaretPosition(getRoot(), 2));
|
||||
});
|
||||
|
||||
test('before', function() {
|
||||
setupHtml('abc<b>123</b>');
|
||||
assertCaretPosition(CaretPosition.before(getRoot().firstChild), new CaretPosition(getRoot(), 0));
|
||||
assertCaretPosition(CaretPosition.before(getRoot().lastChild), new CaretPosition(getRoot(), 1));
|
||||
});
|
||||
|
||||
test('isAtStart', function() {
|
||||
setupHtml('abc<b>123</b>123');
|
||||
ok(new CaretPosition(getRoot(), 0).isAtStart());
|
||||
ok(!new CaretPosition(getRoot(), 1).isAtStart());
|
||||
ok(!new CaretPosition(getRoot(), 3).isAtStart());
|
||||
ok(new CaretPosition(getRoot().firstChild, 0).isAtStart());
|
||||
ok(!new CaretPosition(getRoot().firstChild, 1).isAtStart());
|
||||
ok(!new CaretPosition(getRoot().firstChild, 3).isAtStart());
|
||||
});
|
||||
|
||||
test('isAtEnd', function() {
|
||||
setupHtml('abc<b>123</b>123');
|
||||
ok(new CaretPosition(getRoot(), 3).isAtEnd());
|
||||
ok(!new CaretPosition(getRoot(), 2).isAtEnd());
|
||||
ok(!new CaretPosition(getRoot(), 0).isAtEnd());
|
||||
ok(new CaretPosition(getRoot().firstChild, 3).isAtEnd());
|
||||
ok(!new CaretPosition(getRoot().firstChild, 0).isAtEnd());
|
||||
ok(!new CaretPosition(getRoot().firstChild, 1).isAtEnd());
|
||||
});
|
||||
|
||||
test('toRange', function() {
|
||||
setupHtml('abc');
|
||||
assertRange(new CaretPosition(getRoot(), 0).toRange(), createRange(getRoot(), 0));
|
||||
assertRange(new CaretPosition(getRoot(), 1).toRange(), createRange(getRoot(), 1));
|
||||
assertRange(new CaretPosition(getRoot().firstChild, 1).toRange(), createRange(getRoot().firstChild, 1));
|
||||
});
|
||||
|
||||
test('isEqual', function() {
|
||||
setupHtml('abc');
|
||||
equal(new CaretPosition(getRoot(), 0).isEqual(new CaretPosition(getRoot(), 0)), true);
|
||||
equal(new CaretPosition(getRoot(), 1).isEqual(new CaretPosition(getRoot(), 0)), false);
|
||||
equal(new CaretPosition(getRoot(), 0).isEqual(new CaretPosition(getRoot().firstChild, 0)), false);
|
||||
});
|
||||
|
||||
test('isVisible', function() {
|
||||
setupHtml('<b> abc</b>');
|
||||
equal(new CaretPosition(getRoot().firstChild.firstChild, 0).isVisible(), false);
|
||||
equal(new CaretPosition(getRoot().firstChild.firstChild, 3).isVisible(), true);
|
||||
});
|
||||
|
||||
test('getClientRects', function() {
|
||||
setupHtml(
|
||||
'<b>abc</b>' +
|
||||
'<div contentEditable="false">1</div>' +
|
||||
'<div contentEditable="false">2</div>' +
|
||||
'<div contentEditable="false">2</div>' +
|
||||
'<input style="margin: 10px">' +
|
||||
'<input style="margin: 10px">' +
|
||||
'<input style="margin: 10px">' +
|
||||
'<p>123</p>' +
|
||||
'<br>'
|
||||
);
|
||||
|
||||
equal(new CaretPosition(getRoot().firstChild.firstChild, 0).getClientRects().length, 1);
|
||||
equal(new CaretPosition(getRoot(), 1).getClientRects().length, 1);
|
||||
equal(new CaretPosition(getRoot(), 2).getClientRects().length, 2);
|
||||
equal(new CaretPosition(getRoot(), 3).getClientRects().length, 2);
|
||||
equal(new CaretPosition(getRoot(), 4).getClientRects().length, 2);
|
||||
equal(new CaretPosition(getRoot(), 5).getClientRects().length, 1);
|
||||
equal(new CaretPosition(getRoot(), 6).getClientRects().length, 1);
|
||||
equal(new CaretPosition(getRoot(), 7).getClientRects().length, 1);
|
||||
equal(new CaretPosition(getRoot(), 8).getClientRects().length, 1);
|
||||
equal(new CaretPosition(getRoot(), 9).getClientRects().length, 0);
|
||||
});
|
||||
|
||||
test('getClientRects between inline node and cE=false', function() {
|
||||
setupHtml(
|
||||
'<span contentEditable="false">def</span>' +
|
||||
'<b>ghi</b>'
|
||||
);
|
||||
|
||||
equal(new CaretPosition(getRoot(), 1).getClientRects().length, 1);
|
||||
});
|
||||
|
||||
test('getClientRects at last visible character', function() {
|
||||
setupHtml('<b>a </b>');
|
||||
|
||||
equal(new CaretPosition(getRoot().firstChild.firstChild, 1).getClientRects().length, 1);
|
||||
});
|
||||
|
||||
test('getClientRects at extending character', function() {
|
||||
setupHtml('a\u0301b');
|
||||
|
||||
equal(new CaretPosition(getRoot().firstChild, 0).getClientRects().length, 1);
|
||||
equal(new CaretPosition(getRoot().firstChild, 1).getClientRects().length, 0);
|
||||
equal(new CaretPosition(getRoot().firstChild, 2).getClientRects().length, 1);
|
||||
});
|
||||
|
||||
test('getClientRects at whitespace character', function() {
|
||||
setupHtml(' a ');
|
||||
|
||||
equal(new CaretPosition(getRoot().firstChild, 0).getClientRects().length, 0);
|
||||
equal(new CaretPosition(getRoot().firstChild, 1).getClientRects().length, 0);
|
||||
equal(new CaretPosition(getRoot().firstChild, 2).getClientRects().length, 1);
|
||||
equal(new CaretPosition(getRoot().firstChild, 3).getClientRects().length, 1);
|
||||
equal(new CaretPosition(getRoot().firstChild, 4).getClientRects().length, 0);
|
||||
equal(new CaretPosition(getRoot().firstChild, 5).getClientRects().length, 0);
|
||||
});
|
||||
|
||||
test('getNode', function() {
|
||||
setupHtml('<b>abc</b><input><input>');
|
||||
|
||||
equal(new CaretPosition(getRoot().firstChild.firstChild, 0).getNode(), getRoot().firstChild.firstChild);
|
||||
equal(new CaretPosition(getRoot(), 1).getNode(), getRoot().childNodes[1]);
|
||||
equal(new CaretPosition(getRoot(), 2).getNode(), getRoot().childNodes[2]);
|
||||
equal(new CaretPosition(getRoot(), 3).getNode(), getRoot().childNodes[2]);
|
||||
});
|
||||
|
||||
test('getNode (before)', function() {
|
||||
setupHtml('<b>abc</b><input><input>');
|
||||
|
||||
equal(new CaretPosition(getRoot().firstChild.firstChild, 0).getNode(true), getRoot().firstChild.firstChild);
|
||||
equal(new CaretPosition(getRoot(), 1).getNode(true), getRoot().childNodes[0]);
|
||||
equal(new CaretPosition(getRoot(), 2).getNode(true), getRoot().childNodes[1]);
|
||||
equal(new CaretPosition(getRoot(), 3).getNode(true), getRoot().childNodes[2]);
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,243 @@
|
||||
ModuleLoader.require([
|
||||
"tinymce/Env",
|
||||
"tinymce/caret/CaretUtils",
|
||||
"tinymce/caret/CaretPosition",
|
||||
"tinymce/text/Zwsp"
|
||||
], function(Env, CaretUtils, CaretPosition, Zwsp) {
|
||||
module("tinymce.caret.CaretUtils");
|
||||
|
||||
if (!Env.ceFalse) {
|
||||
return;
|
||||
}
|
||||
|
||||
var assertRange = Utils.assertRange,
|
||||
createRange = Utils.createRange,
|
||||
ZWSP = Zwsp.ZWSP;
|
||||
|
||||
function getRoot() {
|
||||
return document.getElementById('view');
|
||||
}
|
||||
|
||||
function setupHtml(html) {
|
||||
getRoot().innerHTML = html;
|
||||
}
|
||||
|
||||
function findElm(selector) {
|
||||
return tinymce.$(selector, getRoot())[0];
|
||||
}
|
||||
|
||||
test('isForwards', function() {
|
||||
equal(CaretUtils.isForwards(1), true);
|
||||
equal(CaretUtils.isForwards(10), true);
|
||||
equal(CaretUtils.isForwards(0), false);
|
||||
equal(CaretUtils.isForwards(-1), false);
|
||||
equal(CaretUtils.isForwards(-10), false);
|
||||
});
|
||||
|
||||
test('isBackwards', function() {
|
||||
equal(CaretUtils.isBackwards(1), false);
|
||||
equal(CaretUtils.isBackwards(10), false);
|
||||
equal(CaretUtils.isBackwards(0), false);
|
||||
equal(CaretUtils.isBackwards(-1), true);
|
||||
equal(CaretUtils.isBackwards(-10), true);
|
||||
});
|
||||
|
||||
test('findNode', function() {
|
||||
setupHtml('<b>abc</b><b><i>123</i></b>def');
|
||||
|
||||
function isBold(node) {
|
||||
return node.nodeName == 'B';
|
||||
}
|
||||
|
||||
function isText(node) {
|
||||
return node.nodeType == 3;
|
||||
}
|
||||
|
||||
equal(CaretUtils.findNode(getRoot(), 1, isBold, getRoot()), getRoot().firstChild);
|
||||
equal(CaretUtils.findNode(getRoot(), 1, isText, getRoot()), getRoot().firstChild.firstChild);
|
||||
equal(CaretUtils.findNode(getRoot().childNodes[1], 1, isBold, getRoot().childNodes[1]), null);
|
||||
equal(CaretUtils.findNode(getRoot().childNodes[1], 1, isText, getRoot().childNodes[1]).nodeName, '#text');
|
||||
equal(CaretUtils.findNode(getRoot(), -1, isBold, getRoot()), getRoot().childNodes[1]);
|
||||
equal(CaretUtils.findNode(getRoot(), -1, isText, getRoot()), getRoot().lastChild);
|
||||
});
|
||||
|
||||
test('getEditingHost', function() {
|
||||
setupHtml('<span contentEditable="true"><span contentEditable="false"></span></span>');
|
||||
|
||||
equal(CaretUtils.getEditingHost(getRoot(), getRoot()), getRoot());
|
||||
equal(CaretUtils.getEditingHost(getRoot().firstChild, getRoot()), getRoot());
|
||||
equal(CaretUtils.getEditingHost(getRoot().firstChild.firstChild, getRoot()), getRoot().firstChild);
|
||||
});
|
||||
|
||||
test('getParentBlock', function() {
|
||||
setupHtml('<p>abc</p><div><p><table><tr><td>X</td></tr></p></div>');
|
||||
|
||||
strictEqual(CaretUtils.getParentBlock(findElm('p:first')), findElm('p:first'));
|
||||
strictEqual(CaretUtils.getParentBlock(findElm('td:first').firstChild), findElm('td:first'));
|
||||
strictEqual(CaretUtils.getParentBlock(findElm('td:first')), findElm('td:first'));
|
||||
strictEqual(CaretUtils.getParentBlock(findElm('table')), findElm('table'));
|
||||
});
|
||||
|
||||
test('isInSameBlock', function() {
|
||||
setupHtml('<p>abc</p><p>def<b>ghj</b></p>');
|
||||
|
||||
strictEqual(CaretUtils.isInSameBlock(
|
||||
CaretPosition(findElm('p:first').firstChild, 0),
|
||||
CaretPosition(findElm('p:last').firstChild, 0)
|
||||
), false);
|
||||
|
||||
strictEqual(CaretUtils.isInSameBlock(
|
||||
CaretPosition(findElm('p:first').firstChild, 0),
|
||||
CaretPosition(findElm('p:first').firstChild, 0)
|
||||
), true);
|
||||
|
||||
strictEqual(CaretUtils.isInSameBlock(
|
||||
CaretPosition(findElm('p:last').firstChild, 0),
|
||||
CaretPosition(findElm('b').firstChild, 0)
|
||||
), true);
|
||||
});
|
||||
|
||||
test('isInSameEditingHost', function() {
|
||||
setupHtml(
|
||||
'<p>abc</p>' +
|
||||
'def' +
|
||||
'<span contentEditable="false">' +
|
||||
'<span contentEditable="true">ghi</span>' +
|
||||
'<span contentEditable="true">jkl</span>' +
|
||||
'</span>'
|
||||
);
|
||||
|
||||
strictEqual(CaretUtils.isInSameEditingHost(
|
||||
CaretPosition(findElm('p:first').firstChild, 0),
|
||||
CaretPosition(findElm('p:first').firstChild, 1)
|
||||
), true);
|
||||
|
||||
strictEqual(CaretUtils.isInSameEditingHost(
|
||||
CaretPosition(findElm('p:first').firstChild, 0),
|
||||
CaretPosition(getRoot().childNodes[1], 1)
|
||||
), true);
|
||||
|
||||
strictEqual(CaretUtils.isInSameEditingHost(
|
||||
CaretPosition(findElm('span span:first').firstChild, 0),
|
||||
CaretPosition(findElm('span span:first').firstChild, 1)
|
||||
), true);
|
||||
|
||||
strictEqual(CaretUtils.isInSameEditingHost(
|
||||
CaretPosition(findElm('p:first').firstChild, 0),
|
||||
CaretPosition(findElm('span span:first').firstChild, 1)
|
||||
), false);
|
||||
|
||||
strictEqual(CaretUtils.isInSameEditingHost(
|
||||
CaretPosition(findElm('span span:first').firstChild, 0),
|
||||
CaretPosition(findElm('span span:last').firstChild, 1)
|
||||
), false);
|
||||
});
|
||||
|
||||
test('isBeforeContentEditableFalse', function() {
|
||||
setupHtml(
|
||||
'<span contentEditable="false"></span>' +
|
||||
'<span contentEditable="false"></span>a'
|
||||
);
|
||||
|
||||
strictEqual(CaretUtils.isBeforeContentEditableFalse(CaretPosition(getRoot(), 0)), true);
|
||||
strictEqual(CaretUtils.isBeforeContentEditableFalse(CaretPosition(getRoot(), 1)), true);
|
||||
strictEqual(CaretUtils.isBeforeContentEditableFalse(CaretPosition(getRoot(), 2)), false);
|
||||
strictEqual(CaretUtils.isBeforeContentEditableFalse(CaretPosition(getRoot(), 3)), false);
|
||||
});
|
||||
|
||||
test('isAfterContentEditableFalse', function() {
|
||||
setupHtml(
|
||||
'<span contentEditable="false"></span>' +
|
||||
'<span contentEditable="false"></span>a'
|
||||
);
|
||||
|
||||
strictEqual(CaretUtils.isAfterContentEditableFalse(CaretPosition(getRoot(), 0)), false);
|
||||
strictEqual(CaretUtils.isAfterContentEditableFalse(CaretPosition(getRoot(), 1)), true);
|
||||
strictEqual(CaretUtils.isAfterContentEditableFalse(CaretPosition(getRoot(), 2)), true);
|
||||
strictEqual(CaretUtils.isAfterContentEditableFalse(CaretPosition(getRoot(), 3)), false);
|
||||
});
|
||||
|
||||
test('normalizeRange', function() {
|
||||
setupHtml(
|
||||
'abc<span contentEditable="false">1</span>def'
|
||||
);
|
||||
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(getRoot().firstChild, 2)), createRange(getRoot().firstChild, 2));
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(getRoot().firstChild, 3)), createRange(getRoot(), 1));
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(getRoot().lastChild, 2)), createRange(getRoot().lastChild, 2));
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(getRoot().lastChild, 0)), createRange(getRoot(), 2));
|
||||
});
|
||||
|
||||
test('normalizeRange deep', function() {
|
||||
setupHtml(
|
||||
'<i><b>abc</b></i><span contentEditable="false">1</span><i><b>def</b></i>'
|
||||
);
|
||||
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(findElm('b').firstChild, 2)), createRange(findElm('b').firstChild, 2));
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(findElm('b').firstChild, 3)), createRange(getRoot(), 1));
|
||||
assertRange(CaretUtils.normalizeRange(-1, getRoot(), createRange(findElm('b:last').firstChild, 1)), createRange(findElm('b:last').firstChild, 1));
|
||||
assertRange(CaretUtils.normalizeRange(-1, getRoot(), createRange(findElm('b:last').firstChild, 0)), createRange(getRoot(), 2));
|
||||
});
|
||||
|
||||
test('normalizeRange break at candidate', function() {
|
||||
setupHtml(
|
||||
'<p><b>abc</b><input></p><p contentEditable="false">1</p><p><input><b>abc</b></p>'
|
||||
);
|
||||
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(findElm('b').firstChild, 3)), createRange(findElm('b').firstChild, 3));
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(findElm('b:last').lastChild, 0)), createRange(findElm('b:last').lastChild, 0));
|
||||
});
|
||||
|
||||
test('normalizeRange at block caret container', function() {
|
||||
setupHtml(
|
||||
'<p data-mce-caret="before">\u00a0</p><p contentEditable="false">1</p><p data-mce-caret="after">\u00a0</p>'
|
||||
);
|
||||
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(findElm('p:first').firstChild, 0)), createRange(getRoot(), 1));
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(findElm('p:first').firstChild, 1)), createRange(getRoot(), 1));
|
||||
assertRange(CaretUtils.normalizeRange(-1, getRoot(), createRange(findElm('p:last').firstChild, 0)), createRange(getRoot(), 2));
|
||||
assertRange(CaretUtils.normalizeRange(-1, getRoot(), createRange(findElm('p:last').firstChild, 1)), createRange(getRoot(), 2));
|
||||
});
|
||||
|
||||
test('normalizeRange at inline caret container', function() {
|
||||
setupHtml(
|
||||
'abc<span contentEditable="false">1</span>def'
|
||||
);
|
||||
|
||||
getRoot().insertBefore(document.createTextNode(ZWSP), getRoot().childNodes[1]);
|
||||
getRoot().insertBefore(document.createTextNode(ZWSP), getRoot().childNodes[3]);
|
||||
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(getRoot().firstChild, 3)), createRange(getRoot(), 2));
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(getRoot().childNodes[1], 0)), createRange(getRoot(), 2));
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(getRoot().childNodes[1], 1)), createRange(getRoot(), 2));
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(getRoot().lastChild, 0)), createRange(getRoot(), 3));
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(getRoot().childNodes[3], 0)), createRange(getRoot(), 3));
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(getRoot().childNodes[3], 1)), createRange(getRoot(), 3));
|
||||
assertRange(CaretUtils.normalizeRange(-1, getRoot(), createRange(getRoot().firstChild, 3)), createRange(getRoot(), 2));
|
||||
assertRange(CaretUtils.normalizeRange(-1, getRoot(), createRange(getRoot().childNodes[1], 0)), createRange(getRoot(), 2));
|
||||
assertRange(CaretUtils.normalizeRange(-1, getRoot(), createRange(getRoot().childNodes[1], 1)), createRange(getRoot(), 2));
|
||||
assertRange(CaretUtils.normalizeRange(-1, getRoot(), createRange(getRoot().lastChild, 0)), createRange(getRoot(), 3));
|
||||
assertRange(CaretUtils.normalizeRange(-1, getRoot(), createRange(getRoot().childNodes[3], 0)), createRange(getRoot(), 3));
|
||||
assertRange(CaretUtils.normalizeRange(-1, getRoot(), createRange(getRoot().childNodes[3], 1)), createRange(getRoot(), 3));
|
||||
});
|
||||
|
||||
test('normalizeRange at inline caret container (combined)', function() {
|
||||
setupHtml(
|
||||
'abc' + ZWSP + '<span contentEditable="false">1</span>' + ZWSP + 'def'
|
||||
);
|
||||
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(getRoot().firstChild, 3)), createRange(getRoot(), 1));
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(getRoot().firstChild, 4)), createRange(getRoot(), 1));
|
||||
assertRange(CaretUtils.normalizeRange(-1, getRoot(), createRange(getRoot().lastChild, 0)), createRange(getRoot(), 2));
|
||||
assertRange(CaretUtils.normalizeRange(-1, getRoot(), createRange(getRoot().lastChild, 1)), createRange(getRoot(), 2));
|
||||
});
|
||||
|
||||
test('normalizeRange at inline caret container after block', function() {
|
||||
setupHtml(
|
||||
'<p><span contentEditable="false">1</span></p>' + ZWSP + 'abc'
|
||||
);
|
||||
|
||||
assertRange(CaretUtils.normalizeRange(1, getRoot(), createRange(getRoot().lastChild, 0)), createRange(getRoot().lastChild, 0));
|
||||
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,273 @@
|
||||
ModuleLoader.require([
|
||||
"tinymce/Env",
|
||||
"tinymce/caret/CaretWalker",
|
||||
"tinymce/caret/CaretPosition"
|
||||
], function(Env, CaretWalker, CaretPosition) {
|
||||
module("tinymce.caret.CaretWalker");
|
||||
|
||||
if (!Env.ceFalse) {
|
||||
return;
|
||||
}
|
||||
|
||||
function getRoot() {
|
||||
return document.getElementById('view');
|
||||
}
|
||||
|
||||
function setupHtml(html) {
|
||||
tinymce.$(getRoot()).empty();
|
||||
getRoot().innerHTML = html;
|
||||
}
|
||||
|
||||
function findElm(selector) {
|
||||
return tinymce.$(selector, getRoot())[0];
|
||||
}
|
||||
|
||||
function findElmPos(selector, offset) {
|
||||
return CaretPosition(tinymce.$(selector, getRoot())[0], offset);
|
||||
}
|
||||
|
||||
function findTextPos(selector, offset) {
|
||||
return CaretPosition(tinymce.$(selector, getRoot())[0].firstChild, offset);
|
||||
}
|
||||
|
||||
var assertCaretPosition = Utils.assertCaretPosition,
|
||||
logicalCaret = new CaretWalker(getRoot());
|
||||
|
||||
test('inside empty root', function() {
|
||||
setupHtml('');
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 0)), null);
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 0)), null);
|
||||
});
|
||||
|
||||
test('on null', function() {
|
||||
setupHtml('');
|
||||
assertCaretPosition(logicalCaret.next(null), null);
|
||||
assertCaretPosition(logicalCaret.prev(null), null);
|
||||
});
|
||||
|
||||
test('within text node in root', function() {
|
||||
setupHtml('abc');
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot().firstChild, 0)), CaretPosition(getRoot().firstChild, 1));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot().firstChild, 1)), CaretPosition(getRoot().firstChild, 2));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot().firstChild, 2)), CaretPosition(getRoot().firstChild, 3));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot().firstChild, 3)), null);
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot().firstChild, 3)), CaretPosition(getRoot().firstChild, 2));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot().firstChild, 2)), CaretPosition(getRoot().firstChild, 1));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot().firstChild, 1)), CaretPosition(getRoot().firstChild, 0));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot().firstChild, 0)), null);
|
||||
});
|
||||
|
||||
test('within text node in element', function() {
|
||||
setupHtml('<p>abc</p>');
|
||||
assertCaretPosition(logicalCaret.next(findTextPos('p', 0)), findTextPos('p', 1));
|
||||
assertCaretPosition(logicalCaret.next(findTextPos('p', 1)), findTextPos('p', 2));
|
||||
assertCaretPosition(logicalCaret.next(findTextPos('p', 2)), findTextPos('p', 3));
|
||||
assertCaretPosition(logicalCaret.next(findTextPos('p', 3)), null);
|
||||
assertCaretPosition(logicalCaret.prev(findTextPos('p', 3)), findTextPos('p', 2));
|
||||
assertCaretPosition(logicalCaret.prev(findTextPos('p', 2)), findTextPos('p', 1));
|
||||
assertCaretPosition(logicalCaret.prev(findTextPos('p', 1)), findTextPos('p', 0));
|
||||
assertCaretPosition(logicalCaret.prev(findTextPos('p', 0)), null);
|
||||
});
|
||||
|
||||
test('from index text node over comment', function() {
|
||||
setupHtml('abcd<!-- x -->abcd');
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 0)), CaretPosition(getRoot().firstChild, 0));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 1)), CaretPosition(getRoot().lastChild, 0));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 2)), CaretPosition(getRoot().firstChild, 4));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 3)), CaretPosition(getRoot().lastChild, 4));
|
||||
});
|
||||
|
||||
test('from text to text across elements', function() {
|
||||
setupHtml('<p>abc</p><p>abc</p>');
|
||||
assertCaretPosition(logicalCaret.next(findTextPos('p:first', 3)), findTextPos('p:last', 0));
|
||||
assertCaretPosition(logicalCaret.prev(findTextPos('p:last', 0)), findTextPos('p:first', 3));
|
||||
});
|
||||
|
||||
test('from text to text across elements with siblings', function() {
|
||||
setupHtml('<p>abc<b><!-- x --></b></p><p><b><!-- x --></b></p><p><b><!-- x --></b>abc</p>');
|
||||
assertCaretPosition(logicalCaret.next(findTextPos('p:first', 3)), CaretPosition(findElm('p:last').lastChild, 0));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(findElm('p:last').lastChild)), findTextPos('p:first', 3));
|
||||
});
|
||||
|
||||
test('from input to text', function() {
|
||||
setupHtml('123<input>456');
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 2)), CaretPosition(getRoot().lastChild, 0));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 1)), CaretPosition(getRoot().firstChild, 3));
|
||||
});
|
||||
|
||||
test('from input to input across elements', function() {
|
||||
setupHtml('<p><input></p><p><input></p>');
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(findElm('p:first'), 1)), CaretPosition(findElm('p:last'), 0));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(findElm('p:last'), 0)), CaretPosition(findElm('p:first'), 1));
|
||||
});
|
||||
|
||||
test('from br to br across elements', function() {
|
||||
setupHtml('<p><br></p><p><br></p>');
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(findElm('p:first'), 1)), CaretPosition(findElm('p:last'), 0));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(findElm('p:last'), 0)), CaretPosition(findElm('p:first'), 1));
|
||||
});
|
||||
|
||||
test('from before/after br to text', function() {
|
||||
setupHtml('<br>123<br>456<br>789');
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 0)), CaretPosition(getRoot(), 1));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 2)), CaretPosition(getRoot(), 3));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 4)), CaretPosition(getRoot(), 5));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 5)), CaretPosition(getRoot().lastChild, 0));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 5)), CaretPosition(getRoot(), 4));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 4)), CaretPosition(getRoot().childNodes[3], 3));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 1)), CaretPosition(getRoot(), 0));
|
||||
});
|
||||
|
||||
test('over br', function() {
|
||||
setupHtml('<br><br><br>');
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 0)), CaretPosition(getRoot(), 1));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 1)), CaretPosition(getRoot(), 2));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 2)), CaretPosition(getRoot(), 3));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 3)), null);
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 3)), CaretPosition(getRoot(), 2));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 2)), CaretPosition(getRoot(), 1));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 1)), CaretPosition(getRoot(), 0));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 0)), null);
|
||||
});
|
||||
|
||||
test('over input', function() {
|
||||
setupHtml('<input><input><input>');
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 0)), CaretPosition(getRoot(), 1));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 1)), CaretPosition(getRoot(), 2));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 2)), CaretPosition(getRoot(), 3));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 3)), null);
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 3)), CaretPosition(getRoot(), 2));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 2)), CaretPosition(getRoot(), 1));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 1)), CaretPosition(getRoot(), 0));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 0)), null);
|
||||
});
|
||||
|
||||
test('over img', function() {
|
||||
setupHtml('<img src="about:blank"><img src="about:blank"><img src="about:blank">');
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 0)), CaretPosition(getRoot(), 1));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 1)), CaretPosition(getRoot(), 2));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 2)), CaretPosition(getRoot(), 3));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 3)), null);
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 3)), CaretPosition(getRoot(), 2));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 2)), CaretPosition(getRoot(), 1));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 1)), CaretPosition(getRoot(), 0));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 0)), null);
|
||||
});
|
||||
|
||||
test('over script/style/textarea', function() {
|
||||
setupHtml('a<script>//x</script>b<style>x{}</style>c<textarea>x</textarea>d');
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot().firstChild, 1)), CaretPosition(getRoot().childNodes[2], 0));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot().childNodes[2], 1)), CaretPosition(getRoot().childNodes[4], 0));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 5)), CaretPosition(getRoot(), 6));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 6)), CaretPosition(getRoot(), 5));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot().childNodes[4], 0)), CaretPosition(getRoot().childNodes[2], 1));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 2)), CaretPosition(getRoot().childNodes[0], 1));
|
||||
});
|
||||
|
||||
test('around tables', function() {
|
||||
setupHtml('a<table><tr><td>A</td></tr></table><table><tr><td>B</td></tr></table>b');
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot().firstChild, 1)), CaretPosition(getRoot(), 1));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 1)), findTextPos('td:first', 0));
|
||||
assertCaretPosition(logicalCaret.next(findTextPos('td:first', 1)), CaretPosition(getRoot(), 2));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 2)), findTextPos('td:last', 0));
|
||||
assertCaretPosition(logicalCaret.next(findTextPos('table:last td', 1)), CaretPosition(getRoot(), 3));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 3)), CaretPosition(getRoot().lastChild, 0));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot().lastChild, 0)), CaretPosition(getRoot(), 3));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 3)), findTextPos('td:last', 1));
|
||||
assertCaretPosition(logicalCaret.prev(findTextPos('td:last', 0)), CaretPosition(getRoot(), 2));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 2)), findTextPos('td:first', 1));
|
||||
assertCaretPosition(logicalCaret.prev(findTextPos('td:first', 0)), CaretPosition(getRoot(), 1));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 1)), CaretPosition(getRoot().firstChild, 1));
|
||||
});
|
||||
|
||||
test('over cE=false', function() {
|
||||
setupHtml('123<span contentEditable="false">a</span>456');
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot().firstChild, 3)), CaretPosition(getRoot(), 1));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 1)), CaretPosition(getRoot(), 2));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 2)), CaretPosition(getRoot(), 1));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot().lastChild, 0)), CaretPosition(getRoot(), 2));
|
||||
});
|
||||
/*
|
||||
test('from outside cE=false to nested cE=true', function() {
|
||||
setupHtml('abc<span contentEditable="false">b<span contentEditable="true">c</span></span>def');
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot().firstChild, 3)), CaretPosition(getRoot(), 1));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 1)), findTextPos('span span', 0));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot().lastChild, 0)), CaretPosition(getRoot(), 2));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 2)), findTextPos('span span', 1));
|
||||
});
|
||||
|
||||
test('from outside cE=false to nested cE=true before/after cE=false', function() {
|
||||
setupHtml('a<span contentEditable="false">b<span contentEditable="true"><span contentEditable="false"></span></span></span>d');
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot(), 1)), CaretPosition(findElm('span span'), 0));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(findElm('span span'), 1)), CaretPosition(getRoot(), 2));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot(), 2)), CaretPosition(findElm('span span'), 1));
|
||||
});
|
||||
*/
|
||||
test('from inside cE=true in cE=false to after cE=false', function() {
|
||||
setupHtml(
|
||||
'<p>' +
|
||||
'<span contentEditable="false">' +
|
||||
'<span contentEditable="true">' +
|
||||
'abc' +
|
||||
'</span>' +
|
||||
'def' +
|
||||
'</span>' +
|
||||
'</p>' +
|
||||
'<p>abc</p>'
|
||||
);
|
||||
|
||||
assertCaretPosition(logicalCaret.next(findTextPos('span span', 3)), CaretPosition(findElm('p'), 1));
|
||||
});
|
||||
|
||||
test('around cE=false inside nested cE=true', function() {
|
||||
setupHtml(
|
||||
'<span contentEditable="false">' +
|
||||
'<span contentEditable="true">' +
|
||||
'<span contentEditable="false">1</span>' +
|
||||
'<span contentEditable="false">2</span>' +
|
||||
'<span contentEditable="false">3</span>' +
|
||||
'</span>' +
|
||||
'</span>'
|
||||
);
|
||||
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(findElm('span span'), 0)), CaretPosition(findElm('span span'), 1));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(findElm('span span'), 1)), CaretPosition(findElm('span span'), 2));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(findElm('span span'), 2)), CaretPosition(findElm('span span'), 3));
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(findElm('span span'), 3)), CaretPosition(getRoot(), 1));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(findElm('span span'), 0)), CaretPosition(getRoot(), 0));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(findElm('span span'), 1)), CaretPosition(findElm('span span'), 0));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(findElm('span span'), 2)), CaretPosition(findElm('span span'), 1));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(findElm('span span'), 3)), CaretPosition(findElm('span span'), 2));
|
||||
});
|
||||
|
||||
test('next from last node', function() {
|
||||
setupHtml(
|
||||
'<p><b><input></b></p>' +
|
||||
'<input>' +
|
||||
'<p><b><input></b></p>'
|
||||
);
|
||||
|
||||
assertCaretPosition(logicalCaret.next(findElmPos('p:first', 1)), CaretPosition(getRoot(), 1));
|
||||
assertCaretPosition(logicalCaret.next(findElmPos('p:last', 1)), null);
|
||||
});
|
||||
|
||||
test('left/right between cE=false inlines in different blocks', function() {
|
||||
setupHtml(
|
||||
'<p>' +
|
||||
'<span contentEditable="false">abc</span>' +
|
||||
'</p>' +
|
||||
'<p>' +
|
||||
'<span contentEditable="false">def</span>' +
|
||||
'</p>'
|
||||
);
|
||||
|
||||
assertCaretPosition(logicalCaret.next(findElmPos('p:first', 1)), findElmPos('p:last', 0));
|
||||
assertCaretPosition(logicalCaret.prev(findElmPos('p:last', 0)), findElmPos('p:first', 1));
|
||||
});
|
||||
|
||||
test('never into caret containers', function() {
|
||||
setupHtml('abc<b data-mce-caret="1">def</b>ghi');
|
||||
assertCaretPosition(logicalCaret.next(CaretPosition(getRoot().firstChild, 3)), CaretPosition(getRoot().lastChild, 0));
|
||||
assertCaretPosition(logicalCaret.prev(CaretPosition(getRoot().lastChild, 0)), CaretPosition(getRoot().firstChild, 3));
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,94 @@
|
||||
ModuleLoader.require([
|
||||
"tinymce/Env",
|
||||
"tinymce/caret/FakeCaret",
|
||||
"tinymce/dom/DomQuery",
|
||||
"tinymce/text/Zwsp"
|
||||
], function(Env, FakeCaret, $, Zwsp) {
|
||||
var fakeCaret;
|
||||
|
||||
if (!Env.ceFalse) {
|
||||
return;
|
||||
}
|
||||
|
||||
module("tinymce.caret.FakeCaret", {
|
||||
setupModule: function() {
|
||||
fakeCaret = new FakeCaret($('#view')[0], isBlock);
|
||||
},
|
||||
|
||||
teardownModule: function() {
|
||||
fakeCaret.destroy();
|
||||
}
|
||||
});
|
||||
|
||||
function isBlock(node) {
|
||||
return node.nodeName == 'DIV';
|
||||
}
|
||||
|
||||
test('show/hide (before, block)', function() {
|
||||
var rng, $fakeCaretElm;
|
||||
|
||||
$('#view').html('<div>a</div>');
|
||||
|
||||
rng = fakeCaret.show(true, $('#view div')[0]);
|
||||
$fakeCaretElm = $('#view').children();
|
||||
|
||||
equal($fakeCaretElm[0].nodeName, 'P');
|
||||
equal($fakeCaretElm.attr('data-mce-caret'), 'before');
|
||||
Utils.assertRange(rng, Utils.createRange($fakeCaretElm[0].firstChild, 0, $fakeCaretElm[0].firstChild, 1));
|
||||
|
||||
fakeCaret.hide();
|
||||
equal($('#view *[data-mce-caret]').length, 0);
|
||||
});
|
||||
|
||||
test('show/hide (before, block)', function() {
|
||||
var rng, $fakeCaretElm;
|
||||
|
||||
$('#view').html('<div>a</div>');
|
||||
|
||||
rng = fakeCaret.show(false, $('#view div')[0]);
|
||||
$fakeCaretElm = $('#view').children();
|
||||
|
||||
equal($fakeCaretElm[1].nodeName, 'P');
|
||||
equal($fakeCaretElm.eq(1).attr('data-mce-caret'), 'after');
|
||||
Utils.assertRange(rng, Utils.createRange($fakeCaretElm[1].firstChild, 0, $fakeCaretElm[1].firstChild, 1));
|
||||
|
||||
fakeCaret.hide();
|
||||
equal($('#view *[data-mce-caret]').length, 0);
|
||||
});
|
||||
|
||||
test('show/hide (before, inline)', function() {
|
||||
var rng, $fakeCaretText;
|
||||
|
||||
$('#view').html('<span>a</span>');
|
||||
|
||||
rng = fakeCaret.show(true, $('#view span')[0]);
|
||||
$fakeCaretText = $('#view').contents();
|
||||
|
||||
equal($fakeCaretText[0].nodeName, '#text');
|
||||
equal($fakeCaretText[0].data, Zwsp.ZWSP);
|
||||
Utils.assertRange(rng, Utils.createRange($fakeCaretText[0], 1));
|
||||
|
||||
fakeCaret.hide();
|
||||
equal($('#view').contents()[0].nodeName, 'SPAN');
|
||||
});
|
||||
|
||||
test('show/hide (after, inline)', function() {
|
||||
var rng, $fakeCaretText;
|
||||
|
||||
$('#view').html('<span>a</span>');
|
||||
|
||||
rng = fakeCaret.show(false, $('#view span')[0]);
|
||||
$fakeCaretText = $('#view').contents();
|
||||
|
||||
equal($fakeCaretText[1].nodeName, '#text');
|
||||
equal($fakeCaretText[1].data, Zwsp.ZWSP);
|
||||
Utils.assertRange(rng, Utils.createRange($fakeCaretText[1], 1));
|
||||
|
||||
fakeCaret.hide();
|
||||
equal($('#view').contents()[0].nodeName, 'SPAN');
|
||||
});
|
||||
|
||||
test('getCss', function() {
|
||||
equal(fakeCaret.getCss().length > 10, true);
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,28 @@
|
||||
ModuleLoader.require([
|
||||
"tinymce/Env",
|
||||
"tinymce/caret/LineUtils"
|
||||
], function(Env, LineUtils) {
|
||||
module("tinymce.caret.LineUtils");
|
||||
|
||||
if (!Env.ceFalse) {
|
||||
return;
|
||||
}
|
||||
|
||||
function rect(x, y, w, h) {
|
||||
return {
|
||||
left: x,
|
||||
top: y,
|
||||
bottom: y + h,
|
||||
right: x + w,
|
||||
width: w,
|
||||
height: h
|
||||
};
|
||||
}
|
||||
|
||||
test('findClosestClientRect', function() {
|
||||
deepEqual(LineUtils.findClosestClientRect([rect(10, 10, 10, 10), rect(30, 10, 10, 10)], 15), rect(10, 10, 10, 10));
|
||||
deepEqual(LineUtils.findClosestClientRect([rect(10, 10, 10, 10), rect(30, 10, 10, 10)], 27), rect(30, 10, 10, 10));
|
||||
deepEqual(LineUtils.findClosestClientRect([rect(10, 10, 10, 10), rect(30, 10, 10, 10)], 23), rect(10, 10, 10, 10));
|
||||
deepEqual(LineUtils.findClosestClientRect([rect(10, 10, 10, 10), rect(20, 10, 10, 10)], 13), rect(10, 10, 10, 10));
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,88 @@
|
||||
ModuleLoader.require([
|
||||
"tinymce/Env",
|
||||
"tinymce/caret/LineWalker",
|
||||
"tinymce/caret/CaretPosition",
|
||||
"tinymce/dom/DomQuery"
|
||||
], function(Env, LineWalker, CaretPosition, $) {
|
||||
module("tinymce.caret.LineWalker");
|
||||
|
||||
if (!Env.ceFalse) {
|
||||
return;
|
||||
}
|
||||
|
||||
test('positionsUntil', function() {
|
||||
var result, predicateCallCount = 0;
|
||||
|
||||
function predicate() {
|
||||
predicateCallCount++;
|
||||
return false;
|
||||
}
|
||||
|
||||
$('#view').html('<span contentEditable="false">a</span><span>b</span>');
|
||||
result = LineWalker.positionsUntil(1, $('#view')[0], predicate, $('#view')[0].firstChild);
|
||||
equal(result.length, 3);
|
||||
equal(result[0].position.getNode(), $('#view')[0].lastChild);
|
||||
equal(result[1].position.getNode(), $('#view')[0].lastChild.firstChild);
|
||||
equal(result[2].position.getNode(), $('#view')[0].lastChild.firstChild);
|
||||
equal(predicateCallCount, 3);
|
||||
|
||||
predicateCallCount = 0;
|
||||
$('#view').html('<span>a</span><span contentEditable="false">b</span>');
|
||||
result = LineWalker.positionsUntil(-1, $('#view')[0], predicate, $('#view')[0].lastChild);
|
||||
equal(result.length, 3);
|
||||
equal(result[0].position.getNode(), $('#view')[0].lastChild);
|
||||
equal(result[1].position.getNode(), $('#view')[0].firstChild.firstChild);
|
||||
equal(result[2].position.getNode(), $('#view')[0].firstChild.firstChild);
|
||||
equal(predicateCallCount, 3);
|
||||
});
|
||||
|
||||
test('upUntil', function() {
|
||||
var caretPosition, result, predicateCallCount = 0;
|
||||
|
||||
function predicate() {
|
||||
predicateCallCount++;
|
||||
return false;
|
||||
}
|
||||
|
||||
$('#view').html('<p>a</p><p>b</p><p>c</p>');
|
||||
|
||||
caretPosition = new CaretPosition($('#view')[0].lastChild.lastChild, 1);
|
||||
result = LineWalker.upUntil($('#view')[0], predicate, caretPosition);
|
||||
|
||||
equal(result.length, 3);
|
||||
equal(result[0].line, 0);
|
||||
equal(result[1].line, 1);
|
||||
equal(result[2].line, 2);
|
||||
equal(predicateCallCount, 3);
|
||||
});
|
||||
|
||||
test('downUntil', function() {
|
||||
var caretPosition, result, predicateCallCount = 0;
|
||||
|
||||
function predicate() {
|
||||
predicateCallCount++;
|
||||
return false;
|
||||
}
|
||||
|
||||
$('#view').html('<p>a</p><p>b</p><p>c</p>');
|
||||
|
||||
caretPosition = new CaretPosition($('#view')[0].firstChild.firstChild, 0);
|
||||
result = LineWalker.downUntil($('#view')[0], predicate, caretPosition);
|
||||
|
||||
equal(result.length, 3);
|
||||
equal(result[0].line, 0);
|
||||
equal(result[1].line, 1);
|
||||
equal(result[2].line, 2);
|
||||
equal(predicateCallCount, 3);
|
||||
});
|
||||
|
||||
test('isAboveLine', function() {
|
||||
equal(LineWalker.isAboveLine(5)({line: 10}), true);
|
||||
equal(LineWalker.isAboveLine(5)({line: 2}), false);
|
||||
});
|
||||
|
||||
test('isLine', function() {
|
||||
equal(LineWalker.isLine(3)({line: 3}), true);
|
||||
equal(LineWalker.isLine(3)({line: 4}), false);
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,34 @@
|
||||
ModuleLoader.require([
|
||||
"tinymce/util/Arr",
|
||||
"tinymce/dom/Dimensions"
|
||||
], function(Arr, Dimensions) {
|
||||
module("tinymce.dom.Dimensions");
|
||||
|
||||
function setupHtml(html) {
|
||||
var viewElm;
|
||||
|
||||
viewElm = document.getElementById('view');
|
||||
viewElm.innerHTML = html;
|
||||
|
||||
return viewElm;
|
||||
}
|
||||
|
||||
test('getClientRects', function() {
|
||||
var viewElm = setupHtml('abc<span>123</span>');
|
||||
|
||||
strictEqual(Dimensions.getClientRects(viewElm.firstChild).length, 1);
|
||||
strictEqual(Dimensions.getClientRects(viewElm.lastChild).length, 1);
|
||||
strictEqual(Dimensions.getClientRects(viewElm.firstChild)[0].node, viewElm.firstChild);
|
||||
strictEqual(Dimensions.getClientRects(viewElm.firstChild)[0].left > 3, true);
|
||||
strictEqual(Dimensions.getClientRects(viewElm.lastChild)[0].left > 3, true);
|
||||
});
|
||||
|
||||
test('getClientRects from array', function() {
|
||||
var viewElm = setupHtml('<b>a</b><b>b</b>'),
|
||||
clientRects = Dimensions.getClientRects(Arr.toArray(viewElm.childNodes));
|
||||
|
||||
strictEqual(clientRects.length, 2);
|
||||
strictEqual(clientRects[0].node, viewElm.childNodes[0]);
|
||||
strictEqual(clientRects[1].node, viewElm.childNodes[1]);
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,81 @@
|
||||
ModuleLoader.require([
|
||||
"tinymce/dom/NodeType",
|
||||
"tinymce/dom/DomQuery"
|
||||
], function(NodeType, $) {
|
||||
module("tinymce.dom.NodeType");
|
||||
|
||||
test('isText/isElement/isComment', function() {
|
||||
strictEqual(NodeType.isText(document.createTextNode("x")), true);
|
||||
strictEqual(NodeType.isText(null), false);
|
||||
strictEqual(NodeType.isText(document.createElement("div")), false);
|
||||
strictEqual(NodeType.isText(document.createComment("x")), false);
|
||||
|
||||
strictEqual(NodeType.isElement(document.createElement("div")), true);
|
||||
strictEqual(NodeType.isElement(null), false);
|
||||
strictEqual(NodeType.isElement(document.createTextNode("x")), false);
|
||||
strictEqual(NodeType.isElement(document.createComment("x")), false);
|
||||
|
||||
strictEqual(NodeType.isComment(document.createComment("x")), true);
|
||||
strictEqual(NodeType.isComment(null), false);
|
||||
strictEqual(NodeType.isComment(document.createTextNode("x")), false);
|
||||
strictEqual(NodeType.isComment(document.createElement("div")), false);
|
||||
});
|
||||
|
||||
test('isBr', function() {
|
||||
strictEqual(NodeType.isBr(null), false);
|
||||
strictEqual(NodeType.isBr(document.createTextNode("x")), false);
|
||||
strictEqual(NodeType.isBr(document.createElement('br')), true);
|
||||
strictEqual(NodeType.isBr(document.createComment("x")), false);
|
||||
});
|
||||
|
||||
test('isContentEditableTrue', function() {
|
||||
strictEqual(NodeType.isContentEditableTrue(null), false);
|
||||
strictEqual(NodeType.isContentEditableTrue(document.createComment("x")), false);
|
||||
strictEqual(NodeType.isContentEditableTrue(document.createTextNode("x")), false);
|
||||
strictEqual(NodeType.isContentEditableTrue(document.createElement('div')), false);
|
||||
strictEqual(NodeType.isContentEditableTrue($('<div contentEditable="true"></div>')[0]), true);
|
||||
strictEqual(NodeType.isContentEditableTrue($('<div contentEditable="trUe"></div>')[0]), true);
|
||||
strictEqual(NodeType.isContentEditableTrue($('<div contentEditable="false"></div>')[0]), false);
|
||||
strictEqual(NodeType.isContentEditableTrue($('<div contentEditable="fAlse"></div>')[0]), false);
|
||||
strictEqual(NodeType.isContentEditableTrue($('<div contentEditable="inherit"></div>')[0]), false);
|
||||
});
|
||||
|
||||
test('isContentEditableFalse', function() {
|
||||
strictEqual(NodeType.isContentEditableFalse(null), false);
|
||||
strictEqual(NodeType.isContentEditableFalse(document.createComment("x")), false);
|
||||
strictEqual(NodeType.isContentEditableFalse(document.createTextNode("x")), false);
|
||||
strictEqual(NodeType.isContentEditableFalse(document.createElement('div')), false);
|
||||
strictEqual(NodeType.isContentEditableFalse($('<div contentEditable="true"></div>')[0]), false);
|
||||
strictEqual(NodeType.isContentEditableFalse($('<div contentEditable="trUe"></div>')[0]), false);
|
||||
strictEqual(NodeType.isContentEditableFalse($('<div contentEditable="false"></div>')[0]), true);
|
||||
strictEqual(NodeType.isContentEditableFalse($('<div contentEditable="fAlse"></div>')[0]), true);
|
||||
strictEqual(NodeType.isContentEditableFalse($('<div contentEditable="inherit"></div>')[0]), false);
|
||||
});
|
||||
|
||||
test('matchNodeNames', function() {
|
||||
var matchNodeNames = NodeType.matchNodeNames('a div #text');
|
||||
|
||||
strictEqual(matchNodeNames(null), false);
|
||||
strictEqual(matchNodeNames(document.createTextNode('x')), true);
|
||||
strictEqual(matchNodeNames(document.createElement('a')), true);
|
||||
strictEqual(matchNodeNames(document.createElement('div')), true);
|
||||
strictEqual(matchNodeNames(document.createElement('b')), false);
|
||||
});
|
||||
|
||||
test('hasPropValue', function() {
|
||||
var hasTabIndex3 = NodeType.hasPropValue('tabIndex', 3);
|
||||
|
||||
strictEqual(hasTabIndex3(null), false);
|
||||
strictEqual(hasTabIndex3($('<div tabIndex="3"></div>')[0]), true);
|
||||
strictEqual(hasTabIndex3(document.createElement('div')), false);
|
||||
strictEqual(hasTabIndex3(document.createElement('b')), false);
|
||||
});
|
||||
|
||||
test('isBogus', function() {
|
||||
strictEqual(NodeType.isBogus($('<div data-mce-bogus="1"></div>')[0]), true);
|
||||
strictEqual(NodeType.isBogus($('<div data-mce-bogus="all"></div>')[0]), true);
|
||||
strictEqual(NodeType.isBogus($('<div></div>')[0]), false);
|
||||
strictEqual(NodeType.isBogus(document.createTextNode('test')), false);
|
||||
strictEqual(NodeType.isBogus(null), false);
|
||||
});
|
||||
});
|
||||
File diff suppressed because it is too large
Load Diff
@@ -89,7 +89,9 @@ test('Form elements (general)', function() {
|
||||
equal(ser.serialize(DOM.get('test')), '<label for="test">label</label>');
|
||||
|
||||
DOM.setHTML('test', '<input type="checkbox" value="test" /><input type="button" /><textarea></textarea>');
|
||||
equal(ser.serialize(DOM.get('test')), '<input type="checkbox" value="test" /><input type="button" /><textarea></textarea>');
|
||||
|
||||
// Edge will add an empty input value so remove that to normalize test since it doesn't break anything
|
||||
equal(ser.serialize(DOM.get('test')).replace(/ value=""/g, ''), '<input type="checkbox" value="test" /><input type="button" /><textarea></textarea>');
|
||||
});
|
||||
|
||||
test('Form elements (checkbox)', function() {
|
||||
|
||||
@@ -10,7 +10,6 @@ module("tinymce.dom.TridentSelection", {
|
||||
tinymce.init({
|
||||
selector: "textarea",
|
||||
elements: "elm1",
|
||||
plugins: wpPlugins,
|
||||
add_unload_trigger: false,
|
||||
disable_nodechange: true,
|
||||
skin: false,
|
||||
|
||||
@@ -28,4 +28,24 @@ ModuleLoader.require([
|
||||
strictEqual(result[0].image, document.getElementById('view').firstChild);
|
||||
});
|
||||
});
|
||||
|
||||
QUnit.asyncTest("findAll (filtered)", function() {
|
||||
var imageScanner = new ImageScanner(new BlobCache());
|
||||
|
||||
function predicate(img) {
|
||||
return !img.hasAttribute('data-skip');
|
||||
}
|
||||
|
||||
document.getElementById('view').innerHTML = (
|
||||
'<img src="' + base64Src + '">' +
|
||||
'<img src="' + base64Src + '" data-skip="1">'
|
||||
);
|
||||
|
||||
imageScanner.findAll(document.getElementById('view'), predicate).then(function(result) {
|
||||
QUnit.start();
|
||||
equal(result.length, 1);
|
||||
equal('data:image/gif;base64,' + result[0].blobInfo.base64(), base64Src);
|
||||
strictEqual(result[0].image, document.getElementById('view').firstChild);
|
||||
});
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,70 @@
|
||||
ModuleLoader.require([
|
||||
"tinymce/geom/ClientRect"
|
||||
], function(ClientRect) {
|
||||
module("tinymce.geom.ClientRect");
|
||||
|
||||
function rect(x, y, w, h) {
|
||||
return {
|
||||
left: x,
|
||||
top: y,
|
||||
bottom: y + h,
|
||||
right: x + w,
|
||||
width: w,
|
||||
height: h
|
||||
};
|
||||
}
|
||||
|
||||
test('clone', function() {
|
||||
deepEqual(ClientRect.clone(rect(10, 20, 30, 40)), rect(10, 20, 30, 40));
|
||||
deepEqual(ClientRect.clone(rect(10.1, 20.1, 30.1, 40.1)), rect(10, 20, 30, 40));
|
||||
});
|
||||
|
||||
test('collapse', function() {
|
||||
deepEqual(ClientRect.collapse(rect(10, 20, 30, 40), true), rect(10, 20, 0, 40));
|
||||
deepEqual(ClientRect.collapse(rect(10, 20, 30, 40), false), rect(40, 20, 0, 40));
|
||||
});
|
||||
|
||||
test('isAbove', function() {
|
||||
equal(ClientRect.isAbove(rect(10, 70, 10, 40), rect(20, 40, 10, 20)), false);
|
||||
equal(ClientRect.isAbove(rect(10, 40, 10, 20), rect(20, 70, 10, 40)), true);
|
||||
});
|
||||
|
||||
test('isAbove intersects', function() {
|
||||
equal(ClientRect.isAbove(rect(10, 20, 10, 10), rect(20, 20, 10, 10)), false);
|
||||
equal(ClientRect.isAbove(rect(10, 20, 10, 40), rect(20, 20, 10, 10)), false);
|
||||
equal(ClientRect.isAbove(rect(10, 20, 10, 10), rect(20, 20, 10, 40)), false);
|
||||
equal(ClientRect.isAbove(rect(10, 10, 10, 10), rect(20, 20, 10, 10)), true);
|
||||
equal(ClientRect.isAbove(rect(10, 15, 10, 10), rect(20, 20, 10, 10)), false);
|
||||
});
|
||||
|
||||
test('isBelow', function() {
|
||||
equal(ClientRect.isBelow(rect(10, 70, 10, 40), rect(20, 40, 10, 20)), true);
|
||||
equal(ClientRect.isBelow(rect(10, 40, 10, 20), rect(20, 70, 10, 40)), false);
|
||||
});
|
||||
|
||||
test('isBelow intersects', function() {
|
||||
equal(ClientRect.isBelow(rect(10, 30, 10, 20), rect(20, 10, 10, 20)), true);
|
||||
equal(ClientRect.isBelow(rect(10, 30, 10, 20), rect(20, 10, 10, 25)), true);
|
||||
equal(ClientRect.isBelow(rect(10, 15, 10, 20), rect(20, 30, 10, 20)), false);
|
||||
equal(ClientRect.isBelow(rect(10, 29, 10, 20), rect(20, 10, 10, 30)), false);
|
||||
equal(ClientRect.isBelow(rect(10, 30, 10, 20), rect(20, 10, 10, 30)), true);
|
||||
equal(ClientRect.isBelow(rect(10, 20, 10, 20), rect(20, 10, 10, 30)), false);
|
||||
});
|
||||
|
||||
test('isLeft', function() {
|
||||
equal(ClientRect.isLeft(rect(10, 20, 30, 40), rect(20, 20, 30, 40)), true);
|
||||
equal(ClientRect.isLeft(rect(20, 20, 30, 40), rect(10, 20, 30, 40)), false);
|
||||
});
|
||||
|
||||
test('isRight', function() {
|
||||
equal(ClientRect.isRight(rect(10, 20, 30, 40), rect(20, 20, 30, 40)), false);
|
||||
equal(ClientRect.isRight(rect(20, 20, 30, 40), rect(10, 20, 30, 40)), true);
|
||||
});
|
||||
|
||||
test('compare', function() {
|
||||
equal(ClientRect.compare(rect(10, 70, 10, 40), rect(10, 40, 10, 20)), 1);
|
||||
equal(ClientRect.compare(rect(10, 40, 10, 20), rect(10, 70, 10, 40)), -1);
|
||||
equal(ClientRect.compare(rect(5, 10, 10, 10), rect(10, 10, 10, 10)), -1);
|
||||
equal(ClientRect.compare(rect(15, 10, 10, 10), rect(10, 10, 10, 10)), 1);
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,92 @@
|
||||
ModuleLoader.require([
|
||||
"tinymce/geom/Rect",
|
||||
"tinymce/util/Tools"
|
||||
], function(Rect, Tools) {
|
||||
module("tinymce.geom.Rect");
|
||||
|
||||
test('relativePosition', function() {
|
||||
var sourceRect = Rect.create(0, 0, 20, 30),
|
||||
targetRect = Rect.create(10, 20, 40, 50),
|
||||
tests = [
|
||||
// Only test a few of them all would be 81
|
||||
['tl-tl', 10, 20, 20, 30],
|
||||
['tc-tc', 20, 20, 20, 30],
|
||||
['tr-tr', 30, 20, 20, 30],
|
||||
['cl-cl', 10, 30, 20, 30],
|
||||
['cc-cc', 20, 30, 20, 30],
|
||||
['cr-cr', 30, 30, 20, 30],
|
||||
['bl-bl', 10, 40, 20, 30],
|
||||
['bc-bc', 20, 40, 20, 30],
|
||||
['br-br', 30, 40, 20, 30],
|
||||
['tr-tl', 50, 20, 20, 30],
|
||||
['br-bl', 50, 40, 20, 30]
|
||||
];
|
||||
|
||||
Tools.each(tests, function(item) {
|
||||
deepEqual(
|
||||
Rect.relativePosition(sourceRect, targetRect, item[0]),
|
||||
Rect.create(item[1], item[2], item[3], item[4]),
|
||||
item[0]
|
||||
);
|
||||
});
|
||||
});
|
||||
|
||||
test('findBestRelativePosition', function() {
|
||||
var sourceRect = Rect.create(0, 0, 20, 30),
|
||||
targetRect = Rect.create(10, 20, 40, 50),
|
||||
tests = [
|
||||
[['tl-tl'], 5, 15, 100, 100, 'tl-tl'],
|
||||
[['tl-tl'], 20, 30, 100, 100, null],
|
||||
[['tl-tl', 'tr-tl'], 20, 20, 100, 100, 'tr-tl'],
|
||||
[['tl-bl', 'tr-tl', 'bl-tl'], 10, 20, 40, 100, 'bl-tl']
|
||||
];
|
||||
|
||||
Tools.each(tests, function(item) {
|
||||
equal(
|
||||
Rect.findBestRelativePosition(sourceRect, targetRect, Rect.create(item[1], item[2], item[3], item[4]), item[0]),
|
||||
item[5],
|
||||
item[5]
|
||||
);
|
||||
});
|
||||
});
|
||||
|
||||
test('inflate', function() {
|
||||
deepEqual(Rect.inflate(Rect.create(10, 20, 30, 40), 5, 10), Rect.create(5, 10, 40, 60));
|
||||
});
|
||||
|
||||
test('intersect', function() {
|
||||
ok(Rect.intersect(Rect.create(10, 20, 30, 40), Rect.create(10, 20, 30, 40)));
|
||||
ok(Rect.intersect(Rect.create(10, 20, 30, 40), Rect.create(15, 25, 30, 40)));
|
||||
ok(Rect.intersect(Rect.create(10, 20, 30, 40), Rect.create(15, 25, 5, 5)));
|
||||
ok(!Rect.intersect(Rect.create(10, 20, 30, 40), Rect.create(0, 10, 5, 5)));
|
||||
ok(!Rect.intersect(Rect.create(10, 20, 30, 40), Rect.create(45, 20, 5, 5)));
|
||||
ok(!Rect.intersect(Rect.create(10, 20, 30, 40), Rect.create(10, 65, 5, 5)));
|
||||
ok(Rect.intersect(Rect.create(10, 20, 30, 40), Rect.create(40, 20, 30, 40)));
|
||||
ok(Rect.intersect(Rect.create(10, 20, 30, 40), Rect.create(10, 60, 30, 40)));
|
||||
});
|
||||
|
||||
test('clamp', function() {
|
||||
deepEqual(
|
||||
Rect.clamp(Rect.create(10, 20, 30, 40), Rect.create(10, 20, 30, 40)),
|
||||
Rect.create(10, 20, 30, 40)
|
||||
);
|
||||
|
||||
deepEqual(
|
||||
Rect.clamp(Rect.create(5, 20, 30, 40), Rect.create(10, 20, 30, 40)),
|
||||
Rect.create(10, 20, 25, 40)
|
||||
);
|
||||
|
||||
deepEqual(
|
||||
Rect.clamp(Rect.create(5, 20, 30, 40), Rect.create(10, 20, 30, 40), true),
|
||||
Rect.create(10, 20, 30, 40)
|
||||
);
|
||||
});
|
||||
|
||||
test('create', function() {
|
||||
deepEqual(Rect.create(10, 20, 30, 40), {x: 10, y: 20, w: 30, h: 40});
|
||||
});
|
||||
|
||||
test('fromClientRect', function() {
|
||||
deepEqual(Rect.fromClientRect({left: 10, top: 20, width: 30, height: 40}), {x: 10, y: 20, w: 30, h: 40});
|
||||
});
|
||||
});
|
||||
@@ -4,7 +4,6 @@ module( 'tinymce.html.Obsolete', {
|
||||
|
||||
tinymce.init({
|
||||
selector: 'textarea',
|
||||
plugins: wpPlugins,
|
||||
add_unload_trigger : false,
|
||||
skin: false,
|
||||
indent : false,
|
||||
|
||||
@@ -168,8 +168,7 @@ test('getBoolAttrs', function() {
|
||||
"DECLARE": {}, "COMPACT": {}, "CHECKED": {},
|
||||
"controls": {}, "loop": {}, "autoplay": {}, "selected": {}, "readonly": {}, "nowrap": {},
|
||||
"noshade": {}, "noresize": {}, "nohref": {}, "multiple": {}, "ismap": {}, "disabled": {}, "defer": {},
|
||||
"declare": {}, "compact": {}, "checked": {},
|
||||
"allowfullscreen": {}, "mozallowfullscreen": {}, "webkitallowfullscreen": {} // WP
|
||||
"declare": {}, "compact": {}, "checked": {}
|
||||
});
|
||||
});
|
||||
|
||||
@@ -181,7 +180,7 @@ test('getBlockElements', function() {
|
||||
schema = new tinymce.html.Schema();
|
||||
deepEqual(schema.getBlockElements(), {
|
||||
ASIDE: {}, HGROUP: {}, SECTION: {}, ARTICLE: {}, FOOTER: {}, HEADER: {},
|
||||
ISINDEX: {}, MENU: {}, NOSCRIPT: {}, FIELDSET: {}, DIR: {}, DD: {}, DT: {},
|
||||
ISINDEX: {}, MENU: {}, NOSCRIPT: {}, FIELDSET: {}, FIGCAPTION: {}, DIR: {}, DD: {}, DT: {},
|
||||
DL: {}, CENTER: {}, BLOCKQUOTE: {}, CAPTION: {}, UL: {}, OL: {}, LI: {},
|
||||
TD: {}, TR: {}, TH: {}, TFOOT: {}, THEAD: {}, TBODY: {}, TABLE: {}, FORM: {},
|
||||
PRE: {}, ADDRESS: {}, DIV: {}, P: {}, HR: {}, H6: {}, H5: {}, H4: {}, H3: {},
|
||||
@@ -190,7 +189,7 @@ test('getBlockElements', function() {
|
||||
isindex: {}, menu: {}, noscript: {}, fieldset: {}, dir: {}, dd: {}, dt: {}, dl: {}, center: {},
|
||||
blockquote: {}, caption: {}, ul: {}, ol: {}, li: {}, td: {}, tr: {}, th: {}, tfoot: {}, thead: {},
|
||||
tbody: {}, table: {}, form: {}, pre: {}, address: {}, div: {}, p: {}, hr: {}, h6: {},
|
||||
h5: {}, h4: {}, h3: {}, h2: {}, h1: {}, nav: {}, figure: {}, datalist: {}, optgroup: {},
|
||||
h5: {}, h4: {}, h3: {}, h2: {}, h1: {}, nav: {}, figure: {}, figcaption: {}, datalist: {}, optgroup: {},
|
||||
option: {}, select: {}
|
||||
});
|
||||
});
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
ModuleLoader.require(["tinymce/text/ExtendingChar"], function(ExtendingChar) {
|
||||
module("tinymce.text.ExtendingChar");
|
||||
|
||||
test('isExtendingChar', function() {
|
||||
strictEqual(ExtendingChar.isExtendingChar('a'), false);
|
||||
strictEqual(ExtendingChar.isExtendingChar('\u0301'), true);
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,15 @@
|
||||
ModuleLoader.require(["tinymce/text/Zwsp"], function(Zwsp) {
|
||||
module("tinymce.text.Zwsp");
|
||||
|
||||
test('ZWSP', function() {
|
||||
strictEqual(Zwsp.ZWSP, '\u200b');
|
||||
});
|
||||
|
||||
test('isZwsp', function() {
|
||||
strictEqual(Zwsp.isZwsp(Zwsp.ZWSP), true);
|
||||
});
|
||||
|
||||
test('isZwsp', function() {
|
||||
strictEqual(Zwsp.trim('a' + Zwsp.ZWSP + 'b'), 'ab');
|
||||
});
|
||||
});
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
ctrl = new tinymce.ui.Control({});
|
||||
|
||||
// Check inital states
|
||||
// Check initial states
|
||||
equal(ctrl.disabled(), false);
|
||||
equal(ctrl.active(), false);
|
||||
equal(ctrl.visible(), true);
|
||||
|
||||
@@ -0,0 +1,114 @@
|
||||
ModuleLoader.require([
|
||||
"tinymce/util/Delay"
|
||||
], function(Delay) {
|
||||
module("tinymce.util.Delay");
|
||||
|
||||
asyncTest('requestAnimationFrame', function() {
|
||||
Delay.requestAnimationFrame(function() {
|
||||
ok("requestAnimationFrame was executed.", true);
|
||||
QUnit.start();
|
||||
});
|
||||
});
|
||||
|
||||
asyncTest('setTimeout', function() {
|
||||
Delay.setTimeout(function() {
|
||||
ok("setTimeout was executed.", true);
|
||||
QUnit.start();
|
||||
});
|
||||
});
|
||||
|
||||
asyncTest('setInterval', function() {
|
||||
var count = 0, id;
|
||||
|
||||
id = Delay.setInterval(function() {
|
||||
if (++count == 2) {
|
||||
Delay.clearInterval(id);
|
||||
equal(count, 2);
|
||||
QUnit.start();
|
||||
} else if (count > 3) {
|
||||
throw new Error("Still executing setInterval.");
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
asyncTest('setEditorTimeout', function() {
|
||||
var fakeEditor = {};
|
||||
|
||||
Delay.setEditorTimeout(fakeEditor, function() {
|
||||
ok("setEditorTimeout was executed.", true);
|
||||
QUnit.start();
|
||||
});
|
||||
});
|
||||
|
||||
test('setEditorTimeout (removed)', function() {
|
||||
var fakeEditor = {removed: true};
|
||||
|
||||
Delay.setEditorTimeout(fakeEditor, function() {
|
||||
throw new Error("Still executing setEditorTimeout.");
|
||||
});
|
||||
|
||||
ok(true, "setEditorTimeout on removed instance.");
|
||||
});
|
||||
|
||||
asyncTest('setEditorInterval', function() {
|
||||
var count = 0, id, fakeEditor = {};
|
||||
|
||||
id = Delay.setEditorInterval(fakeEditor, function() {
|
||||
if (++count == 2) {
|
||||
Delay.clearInterval(id);
|
||||
equal(count, 2);
|
||||
QUnit.start();
|
||||
} else if (count > 3) {
|
||||
throw new Error("Still executing setEditorInterval.");
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
test('setEditorInterval (removed)', function() {
|
||||
var fakeEditor = {removed: true};
|
||||
|
||||
Delay.setEditorInterval(fakeEditor, function() {
|
||||
throw new Error("Still executing setEditorInterval.");
|
||||
});
|
||||
|
||||
ok(true, "setEditorTimeout on removed instance.");
|
||||
});
|
||||
|
||||
asyncTest('throttle', function() {
|
||||
var fn, args = [];
|
||||
|
||||
fn = Delay.throttle(function(a) {
|
||||
args.push(a);
|
||||
}, 0);
|
||||
|
||||
fn(1);
|
||||
fn(2);
|
||||
|
||||
Delay.setTimeout(function() {
|
||||
deepEqual(args, [2]);
|
||||
QUnit.start();
|
||||
}, 10);
|
||||
});
|
||||
|
||||
test('clearTimeout', function() {
|
||||
var id;
|
||||
|
||||
id = Delay.setTimeout(function() {
|
||||
throw new Error("clearTimeout didn't work.");
|
||||
});
|
||||
|
||||
Delay.clearTimeout(id);
|
||||
ok(true, "clearTimeout works.");
|
||||
});
|
||||
|
||||
test('clearTimeout', function() {
|
||||
var id;
|
||||
|
||||
id = Delay.setInterval(function() {
|
||||
throw new Error("clearInterval didn't work.");
|
||||
});
|
||||
|
||||
Delay.clearInterval(id);
|
||||
ok(true, "clearInterval works.");
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,49 @@
|
||||
ModuleLoader.require([
|
||||
"tinymce/util/Fun"
|
||||
], function(Fun) {
|
||||
module("tinymce.util.Fun");
|
||||
|
||||
function isTrue(value) {
|
||||
return value === true;
|
||||
}
|
||||
|
||||
function isFalse(value) {
|
||||
return value === true;
|
||||
}
|
||||
|
||||
function isAbove(target, value) {
|
||||
return value() > target();
|
||||
}
|
||||
|
||||
test('constant', function() {
|
||||
strictEqual(Fun.constant(1)(), 1);
|
||||
strictEqual(Fun.constant("1")(), "1");
|
||||
strictEqual(Fun.constant(null)(), null);
|
||||
});
|
||||
|
||||
test('negate', function() {
|
||||
strictEqual(Fun.negate(isTrue)(false), true);
|
||||
strictEqual(Fun.negate(isFalse)(true), false);
|
||||
});
|
||||
|
||||
test('and', function() {
|
||||
var isAbove5 = Fun.curry(isAbove, Fun.constant(5));
|
||||
var isAbove10 = Fun.curry(isAbove, Fun.constant(10));
|
||||
|
||||
strictEqual(Fun.and(isAbove10, isAbove5)(Fun.constant(10)), false);
|
||||
strictEqual(Fun.and(isAbove10, isAbove5)(Fun.constant(30)), true);
|
||||
});
|
||||
|
||||
test('or', function() {
|
||||
var isAbove5 = Fun.curry(isAbove, Fun.constant(5));
|
||||
var isAbove10 = Fun.curry(isAbove, Fun.constant(10));
|
||||
|
||||
strictEqual(Fun.or(isAbove10, isAbove5)(Fun.constant(5)), false);
|
||||
strictEqual(Fun.or(isAbove10, isAbove5)(Fun.constant(15)), true);
|
||||
strictEqual(Fun.or(isAbove5, isAbove10)(Fun.constant(15)), true);
|
||||
});
|
||||
|
||||
test('compose', function() {
|
||||
strictEqual(Fun.compose(Fun.curry(isAbove, Fun.constant(5)), Fun.constant)(10), true);
|
||||
});
|
||||
});
|
||||
@@ -5,7 +5,6 @@ module("tinymce.utils.Quirks_WebKit", {
|
||||
tinymce.init({
|
||||
selector: "textarea",
|
||||
elements: "elm1",
|
||||
plugins: wpPlugins,
|
||||
add_unload_trigger: false,
|
||||
skin: false,
|
||||
indent: false,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
( function( $, QUnit, tinymce, _type, setTimeout ) {
|
||||
( function( $, QUnit, tinymce, setTimeout ) {
|
||||
var editor,
|
||||
count = 0;
|
||||
|
||||
@@ -6,6 +6,111 @@
|
||||
return;
|
||||
}
|
||||
|
||||
function mceType(chr) {
|
||||
var editor = tinymce.activeEditor, keyCode, charCode, evt, startElm, rng, startContainer, startOffset, textNode;
|
||||
|
||||
function charCodeToKeyCode(charCode) {
|
||||
var lookup = {
|
||||
'0': 48, '1': 49, '2': 50, '3': 51, '4': 52, '5': 53, '6': 54, '7': 55, '8': 56, '9': 57,'a': 65, 'b': 66, 'c': 67,
|
||||
'd': 68, 'e': 69, 'f': 70, 'g': 71, 'h': 72, 'i': 73, 'j': 74, 'k': 75, 'l': 76, 'm': 77, 'n': 78, 'o': 79, 'p': 80, 'q': 81,
|
||||
'r': 82, 's': 83, 't': 84, 'u': 85, 'v': 86, 'w': 87, 'x': 88, 'y': 89, ' ': 32, ',': 188, '-': 189, '.': 190, '/': 191, '\\': 220,
|
||||
'[': 219, ']': 221, '\'': 222, ';': 186, '=': 187, ')': 41
|
||||
};
|
||||
|
||||
return lookup[String.fromCharCode(charCode)];
|
||||
}
|
||||
|
||||
function fakeEvent(target, type, evt) {
|
||||
editor.dom.fire(target, type, evt);
|
||||
}
|
||||
|
||||
// Numeric keyCode
|
||||
if (typeof(chr) === 'number') {
|
||||
charCode = chr;
|
||||
keyCode = charCodeToKeyCode(charCode);
|
||||
} else if (typeof(chr) === 'string') {
|
||||
// String value
|
||||
if (chr === '\b') {
|
||||
keyCode = 8;
|
||||
charCode = chr.charCodeAt(0);
|
||||
} else if (chr === '\n') {
|
||||
keyCode = 13;
|
||||
charCode = chr.charCodeAt(0);
|
||||
} else {
|
||||
charCode = chr.charCodeAt(0);
|
||||
keyCode = charCodeToKeyCode(charCode);
|
||||
}
|
||||
} else {
|
||||
evt = chr;
|
||||
|
||||
if (evt.charCode) {
|
||||
chr = String.fromCharCode(evt.charCode);
|
||||
}
|
||||
|
||||
if (evt.keyCode) {
|
||||
keyCode = evt.keyCode;
|
||||
}
|
||||
}
|
||||
|
||||
evt = evt || {keyCode: keyCode, charCode: charCode};
|
||||
|
||||
startElm = editor.selection.getStart();
|
||||
fakeEvent(startElm, 'keydown', evt);
|
||||
fakeEvent(startElm, 'keypress', evt);
|
||||
|
||||
if (!evt.isDefaultPrevented()) {
|
||||
if (keyCode === 8) {
|
||||
if (editor.getDoc().selection) {
|
||||
rng = editor.getDoc().selection.createRange();
|
||||
|
||||
if (rng.text.length === 0) {
|
||||
rng.moveStart('character', -1);
|
||||
rng.select();
|
||||
}
|
||||
|
||||
rng.execCommand('Delete', false, null);
|
||||
} else {
|
||||
rng = editor.selection.getRng();
|
||||
startContainer = rng.startContainer;
|
||||
|
||||
if (startContainer.nodeType === 1 && rng.collapsed) {
|
||||
var nodes = rng.startContainer.childNodes;
|
||||
startContainer = nodes[nodes.length - 1];
|
||||
}
|
||||
|
||||
// If caret is at <p>abc|</p> and after the abc text node then move it to the end of the text node
|
||||
// Expand the range to include the last char <p>ab[c]</p> since IE 11 doesn't delete otherwise
|
||||
if ( rng.collapsed && startContainer && startContainer.nodeType === 3 && startContainer.data.length > 0) {
|
||||
rng.setStart(startContainer, startContainer.data.length - 1);
|
||||
rng.setEnd(startContainer, startContainer.data.length);
|
||||
editor.selection.setRng(rng);
|
||||
}
|
||||
|
||||
editor.getDoc().execCommand('Delete', false, null);
|
||||
}
|
||||
} else if (typeof(chr) === 'string') {
|
||||
rng = editor.selection.getRng(true);
|
||||
|
||||
if (rng.startContainer.nodeType === 3 && rng.collapsed) {
|
||||
// `insertData` may alter the range.
|
||||
startContainer = rng.startContainer;
|
||||
startOffset = rng.startOffset;
|
||||
rng.startContainer.insertData( rng.startOffset, chr );
|
||||
rng.setStart( startContainer, startOffset + 1 );
|
||||
} else {
|
||||
textNode = editor.getDoc().createTextNode(chr);
|
||||
rng.insertNode(textNode);
|
||||
rng.setStart(textNode, 1);
|
||||
}
|
||||
|
||||
rng.collapse(true);
|
||||
editor.selection.setRng(rng);
|
||||
}
|
||||
}
|
||||
|
||||
fakeEvent(startElm, 'keyup', evt);
|
||||
}
|
||||
|
||||
function type() {
|
||||
var args = arguments;
|
||||
|
||||
@@ -17,7 +122,7 @@
|
||||
if ( typeof args[0] === 'function' ) {
|
||||
args[0]();
|
||||
} else {
|
||||
_type( args[0].shift() );
|
||||
mceType( args[0].shift() );
|
||||
}
|
||||
|
||||
if ( ! args[0].length ) {
|
||||
@@ -172,4 +277,4 @@
|
||||
assert.equal( editor.getContent(), '<p>### </p>\n<p> </p>' );
|
||||
}, assert.async() );
|
||||
} );
|
||||
} )( window.jQuery, window.QUnit, window.tinymce, window.Utils.type, window.setTimeout );
|
||||
} )( window.jQuery, window.QUnit, window.tinymce, window.setTimeout );
|
||||
|
||||
Reference in New Issue
Block a user