radiant-ck_editor_filter-extension 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- data/README.markdown +7 -1
- data/VERSION +1 -1
- data/ck_editor_filter_extension.rb +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/CHANGES.html +1130 -373
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/INSTALL.html +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/LICENSE.html +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/adobeair/application.xml +32 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/adobeair/run.bat +9 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/adobeair/run.sh +8 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/adobeair/sample.html +45 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/ajax.html +23 -25
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/api.html +64 -24
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/api_dialog.html +36 -19
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/api_dialog/my_dialog.js +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/asp/advanced.asp +105 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/asp/events.asp +136 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/asp/index.html +103 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/asp/replace.asp +72 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/asp/replaceall.asp +77 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/asp/sample_posteddata.asp +46 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/asp/standalone.asp +72 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/assets/_posteddata.php +59 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/assets/output_for_flash.fla +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/assets/output_for_flash.swf +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/assets/output_xhtml.css +204 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/assets/parsesample.css +70 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/assets/swfobject.js +18 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/autogrow.html +103 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/bbcode.html +136 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/devtools.html +94 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/divreplace.html +27 -10
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/enterkey.html +39 -12
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/fullpage.html +33 -13
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/index.html +88 -25
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/jqueryadapter.html +34 -8
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/output_for_flash.html +275 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/output_html.html +285 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/output_xhtml.html +181 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/php/advanced.php +56 -29
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/php/events.php +58 -35
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/php/index.html +47 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/php/replace.php +48 -24
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/php/replaceall.php +50 -30
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/php/standalone.php +52 -33
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/placeholder.html +81 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/readonly.html +91 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/replacebyclass.html +22 -7
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/replacebycode.html +25 -8
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/sample.css +85 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/sample.js +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/sample_posteddata.php +21 -59
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/sharedspaces.html +32 -10
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/skins.html +38 -11
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/stylesheetparser.html +93 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/tableresize.html +115 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/ui_color.html +49 -7
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_samples/ui_languages.html +53 -23
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/adapters/jquery.js +17 -8
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/_bootstrap.js +21 -18
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/ckeditor.js +42 -4
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/ckeditor_base.js +66 -29
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/ckeditor_basic.js +12 -15
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/command.js +138 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/commanddefinition.js +59 -16
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/config.js +142 -18
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/dataprocessor.js +6 -7
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/dom.js +2 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/dom/comment.js +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/dom/document.js +29 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/dom/documentfragment.js +3 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/dom/domobject.js +59 -11
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/dom/element.js +249 -27
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/dom/elementpath.js +18 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/dom/event.js +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/dom/node.js +84 -56
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/dom/nodelist.js +4 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/dom/range.js +345 -48
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/dom/rangelist.js +213 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/dom/text.js +6 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/dom/walker.js +40 -29
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/dom/window.js +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/dtd.js +15 -11
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/editor.js +336 -15
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/editor_basic.js +19 -12
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/env.js +80 -17
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/event.js +12 -6
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/eventInfo.js +5 -5
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/focusmanager.js +27 -12
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/htmlparser.js +17 -5
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/htmlparser/basicwriter.js +3 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/htmlparser/cdata.js +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/htmlparser/comment.js +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/htmlparser/element.js +14 -5
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/htmlparser/filter.js +34 -8
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/htmlparser/fragment.js +105 -108
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/htmlparser/text.js +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/lang.js +12 -7
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/loader.js +7 -9
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/plugindefinition.js +18 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/plugins.js +21 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/resourcemanager.js +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/scriptloader.js +7 -25
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/skins.js +5 -25
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/themes.js +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/tools.js +61 -12
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/ui.js +13 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/_languages.js +2 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/_translationstatus.txt +58 -57
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/af.js +521 -410
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/ar.js +160 -49
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/bg.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/bn.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/bs.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/ca.js +260 -149
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/cs.js +233 -122
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/cy.js +159 -48
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/da.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/de.js +217 -106
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/el.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/en-au.js +166 -55
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/en-ca.js +166 -55
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/en-gb.js +277 -166
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/en.js +166 -55
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/eo.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/es.js +182 -71
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/et.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/eu.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/fa.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/fi.js +178 -67
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/fo.js +339 -228
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/fr-ca.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/fr.js +261 -150
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/gl.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/gu.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/he.js +179 -68
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/hi.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/hr.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/hu.js +341 -230
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/is.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/it.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/ja.js +195 -84
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/ka.js +810 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/km.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/ko.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/lt.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/lv.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/mn.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/ms.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/nb.js +286 -175
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/nl.js +178 -67
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/no.js +286 -175
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/pl.js +279 -168
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/pt-br.js +318 -208
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/pt.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/ro.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/ru.js +159 -48
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/sk.js +192 -81
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/sl.js +161 -50
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/sr-latn.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/sr.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/sv.js +357 -247
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/th.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/tr.js +345 -235
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/uk.js +387 -276
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/vi.js +336 -225
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/zh-cn.js +271 -160
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/lang/zh.js +162 -51
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/a11yhelp/dialogs/a11yhelp.js +16 -5
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/a11yhelp/lang/en.js +3 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/a11yhelp/lang/he.js +216 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/a11yhelp/plugin.js +4 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/about/dialogs/about.js +4 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/about/plugin.js +2 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/adobeair/plugin.js +228 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/ajax/plugin.js +152 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/autogrow/plugin.js +88 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/basicstyles/plugin.js +27 -19
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/bbcode/plugin.js +924 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/bidi/plugin.js +331 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/blockquote/plugin.js +8 -4
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/button/plugin.js +70 -55
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/clipboard/dialogs/paste.js +115 -78
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/clipboard/plugin.js +133 -69
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/colorbutton/plugin.js +91 -23
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/colordialog/dialogs/colordialog.js +192 -43
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/colordialog/plugin.js +12 -10
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/contextmenu/plugin.js +124 -221
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/devtools/lang/en.js +16 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/devtools/plugin.js +173 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/dialog/dialogDefinition.js +840 -56
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/dialog/plugin.js +652 -301
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/dialogadvtab/plugin.js +205 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/dialogui/plugin.js +179 -50
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/div/dialogs/div.js +40 -40
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/div/plugin.js +4 -4
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/docprops/dialogs/docprops.js +686 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/docprops/plugin.js +22 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/domiterator/plugin.js +59 -53
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/editingblock/plugin.js +62 -17
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/elementspath/plugin.js +137 -108
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/enterkey/plugin.js +117 -47
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/entities/plugin.js +95 -45
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/fakeobjects/plugin.js +22 -16
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/filebrowser/plugin.js +75 -30
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/find/dialogs/find.js +111 -69
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/find/plugin.js +2 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/flash/dialogs/flash.js +28 -20
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/flash/plugin.js +14 -11
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/floatpanel/plugin.js +50 -21
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/font/plugin.js +3 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/format/plugin.js +17 -13
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/forms/dialogs/button.js +38 -55
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/forms/dialogs/checkbox.js +21 -11
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/forms/dialogs/form.js +6 -6
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/forms/dialogs/hiddenfield.js +26 -17
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/forms/dialogs/radio.js +6 -6
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/forms/dialogs/select.js +13 -7
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/forms/dialogs/textarea.js +4 -4
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/forms/dialogs/textfield.js +11 -5
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/forms/images/hiddenfield.gif +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/forms/plugin.js +112 -41
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/horizontalrule/plugin.js +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/htmldataprocessor/plugin.js +200 -63
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/htmlwriter/plugin.js +26 -21
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/iframe/dialogs/iframe.js +257 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/iframe/images/placeholder.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/iframe/plugin.js +106 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/iframedialog/plugin.js +59 -7
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/image/dialogs/image.js +243 -218
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/image/plugin.js +19 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/indent/plugin.js +335 -223
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/justify/plugin.js +115 -30
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/keystrokes/plugin.js +3 -7
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/link/dialogs/anchor.js +85 -40
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/link/dialogs/link.js +163 -184
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/link/plugin.js +180 -32
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/list/plugin.js +165 -81
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/listblock/plugin.js +11 -6
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/liststyle/dialogs/liststyle.js +204 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/liststyle/plugin.js +66 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/maximize/plugin.js +109 -40
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/menu/plugin.js +166 -67
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/menubutton/plugin.js +12 -7
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/newpage/plugin.js +3 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/pagebreak/plugin.js +95 -29
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/panel/plugin.js +43 -20
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/panelbutton/plugin.js +10 -11
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/pastefromword/filter/default.js +316 -119
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/pastefromword/plugin.js +32 -11
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/pastetext/dialogs/pastetext.js +19 -29
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/pastetext/plugin.js +15 -79
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/placeholder/dialogs/placeholder.js +71 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/placeholder/lang/en.js +16 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/placeholder/lang/he.js +16 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/placeholder/placeholder.gif +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/placeholder/plugin.js +171 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/popup/plugin.js +9 -7
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/preview/plugin.js +3 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/print/plugin.js +2 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/removeformat/plugin.js +89 -36
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/resize/plugin.js +71 -18
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/richcombo/plugin.js +40 -29
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/save/plugin.js +2 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/scayt/dialogs/options.js +114 -110
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/scayt/plugin.js +531 -170
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/selection/plugin.js +791 -331
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/showblocks/images/block_address.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/showblocks/images/block_blockquote.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/showblocks/images/block_div.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/showblocks/images/block_h1.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/showblocks/images/block_h2.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/showblocks/images/block_h3.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/showblocks/images/block_h4.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/showblocks/images/block_h5.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/showblocks/images/block_h6.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/showblocks/images/block_p.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/showblocks/images/block_pre.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/showblocks/plugin.js +14 -8
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/showborders/plugin.js +63 -26
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/smiley/dialogs/smiley.js +31 -22
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/smiley/plugin.js +15 -6
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/sourcearea/plugin.js +18 -14
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/specialchar/dialogs/specialchar.js +36 -59
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/specialchar/lang/en.js +89 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/specialchar/plugin.js +45 -4
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/styles/plugin.js +632 -212
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/{stylescombo → styles}/styles/default.js +5 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/stylescombo/plugin.js +77 -140
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/stylesheetparser/plugin.js +143 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/tab/plugin.js +109 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/table/dialogs/table.js +106 -23
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/table/plugin.js +11 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/tableresize/plugin.js +450 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/tabletools/dialogs/tableCell.js +66 -64
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/tabletools/plugin.js +348 -179
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/templates/dialogs/templates.js +41 -36
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/templates/plugin.js +3 -4
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/templates/templates/default.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/toolbar/plugin.js +193 -122
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/uicolor/dialogs/uicolor.js +6 -5
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/uicolor/lang/en.js +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/uicolor/lang/he.js +15 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/uicolor/plugin.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/uicolor/yui/assets/yui.css +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/undo/plugin.js +73 -12
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/wsc/dialogs/ciframe.html +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/wsc/dialogs/tmpFrameset.html +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/wsc/dialogs/wsc.css +1 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/wsc/dialogs/wsc.js +20 -4
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/wsc/plugin.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/wysiwygarea/plugin.js +751 -251
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/xml/plugin.js +170 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/kama/dialog.css +116 -18
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/kama/editor.css +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/kama/elementspath.css +2 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/kama/icons.css +42 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/kama/icons.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/kama/icons_rtl.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/kama/mainui.css +25 -5
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/kama/menu.css +36 -15
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/kama/panel.css +18 -17
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/kama/presets.css +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/kama/reset.css +7 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/kama/richcombo.css +27 -10
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/kama/skin.js +4 -36
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/kama/templates.css +16 -12
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/kama/toolbar.css +69 -83
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/office2003/dialog.css +111 -13
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/office2003/editor.css +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/office2003/elementspath.css +2 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/office2003/icons.css +40 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/office2003/icons.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/office2003/icons_rtl.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/office2003/mainui.css +33 -7
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/office2003/menu.css +37 -15
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/office2003/panel.css +23 -22
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/office2003/presets.css +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/office2003/reset.css +7 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/office2003/richcombo.css +40 -20
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/office2003/skin.js +10 -17
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/office2003/templates.css +16 -10
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/office2003/toolbar.css +79 -32
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/v2/dialog.css +112 -13
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/v2/editor.css +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/v2/elementspath.css +2 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/v2/icons.css +40 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/v2/icons.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/v2/icons_rtl.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/v2/mainui.css +25 -5
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/v2/menu.css +38 -16
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/v2/panel.css +22 -21
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/v2/presets.css +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/v2/reset.css +7 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/v2/richcombo.css +36 -23
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/v2/skin.js +10 -17
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/v2/templates.css +16 -10
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/skins/v2/toolbar.css +67 -27
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/themes/default/theme.js +106 -46
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/adapters/jquery.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/ckeditor.asp +955 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/ckeditor.js +141 -117
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/ckeditor.pack +13 -7
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/ckeditor.php +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/ckeditor_basic.js +4 -4
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/ckeditor_basic_source.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/ckeditor_php4.php +27 -54
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/ckeditor_php5.php +26 -53
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/ckeditor_source.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/config.js +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/contents.css +4 -16
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/_languages.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/_translationstatus.txt +58 -57
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/af.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/ar.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/bg.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/bn.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/bs.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/ca.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/cs.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/cy.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/da.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/de.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/el.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/en-au.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/en-ca.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/en-gb.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/en.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/eo.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/es.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/et.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/eu.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/fa.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/fi.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/fo.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/fr-ca.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/fr.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/gl.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/gu.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/he.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/hi.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/hr.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/hu.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/is.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/it.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/ja.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/ka.js +6 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/km.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/ko.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/lt.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/lv.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/mn.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/ms.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/nb.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/nl.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/no.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/pl.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/pt-br.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/pt.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/ro.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/ru.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/sk.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/sl.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/sr-latn.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/sr.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/sv.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/th.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/tr.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/uk.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/vi.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/zh-cn.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/lang/zh.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/a11yhelp/dialogs/a11yhelp.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/a11yhelp/lang/en.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/a11yhelp/lang/he.js +6 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/about/dialogs/about.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/adobeair/plugin.js +6 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/ajax/plugin.js +6 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/autogrow/plugin.js +6 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/bbcode/plugin.js +9 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/clipboard/dialogs/paste.js +3 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/colordialog/dialogs/colordialog.js +3 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/devtools/lang/en.js +6 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/devtools/plugin.js +6 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/dialog/dialogDefinition.js +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/div/dialogs/div.js +3 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/docprops/dialogs/docprops.js +10 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/docprops/plugin.js +6 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/find/dialogs/find.js +5 -5
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/flash/dialogs/flash.js +5 -5
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/forms/dialogs/button.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/forms/dialogs/checkbox.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/forms/dialogs/form.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/forms/dialogs/hiddenfield.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/forms/dialogs/radio.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/forms/dialogs/select.js +4 -4
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/forms/dialogs/textarea.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/forms/dialogs/textfield.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/forms/images/hiddenfield.gif +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/iframe/dialogs/iframe.js +7 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/iframe/images/placeholder.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/iframedialog/plugin.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/image/dialogs/image.js +9 -9
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/link/dialogs/anchor.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/link/dialogs/link.js +7 -7
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/liststyle/dialogs/liststyle.js +6 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/pastefromword/filter/default.js +7 -6
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/pastetext/dialogs/pastetext.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/placeholder/dialogs/placeholder.js +6 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/placeholder/lang/en.js +6 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/placeholder/lang/he.js +6 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/placeholder/placeholder.gif +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/placeholder/plugin.js +6 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/radiantpreview/images/radiant-preview.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/scayt/dialogs/options.js +4 -4
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/scayt/dialogs/toolbar.css +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/showblocks/images/block_address.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/showblocks/images/block_blockquote.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/showblocks/images/block_div.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/showblocks/images/block_h1.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/showblocks/images/block_h2.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/showblocks/images/block_h3.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/showblocks/images/block_h4.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/showblocks/images/block_h5.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/showblocks/images/block_h6.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/showblocks/images/block_p.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/showblocks/images/block_pre.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/smiley/dialogs/smiley.js +3 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/specialchar/dialogs/specialchar.js +3 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/specialchar/lang/en.js +6 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/{stylescombo → styles}/styles/default.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/stylesheetparser/plugin.js +6 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/table/dialogs/table.js +5 -5
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/tableresize/plugin.js +7 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/tabletools/dialogs/tableCell.js +4 -4
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/templates/dialogs/templates.js +3 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/templates/templates/default.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/uicolor/dialogs/uicolor.js +3 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/uicolor/lang/en.js +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/uicolor/lang/he.js +6 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/uicolor/plugin.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/uicolor/yui/assets/yui.css +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/uicolor/yui/yui.js +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/wsc/dialogs/ciframe.html +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/wsc/dialogs/tmpFrameset.html +1 -1
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/wsc/dialogs/wsc.css +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/wsc/dialogs/wsc.js +3 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/plugins/xml/plugin.js +6 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/kama/dialog.css +5 -5
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/kama/editor.css +9 -8
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/kama/icons.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/kama/icons_rtl.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/kama/skin.js +3 -3
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/kama/templates.css +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/office2003/dialog.css +5 -5
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/office2003/editor.css +10 -9
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/office2003/icons.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/office2003/icons_rtl.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/office2003/skin.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/office2003/templates.css +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/v2/dialog.css +5 -4
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/v2/editor.css +9 -8
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/v2/icons.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/v2/icons_rtl.png +0 -0
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/v2/skin.js +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/skins/v2/templates.css +2 -2
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/themes/default/theme.js +4 -4
- data/public/javascripts/extensions/ck_editor_filter/radiant.ckeditor.js +21 -12
- metadata +94 -9
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/ajax.js +0 -143
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/imagecacher.js +0 -58
- data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/core/xml.js +0 -165
@@ -1,5 +1,5 @@
|
|
1
1
|
/*
|
2
|
-
Copyright (c) 2003-
|
2
|
+
Copyright (c) 2003-2011, CKSource - Frederico Knabben. All rights reserved.
|
3
3
|
For licensing, see LICENSE.html or http://ckeditor.com/license
|
4
4
|
*/
|
5
5
|
|
@@ -11,6 +11,7 @@ CKEDITOR.dialog.add( 'specialchar', function( editor )
|
|
11
11
|
*/
|
12
12
|
var dialog,
|
13
13
|
lang = editor.lang.specialChar;
|
14
|
+
|
14
15
|
var onChoice = function( evt )
|
15
16
|
{
|
16
17
|
var target, value;
|
@@ -23,7 +24,11 @@ CKEDITOR.dialog.add( 'specialchar', function( editor )
|
|
23
24
|
{
|
24
25
|
target.removeClass( "cke_light_background" );
|
25
26
|
dialog.hide();
|
26
|
-
|
27
|
+
|
28
|
+
// We must use "insertText" here to keep text styled.
|
29
|
+
var span = editor.document.createElement( 'span' );
|
30
|
+
span.setHtml( value );
|
31
|
+
editor.insertText( span.getText() );
|
27
32
|
}
|
28
33
|
};
|
29
34
|
|
@@ -80,7 +85,8 @@ CKEDITOR.dialog.add( 'specialchar', function( editor )
|
|
80
85
|
// Get an Anchor element.
|
81
86
|
var element = ev.getTarget();
|
82
87
|
var relative, nodeToMove;
|
83
|
-
var keystroke = ev.getKeystroke()
|
88
|
+
var keystroke = ev.getKeystroke(),
|
89
|
+
rtl = editor.lang.dir == 'rtl';
|
84
90
|
|
85
91
|
switch ( keystroke )
|
86
92
|
{
|
@@ -119,7 +125,7 @@ CKEDITOR.dialog.add( 'specialchar', function( editor )
|
|
119
125
|
break;
|
120
126
|
|
121
127
|
// RIGHT-ARROW
|
122
|
-
case 39 :
|
128
|
+
case rtl ? 37 : 39 :
|
123
129
|
// TAB
|
124
130
|
case 9 :
|
125
131
|
// relative is TD
|
@@ -153,7 +159,7 @@ CKEDITOR.dialog.add( 'specialchar', function( editor )
|
|
153
159
|
break;
|
154
160
|
|
155
161
|
// LEFT-ARROW
|
156
|
-
case 37 :
|
162
|
+
case rtl ? 39 : 37 :
|
157
163
|
// SHIFT + TAB
|
158
164
|
case CKEDITOR.SHIFT + 9 :
|
159
165
|
// relative is TD
|
@@ -189,50 +195,14 @@ CKEDITOR.dialog.add( 'specialchar', function( editor )
|
|
189
195
|
minHeight : 280,
|
190
196
|
buttons : [ CKEDITOR.dialog.cancelButton ],
|
191
197
|
charColumns : 17,
|
192
|
-
chars :
|
193
|
-
[
|
194
|
-
'!','"','#','$','%','&',"'",'(',')','*','+','-','.','/',
|
195
|
-
'0','1','2','3','4','5','6','7','8','9',':',';',
|
196
|
-
'<','=','>','?','@',
|
197
|
-
'A','B','C','D','E','F','G','H','I','J','K','L','M','N','O',
|
198
|
-
'P','Q','R','S','T','U','V','W','X','Y','Z',
|
199
|
-
'[',']','^','_','`',
|
200
|
-
'a','b','c','d','e','f','g','h','i','j','k','l','m','n','o','p',
|
201
|
-
'q','r','s','t','u','v','w','x','y','z',
|
202
|
-
'{','|','}','~','€(EURO SIGN)','‘(LEFT SINGLE QUOTATION MARK)','’(RIGHT SINGLE QUOTATION MARK)','“(LEFT DOUBLE QUOTATION MARK)',
|
203
|
-
'”(RIGHT DOUBLE QUOTATION MARK)','–(EN DASH)','—(EM DASH)','¡(INVERTED EXCLAMATION MARK)','¢(CENT SIGN)','£(POUND SIGN)',
|
204
|
-
'¤(CURRENCY SIGN)','¥(YEN SIGN)','¦(BROKEN BAR)','§(SECTION SIGN)','¨(DIAERESIS)','©(COPYRIGHT SIGN)','ª(FEMININE ORDINAL INDICATOR)',
|
205
|
-
'«(LEFT-POINTING DOUBLE ANGLE QUOTATION MARK)','¬(NOT SIGN)','®(REGISTERED SIGN)','¯(MACRON)','°(DEGREE SIGN)','±(PLUS-MINUS SIGN)','²(SUPERSCRIPT TWO)',
|
206
|
-
'³(SUPERSCRIPT THREE)','´(ACUTE ACCENT)','µ(MICRO SIGN)','¶(PILCROW SIGN)','·(MIDDLE DOT)','¸(CEDILLA)',
|
207
|
-
'¹(SUPERSCRIPT ONE)','º(MASCULINE ORDINAL INDICATOR)','»(RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK)','¼(VULGAR FRACTION ONE QUARTER)','½(VULGAR FRACTION ONE HALF)','¾(VULGAR FRACTION THREE QUARTERS)',
|
208
|
-
'¿(INVERTED QUESTION MARK)','À(LATIN CAPITAL LETTER A WITH GRAVE)','Á(LATIN CAPITAL LETTER A WITH ACUTE)','Â(LATIN CAPITAL LETTER A WITH CIRCUMFLEX)','Ã(LATIN CAPITAL LETTER A WITH TILDE)','Ä(LATIN CAPITAL LETTER A WITH DIAERESIS)',
|
209
|
-
'Å(LATIN CAPITAL LETTER A WITH RING ABOVE)','Æ(LATIN CAPITAL LETTER AE)','Ç(LATIN CAPITAL LETTER C WITH CEDILLA)','È(LATIN CAPITAL LETTER E WITH GRAVE)','É(LATIN CAPITAL LETTER E WITH ACUTE)','Ê(LATIN CAPITAL LETTER E WITH CIRCUMFLEX)',
|
210
|
-
'Ë(LATIN CAPITAL LETTER E WITH DIAERESIS)','Ì(LATIN CAPITAL LETTER I WITH GRAVE)','Í(LATIN CAPITAL LETTER I WITH ACUTE)','Î(LATIN CAPITAL LETTER I WITH CIRCUMFLEX)','Ï(LATIN CAPITAL LETTER I WITH DIAERESIS)','Ð(LATIN CAPITAL LETTER ETH)',
|
211
|
-
'Ñ(LATIN CAPITAL LETTER N WITH TILDE)','Ò(LATIN CAPITAL LETTER O WITH GRAVE)','Ó(LATIN CAPITAL LETTER O WITH ACUTE)','Ô(LATIN CAPITAL LETTER O WITH CIRCUMFLEX)','Õ(LATIN CAPITAL LETTER O WITH TILDE)','Ö(LATIN CAPITAL LETTER O WITH DIAERESIS)',
|
212
|
-
'×(MULTIPLICATION SIGN)','Ø(LATIN CAPITAL LETTER O WITH STROKE)','Ù(LATIN CAPITAL LETTER U WITH GRAVE)','Ú(LATIN CAPITAL LETTER U WITH ACUTE)','Û(LATIN CAPITAL LETTER U WITH CIRCUMFLEX)','Ü(LATIN CAPITAL LETTER U WITH DIAERESIS)',
|
213
|
-
'Ý(LATIN CAPITAL LETTER Y WITH ACUTE)','Þ(LATIN CAPITAL LETTER THORN)','ß(LATIN SMALL LETTER SHARP S)','à(LATIN SMALL LETTER A WITH GRAVE)','á(LATIN SMALL LETTER A WITH ACUTE)','â(LATIN SMALL LETTER A WITH CIRCUMFLEX)',
|
214
|
-
'ã(LATIN SMALL LETTER A WITH TILDE)','ä(LATIN SMALL LETTER A WITH DIAERESIS)','å(LATIN SMALL LETTER A WITH RING ABOVE)','æ(LATIN SMALL LETTER AE)','ç(LATIN SMALL LETTER C WITH CEDILLA)','è(LATIN SMALL LETTER E WITH GRAVE)',
|
215
|
-
'é(LATIN SMALL LETTER E WITH ACUTE)','ê(LATIN SMALL LETTER E WITH CIRCUMFLEX)','ë(LATIN SMALL LETTER E WITH DIAERESIS)','ì(LATIN SMALL LETTER I WITH GRAVE)','í(LATIN SMALL LETTER I WITH ACUTE)','î(LATIN SMALL LETTER I WITH CIRCUMFLEX)',
|
216
|
-
'ï(LATIN SMALL LETTER I WITH DIAERESIS)','ð(LATIN SMALL LETTER ETH)','ñ(LATIN SMALL LETTER N WITH TILDE)','ò(LATIN SMALL LETTER O WITH GRAVE)','ó(LATIN SMALL LETTER O WITH ACUTE)','ô(LATIN SMALL LETTER O WITH CIRCUMFLEX)',
|
217
|
-
'õ(LATIN SMALL LETTER O WITH TILDE)','ö(LATIN SMALL LETTER O WITH DIAERESIS)',
|
218
|
-
'÷(DIVISION SIGN)','ø(LATIN SMALL LETTER O WITH STROKE)',
|
219
|
-
'ù(LATIN SMALL LETTER U WITH GRAVE)','ú(LATIN SMALL LETTER U WITH ACUTE)',
|
220
|
-
'û(LATIN SMALL LETTER U WITH CIRCUMFLEX)','ü(LATIN SMALL LETTER U WITH DIAERESIS)',
|
221
|
-
'ü(LATIN SMALL LETTER U WITH DIAERESIS)','ý(LATIN SMALL LETTER Y WITH ACUTE)','þ(LATIN SMALL LETTER THORN)','ÿ(LATIN SMALL LETTER Y WITH DIAERESIS)',
|
222
|
-
'Œ(LATIN CAPITAL LIGATURE OE)',
|
223
|
-
'œ(LATIN SMALL LIGATURE OE)','Ŵ(LATIN CAPITAL LETTER W WITH CIRCUMFLEX)',
|
224
|
-
'Ŷ(LATIN CAPITAL LETTER Y WITH CIRCUMFLEX)','ŵ(LATIN SMALL LETTER W WITH CIRCUMFLEX)',
|
225
|
-
'ŷ(LATIN SMALL LETTER Y WITH CIRCUMFLEX)','‚(SINGLE LOW-9 QUOTATION MARK)',
|
226
|
-
'‛(SINGLE HIGH-REVERSED-9 QUOTATION MARK)','„(DOUBLE LOW-9 QUOTATION MARK)','…(HORIZONTAL ELLIPSIS)',
|
227
|
-
'™(TRADE MARK SIGN)','►(BLACK RIGHT-POINTING POINTER)','•(BULLET)',
|
228
|
-
'→(RIGHTWARDS ARROW)','⇒(RIGHTWARDS DOUBLE ARROW)','⇔(LEFT RIGHT DOUBLE ARROW)','♦(BLACK DIAMOND SUIT)','≈(ALMOST EQUAL TO)'
|
229
|
-
],
|
230
198
|
onLoad : function()
|
231
199
|
{
|
232
200
|
var columns = this.definition.charColumns,
|
233
|
-
|
201
|
+
extraChars = editor.config.extraSpecialChars,
|
202
|
+
chars = editor.config.specialChars;
|
234
203
|
|
235
|
-
var
|
204
|
+
var charsTableLabel = CKEDITOR.tools.getNextId() + '_specialchar_table_label';
|
205
|
+
var html = [ '<table role="listbox" aria-labelledby="' + charsTableLabel + '"' +
|
236
206
|
' style="width: 320px; height: 100%; border-collapse: separate;"' +
|
237
207
|
' align="center" cellspacing="2" cellpadding="2" border="0">' ];
|
238
208
|
|
@@ -250,21 +220,28 @@ CKEDITOR.dialog.add( 'specialchar', function( editor )
|
|
250
220
|
if ( ( character = chars[ i ] ) )
|
251
221
|
{
|
252
222
|
charDesc = '';
|
253
|
-
character = character.replace( /\((.*?)\)/, function( match, desc )
|
254
|
-
{
|
255
|
-
charDesc = desc;
|
256
|
-
return '';
|
257
|
-
} );
|
258
223
|
|
259
|
-
|
260
|
-
|
224
|
+
if ( character instanceof Array )
|
225
|
+
{
|
226
|
+
charDesc = character[ 1 ];
|
227
|
+
character = character[ 0 ];
|
228
|
+
}
|
229
|
+
else
|
230
|
+
{
|
231
|
+
var _tmpName = character.toLowerCase().replace( '&', '' ).replace( ';', '' ).replace( '#', '' );
|
232
|
+
|
233
|
+
// Use character in case description unavailable.
|
234
|
+
charDesc = lang[ _tmpName ] || character;
|
235
|
+
}
|
236
|
+
|
237
|
+
var charLabelId = 'cke_specialchar_label_' + i + '_' + CKEDITOR.tools.getNextNumber();
|
261
238
|
|
262
239
|
html.push(
|
263
|
-
'<td class="cke_dark_background" style="cursor: default">' +
|
240
|
+
'<td class="cke_dark_background" style="cursor: default" role="presentation">' +
|
264
241
|
'<a href="javascript: void(0);" role="option"' +
|
265
242
|
' aria-posinset="' + ( i +1 ) + '"',
|
266
243
|
' aria-setsize="' + size + '"',
|
267
|
-
' aria-labelledby="
|
244
|
+
' aria-labelledby="' + charLabelId + '"',
|
268
245
|
' style="cursor: inherit; display: block; height: 1.25em; margin-top: 0.25em; text-align: center;" title="', CKEDITOR.tools.htmlEncode( charDesc ), '"' +
|
269
246
|
' onkeydown="CKEDITOR.tools.callFunction( ' + onKeydown + ', event, this )"' +
|
270
247
|
' onclick="CKEDITOR.tools.callFunction(' + onClick + ', this); return false;"' +
|
@@ -272,7 +249,7 @@ CKEDITOR.dialog.add( 'specialchar', function( editor )
|
|
272
249
|
'<span style="margin: 0 auto;cursor: inherit">' +
|
273
250
|
character +
|
274
251
|
'</span>' +
|
275
|
-
'<span class="cke_voice_label" id="
|
252
|
+
'<span class="cke_voice_label" id="' + charLabelId + '">' +
|
276
253
|
charDesc +
|
277
254
|
'</span></a>');
|
278
255
|
}
|
@@ -284,7 +261,7 @@ CKEDITOR.dialog.add( 'specialchar', function( editor )
|
|
284
261
|
html.push( '</tr>' );
|
285
262
|
}
|
286
263
|
|
287
|
-
html.push( '</tbody></table>', '<span id="
|
264
|
+
html.push( '</tbody></table>', '<span id="' + charsTableLabel + '" class="cke_voice_label">' + lang.options +'</span>' );
|
288
265
|
|
289
266
|
this.getContentElement( 'info', 'charContainer' ).getElement().setHtml( html.join( '' ) );
|
290
267
|
},
|
@@ -311,11 +288,11 @@ CKEDITOR.dialog.add( 'specialchar', function( editor )
|
|
311
288
|
focus : function()
|
312
289
|
{
|
313
290
|
var firstChar = this.getElement().getElementsByTag( 'a' ).getItem( 0 );
|
314
|
-
setTimeout(function()
|
291
|
+
setTimeout( function()
|
315
292
|
{
|
316
293
|
firstChar.focus();
|
317
294
|
onFocus( null, firstChar );
|
318
|
-
});
|
295
|
+
}, 0 );
|
319
296
|
},
|
320
297
|
onShow : function()
|
321
298
|
{
|
@@ -324,7 +301,7 @@ CKEDITOR.dialog.add( 'specialchar', function( editor )
|
|
324
301
|
{
|
325
302
|
firstChar.focus();
|
326
303
|
onFocus( null, firstChar );
|
327
|
-
});
|
304
|
+
}, 0 );
|
328
305
|
},
|
329
306
|
onLoad : function( event )
|
330
307
|
{
|
data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/specialchar/lang/en.js
ADDED
@@ -0,0 +1,89 @@
|
|
1
|
+
|
2
|
+
CKEDITOR.plugins.setLang( 'specialchar', 'en',
|
3
|
+
{
|
4
|
+
euro: "Euro sign",
|
5
|
+
lsquo: "Left single quotation mark",
|
6
|
+
rsquo: "Right single quotation mark",
|
7
|
+
ldquo: "Left double quotation mark",
|
8
|
+
rdquo: "Right double quotation mark",
|
9
|
+
ndash: "En dash",
|
10
|
+
mdash: "Em dash",
|
11
|
+
iexcl: "Inverted exclamation mark",
|
12
|
+
cent: "Cent sign",
|
13
|
+
pound: "Pound sign",
|
14
|
+
curren: "Currency sign",
|
15
|
+
yen: "Yen sign",
|
16
|
+
brvbar: "Broken bar",
|
17
|
+
sect: "Section sign",
|
18
|
+
uml: "Diaeresis",
|
19
|
+
copy: "Copyright sign",
|
20
|
+
ordf: "Feminine ordinal indicator",
|
21
|
+
laquo: "Left-pointing double angle quotation mark",
|
22
|
+
not: "Not sign",
|
23
|
+
reg: "Registered sign",
|
24
|
+
macr: "Macron",
|
25
|
+
deg: "Degree sign",
|
26
|
+
sup2: "Superscript two",
|
27
|
+
sup3: "Superscript three",
|
28
|
+
acute: "Acute accent",
|
29
|
+
micro: "Micro sign",
|
30
|
+
para: "Pilcrow sign",
|
31
|
+
middot: "Middle dot",
|
32
|
+
cedil: "Cedilla",
|
33
|
+
sup1: "Superscript one",
|
34
|
+
ordm: "Masculine ordinal indicator",
|
35
|
+
frac14: "Vulgar fraction one quarter",
|
36
|
+
frac12: "Vulgar fraction one half",
|
37
|
+
frac34: "Vulgar fraction three quarters",
|
38
|
+
iquest: "Inverted question mark",
|
39
|
+
agrave: "Latin small letter a with grave",
|
40
|
+
aacute: "Latin small letter a with acute",
|
41
|
+
acirc: "Latin small letter a with circumflex",
|
42
|
+
atilde: "Latin small letter a with tilde",
|
43
|
+
auml: "Latin small letter a with diaeresis",
|
44
|
+
aring: "Latin small letter a with ring above",
|
45
|
+
aelig: "Latin small letter ae",
|
46
|
+
ccedil: "Latin small letter c with cedilla",
|
47
|
+
egrave: "Latin small letter e with grave",
|
48
|
+
eacute: "Latin small letter e with acute",
|
49
|
+
ecirc: "Latin small letter e with circumflex",
|
50
|
+
euml: "Latin small letter e with diaeresis",
|
51
|
+
igrave: "Latin small letter i with grave",
|
52
|
+
iacute: "Latin small letter i with acute",
|
53
|
+
icirc: "Latin small letter i with circumflex",
|
54
|
+
iuml: "Latin small letter i with diaeresis",
|
55
|
+
eth: "Latin small letter eth",
|
56
|
+
ntilde: "Latin small letter n with tilde",
|
57
|
+
ograve: "Latin small letter o with grave",
|
58
|
+
oacute: "Latin small letter o with acute",
|
59
|
+
ocirc: "Latin small letter o with circumflex",
|
60
|
+
otilde: "Latin small letter o with tilde",
|
61
|
+
ouml: "Latin small letter o with diaeresis",
|
62
|
+
times: "Multiplication sign",
|
63
|
+
oslash: "Latin small letter o with stroke",
|
64
|
+
ugrave: "Latin small letter u with grave",
|
65
|
+
uacute: "Latin small letter u with acute",
|
66
|
+
ucirc: "Latin small letter u with circumflex",
|
67
|
+
uuml: "Latin small letter u with diaeresis",
|
68
|
+
yacute: "Latin small letter y with acute",
|
69
|
+
thorn: "Latin small letter thorn",
|
70
|
+
szlig: "Latin small letter sharp s",
|
71
|
+
divide: "Division sign",
|
72
|
+
yuml: "Latin small letter y with diaeresis",
|
73
|
+
oelig: "Latin small ligature oe",
|
74
|
+
'372': "Latin capital letter w with circumflex",
|
75
|
+
'374': "Latin capital letter y with circumflex",
|
76
|
+
'373': "Latin small letter w with circumflex",
|
77
|
+
'375': "Latin small letter y with circumflex",
|
78
|
+
8219: "Single high-reversed-9 quotation mark",
|
79
|
+
bdquo: "Double low-9 quotation mark",
|
80
|
+
hellip: "Horizontal ellipsis",
|
81
|
+
trade: "Trade mark sign",
|
82
|
+
'9658': "Black right-pointing pointer",
|
83
|
+
bull: "Bullet",
|
84
|
+
rarr: "Rightwards double arrow",
|
85
|
+
harr: "Left right double arrow",
|
86
|
+
diams: "Black diamond suit",
|
87
|
+
asymp: "Almost equal to",
|
88
|
+
sbquo: "Single low-9 quotation mark"
|
89
|
+
});
|
data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/specialchar/plugin.js
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
/*
|
2
|
-
Copyright (c) 2003-
|
2
|
+
Copyright (c) 2003-2011, CKSource - Frederico Knabben. All rights reserved.
|
3
3
|
For licensing, see LICENSE.html or http://ckeditor.com/license
|
4
4
|
*/
|
5
5
|
|
@@ -9,15 +9,35 @@ For licensing, see LICENSE.html or http://ckeditor.com/license
|
|
9
9
|
|
10
10
|
CKEDITOR.plugins.add( 'specialchar',
|
11
11
|
{
|
12
|
+
// List of available localizations.
|
13
|
+
availableLangs : { en:1 },
|
14
|
+
|
12
15
|
init : function( editor )
|
13
16
|
{
|
14
|
-
var pluginName = 'specialchar'
|
17
|
+
var pluginName = 'specialchar',
|
18
|
+
plugin = this;
|
15
19
|
|
16
20
|
// Register the dialog.
|
17
21
|
CKEDITOR.dialog.add( pluginName, this.path + 'dialogs/specialchar.js' );
|
18
22
|
|
19
|
-
|
20
|
-
|
23
|
+
editor.addCommand( pluginName,
|
24
|
+
{
|
25
|
+
exec : function()
|
26
|
+
{
|
27
|
+
var langCode = editor.langCode;
|
28
|
+
langCode = plugin.availableLangs[ langCode ] ? langCode : 'en';
|
29
|
+
|
30
|
+
CKEDITOR.scriptLoader.load(
|
31
|
+
CKEDITOR.getUrl( plugin.path + 'lang/' + langCode + '.js' ),
|
32
|
+
function()
|
33
|
+
{
|
34
|
+
CKEDITOR.tools.extend( editor.lang.specialChar, plugin.langEntries[ langCode ] );
|
35
|
+
editor.openDialog( pluginName );
|
36
|
+
});
|
37
|
+
},
|
38
|
+
modes : { wysiwyg:1 },
|
39
|
+
canUndo : false
|
40
|
+
});
|
21
41
|
|
22
42
|
// Register the toolbar button.
|
23
43
|
editor.ui.addButton( 'SpecialChar',
|
@@ -27,3 +47,24 @@ CKEDITOR.plugins.add( 'specialchar',
|
|
27
47
|
});
|
28
48
|
}
|
29
49
|
} );
|
50
|
+
|
51
|
+
/**
|
52
|
+
* The list of special characters visible in Special Character dialog.
|
53
|
+
* @type Array
|
54
|
+
* @example
|
55
|
+
* config.specialChars = [ '"', '’', [ '&custom;', 'Custom label' ] ];
|
56
|
+
* config.specialChars = config.specialChars.concat( [ '"', [ '’', 'Custom label' ] ] );
|
57
|
+
*/
|
58
|
+
CKEDITOR.config.specialChars =
|
59
|
+
[
|
60
|
+
'!','"','#','$','%','&',"'",'(',')','*','+','-','.','/',
|
61
|
+
'0','1','2','3','4','5','6','7','8','9',':',';',
|
62
|
+
'<','=','>','?','@',
|
63
|
+
'A','B','C','D','E','F','G','H','I','J','K','L','M','N','O',
|
64
|
+
'P','Q','R','S','T','U','V','W','X','Y','Z',
|
65
|
+
'[',']','^','_','`',
|
66
|
+
'a','b','c','d','e','f','g','h','i','j','k','l','m','n','o','p',
|
67
|
+
'q','r','s','t','u','v','w','x','y','z',
|
68
|
+
'{','|','}','~',
|
69
|
+
"€", "‘", "’", "“", "”", "–", "—", "¡", "¢", "£", "¤", "¥", "¦", "§", "¨", "©", "ª", "«", "¬", "®", "¯", "°", "&", "²", "³", "´", "µ", "¶", "·", "¸", "¹", "º", "&", "¼", "½", "¾", "¿", "À", "Á", "Â", "Ã", "Ä", "Å", "Æ", "Ç", "È", "É", "Ê", "Ë", "Ì", "Í", "Î", "Ï", "Ð", "Ñ", "Ò", "Ó", "Ô", "Õ", "Ö", "×", "Ø", "Ù", "Ú", "Û", "Ü", "Ý", "Þ", "ß", "à", "á", "â", "ã", "ä", "å", "æ", "ç", "è", "é", "ê", "ë", "ì", "í", "î", "ï", "ð", "ñ", "ò", "ó", "ô", "õ", "ö", "÷", "ø", "ù", "ú", "û", "ü", "ü", "ý", "þ", "ÿ", "Œ", "œ", "Ŵ", "Ŷ", "ŵ", "ŷ", "‚", "‛", "„", "…", "™", "►", "•", "→", "⇒", "⇔", "♦", "≈"
|
70
|
+
];
|
data/public/javascripts/extensions/ck_editor_filter/ckeditor/_source/plugins/styles/plugin.js
CHANGED
@@ -1,19 +1,29 @@
|
|
1
1
|
/*
|
2
|
-
Copyright (c) 2003-
|
2
|
+
Copyright (c) 2003-2011, CKSource - Frederico Knabben. All rights reserved.
|
3
3
|
For licensing, see LICENSE.html or http://ckeditor.com/license
|
4
4
|
*/
|
5
5
|
|
6
6
|
CKEDITOR.plugins.add( 'styles',
|
7
7
|
{
|
8
|
-
requires : [ 'selection' ]
|
8
|
+
requires : [ 'selection' ],
|
9
|
+
init : function( editor )
|
10
|
+
{
|
11
|
+
// This doesn't look like correct, but it's the safest way to proper
|
12
|
+
// pass the disableReadonlyStyling configuration to the style system
|
13
|
+
// without having to change any method signature in the API. (#6103)
|
14
|
+
editor.on( 'contentDom', function()
|
15
|
+
{
|
16
|
+
editor.document.setCustomData( 'cke_includeReadonly', !editor.config.disableReadonlyStyling );
|
17
|
+
});
|
18
|
+
}
|
9
19
|
});
|
10
20
|
|
11
21
|
/**
|
12
|
-
* Registers a function to be called whenever
|
22
|
+
* Registers a function to be called whenever the selection position changes in the
|
13
23
|
* editing area. The current state is passed to the function. The possible
|
14
24
|
* states are {@link CKEDITOR.TRISTATE_ON} and {@link CKEDITOR.TRISTATE_OFF}.
|
15
|
-
* @param {CKEDITOR.style} The style to be watched.
|
16
|
-
* @param {Function} The function to be called
|
25
|
+
* @param {CKEDITOR.style} style The style to be watched.
|
26
|
+
* @param {Function} callback The function to be called.
|
17
27
|
* @example
|
18
28
|
* // Create a style object for the <b> element.
|
19
29
|
* var style = new CKEDITOR.style( { element : 'b' } );
|
@@ -51,22 +61,14 @@ CKEDITOR.editor.prototype.attachStyleStateChange = function( style, callback )
|
|
51
61
|
// callback.
|
52
62
|
var currentState = callback.style.checkActive( ev.data.path ) ? CKEDITOR.TRISTATE_ON : CKEDITOR.TRISTATE_OFF;
|
53
63
|
|
54
|
-
//
|
55
|
-
|
56
|
-
|
57
|
-
// Call the callback function, passing the current
|
58
|
-
// state to it.
|
59
|
-
callback.fn.call( this, currentState );
|
60
|
-
|
61
|
-
// Save the current state, so it can be compared next
|
62
|
-
// time.
|
63
|
-
callback.state !== currentState;
|
64
|
-
}
|
64
|
+
// Call the callback function, passing the current
|
65
|
+
// state to it.
|
66
|
+
callback.fn.call( this, currentState );
|
65
67
|
}
|
66
68
|
});
|
67
69
|
}
|
68
70
|
|
69
|
-
// Save the callback info, so it can be checked on the next
|
71
|
+
// Save the callback info, so it can be checked on the next occurrence of
|
70
72
|
// selectionChange.
|
71
73
|
styleStateChangeCallbacks.push( { style : style, fn : callback } );
|
72
74
|
};
|
@@ -77,10 +79,14 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
77
79
|
|
78
80
|
(function()
|
79
81
|
{
|
80
|
-
var blockElements = { address:1,div:1,h1:1,h2:1,h3:1,h4:1,h5:1,h6:1,p:1,pre:1 }
|
81
|
-
|
82
|
+
var blockElements = { address:1,div:1,h1:1,h2:1,h3:1,h4:1,h5:1,h6:1,p:1,pre:1 },
|
83
|
+
objectElements = { a:1,embed:1,hr:1,img:1,li:1,object:1,ol:1,table:1,td:1,tr:1,th:1,ul:1,dl:1,dt:1,dd:1,form:1};
|
84
|
+
|
85
|
+
var semicolonFixRegex = /\s*(?:;\s*|$)/,
|
86
|
+
varRegex = /#\((.+?)\)/g;
|
82
87
|
|
83
|
-
var
|
88
|
+
var notBookmark = CKEDITOR.dom.walker.bookmark( 0, 1 ),
|
89
|
+
nonWhitespaces = CKEDITOR.dom.walker.whitespaces( 1 );
|
84
90
|
|
85
91
|
CKEDITOR.style = function( styleDefinition, variablesValues )
|
86
92
|
{
|
@@ -95,7 +101,7 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
95
101
|
var element = this.element = ( styleDefinition.element || '*' ).toLowerCase();
|
96
102
|
|
97
103
|
this.type =
|
98
|
-
|
104
|
+
blockElements[ element ] ?
|
99
105
|
CKEDITOR.STYLE_BLOCK
|
100
106
|
: objectElements[ element ] ?
|
101
107
|
CKEDITOR.STYLE_OBJECT
|
@@ -127,6 +133,8 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
127
133
|
applyInlineStyle
|
128
134
|
: this.type == CKEDITOR.STYLE_BLOCK ?
|
129
135
|
applyBlockStyle
|
136
|
+
: this.type == CKEDITOR.STYLE_OBJECT ?
|
137
|
+
applyObjectStyle
|
130
138
|
: null ).call( this, range );
|
131
139
|
},
|
132
140
|
|
@@ -135,6 +143,10 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
135
143
|
return ( this.removeFromRange =
|
136
144
|
this.type == CKEDITOR.STYLE_INLINE ?
|
137
145
|
removeInlineStyle
|
146
|
+
: this.type == CKEDITOR.STYLE_BLOCK ?
|
147
|
+
removeBlockStyle
|
148
|
+
: this.type == CKEDITOR.STYLE_OBJECT ?
|
149
|
+
removeObjectStyle
|
138
150
|
: null ).call( this, range );
|
139
151
|
},
|
140
152
|
|
@@ -154,17 +166,23 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
154
166
|
case CKEDITOR.STYLE_BLOCK :
|
155
167
|
return this.checkElementRemovable( elementPath.block || elementPath.blockLimit, true );
|
156
168
|
|
169
|
+
case CKEDITOR.STYLE_OBJECT :
|
157
170
|
case CKEDITOR.STYLE_INLINE :
|
158
171
|
|
159
172
|
var elements = elementPath.elements;
|
160
173
|
|
161
174
|
for ( var i = 0, element ; i < elements.length ; i++ )
|
162
175
|
{
|
163
|
-
element = elements[i];
|
176
|
+
element = elements[ i ];
|
164
177
|
|
165
|
-
if (
|
178
|
+
if ( this.type == CKEDITOR.STYLE_INLINE
|
179
|
+
&& ( element == elementPath.block || element == elementPath.blockLimit ) )
|
166
180
|
continue;
|
167
181
|
|
182
|
+
if( this.type == CKEDITOR.STYLE_OBJECT
|
183
|
+
&& !( element.getName() in objectElements ) )
|
184
|
+
continue;
|
185
|
+
|
168
186
|
if ( this.checkElementRemovable( element, true ) )
|
169
187
|
return true;
|
170
188
|
}
|
@@ -172,11 +190,30 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
172
190
|
return false;
|
173
191
|
},
|
174
192
|
|
193
|
+
/**
|
194
|
+
* Whether this style can be applied at the element path.
|
195
|
+
* @param elementPath
|
196
|
+
*/
|
197
|
+
checkApplicable : function( elementPath )
|
198
|
+
{
|
199
|
+
switch ( this.type )
|
200
|
+
{
|
201
|
+
case CKEDITOR.STYLE_INLINE :
|
202
|
+
case CKEDITOR.STYLE_BLOCK :
|
203
|
+
break;
|
204
|
+
|
205
|
+
case CKEDITOR.STYLE_OBJECT :
|
206
|
+
return elementPath.lastElement.getAscendant( this.element, true );
|
207
|
+
}
|
208
|
+
|
209
|
+
return true;
|
210
|
+
},
|
211
|
+
|
175
212
|
// Checks if an element, or any of its attributes, is removable by the
|
176
213
|
// current style definition.
|
177
214
|
checkElementRemovable : function( element, fullMatch )
|
178
215
|
{
|
179
|
-
if ( !element )
|
216
|
+
if ( !element || element.isReadOnly() )
|
180
217
|
return false;
|
181
218
|
|
182
219
|
var def = this._.definition,
|
@@ -199,9 +236,11 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
199
236
|
continue;
|
200
237
|
|
201
238
|
var elementAttr = element.getAttribute( attName ) || '';
|
202
|
-
|
203
|
-
|
204
|
-
|
239
|
+
|
240
|
+
// Special treatment for 'style' attribute is required.
|
241
|
+
if ( attName == 'style' ?
|
242
|
+
compareCssText( attribs[ attName ], normalizeCssText( elementAttr, false ) )
|
243
|
+
: attribs[ attName ] == elementAttr )
|
205
244
|
{
|
206
245
|
if ( !fullMatch )
|
207
246
|
return true;
|
@@ -246,6 +285,39 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
246
285
|
}
|
247
286
|
}
|
248
287
|
return false;
|
288
|
+
},
|
289
|
+
|
290
|
+
// Builds the preview HTML based on the styles definition.
|
291
|
+
buildPreview : function( label )
|
292
|
+
{
|
293
|
+
var styleDefinition = this._.definition,
|
294
|
+
html = [],
|
295
|
+
elementName = styleDefinition.element;
|
296
|
+
|
297
|
+
// Avoid <bdo> in the preview.
|
298
|
+
if ( elementName == 'bdo' )
|
299
|
+
elementName = 'span';
|
300
|
+
|
301
|
+
html = [ '<', elementName ];
|
302
|
+
|
303
|
+
// Assign all defined attributes.
|
304
|
+
var attribs = styleDefinition.attributes;
|
305
|
+
if ( attribs )
|
306
|
+
{
|
307
|
+
for ( var att in attribs )
|
308
|
+
{
|
309
|
+
html.push( ' ', att, '="', attribs[ att ], '"' );
|
310
|
+
}
|
311
|
+
}
|
312
|
+
|
313
|
+
// Assign the style attribute.
|
314
|
+
var cssStyle = CKEDITOR.style.getStyleText( styleDefinition );
|
315
|
+
if ( cssStyle )
|
316
|
+
html.push( ' style="', cssStyle, '"' );
|
317
|
+
|
318
|
+
html.push( '>', ( label || styleDefinition.name ), '</', elementName, '>' );
|
319
|
+
|
320
|
+
return html.join( '' );
|
249
321
|
}
|
250
322
|
};
|
251
323
|
|
@@ -260,24 +332,64 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
260
332
|
stylesDef = styleDefinition.styles;
|
261
333
|
|
262
334
|
// Builds the StyleText.
|
263
|
-
|
264
|
-
|
335
|
+
var stylesText = ( styleDefinition.attributes && styleDefinition.attributes[ 'style' ] ) || '',
|
336
|
+
specialStylesText = '';
|
265
337
|
|
266
338
|
if ( stylesText.length )
|
267
339
|
stylesText = stylesText.replace( semicolonFixRegex, ';' );
|
268
340
|
|
269
341
|
for ( var style in stylesDef )
|
270
|
-
|
342
|
+
{
|
343
|
+
var styleVal = stylesDef[ style ],
|
344
|
+
text = ( style + ':' + styleVal ).replace( semicolonFixRegex, ';' );
|
345
|
+
|
346
|
+
// Some browsers don't support 'inherit' property value, leave them intact. (#5242)
|
347
|
+
if ( styleVal == 'inherit' )
|
348
|
+
specialStylesText += text;
|
349
|
+
else
|
350
|
+
stylesText += text;
|
351
|
+
}
|
271
352
|
|
272
353
|
// Browsers make some changes to the style when applying them. So, here
|
273
354
|
// we normalize it to the browser format.
|
274
355
|
if ( stylesText.length )
|
275
356
|
stylesText = normalizeCssText( stylesText );
|
276
357
|
|
358
|
+
stylesText += specialStylesText;
|
359
|
+
|
277
360
|
// Return it, saving it to the next request.
|
278
361
|
return ( styleDefinition._ST = stylesText );
|
279
362
|
};
|
280
363
|
|
364
|
+
// Gets the parent element which blocks the styling for an element. This
|
365
|
+
// can be done through read-only elements (contenteditable=false) or
|
366
|
+
// elements with the "data-nostyle" attribute.
|
367
|
+
function getUnstylableParent( element )
|
368
|
+
{
|
369
|
+
var unstylable,
|
370
|
+
editable;
|
371
|
+
|
372
|
+
while ( ( element = element.getParent() ) )
|
373
|
+
{
|
374
|
+
if ( element.getName() == 'body' )
|
375
|
+
break;
|
376
|
+
|
377
|
+
if ( element.getAttribute( 'data-nostyle' ) )
|
378
|
+
unstylable = element;
|
379
|
+
else if ( !editable )
|
380
|
+
{
|
381
|
+
var contentEditable = element.getAttribute( 'contentEditable' );
|
382
|
+
|
383
|
+
if ( contentEditable == 'false' )
|
384
|
+
unstylable = element;
|
385
|
+
else if ( contentEditable == 'true' )
|
386
|
+
editable = 1;
|
387
|
+
}
|
388
|
+
}
|
389
|
+
|
390
|
+
return unstylable;
|
391
|
+
}
|
392
|
+
|
281
393
|
function applyInlineStyle( range )
|
282
394
|
{
|
283
395
|
var document = range.document;
|
@@ -300,59 +412,48 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
300
412
|
var def = this._.definition;
|
301
413
|
var isUnknownElement;
|
302
414
|
|
415
|
+
// Indicates that fully selected read-only elements are to be included in the styling range.
|
416
|
+
var includeReadonly = def.includeReadonly;
|
417
|
+
|
418
|
+
// If the read-only inclusion is not available in the definition, try
|
419
|
+
// to get it from the document data.
|
420
|
+
if ( includeReadonly == undefined )
|
421
|
+
includeReadonly = document.getCustomData( 'cke_includeReadonly' );
|
422
|
+
|
303
423
|
// Get the DTD definition for the element. Defaults to "span".
|
304
424
|
var dtd = CKEDITOR.dtd[ elementName ] || ( isUnknownElement = true, CKEDITOR.dtd.span );
|
305
425
|
|
306
|
-
// Bookmark the range so we can re-select it after processing.
|
307
|
-
var bookmark = range.createBookmark();
|
308
|
-
|
309
426
|
// Expand the range.
|
310
|
-
range.enlarge( CKEDITOR.ENLARGE_ELEMENT );
|
427
|
+
range.enlarge( CKEDITOR.ENLARGE_ELEMENT, 1 );
|
311
428
|
range.trim();
|
312
429
|
|
313
430
|
// Get the first node to be processed and the last, which concludes the
|
314
431
|
// processing.
|
315
|
-
var boundaryNodes = range.
|
316
|
-
|
317
|
-
|
318
|
-
|
319
|
-
// Probably the document end is reached, we need a marker node.
|
320
|
-
if ( !lastNode )
|
321
|
-
{
|
322
|
-
var marker;
|
323
|
-
lastNode = marker = document.createText( '' );
|
324
|
-
lastNode.insertAfter( range.endContainer );
|
325
|
-
}
|
326
|
-
// The detection algorithm below skips the contents inside bookmark nodes, so
|
327
|
-
// we'll need to make sure lastNode isn't the inside a bookmark node.
|
328
|
-
var lastParent = lastNode.getParent();
|
329
|
-
if ( lastParent && lastParent.getAttribute( '_fck_bookmark' ) )
|
330
|
-
lastNode = lastParent;
|
331
|
-
|
332
|
-
if ( lastNode.equals( firstNode ) )
|
333
|
-
{
|
334
|
-
// If the last node is the same as the the first one, we must move
|
335
|
-
// it to the next one, otherwise the first one will not be
|
336
|
-
// processed.
|
337
|
-
lastNode = lastNode.getNextSourceNode( true );
|
338
|
-
|
339
|
-
// It may happen that there are no more nodes after it (the end of
|
340
|
-
// the document), so we must add something there to make our code
|
341
|
-
// simpler.
|
342
|
-
if ( !lastNode )
|
343
|
-
{
|
344
|
-
lastNode = marker = document.createText( '' );
|
345
|
-
lastNode.insertAfter( firstNode );
|
346
|
-
}
|
347
|
-
}
|
432
|
+
var boundaryNodes = range.createBookmark(),
|
433
|
+
firstNode = boundaryNodes.startNode,
|
434
|
+
lastNode = boundaryNodes.endNode;
|
348
435
|
|
349
436
|
var currentNode = firstNode;
|
350
437
|
|
351
438
|
var styleRange;
|
352
439
|
|
353
|
-
//
|
354
|
-
|
355
|
-
|
440
|
+
// Check if the boundaries are inside non stylable elements.
|
441
|
+
var firstUnstylable = getUnstylableParent( firstNode ),
|
442
|
+
lastUnstylable = getUnstylableParent( lastNode );
|
443
|
+
|
444
|
+
// If the first element can't be styled, we'll start processing right
|
445
|
+
// after its unstylable root.
|
446
|
+
if ( firstUnstylable )
|
447
|
+
currentNode = firstUnstylable.getNextSourceNode( true );
|
448
|
+
|
449
|
+
// If the last element can't be styled, we'll stop processing on its
|
450
|
+
// unstylable root.
|
451
|
+
if ( lastUnstylable )
|
452
|
+
lastNode = lastUnstylable;
|
453
|
+
|
454
|
+
// Do nothing if the current node now follows the last node to be processed.
|
455
|
+
if ( currentNode.getPosition( lastNode ) == CKEDITOR.POSITION_FOLLOWING )
|
456
|
+
currentNode = 0;
|
356
457
|
|
357
458
|
while ( currentNode )
|
358
459
|
{
|
@@ -367,8 +468,10 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
367
468
|
{
|
368
469
|
var nodeType = currentNode.type;
|
369
470
|
var nodeName = nodeType == CKEDITOR.NODE_ELEMENT ? currentNode.getName() : null;
|
471
|
+
var nodeIsReadonly = nodeName && ( currentNode.getAttribute( 'contentEditable' ) == 'false' );
|
472
|
+
var nodeIsNoStyle = nodeName && currentNode.getAttribute( 'data-nostyle' );
|
370
473
|
|
371
|
-
if ( nodeName && currentNode.
|
474
|
+
if ( nodeName && currentNode.data( 'cke-bookmark' ) )
|
372
475
|
{
|
373
476
|
currentNode = currentNode.getNextSourceNode( true );
|
374
477
|
continue;
|
@@ -376,6 +479,8 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
376
479
|
|
377
480
|
// Check if the current node can be a child of the style element.
|
378
481
|
if ( !nodeName || ( dtd[ nodeName ]
|
482
|
+
&& !nodeIsNoStyle
|
483
|
+
&& ( !nodeIsReadonly || includeReadonly )
|
379
484
|
&& ( currentNode.getPosition( lastNode ) | CKEDITOR.POSITION_PRECEDING | CKEDITOR.POSITION_IDENTICAL | CKEDITOR.POSITION_IS_CONTAINED ) == ( CKEDITOR.POSITION_PRECEDING + CKEDITOR.POSITION_IDENTICAL + CKEDITOR.POSITION_IS_CONTAINED )
|
380
485
|
&& ( !def.childRule || def.childRule( currentNode ) ) ) )
|
381
486
|
{
|
@@ -397,9 +502,9 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
397
502
|
styleRange.setStartBefore( currentNode );
|
398
503
|
}
|
399
504
|
|
400
|
-
// Non element nodes,
|
401
|
-
// completely to the range.
|
402
|
-
if ( nodeType == CKEDITOR.NODE_TEXT || ( nodeType == CKEDITOR.NODE_ELEMENT && !currentNode.getChildCount() ) )
|
505
|
+
// Non element nodes, readonly elements, or empty
|
506
|
+
// elements can be added completely to the range.
|
507
|
+
if ( nodeType == CKEDITOR.NODE_TEXT || nodeIsReadonly || ( nodeType == CKEDITOR.NODE_ELEMENT && !currentNode.getChildCount() ) )
|
403
508
|
{
|
404
509
|
var includedNode = currentNode;
|
405
510
|
var parentNode;
|
@@ -407,8 +512,8 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
407
512
|
// This node is about to be included completelly, but,
|
408
513
|
// if this is the last node in its parent, we must also
|
409
514
|
// check if the parent itself can be added completelly
|
410
|
-
// to the range.
|
411
|
-
while ( !includedNode
|
515
|
+
// to the range, otherwise apply the style immediately.
|
516
|
+
while ( ( applyStyle = !includedNode.getNext( notBookmark ) )
|
412
517
|
&& ( parentNode = includedNode.getParent(), dtd[ parentNode.getName() ] )
|
413
518
|
&& ( parentNode.getPosition( firstNode ) | CKEDITOR.POSITION_FOLLOWING | CKEDITOR.POSITION_IDENTICAL | CKEDITOR.POSITION_IS_CONTAINED ) == ( CKEDITOR.POSITION_FOLLOWING + CKEDITOR.POSITION_IDENTICAL + CKEDITOR.POSITION_IS_CONTAINED )
|
414
519
|
&& ( !def.childRule || def.childRule( parentNode ) ) )
|
@@ -418,14 +523,6 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
418
523
|
|
419
524
|
styleRange.setEndAfter( includedNode );
|
420
525
|
|
421
|
-
// If the included node still is the last node in its
|
422
|
-
// parent, it means that the parent can't be included
|
423
|
-
// in this style DTD, so apply the style immediately.
|
424
|
-
if ( !includedNode.$.nextSibling )
|
425
|
-
applyStyle = true;
|
426
|
-
|
427
|
-
if ( !hasContents )
|
428
|
-
hasContents = ( nodeType != CKEDITOR.NODE_TEXT || (/[^\s\ufeff]/).test( currentNode.getText() ) );
|
429
526
|
}
|
430
527
|
}
|
431
528
|
else
|
@@ -435,46 +532,71 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
435
532
|
applyStyle = true;
|
436
533
|
|
437
534
|
// Get the next node to be processed.
|
438
|
-
currentNode = currentNode.getNextSourceNode();
|
535
|
+
currentNode = currentNode.getNextSourceNode( nodeIsNoStyle || nodeIsReadonly );
|
439
536
|
}
|
440
537
|
|
441
538
|
// Apply the style if we have something to which apply it.
|
442
|
-
if ( applyStyle &&
|
539
|
+
if ( applyStyle && styleRange && !styleRange.collapsed )
|
443
540
|
{
|
444
541
|
// Build the style element, based on the style object definition.
|
445
|
-
var styleNode = getElement( this, document )
|
542
|
+
var styleNode = getElement( this, document ),
|
543
|
+
styleHasAttrs = styleNode.hasAttributes();
|
446
544
|
|
447
545
|
// Get the element that holds the entire range.
|
448
546
|
var parent = styleRange.getCommonAncestor();
|
449
547
|
|
548
|
+
var removeList = {
|
549
|
+
styles : {},
|
550
|
+
attrs : {},
|
551
|
+
// Styles cannot be removed.
|
552
|
+
blockedStyles : {},
|
553
|
+
// Attrs cannot be removed.
|
554
|
+
blockedAttrs : {}
|
555
|
+
};
|
556
|
+
|
557
|
+
var attName, styleName, value;
|
558
|
+
|
450
559
|
// Loop through the parents, removing the redundant attributes
|
451
560
|
// from the element to be applied.
|
452
561
|
while ( styleNode && parent )
|
453
562
|
{
|
454
563
|
if ( parent.getName() == elementName )
|
455
564
|
{
|
456
|
-
for (
|
565
|
+
for ( attName in def.attributes )
|
457
566
|
{
|
458
|
-
if (
|
459
|
-
|
460
|
-
}
|
567
|
+
if ( removeList.blockedAttrs[ attName ] || !( value = parent.getAttribute( styleName ) ) )
|
568
|
+
continue;
|
461
569
|
|
462
|
-
|
463
|
-
|
464
|
-
|
465
|
-
|
570
|
+
if ( styleNode.getAttribute( attName ) == value )
|
571
|
+
removeList.attrs[ attName ] = 1;
|
572
|
+
else
|
573
|
+
removeList.blockedAttrs[ attName ] = 1;
|
466
574
|
}
|
467
575
|
|
468
|
-
|
576
|
+
for ( styleName in def.styles )
|
469
577
|
{
|
470
|
-
|
471
|
-
|
578
|
+
if ( removeList.blockedStyles[ styleName ] || !( value = parent.getStyle( styleName ) ) )
|
579
|
+
continue;
|
580
|
+
|
581
|
+
if ( styleNode.getStyle( styleName ) == value )
|
582
|
+
removeList.styles[ styleName ] = 1;
|
583
|
+
else
|
584
|
+
removeList.blockedStyles[ styleName ] = 1;
|
472
585
|
}
|
473
586
|
}
|
474
587
|
|
475
588
|
parent = parent.getParent();
|
476
589
|
}
|
477
590
|
|
591
|
+
for ( attName in removeList.attrs )
|
592
|
+
styleNode.removeAttribute( attName );
|
593
|
+
|
594
|
+
for ( styleName in removeList.styles )
|
595
|
+
styleNode.removeStyle( styleName );
|
596
|
+
|
597
|
+
if ( styleHasAttrs && !styleNode.hasAttributes() )
|
598
|
+
styleNode = null;
|
599
|
+
|
478
600
|
if ( styleNode )
|
479
601
|
{
|
480
602
|
// Move the contents of the range to the style element.
|
@@ -489,7 +611,7 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
489
611
|
styleRange.insertNode( styleNode );
|
490
612
|
|
491
613
|
// Let's merge our new style with its neighbors, if possible.
|
492
|
-
mergeSiblings(
|
614
|
+
styleNode.mergeSiblings();
|
493
615
|
|
494
616
|
// As the style system breaks text nodes constantly, let's normalize
|
495
617
|
// things for performance.
|
@@ -500,6 +622,15 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
500
622
|
if ( !CKEDITOR.env.ie )
|
501
623
|
styleNode.$.normalize();
|
502
624
|
}
|
625
|
+
// Style already inherit from parents, left just to clear up any internal overrides. (#5931)
|
626
|
+
else
|
627
|
+
{
|
628
|
+
styleNode = new CKEDITOR.dom.element( 'span' );
|
629
|
+
styleRange.extractContents().appendTo( styleNode );
|
630
|
+
styleRange.insertNode( styleNode );
|
631
|
+
removeFromInsideElement( this, styleNode );
|
632
|
+
styleNode.remove( true );
|
633
|
+
}
|
503
634
|
|
504
635
|
// Style applied, let's release the range, so it gets
|
505
636
|
// re-initialization in the next loop.
|
@@ -507,9 +638,11 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
507
638
|
}
|
508
639
|
}
|
509
640
|
|
510
|
-
// Remove the
|
511
|
-
|
512
|
-
|
641
|
+
// Remove the bookmark nodes.
|
642
|
+
range.moveToBookmark( boundaryNodes );
|
643
|
+
|
644
|
+
// Minimize the result range to exclude empty text nodes. (#5374)
|
645
|
+
range.shrink( CKEDITOR.SHRINK_TEXT );
|
513
646
|
}
|
514
647
|
|
515
648
|
function removeInlineStyle( range )
|
@@ -518,7 +651,7 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
518
651
|
* Make sure our range has included all "collpased" parent inline nodes so
|
519
652
|
* that our operation logic can be simpler.
|
520
653
|
*/
|
521
|
-
range.enlarge( CKEDITOR.ENLARGE_ELEMENT );
|
654
|
+
range.enlarge( CKEDITOR.ENLARGE_ELEMENT, 1 );
|
522
655
|
|
523
656
|
var bookmark = range.createBookmark(),
|
524
657
|
startNode = bookmark.startNode;
|
@@ -546,12 +679,14 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
546
679
|
|
547
680
|
if ( this.checkElementRemovable( element ) )
|
548
681
|
{
|
549
|
-
var
|
550
|
-
|
551
|
-
if (
|
682
|
+
var isStart;
|
683
|
+
|
684
|
+
if ( range.collapsed && (
|
685
|
+
range.checkBoundaryOfElement( element, CKEDITOR.END ) ||
|
686
|
+
( isStart = range.checkBoundaryOfElement( element, CKEDITOR.START ) ) ) )
|
552
687
|
{
|
553
688
|
boundaryElement = element;
|
554
|
-
boundaryElement.match =
|
689
|
+
boundaryElement.match = isStart ? 'start' : 'end';
|
555
690
|
}
|
556
691
|
else
|
557
692
|
{
|
@@ -561,9 +696,11 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
561
696
|
* no difference that they're separate entities in the DOM tree. So, merge
|
562
697
|
* them before removal.
|
563
698
|
*/
|
564
|
-
mergeSiblings(
|
565
|
-
|
566
|
-
|
699
|
+
element.mergeSiblings();
|
700
|
+
if ( element.getName() == this.element )
|
701
|
+
removeFromElement( this, element );
|
702
|
+
else
|
703
|
+
removeOverrides( element, getOverrides( this )[ element.getName() ] );
|
567
704
|
}
|
568
705
|
}
|
569
706
|
}
|
@@ -672,7 +809,49 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
672
809
|
}
|
673
810
|
|
674
811
|
range.moveToBookmark( bookmark );
|
675
|
-
}
|
812
|
+
}
|
813
|
+
|
814
|
+
function applyObjectStyle( range )
|
815
|
+
{
|
816
|
+
var root = range.getCommonAncestor( true, true ),
|
817
|
+
element = root.getAscendant( this.element, true );
|
818
|
+
element && !element.isReadOnly() && setupElement( element, this );
|
819
|
+
}
|
820
|
+
|
821
|
+
function removeObjectStyle( range )
|
822
|
+
{
|
823
|
+
var root = range.getCommonAncestor( true, true ),
|
824
|
+
element = root.getAscendant( this.element, true );
|
825
|
+
|
826
|
+
if ( !element )
|
827
|
+
return;
|
828
|
+
|
829
|
+
var style = this,
|
830
|
+
def = style._.definition,
|
831
|
+
attributes = def.attributes;
|
832
|
+
var styles = CKEDITOR.style.getStyleText( def );
|
833
|
+
|
834
|
+
// Remove all defined attributes.
|
835
|
+
if ( attributes )
|
836
|
+
{
|
837
|
+
for ( var att in attributes )
|
838
|
+
{
|
839
|
+
element.removeAttribute( att, attributes[ att ] );
|
840
|
+
}
|
841
|
+
}
|
842
|
+
|
843
|
+
// Assign all defined styles.
|
844
|
+
if ( def.styles )
|
845
|
+
{
|
846
|
+
for ( var i in def.styles )
|
847
|
+
{
|
848
|
+
if ( !def.styles.hasOwnProperty( i ) )
|
849
|
+
continue;
|
850
|
+
|
851
|
+
element.removeStyle( i );
|
852
|
+
}
|
853
|
+
}
|
854
|
+
}
|
676
855
|
|
677
856
|
function applyBlockStyle( range )
|
678
857
|
{
|
@@ -683,14 +862,54 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
683
862
|
var iterator = range.createIterator();
|
684
863
|
iterator.enforceRealBlocks = true;
|
685
864
|
|
865
|
+
// make recognize <br /> tag as a separator in ENTER_BR mode (#5121)
|
866
|
+
if ( this._.enterMode )
|
867
|
+
iterator.enlargeBr = ( this._.enterMode != CKEDITOR.ENTER_BR );
|
868
|
+
|
686
869
|
var block;
|
687
870
|
var doc = range.document;
|
688
871
|
var previousPreBlock;
|
689
872
|
|
690
873
|
while ( ( block = iterator.getNextParagraph() ) ) // Only one =
|
691
874
|
{
|
692
|
-
|
693
|
-
|
875
|
+
if ( !block.isReadOnly() )
|
876
|
+
{
|
877
|
+
var newBlock = getElement( this, doc, block );
|
878
|
+
replaceBlock( block, newBlock );
|
879
|
+
}
|
880
|
+
}
|
881
|
+
|
882
|
+
range.moveToBookmark( bookmark );
|
883
|
+
}
|
884
|
+
|
885
|
+
function removeBlockStyle( range )
|
886
|
+
{
|
887
|
+
// Serializible bookmarks is needed here since
|
888
|
+
// elements may be merged.
|
889
|
+
var bookmark = range.createBookmark( 1 );
|
890
|
+
|
891
|
+
var iterator = range.createIterator();
|
892
|
+
iterator.enforceRealBlocks = true;
|
893
|
+
iterator.enlargeBr = this._.enterMode != CKEDITOR.ENTER_BR;
|
894
|
+
|
895
|
+
var block;
|
896
|
+
while ( ( block = iterator.getNextParagraph() ) )
|
897
|
+
{
|
898
|
+
if ( this.checkElementRemovable( block ) )
|
899
|
+
{
|
900
|
+
// <pre> get special treatment.
|
901
|
+
if ( block.is( 'pre' ) )
|
902
|
+
{
|
903
|
+
var newBlock = this._.enterMode == CKEDITOR.ENTER_BR ?
|
904
|
+
null : range.document.createElement(
|
905
|
+
this._.enterMode == CKEDITOR.ENTER_P ? 'p' : 'div' );
|
906
|
+
|
907
|
+
newBlock && block.copyAttributes( newBlock );
|
908
|
+
replaceBlock( block, newBlock );
|
909
|
+
}
|
910
|
+
else
|
911
|
+
removeFromElement( this, block, 1 );
|
912
|
+
}
|
694
913
|
}
|
695
914
|
|
696
915
|
range.moveToBookmark( bookmark );
|
@@ -701,8 +920,17 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
701
920
|
// when necessary.(#3188)
|
702
921
|
function replaceBlock( block, newBlock )
|
703
922
|
{
|
704
|
-
|
705
|
-
|
923
|
+
// Block is to be removed, create a temp element to
|
924
|
+
// save contents.
|
925
|
+
var removeBlock = !newBlock;
|
926
|
+
if ( removeBlock )
|
927
|
+
{
|
928
|
+
newBlock = block.getDocument().createElement( 'div' );
|
929
|
+
block.copyAttributes( newBlock );
|
930
|
+
}
|
931
|
+
|
932
|
+
var newBlockIsPre = newBlock && newBlock.is( 'pre' );
|
933
|
+
var blockIsPre = block.is( 'pre' );
|
706
934
|
|
707
935
|
var isToPre = newBlockIsPre && !blockIsPre;
|
708
936
|
var isFromPre = !newBlockIsPre && blockIsPre;
|
@@ -711,7 +939,8 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
711
939
|
newBlock = toPre( block, newBlock );
|
712
940
|
else if ( isFromPre )
|
713
941
|
// Split big <pre> into pieces before start to convert.
|
714
|
-
newBlock = fromPres(
|
942
|
+
newBlock = fromPres( removeBlock ?
|
943
|
+
[ block.getHtml() ] : splitIntoPres( block ), newBlock );
|
715
944
|
else
|
716
945
|
block.moveChildren( newBlock );
|
717
946
|
|
@@ -722,6 +951,8 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
722
951
|
// Merge previous <pre> blocks.
|
723
952
|
mergePre( newBlock );
|
724
953
|
}
|
954
|
+
else if ( removeBlock )
|
955
|
+
removeNoAttribsElement( newBlock );
|
725
956
|
}
|
726
957
|
|
727
958
|
/**
|
@@ -730,7 +961,7 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
730
961
|
function mergePre( preBlock )
|
731
962
|
{
|
732
963
|
var previousBlock;
|
733
|
-
if ( !( ( previousBlock = preBlock.
|
964
|
+
if ( !( ( previousBlock = preBlock.getPrevious( nonWhitespaces ) )
|
734
965
|
&& previousBlock.is
|
735
966
|
&& previousBlock.is( 'pre') ) )
|
736
967
|
return;
|
@@ -762,7 +993,7 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
762
993
|
{
|
763
994
|
// Exclude the ones at header OR at tail,
|
764
995
|
// and ignore bookmark content between them.
|
765
|
-
var duoBrRegex = /(\S\s*)\n(?:\s|(<span[^>]+
|
996
|
+
var duoBrRegex = /(\S\s*)\n(?:\s|(<span[^>]+data-cke-bookmark.*?\/span>))*\n(?!$)/gi,
|
766
997
|
blockName = preBlock.getName(),
|
767
998
|
splitedHtml = replace( preBlock.getOuterHtml(),
|
768
999
|
duoBrRegex,
|
@@ -772,7 +1003,7 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
772
1003
|
} );
|
773
1004
|
|
774
1005
|
var pres = [];
|
775
|
-
splitedHtml.replace( /<pre
|
1006
|
+
splitedHtml.replace( /<pre\b.*?>([\s\S]*?)<\/pre>/gi, function( match, preContent ){
|
776
1007
|
pres.push( preContent );
|
777
1008
|
} );
|
778
1009
|
return pres;
|
@@ -784,7 +1015,7 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
784
1015
|
var headBookmark = '',
|
785
1016
|
tailBookmark = '';
|
786
1017
|
|
787
|
-
str = str.replace( /(^<span[^>]+
|
1018
|
+
str = str.replace( /(^<span[^>]+data-cke-bookmark.*?\/span>)|(<span[^>]+data-cke-bookmark.*?\/span>$)/gi,
|
788
1019
|
function( str, m1, m2 ){
|
789
1020
|
m1 && ( headBookmark = m1 );
|
790
1021
|
m2 && ( tailBookmark = m2 );
|
@@ -792,12 +1023,16 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
792
1023
|
} );
|
793
1024
|
return headBookmark + str.replace( regexp, replacement ) + tailBookmark;
|
794
1025
|
}
|
1026
|
+
|
795
1027
|
/**
|
796
1028
|
* Converting a list of <pre> into blocks with format well preserved.
|
797
1029
|
*/
|
798
1030
|
function fromPres( preHtmls, newBlock )
|
799
1031
|
{
|
800
|
-
var docFrag
|
1032
|
+
var docFrag;
|
1033
|
+
if ( preHtmls.length > 1 )
|
1034
|
+
docFrag = new CKEDITOR.dom.documentFragment( newBlock.getDocument() );
|
1035
|
+
|
801
1036
|
for ( var i = 0 ; i < preHtmls.length ; i++ )
|
802
1037
|
{
|
803
1038
|
var blockHtml = preHtmls[ i ];
|
@@ -827,11 +1062,17 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
827
1062
|
return CKEDITOR.tools.repeat( ' ', match.length - 1 ) + ' ' ;
|
828
1063
|
} ) ;
|
829
1064
|
|
830
|
-
|
831
|
-
|
832
|
-
|
1065
|
+
if ( docFrag )
|
1066
|
+
{
|
1067
|
+
var newBlockClone = newBlock.clone();
|
1068
|
+
newBlockClone.setHtml( blockHtml );
|
1069
|
+
docFrag.append( newBlockClone );
|
1070
|
+
}
|
1071
|
+
else
|
1072
|
+
newBlock.setHtml( blockHtml );
|
833
1073
|
}
|
834
|
-
|
1074
|
+
|
1075
|
+
return docFrag || newBlock;
|
835
1076
|
}
|
836
1077
|
|
837
1078
|
/**
|
@@ -839,6 +1080,9 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
839
1080
|
*/
|
840
1081
|
function toPre( block, newBlock )
|
841
1082
|
{
|
1083
|
+
var bogus = block.getBogus();
|
1084
|
+
bogus && bogus.remove();
|
1085
|
+
|
842
1086
|
// First trim the block content.
|
843
1087
|
var preHtml = block.getHtml();
|
844
1088
|
|
@@ -861,6 +1105,7 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
861
1105
|
var temp = block.getDocument().createElement( 'div' );
|
862
1106
|
temp.append( newBlock );
|
863
1107
|
newBlock.$.outerHTML = '<pre>' + preHtml + '</pre>';
|
1108
|
+
newBlock.copyAttributes( temp.getFirst() );
|
864
1109
|
newBlock = temp.getFirst().remove();
|
865
1110
|
}
|
866
1111
|
else
|
@@ -873,31 +1118,39 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
873
1118
|
function removeFromElement( style, element )
|
874
1119
|
{
|
875
1120
|
var def = style._.definition,
|
876
|
-
attributes = def.attributes,
|
1121
|
+
attributes = CKEDITOR.tools.extend( {}, def.attributes, getOverrides( style )[ element.getName() ] ),
|
877
1122
|
styles = def.styles,
|
878
|
-
|
1123
|
+
// If the style is only about the element itself, we have to remove the element.
|
1124
|
+
removeEmpty = CKEDITOR.tools.isEmpty( attributes ) && CKEDITOR.tools.isEmpty( styles );
|
879
1125
|
|
880
|
-
|
1126
|
+
// Remove definition attributes/style from the elemnt.
|
1127
|
+
for ( var attName in attributes )
|
881
1128
|
{
|
882
|
-
|
883
|
-
|
884
|
-
|
885
|
-
|
886
|
-
|
887
|
-
|
888
|
-
}
|
1129
|
+
// The 'class' element value must match (#1318).
|
1130
|
+
if ( ( attName == 'class' || style._.definition.fullMatch )
|
1131
|
+
&& element.getAttribute( attName ) != normalizeProperty( attName, attributes[ attName ] ) )
|
1132
|
+
continue;
|
1133
|
+
removeEmpty = element.hasAttribute( attName );
|
1134
|
+
element.removeAttribute( attName );
|
889
1135
|
}
|
890
1136
|
|
891
|
-
// Remove definition attributes/style from the elemnt.
|
892
|
-
removeAttrs();
|
893
1137
|
for ( var styleName in styles )
|
1138
|
+
{
|
1139
|
+
// Full match style insist on having fully equivalence. (#5018)
|
1140
|
+
if ( style._.definition.fullMatch
|
1141
|
+
&& element.getStyle( styleName ) != normalizeProperty( styleName, styles[ styleName ], true ) )
|
1142
|
+
continue;
|
1143
|
+
|
1144
|
+
removeEmpty = removeEmpty || !!element.getStyle( styleName );
|
894
1145
|
element.removeStyle( styleName );
|
1146
|
+
}
|
895
1147
|
|
896
|
-
|
897
|
-
|
898
|
-
|
899
|
-
|
900
|
-
|
1148
|
+
if ( removeEmpty )
|
1149
|
+
{
|
1150
|
+
!CKEDITOR.dtd.$block[ element.getName() ] || style._.enterMode == CKEDITOR.ENTER_BR && !element.hasAttributes() ?
|
1151
|
+
removeNoAttribsElement( element ) :
|
1152
|
+
element.renameNode( style._.enterMode == CKEDITOR.ENTER_P ? 'p' : 'div' );
|
1153
|
+
}
|
901
1154
|
}
|
902
1155
|
|
903
1156
|
// Removes a style from inside an element.
|
@@ -906,9 +1159,8 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
906
1159
|
var def = style._.definition,
|
907
1160
|
attribs = def.attributes,
|
908
1161
|
styles = def.styles,
|
909
|
-
overrides = getOverrides( style )
|
910
|
-
|
911
|
-
var innerElements = element.getElementsByTag( style.element );
|
1162
|
+
overrides = getOverrides( style ),
|
1163
|
+
innerElements = element.getElementsByTag( style.element );
|
912
1164
|
|
913
1165
|
for ( var i = innerElements.count(); --i >= 0 ; )
|
914
1166
|
removeFromElement( style, innerElements.getItem( i ) );
|
@@ -927,7 +1179,6 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
927
1179
|
}
|
928
1180
|
}
|
929
1181
|
}
|
930
|
-
|
931
1182
|
}
|
932
1183
|
|
933
1184
|
/**
|
@@ -974,68 +1225,46 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
974
1225
|
// leaving its children.
|
975
1226
|
if ( !element.hasAttributes() )
|
976
1227
|
{
|
977
|
-
|
978
|
-
// so let's cache the first and last nodes for later checking.
|
979
|
-
var firstChild = element.getFirst();
|
980
|
-
var lastChild = element.getLast();
|
981
|
-
|
982
|
-
element.remove( true );
|
983
|
-
|
984
|
-
if ( firstChild )
|
1228
|
+
if ( CKEDITOR.dtd.$block[ element.getName() ] )
|
985
1229
|
{
|
986
|
-
|
987
|
-
|
988
|
-
|
989
|
-
if ( lastChild && !firstChild.equals( lastChild ) )
|
990
|
-
mergeSiblings( lastChild );
|
991
|
-
}
|
992
|
-
}
|
993
|
-
}
|
994
|
-
|
995
|
-
function mergeSiblings( element )
|
996
|
-
{
|
997
|
-
if ( !element || element.type != CKEDITOR.NODE_ELEMENT || !CKEDITOR.dtd.$removeEmpty[ element.getName() ] )
|
998
|
-
return;
|
999
|
-
|
1000
|
-
mergeElements( element, element.getNext(), true );
|
1001
|
-
mergeElements( element, element.getPrevious() );
|
1002
|
-
}
|
1230
|
+
var previous = element.getPrevious( nonWhitespaces ),
|
1231
|
+
next = element.getNext( nonWhitespaces );
|
1003
1232
|
|
1004
|
-
|
1005
|
-
|
1006
|
-
|
1007
|
-
|
1008
|
-
var hasBookmark = sibling.getAttribute( '_fck_bookmark' );
|
1233
|
+
if ( previous && ( previous.type == CKEDITOR.NODE_TEXT || !previous.isBlockBoundary( { br : 1 } ) ) )
|
1234
|
+
element.append( 'br', 1 );
|
1235
|
+
if ( next && ( next.type == CKEDITOR.NODE_TEXT || !next.isBlockBoundary( { br : 1 } ) ) )
|
1236
|
+
element.append( 'br' );
|
1009
1237
|
|
1010
|
-
|
1011
|
-
|
1012
|
-
|
1013
|
-
if ( sibling && sibling.type == CKEDITOR.NODE_ELEMENT && element.isIdentical( sibling ) )
|
1238
|
+
element.remove( true );
|
1239
|
+
}
|
1240
|
+
else
|
1014
1241
|
{
|
1015
|
-
//
|
1016
|
-
//
|
1017
|
-
var
|
1242
|
+
// Removing elements may open points where merging is possible,
|
1243
|
+
// so let's cache the first and last nodes for later checking.
|
1244
|
+
var firstChild = element.getFirst();
|
1245
|
+
var lastChild = element.getLast();
|
1246
|
+
|
1247
|
+
element.remove( true );
|
1018
1248
|
|
1019
|
-
if (
|
1020
|
-
|
1249
|
+
if ( firstChild )
|
1250
|
+
{
|
1251
|
+
// Check the cached nodes for merging.
|
1252
|
+
firstChild.type == CKEDITOR.NODE_ELEMENT && firstChild.mergeSiblings();
|
1021
1253
|
|
1022
|
-
|
1023
|
-
|
1254
|
+
if ( lastChild && !firstChild.equals( lastChild )
|
1255
|
+
&& lastChild.type == CKEDITOR.NODE_ELEMENT )
|
1256
|
+
lastChild.mergeSiblings();
|
1257
|
+
}
|
1024
1258
|
|
1025
|
-
// Now check the last inner child (see two comments above).
|
1026
|
-
if ( innerSibling )
|
1027
|
-
mergeSiblings( innerSibling );
|
1028
1259
|
}
|
1029
1260
|
}
|
1030
1261
|
}
|
1031
1262
|
|
1032
|
-
function getElement( style, targetDocument )
|
1263
|
+
function getElement( style, targetDocument, element )
|
1033
1264
|
{
|
1034
|
-
var el
|
1035
|
-
|
1036
|
-
|
1037
|
-
|
1038
|
-
var elementName = style.element;
|
1265
|
+
var el,
|
1266
|
+
def = style._.definition,
|
1267
|
+
elementName = style.element;
|
1039
1268
|
|
1040
1269
|
// The "*" element name will always be a span for this function.
|
1041
1270
|
if ( elementName == '*' )
|
@@ -1044,14 +1273,26 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
1044
1273
|
// Create the element.
|
1045
1274
|
el = new CKEDITOR.dom.element( elementName, targetDocument );
|
1046
1275
|
|
1047
|
-
|
1276
|
+
// #6226: attributes should be copied before the new ones are applied
|
1277
|
+
if ( element )
|
1278
|
+
element.copyAttributes( el );
|
1279
|
+
|
1280
|
+
el = setupElement( el, style );
|
1281
|
+
|
1282
|
+
// Avoid ID duplication.
|
1283
|
+
if ( targetDocument.getCustomData( 'doc_processing_style' ) && el.hasAttribute( 'id' ) )
|
1284
|
+
el.removeAttribute( 'id' );
|
1285
|
+
else
|
1286
|
+
targetDocument.setCustomData( 'doc_processing_style', 1 );
|
1287
|
+
|
1288
|
+
return el;
|
1048
1289
|
}
|
1049
1290
|
|
1050
1291
|
function setupElement( el, style )
|
1051
1292
|
{
|
1052
|
-
var def = style._.definition
|
1053
|
-
|
1054
|
-
|
1293
|
+
var def = style._.definition,
|
1294
|
+
attributes = def.attributes,
|
1295
|
+
styles = CKEDITOR.style.getStyleText( def );
|
1055
1296
|
|
1056
1297
|
// Assign all defined attributes.
|
1057
1298
|
if ( attributes )
|
@@ -1063,13 +1304,12 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
1063
1304
|
}
|
1064
1305
|
|
1065
1306
|
// Assign all defined styles.
|
1066
|
-
if
|
1307
|
+
if( styles )
|
1067
1308
|
el.setAttribute( 'style', styles );
|
1068
1309
|
|
1069
1310
|
return el;
|
1070
1311
|
}
|
1071
1312
|
|
1072
|
-
var varRegex = /#\((.+?)\)/g;
|
1073
1313
|
function replaceVariables( list, variablesValues )
|
1074
1314
|
{
|
1075
1315
|
for ( var item in list )
|
@@ -1081,7 +1321,6 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
1081
1321
|
}
|
1082
1322
|
}
|
1083
1323
|
|
1084
|
-
|
1085
1324
|
// Returns an object that can be used for style matching comparison.
|
1086
1325
|
// Attributes names and values are all lowercased, and the styles get
|
1087
1326
|
// merged with the style attribute.
|
@@ -1187,6 +1426,15 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
1187
1426
|
return overrides;
|
1188
1427
|
}
|
1189
1428
|
|
1429
|
+
// Make the comparison of attribute value easier by standardizing it.
|
1430
|
+
function normalizeProperty( name, value, isStyle )
|
1431
|
+
{
|
1432
|
+
var temp = new CKEDITOR.dom.element( 'span' );
|
1433
|
+
temp [ isStyle ? 'setStyle' : 'setAttribute' ]( name, value );
|
1434
|
+
return temp[ isStyle ? 'getStyle' : 'getAttribute' ]( name );
|
1435
|
+
}
|
1436
|
+
|
1437
|
+
// Make the comparison of style text easier by standardizing it.
|
1190
1438
|
function normalizeCssText( unparsedCssText, nativeNormalize )
|
1191
1439
|
{
|
1192
1440
|
var styleText;
|
@@ -1201,27 +1449,78 @@ CKEDITOR.STYLE_OBJECT = 3;
|
|
1201
1449
|
else
|
1202
1450
|
styleText = unparsedCssText;
|
1203
1451
|
|
1452
|
+
// Normalize font-family property, ignore quotes and being case insensitive. (#7322)
|
1453
|
+
// http://www.w3.org/TR/css3-fonts/#font-family-the-font-family-property
|
1454
|
+
styleText = styleText.replace( /(font-family:)(.*?)(?=;|$)/, function ( match, prop, val )
|
1455
|
+
{
|
1456
|
+
var names = val.split( ',' );
|
1457
|
+
for ( var i = 0; i < names.length; i++ )
|
1458
|
+
names[ i ] = CKEDITOR.tools.trim( names[ i ].replace( /["']/g, '' ) );
|
1459
|
+
return prop + names.join( ',' );
|
1460
|
+
});
|
1461
|
+
|
1204
1462
|
// Shrinking white-spaces around colon and semi-colon (#4147).
|
1205
1463
|
// Compensate tail semi-colon.
|
1206
1464
|
return styleText.replace( /\s*([;:])\s*/, '$1' )
|
1207
1465
|
.replace( /([^\s;])$/, '$1;')
|
1208
|
-
|
1466
|
+
// Trimming spaces after comma(#4107),
|
1467
|
+
// remove quotations(#6403),
|
1468
|
+
// mostly for differences on "font-family".
|
1469
|
+
.replace( /,\s+/g, ',' )
|
1470
|
+
.replace( /\"/g,'' )
|
1209
1471
|
.toLowerCase();
|
1210
1472
|
}
|
1211
1473
|
|
1474
|
+
// Turn inline style text properties into one hash.
|
1475
|
+
function parseStyleText( styleText )
|
1476
|
+
{
|
1477
|
+
var retval = {};
|
1478
|
+
styleText
|
1479
|
+
.replace( /"/g, '"' )
|
1480
|
+
.replace( /\s*([^ :;]+)\s*:\s*([^;]+)\s*(?=;|$)/g, function( match, name, value )
|
1481
|
+
{
|
1482
|
+
retval[ name ] = value;
|
1483
|
+
} );
|
1484
|
+
return retval;
|
1485
|
+
}
|
1486
|
+
|
1487
|
+
/**
|
1488
|
+
* Compare two bunch of styles, with the speciality that value 'inherit'
|
1489
|
+
* is treated as a wildcard which will match any value.
|
1490
|
+
* @param {Object|String} source
|
1491
|
+
* @param {Object|String} target
|
1492
|
+
*/
|
1493
|
+
function compareCssText( source, target )
|
1494
|
+
{
|
1495
|
+
typeof source == 'string' && ( source = parseStyleText( source ) );
|
1496
|
+
typeof target == 'string' && ( target = parseStyleText( target ) );
|
1497
|
+
for( var name in source )
|
1498
|
+
{
|
1499
|
+
if ( !( name in target &&
|
1500
|
+
( target[ name ] == source[ name ]
|
1501
|
+
|| source[ name ] == 'inherit'
|
1502
|
+
|| target[ name ] == 'inherit' ) ) )
|
1503
|
+
{
|
1504
|
+
return false;
|
1505
|
+
}
|
1506
|
+
}
|
1507
|
+
return true;
|
1508
|
+
}
|
1509
|
+
|
1212
1510
|
function applyStyle( document, remove )
|
1213
1511
|
{
|
1214
|
-
|
1215
|
-
|
1216
|
-
|
1217
|
-
|
1512
|
+
var selection = document.getSelection(),
|
1513
|
+
ranges = selection.getRanges(),
|
1514
|
+
func = remove ? this.removeFromRange : this.applyToRange,
|
1515
|
+
range;
|
1218
1516
|
|
1219
|
-
|
1220
|
-
|
1221
|
-
func.call( this,
|
1517
|
+
var iterator = ranges.createIterator();
|
1518
|
+
while ( ( range = iterator.getNextRange() ) )
|
1519
|
+
func.call( this, range );
|
1222
1520
|
|
1223
|
-
// Select the ranges again.
|
1224
1521
|
selection.selectRanges( ranges );
|
1522
|
+
|
1523
|
+
document.removeCustomData( 'doc_processing_style' );
|
1225
1524
|
}
|
1226
1525
|
})();
|
1227
1526
|
|
@@ -1247,6 +1546,37 @@ CKEDITOR.styleCommand.prototype.exec = function( editor )
|
|
1247
1546
|
return !!doc;
|
1248
1547
|
};
|
1249
1548
|
|
1549
|
+
/**
|
1550
|
+
* Manages styles registration and loading. See also {@link CKEDITOR.config.stylesSet}.
|
1551
|
+
* @namespace
|
1552
|
+
* @augments CKEDITOR.resourceManager
|
1553
|
+
* @constructor
|
1554
|
+
* @since 3.2
|
1555
|
+
* @example
|
1556
|
+
* // The set of styles for the <b>Styles</b> combo
|
1557
|
+
* CKEDITOR.stylesSet.add( 'default',
|
1558
|
+
* [
|
1559
|
+
* // Block Styles
|
1560
|
+
* { name : 'Blue Title' , element : 'h3', styles : { 'color' : 'Blue' } },
|
1561
|
+
* { name : 'Red Title' , element : 'h3', styles : { 'color' : 'Red' } },
|
1562
|
+
*
|
1563
|
+
* // Inline Styles
|
1564
|
+
* { name : 'Marker: Yellow' , element : 'span', styles : { 'background-color' : 'Yellow' } },
|
1565
|
+
* { name : 'Marker: Green' , element : 'span', styles : { 'background-color' : 'Lime' } },
|
1566
|
+
*
|
1567
|
+
* // Object Styles
|
1568
|
+
* {
|
1569
|
+
* name : 'Image on Left',
|
1570
|
+
* element : 'img',
|
1571
|
+
* attributes :
|
1572
|
+
* {
|
1573
|
+
* 'style' : 'padding: 5px; margin-right: 5px',
|
1574
|
+
* 'border' : '2',
|
1575
|
+
* 'align' : 'left'
|
1576
|
+
* }
|
1577
|
+
* }
|
1578
|
+
* ]);
|
1579
|
+
*/
|
1250
1580
|
CKEDITOR.stylesSet = new CKEDITOR.resourceManager( '', 'stylesSet' );
|
1251
1581
|
|
1252
1582
|
// Backward compatibility (#5025).
|
@@ -1256,3 +1586,93 @@ CKEDITOR.loadStylesSet = function( name, url, callback )
|
|
1256
1586
|
CKEDITOR.stylesSet.addExternal( name, url, '' );
|
1257
1587
|
CKEDITOR.stylesSet.load( name, callback );
|
1258
1588
|
};
|
1589
|
+
|
1590
|
+
|
1591
|
+
/**
|
1592
|
+
* Gets the current styleSet for this instance
|
1593
|
+
* @param {Function} callback The function to be called with the styles data.
|
1594
|
+
* @example
|
1595
|
+
* editor.getStylesSet( function( stylesDefinitions ) {} );
|
1596
|
+
*/
|
1597
|
+
CKEDITOR.editor.prototype.getStylesSet = function( callback )
|
1598
|
+
{
|
1599
|
+
if ( !this._.stylesDefinitions )
|
1600
|
+
{
|
1601
|
+
var editor = this,
|
1602
|
+
// Respect the backwards compatible definition entry
|
1603
|
+
configStyleSet = editor.config.stylesCombo_stylesSet || editor.config.stylesSet || 'default';
|
1604
|
+
|
1605
|
+
// #5352 Allow to define the styles directly in the config object
|
1606
|
+
if ( configStyleSet instanceof Array )
|
1607
|
+
{
|
1608
|
+
editor._.stylesDefinitions = configStyleSet;
|
1609
|
+
callback( configStyleSet );
|
1610
|
+
return;
|
1611
|
+
}
|
1612
|
+
|
1613
|
+
var partsStylesSet = configStyleSet.split( ':' ),
|
1614
|
+
styleSetName = partsStylesSet[ 0 ],
|
1615
|
+
externalPath = partsStylesSet[ 1 ],
|
1616
|
+
pluginPath = CKEDITOR.plugins.registered.styles.path;
|
1617
|
+
|
1618
|
+
CKEDITOR.stylesSet.addExternal( styleSetName,
|
1619
|
+
externalPath ?
|
1620
|
+
partsStylesSet.slice( 1 ).join( ':' ) :
|
1621
|
+
pluginPath + 'styles/' + styleSetName + '.js', '' );
|
1622
|
+
|
1623
|
+
CKEDITOR.stylesSet.load( styleSetName, function( stylesSet )
|
1624
|
+
{
|
1625
|
+
editor._.stylesDefinitions = stylesSet[ styleSetName ];
|
1626
|
+
callback( editor._.stylesDefinitions );
|
1627
|
+
} ) ;
|
1628
|
+
}
|
1629
|
+
else
|
1630
|
+
callback( this._.stylesDefinitions );
|
1631
|
+
};
|
1632
|
+
|
1633
|
+
/**
|
1634
|
+
* Indicates that fully selected read-only elements will be included when
|
1635
|
+
* applying the style (for inline styles only).
|
1636
|
+
* @name CKEDITOR.style.includeReadonly
|
1637
|
+
* @type Boolean
|
1638
|
+
* @default false
|
1639
|
+
* @since 3.5
|
1640
|
+
*/
|
1641
|
+
|
1642
|
+
/**
|
1643
|
+
* Disables inline styling on read-only elements.
|
1644
|
+
* @name CKEDITOR.config.disableReadonlyStyling
|
1645
|
+
* @type Boolean
|
1646
|
+
* @default false
|
1647
|
+
* @since 3.5
|
1648
|
+
*/
|
1649
|
+
|
1650
|
+
/**
|
1651
|
+
* The "styles definition set" to use in the editor. They will be used in the
|
1652
|
+
* styles combo and the Style selector of the div container. <br>
|
1653
|
+
* The styles may be defined in the page containing the editor, or can be
|
1654
|
+
* loaded on demand from an external file. In the second case, if this setting
|
1655
|
+
* contains only a name, the styles definition file will be loaded from the
|
1656
|
+
* "styles" folder inside the styles plugin folder.
|
1657
|
+
* Otherwise, this setting has the "name:url" syntax, making it
|
1658
|
+
* possible to set the URL from which loading the styles file.<br>
|
1659
|
+
* Previously this setting was available as config.stylesCombo_stylesSet<br>
|
1660
|
+
* @name CKEDITOR.config.stylesSet
|
1661
|
+
* @type String|Array
|
1662
|
+
* @default 'default'
|
1663
|
+
* @since 3.3
|
1664
|
+
* @example
|
1665
|
+
* // Load from the styles' styles folder (mystyles.js file).
|
1666
|
+
* config.stylesSet = 'mystyles';
|
1667
|
+
* @example
|
1668
|
+
* // Load from a relative URL.
|
1669
|
+
* config.stylesSet = 'mystyles:/editorstyles/styles.js';
|
1670
|
+
* @example
|
1671
|
+
* // Load from a full URL.
|
1672
|
+
* config.stylesSet = 'mystyles:http://www.example.com/editorstyles/styles.js';
|
1673
|
+
* @example
|
1674
|
+
* // Load from a list of definitions.
|
1675
|
+
* config.stylesSet = [
|
1676
|
+
* { name : 'Strong Emphasis', element : 'strong' },
|
1677
|
+
* { name : 'Emphasis', element : 'em' }, ... ];
|
1678
|
+
*/
|