aboutsummaryrefslogtreecommitdiff
path: root/sources/plugins/removeformat
diff options
context:
space:
mode:
authorIsmaël Bouya <ismael.bouya@normalesup.org>2016-02-19 23:38:52 +0100
committerIsmaël Bouya <ismael.bouya@normalesup.org>2016-02-19 23:38:52 +0100
commit3332bebe4da6dfa0fe3e4b2abddc84b1cc62f8f5 (patch)
treea4f77655fe55b79606e7d3416504686a1ab8b058 /sources/plugins/removeformat
downloadpiedsjaloux-ckeditor-component-3332bebe4da6dfa0fe3e4b2abddc84b1cc62f8f5.tar.gz
piedsjaloux-ckeditor-component-3332bebe4da6dfa0fe3e4b2abddc84b1cc62f8f5.tar.zst
piedsjaloux-ckeditor-component-3332bebe4da6dfa0fe3e4b2abddc84b1cc62f8f5.zip
Initial commit4.5.7
Diffstat (limited to 'sources/plugins/removeformat')
-rw-r--r--sources/plugins/removeformat/icons/hidpi/removeformat.pngbin0 -> 2119 bytes
-rw-r--r--sources/plugins/removeformat/icons/removeformat.pngbin0 -> 871 bytes
-rw-r--r--sources/plugins/removeformat/lang/af.js7
-rw-r--r--sources/plugins/removeformat/lang/ar.js7
-rw-r--r--sources/plugins/removeformat/lang/bg.js7
-rw-r--r--sources/plugins/removeformat/lang/bn.js7
-rw-r--r--sources/plugins/removeformat/lang/bs.js7
-rw-r--r--sources/plugins/removeformat/lang/ca.js7
-rw-r--r--sources/plugins/removeformat/lang/cs.js7
-rw-r--r--sources/plugins/removeformat/lang/cy.js7
-rw-r--r--sources/plugins/removeformat/lang/da.js7
-rw-r--r--sources/plugins/removeformat/lang/de-ch.js7
-rw-r--r--sources/plugins/removeformat/lang/de.js7
-rw-r--r--sources/plugins/removeformat/lang/el.js7
-rw-r--r--sources/plugins/removeformat/lang/en-au.js7
-rw-r--r--sources/plugins/removeformat/lang/en-ca.js7
-rw-r--r--sources/plugins/removeformat/lang/en-gb.js7
-rw-r--r--sources/plugins/removeformat/lang/en.js7
-rw-r--r--sources/plugins/removeformat/lang/eo.js7
-rw-r--r--sources/plugins/removeformat/lang/es.js7
-rw-r--r--sources/plugins/removeformat/lang/et.js7
-rw-r--r--sources/plugins/removeformat/lang/eu.js7
-rw-r--r--sources/plugins/removeformat/lang/fa.js7
-rw-r--r--sources/plugins/removeformat/lang/fi.js7
-rw-r--r--sources/plugins/removeformat/lang/fo.js7
-rw-r--r--sources/plugins/removeformat/lang/fr-ca.js7
-rw-r--r--sources/plugins/removeformat/lang/fr.js7
-rw-r--r--sources/plugins/removeformat/lang/gl.js7
-rw-r--r--sources/plugins/removeformat/lang/gu.js7
-rw-r--r--sources/plugins/removeformat/lang/he.js7
-rw-r--r--sources/plugins/removeformat/lang/hi.js7
-rw-r--r--sources/plugins/removeformat/lang/hr.js7
-rw-r--r--sources/plugins/removeformat/lang/hu.js7
-rw-r--r--sources/plugins/removeformat/lang/id.js7
-rw-r--r--sources/plugins/removeformat/lang/is.js7
-rw-r--r--sources/plugins/removeformat/lang/it.js7
-rw-r--r--sources/plugins/removeformat/lang/ja.js7
-rw-r--r--sources/plugins/removeformat/lang/ka.js7
-rw-r--r--sources/plugins/removeformat/lang/km.js7
-rw-r--r--sources/plugins/removeformat/lang/ko.js7
-rw-r--r--sources/plugins/removeformat/lang/ku.js7
-rw-r--r--sources/plugins/removeformat/lang/lt.js7
-rw-r--r--sources/plugins/removeformat/lang/lv.js7
-rw-r--r--sources/plugins/removeformat/lang/mk.js7
-rw-r--r--sources/plugins/removeformat/lang/mn.js7
-rw-r--r--sources/plugins/removeformat/lang/ms.js7
-rw-r--r--sources/plugins/removeformat/lang/nb.js7
-rw-r--r--sources/plugins/removeformat/lang/nl.js7
-rw-r--r--sources/plugins/removeformat/lang/no.js7
-rw-r--r--sources/plugins/removeformat/lang/pl.js7
-rw-r--r--sources/plugins/removeformat/lang/pt-br.js7
-rw-r--r--sources/plugins/removeformat/lang/pt.js7
-rw-r--r--sources/plugins/removeformat/lang/ro.js7
-rw-r--r--sources/plugins/removeformat/lang/ru.js7
-rw-r--r--sources/plugins/removeformat/lang/si.js7
-rw-r--r--sources/plugins/removeformat/lang/sk.js7
-rw-r--r--sources/plugins/removeformat/lang/sl.js7
-rw-r--r--sources/plugins/removeformat/lang/sq.js7
-rw-r--r--sources/plugins/removeformat/lang/sr-latn.js7
-rw-r--r--sources/plugins/removeformat/lang/sr.js7
-rw-r--r--sources/plugins/removeformat/lang/sv.js7
-rw-r--r--sources/plugins/removeformat/lang/th.js7
-rw-r--r--sources/plugins/removeformat/lang/tr.js7
-rw-r--r--sources/plugins/removeformat/lang/tt.js7
-rw-r--r--sources/plugins/removeformat/lang/ug.js7
-rw-r--r--sources/plugins/removeformat/lang/uk.js7
-rw-r--r--sources/plugins/removeformat/lang/vi.js7
-rw-r--r--sources/plugins/removeformat/lang/zh-cn.js7
-rw-r--r--sources/plugins/removeformat/lang/zh.js7
-rw-r--r--sources/plugins/removeformat/plugin.js193
70 files changed, 662 insertions, 0 deletions
diff --git a/sources/plugins/removeformat/icons/hidpi/removeformat.png b/sources/plugins/removeformat/icons/hidpi/removeformat.png
new file mode 100644
index 0000000..910b0a3
--- /dev/null
+++ b/sources/plugins/removeformat/icons/hidpi/removeformat.png
Binary files differ
diff --git a/sources/plugins/removeformat/icons/removeformat.png b/sources/plugins/removeformat/icons/removeformat.png
new file mode 100644
index 0000000..1bc9b38
--- /dev/null
+++ b/sources/plugins/removeformat/icons/removeformat.png
Binary files differ
diff --git a/sources/plugins/removeformat/lang/af.js b/sources/plugins/removeformat/lang/af.js
new file mode 100644
index 0000000..f4aad8d
--- /dev/null
+++ b/sources/plugins/removeformat/lang/af.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'af', {
6 toolbar: 'Verwyder opmaak'
7} );
diff --git a/sources/plugins/removeformat/lang/ar.js b/sources/plugins/removeformat/lang/ar.js
new file mode 100644
index 0000000..fc43002
--- /dev/null
+++ b/sources/plugins/removeformat/lang/ar.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'ar', {
6 toolbar: 'إزالة التنسيقات'
7} );
diff --git a/sources/plugins/removeformat/lang/bg.js b/sources/plugins/removeformat/lang/bg.js
new file mode 100644
index 0000000..bc24b70
--- /dev/null
+++ b/sources/plugins/removeformat/lang/bg.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'bg', {
6 toolbar: 'Премахване на форматирането'
7} );
diff --git a/sources/plugins/removeformat/lang/bn.js b/sources/plugins/removeformat/lang/bn.js
new file mode 100644
index 0000000..40bf380
--- /dev/null
+++ b/sources/plugins/removeformat/lang/bn.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'bn', {
6 toolbar: 'ফরমেট সরাও'
7} );
diff --git a/sources/plugins/removeformat/lang/bs.js b/sources/plugins/removeformat/lang/bs.js
new file mode 100644
index 0000000..ee03684
--- /dev/null
+++ b/sources/plugins/removeformat/lang/bs.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'bs', {
6 toolbar: 'Poništi format'
7} );
diff --git a/sources/plugins/removeformat/lang/ca.js b/sources/plugins/removeformat/lang/ca.js
new file mode 100644
index 0000000..0b94ce4
--- /dev/null
+++ b/sources/plugins/removeformat/lang/ca.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'ca', {
6 toolbar: 'Elimina Format'
7} );
diff --git a/sources/plugins/removeformat/lang/cs.js b/sources/plugins/removeformat/lang/cs.js
new file mode 100644
index 0000000..ce05801
--- /dev/null
+++ b/sources/plugins/removeformat/lang/cs.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'cs', {
6 toolbar: 'Odstranit formátování'
7} );
diff --git a/sources/plugins/removeformat/lang/cy.js b/sources/plugins/removeformat/lang/cy.js
new file mode 100644
index 0000000..14372a1
--- /dev/null
+++ b/sources/plugins/removeformat/lang/cy.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'cy', {
6 toolbar: 'Tynnu Fformat'
7} );
diff --git a/sources/plugins/removeformat/lang/da.js b/sources/plugins/removeformat/lang/da.js
new file mode 100644
index 0000000..d170584
--- /dev/null
+++ b/sources/plugins/removeformat/lang/da.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'da', {
6 toolbar: 'Fjern formatering'
7} );
diff --git a/sources/plugins/removeformat/lang/de-ch.js b/sources/plugins/removeformat/lang/de-ch.js
new file mode 100644
index 0000000..48daf26
--- /dev/null
+++ b/sources/plugins/removeformat/lang/de-ch.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'de-ch', {
6 toolbar: 'Formatierung entfernen'
7} );
diff --git a/sources/plugins/removeformat/lang/de.js b/sources/plugins/removeformat/lang/de.js
new file mode 100644
index 0000000..08ad55c
--- /dev/null
+++ b/sources/plugins/removeformat/lang/de.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'de', {
6 toolbar: 'Formatierung entfernen'
7} );
diff --git a/sources/plugins/removeformat/lang/el.js b/sources/plugins/removeformat/lang/el.js
new file mode 100644
index 0000000..d48c8ab
--- /dev/null
+++ b/sources/plugins/removeformat/lang/el.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'el', {
6 toolbar: 'Εκκαθάριση Μορφοποίησης'
7} );
diff --git a/sources/plugins/removeformat/lang/en-au.js b/sources/plugins/removeformat/lang/en-au.js
new file mode 100644
index 0000000..426d6d1
--- /dev/null
+++ b/sources/plugins/removeformat/lang/en-au.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'en-au', {
6 toolbar: 'Remove Format'
7} );
diff --git a/sources/plugins/removeformat/lang/en-ca.js b/sources/plugins/removeformat/lang/en-ca.js
new file mode 100644
index 0000000..1cc2963
--- /dev/null
+++ b/sources/plugins/removeformat/lang/en-ca.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'en-ca', {
6 toolbar: 'Remove Format'
7} );
diff --git a/sources/plugins/removeformat/lang/en-gb.js b/sources/plugins/removeformat/lang/en-gb.js
new file mode 100644
index 0000000..65af616
--- /dev/null
+++ b/sources/plugins/removeformat/lang/en-gb.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'en-gb', {
6 toolbar: 'Remove Format'
7} );
diff --git a/sources/plugins/removeformat/lang/en.js b/sources/plugins/removeformat/lang/en.js
new file mode 100644
index 0000000..55600fc
--- /dev/null
+++ b/sources/plugins/removeformat/lang/en.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'en', {
6 toolbar: 'Remove Format'
7} );
diff --git a/sources/plugins/removeformat/lang/eo.js b/sources/plugins/removeformat/lang/eo.js
new file mode 100644
index 0000000..c4f04e3
--- /dev/null
+++ b/sources/plugins/removeformat/lang/eo.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'eo', {
6 toolbar: 'Forigi Formaton'
7} );
diff --git a/sources/plugins/removeformat/lang/es.js b/sources/plugins/removeformat/lang/es.js
new file mode 100644
index 0000000..dc48200
--- /dev/null
+++ b/sources/plugins/removeformat/lang/es.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'es', {
6 toolbar: 'Eliminar Formato'
7} );
diff --git a/sources/plugins/removeformat/lang/et.js b/sources/plugins/removeformat/lang/et.js
new file mode 100644
index 0000000..2938e78
--- /dev/null
+++ b/sources/plugins/removeformat/lang/et.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'et', {
6 toolbar: 'Vormingu eemaldamine'
7} );
diff --git a/sources/plugins/removeformat/lang/eu.js b/sources/plugins/removeformat/lang/eu.js
new file mode 100644
index 0000000..ff16de3
--- /dev/null
+++ b/sources/plugins/removeformat/lang/eu.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'eu', {
6 toolbar: 'Kendu formatua'
7} );
diff --git a/sources/plugins/removeformat/lang/fa.js b/sources/plugins/removeformat/lang/fa.js
new file mode 100644
index 0000000..40e8a1d
--- /dev/null
+++ b/sources/plugins/removeformat/lang/fa.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'fa', {
6 toolbar: 'برداشتن فرمت'
7} );
diff --git a/sources/plugins/removeformat/lang/fi.js b/sources/plugins/removeformat/lang/fi.js
new file mode 100644
index 0000000..90f2f54
--- /dev/null
+++ b/sources/plugins/removeformat/lang/fi.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'fi', {
6 toolbar: 'Poista muotoilu'
7} );
diff --git a/sources/plugins/removeformat/lang/fo.js b/sources/plugins/removeformat/lang/fo.js
new file mode 100644
index 0000000..68fbb29
--- /dev/null
+++ b/sources/plugins/removeformat/lang/fo.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'fo', {
6 toolbar: 'Strika sniðgeving'
7} );
diff --git a/sources/plugins/removeformat/lang/fr-ca.js b/sources/plugins/removeformat/lang/fr-ca.js
new file mode 100644
index 0000000..67709de
--- /dev/null
+++ b/sources/plugins/removeformat/lang/fr-ca.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'fr-ca', {
6 toolbar: 'Supprimer le formatage'
7} );
diff --git a/sources/plugins/removeformat/lang/fr.js b/sources/plugins/removeformat/lang/fr.js
new file mode 100644
index 0000000..0ccb8ed
--- /dev/null
+++ b/sources/plugins/removeformat/lang/fr.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'fr', {
6 toolbar: 'Supprimer la mise en forme'
7} );
diff --git a/sources/plugins/removeformat/lang/gl.js b/sources/plugins/removeformat/lang/gl.js
new file mode 100644
index 0000000..8ed13d3
--- /dev/null
+++ b/sources/plugins/removeformat/lang/gl.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'gl', {
6 toolbar: 'Retirar o formato'
7} );
diff --git a/sources/plugins/removeformat/lang/gu.js b/sources/plugins/removeformat/lang/gu.js
new file mode 100644
index 0000000..7d31531
--- /dev/null
+++ b/sources/plugins/removeformat/lang/gu.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'gu', {
6 toolbar: 'ફૉર્મટ કાઢવું'
7} );
diff --git a/sources/plugins/removeformat/lang/he.js b/sources/plugins/removeformat/lang/he.js
new file mode 100644
index 0000000..1073e39
--- /dev/null
+++ b/sources/plugins/removeformat/lang/he.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'he', {
6 toolbar: 'הסרת העיצוב'
7} );
diff --git a/sources/plugins/removeformat/lang/hi.js b/sources/plugins/removeformat/lang/hi.js
new file mode 100644
index 0000000..952feac
--- /dev/null
+++ b/sources/plugins/removeformat/lang/hi.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'hi', {
6 toolbar: 'फ़ॉर्मैट हटायें'
7} );
diff --git a/sources/plugins/removeformat/lang/hr.js b/sources/plugins/removeformat/lang/hr.js
new file mode 100644
index 0000000..9332057
--- /dev/null
+++ b/sources/plugins/removeformat/lang/hr.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'hr', {
6 toolbar: 'Ukloni formatiranje'
7} );
diff --git a/sources/plugins/removeformat/lang/hu.js b/sources/plugins/removeformat/lang/hu.js
new file mode 100644
index 0000000..a7cabfc
--- /dev/null
+++ b/sources/plugins/removeformat/lang/hu.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'hu', {
6 toolbar: 'Formázás eltávolítása'
7} );
diff --git a/sources/plugins/removeformat/lang/id.js b/sources/plugins/removeformat/lang/id.js
new file mode 100644
index 0000000..f677a05
--- /dev/null
+++ b/sources/plugins/removeformat/lang/id.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'id', {
6 toolbar: 'Hapus Format'
7} );
diff --git a/sources/plugins/removeformat/lang/is.js b/sources/plugins/removeformat/lang/is.js
new file mode 100644
index 0000000..5f7c53f
--- /dev/null
+++ b/sources/plugins/removeformat/lang/is.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'is', {
6 toolbar: 'Fjarlægja snið'
7} );
diff --git a/sources/plugins/removeformat/lang/it.js b/sources/plugins/removeformat/lang/it.js
new file mode 100644
index 0000000..840d043
--- /dev/null
+++ b/sources/plugins/removeformat/lang/it.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'it', {
6 toolbar: 'Elimina formattazione'
7} );
diff --git a/sources/plugins/removeformat/lang/ja.js b/sources/plugins/removeformat/lang/ja.js
new file mode 100644
index 0000000..acc7451
--- /dev/null
+++ b/sources/plugins/removeformat/lang/ja.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'ja', {
6 toolbar: '書式を解除'
7} );
diff --git a/sources/plugins/removeformat/lang/ka.js b/sources/plugins/removeformat/lang/ka.js
new file mode 100644
index 0000000..a455c35
--- /dev/null
+++ b/sources/plugins/removeformat/lang/ka.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'ka', {
6 toolbar: 'ფორმატირების მოხსნა'
7} );
diff --git a/sources/plugins/removeformat/lang/km.js b/sources/plugins/removeformat/lang/km.js
new file mode 100644
index 0000000..b20d6ac
--- /dev/null
+++ b/sources/plugins/removeformat/lang/km.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'km', {
6 toolbar: 'ជម្រះ​ទ្រង់​ទ្រាយ'
7} );
diff --git a/sources/plugins/removeformat/lang/ko.js b/sources/plugins/removeformat/lang/ko.js
new file mode 100644
index 0000000..60df7aa
--- /dev/null
+++ b/sources/plugins/removeformat/lang/ko.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'ko', {
6 toolbar: '형식 지우기'
7} );
diff --git a/sources/plugins/removeformat/lang/ku.js b/sources/plugins/removeformat/lang/ku.js
new file mode 100644
index 0000000..5b84310
--- /dev/null
+++ b/sources/plugins/removeformat/lang/ku.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'ku', {
6 toolbar: 'لابردنی داڕشتەکە'
7} );
diff --git a/sources/plugins/removeformat/lang/lt.js b/sources/plugins/removeformat/lang/lt.js
new file mode 100644
index 0000000..88be97e
--- /dev/null
+++ b/sources/plugins/removeformat/lang/lt.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'lt', {
6 toolbar: 'Panaikinti formatą'
7} );
diff --git a/sources/plugins/removeformat/lang/lv.js b/sources/plugins/removeformat/lang/lv.js
new file mode 100644
index 0000000..946e6d9
--- /dev/null
+++ b/sources/plugins/removeformat/lang/lv.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'lv', {
6 toolbar: 'Noņemt stilus'
7} );
diff --git a/sources/plugins/removeformat/lang/mk.js b/sources/plugins/removeformat/lang/mk.js
new file mode 100644
index 0000000..4fcbf8d
--- /dev/null
+++ b/sources/plugins/removeformat/lang/mk.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'mk', {
6 toolbar: 'Remove Format' // MISSING
7} );
diff --git a/sources/plugins/removeformat/lang/mn.js b/sources/plugins/removeformat/lang/mn.js
new file mode 100644
index 0000000..e504411
--- /dev/null
+++ b/sources/plugins/removeformat/lang/mn.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'mn', {
6 toolbar: 'Параргафын загварыг авч хаях'
7} );
diff --git a/sources/plugins/removeformat/lang/ms.js b/sources/plugins/removeformat/lang/ms.js
new file mode 100644
index 0000000..bb6951b
--- /dev/null
+++ b/sources/plugins/removeformat/lang/ms.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'ms', {
6 toolbar: 'Buang Format'
7} );
diff --git a/sources/plugins/removeformat/lang/nb.js b/sources/plugins/removeformat/lang/nb.js
new file mode 100644
index 0000000..461d140
--- /dev/null
+++ b/sources/plugins/removeformat/lang/nb.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'nb', {
6 toolbar: 'Fjern formatering'
7} );
diff --git a/sources/plugins/removeformat/lang/nl.js b/sources/plugins/removeformat/lang/nl.js
new file mode 100644
index 0000000..cbbe0b1
--- /dev/null
+++ b/sources/plugins/removeformat/lang/nl.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'nl', {
6 toolbar: 'Opmaak verwijderen'
7} );
diff --git a/sources/plugins/removeformat/lang/no.js b/sources/plugins/removeformat/lang/no.js
new file mode 100644
index 0000000..d067249
--- /dev/null
+++ b/sources/plugins/removeformat/lang/no.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'no', {
6 toolbar: 'Fjern formatering'
7} );
diff --git a/sources/plugins/removeformat/lang/pl.js b/sources/plugins/removeformat/lang/pl.js
new file mode 100644
index 0000000..5b1bddb
--- /dev/null
+++ b/sources/plugins/removeformat/lang/pl.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'pl', {
6 toolbar: 'Usuń formatowanie'
7} );
diff --git a/sources/plugins/removeformat/lang/pt-br.js b/sources/plugins/removeformat/lang/pt-br.js
new file mode 100644
index 0000000..fb05dce
--- /dev/null
+++ b/sources/plugins/removeformat/lang/pt-br.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'pt-br', {
6 toolbar: 'Remover Formatação'
7} );
diff --git a/sources/plugins/removeformat/lang/pt.js b/sources/plugins/removeformat/lang/pt.js
new file mode 100644
index 0000000..c3e5d97
--- /dev/null
+++ b/sources/plugins/removeformat/lang/pt.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'pt', {
6 toolbar: 'Eliminar Formato'
7} );
diff --git a/sources/plugins/removeformat/lang/ro.js b/sources/plugins/removeformat/lang/ro.js
new file mode 100644
index 0000000..1c045c7
--- /dev/null
+++ b/sources/plugins/removeformat/lang/ro.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'ro', {
6 toolbar: 'Înlătură formatarea'
7} );
diff --git a/sources/plugins/removeformat/lang/ru.js b/sources/plugins/removeformat/lang/ru.js
new file mode 100644
index 0000000..baaa2fb
--- /dev/null
+++ b/sources/plugins/removeformat/lang/ru.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'ru', {
6 toolbar: 'Убрать форматирование'
7} );
diff --git a/sources/plugins/removeformat/lang/si.js b/sources/plugins/removeformat/lang/si.js
new file mode 100644
index 0000000..7a86747
--- /dev/null
+++ b/sources/plugins/removeformat/lang/si.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'si', {
6 toolbar: 'සැකසීම වෙනස් කරන්න'
7} );
diff --git a/sources/plugins/removeformat/lang/sk.js b/sources/plugins/removeformat/lang/sk.js
new file mode 100644
index 0000000..77651f2
--- /dev/null
+++ b/sources/plugins/removeformat/lang/sk.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'sk', {
6 toolbar: 'Odstrániť formátovanie'
7} );
diff --git a/sources/plugins/removeformat/lang/sl.js b/sources/plugins/removeformat/lang/sl.js
new file mode 100644
index 0000000..a717049
--- /dev/null
+++ b/sources/plugins/removeformat/lang/sl.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'sl', {
6 toolbar: 'Odstrani oblikovanje'
7} );
diff --git a/sources/plugins/removeformat/lang/sq.js b/sources/plugins/removeformat/lang/sq.js
new file mode 100644
index 0000000..73c8419
--- /dev/null
+++ b/sources/plugins/removeformat/lang/sq.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'sq', {
6 toolbar: 'Largo Formatin'
7} );
diff --git a/sources/plugins/removeformat/lang/sr-latn.js b/sources/plugins/removeformat/lang/sr-latn.js
new file mode 100644
index 0000000..9e91105
--- /dev/null
+++ b/sources/plugins/removeformat/lang/sr-latn.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'sr-latn', {
6 toolbar: 'Ukloni formatiranje'
7} );
diff --git a/sources/plugins/removeformat/lang/sr.js b/sources/plugins/removeformat/lang/sr.js
new file mode 100644
index 0000000..fd720a9
--- /dev/null
+++ b/sources/plugins/removeformat/lang/sr.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'sr', {
6 toolbar: 'Уклони форматирање'
7} );
diff --git a/sources/plugins/removeformat/lang/sv.js b/sources/plugins/removeformat/lang/sv.js
new file mode 100644
index 0000000..ebb4aed
--- /dev/null
+++ b/sources/plugins/removeformat/lang/sv.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'sv', {
6 toolbar: 'Radera formatering'
7} );
diff --git a/sources/plugins/removeformat/lang/th.js b/sources/plugins/removeformat/lang/th.js
new file mode 100644
index 0000000..d521c58
--- /dev/null
+++ b/sources/plugins/removeformat/lang/th.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'th', {
6 toolbar: 'ล้างรูปแบบ'
7} );
diff --git a/sources/plugins/removeformat/lang/tr.js b/sources/plugins/removeformat/lang/tr.js
new file mode 100644
index 0000000..2d4097c
--- /dev/null
+++ b/sources/plugins/removeformat/lang/tr.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'tr', {
6 toolbar: 'Biçimi Kaldır'
7} );
diff --git a/sources/plugins/removeformat/lang/tt.js b/sources/plugins/removeformat/lang/tt.js
new file mode 100644
index 0000000..4fa5570
--- /dev/null
+++ b/sources/plugins/removeformat/lang/tt.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'tt', {
6 toolbar: 'Форматлауны бетерү'
7} );
diff --git a/sources/plugins/removeformat/lang/ug.js b/sources/plugins/removeformat/lang/ug.js
new file mode 100644
index 0000000..7d9ec29
--- /dev/null
+++ b/sources/plugins/removeformat/lang/ug.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'ug', {
6 toolbar: 'پىچىمنى چىقىرىۋەت'
7} );
diff --git a/sources/plugins/removeformat/lang/uk.js b/sources/plugins/removeformat/lang/uk.js
new file mode 100644
index 0000000..1dea866
--- /dev/null
+++ b/sources/plugins/removeformat/lang/uk.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'uk', {
6 toolbar: 'Видалити форматування'
7} );
diff --git a/sources/plugins/removeformat/lang/vi.js b/sources/plugins/removeformat/lang/vi.js
new file mode 100644
index 0000000..2aaadc2
--- /dev/null
+++ b/sources/plugins/removeformat/lang/vi.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'vi', {
6 toolbar: 'Xoá định dạng'
7} );
diff --git a/sources/plugins/removeformat/lang/zh-cn.js b/sources/plugins/removeformat/lang/zh-cn.js
new file mode 100644
index 0000000..6efbf35
--- /dev/null
+++ b/sources/plugins/removeformat/lang/zh-cn.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'zh-cn', {
6 toolbar: '清除格式'
7} );
diff --git a/sources/plugins/removeformat/lang/zh.js b/sources/plugins/removeformat/lang/zh.js
new file mode 100644
index 0000000..6ce2ef0
--- /dev/null
+++ b/sources/plugins/removeformat/lang/zh.js
@@ -0,0 +1,7 @@
1/*
2Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.md or http://ckeditor.com/license
4*/
5CKEDITOR.plugins.setLang( 'removeformat', 'zh', {
6 toolbar: '移除格式'
7} );
diff --git a/sources/plugins/removeformat/plugin.js b/sources/plugins/removeformat/plugin.js
new file mode 100644
index 0000000..044f54a
--- /dev/null
+++ b/sources/plugins/removeformat/plugin.js
@@ -0,0 +1,193 @@
1/**
2 * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
3 * For licensing, see LICENSE.md or http://ckeditor.com/license
4 */
5
6CKEDITOR.plugins.add( 'removeformat', {
7 // jscs:disable maximumLineLength
8 lang: 'af,ar,bg,bn,bs,ca,cs,cy,da,de,de-ch,el,en,en-au,en-ca,en-gb,eo,es,et,eu,fa,fi,fo,fr,fr-ca,gl,gu,he,hi,hr,hu,id,is,it,ja,ka,km,ko,ku,lt,lv,mk,mn,ms,nb,nl,no,pl,pt,pt-br,ro,ru,si,sk,sl,sq,sr,sr-latn,sv,th,tr,tt,ug,uk,vi,zh,zh-cn', // %REMOVE_LINE_CORE%
9 // jscs:enable maximumLineLength
10 icons: 'removeformat', // %REMOVE_LINE_CORE%
11 hidpi: true, // %REMOVE_LINE_CORE%
12 init: function( editor ) {
13 editor.addCommand( 'removeFormat', CKEDITOR.plugins.removeformat.commands.removeformat );
14 editor.ui.addButton && editor.ui.addButton( 'RemoveFormat', {
15 label: editor.lang.removeformat.toolbar,
16 command: 'removeFormat',
17 toolbar: 'cleanup,10'
18 } );
19 }
20} );
21
22CKEDITOR.plugins.removeformat = {
23 commands: {
24 removeformat: {
25 exec: function( editor ) {
26 var tagsRegex = editor._.removeFormatRegex || ( editor._.removeFormatRegex = new RegExp( '^(?:' + editor.config.removeFormatTags.replace( /,/g, '|' ) + ')$', 'i' ) );
27
28 var removeAttributes = editor._.removeAttributes || ( editor._.removeAttributes = editor.config.removeFormatAttributes.split( ',' ) ),
29 filter = CKEDITOR.plugins.removeformat.filter,
30 ranges = editor.getSelection().getRanges(),
31 iterator = ranges.createIterator(),
32 isElement = function( element ) {
33 return element.type == CKEDITOR.NODE_ELEMENT;
34 },
35 range;
36
37 while ( ( range = iterator.getNextRange() ) ) {
38 if ( !range.collapsed )
39 range.enlarge( CKEDITOR.ENLARGE_ELEMENT );
40
41 // Bookmark the range so we can re-select it after processing.
42 var bookmark = range.createBookmark(),
43 // The style will be applied within the bookmark boundaries.
44 startNode = bookmark.startNode,
45 endNode = bookmark.endNode,
46 currentNode;
47
48 // We need to check the selection boundaries (bookmark spans) to break
49 // the code in a way that we can properly remove partially selected nodes.
50 // For example, removing a <b> style from
51 // <b>This is [some text</b> to show <b>the] problem</b>
52 // ... where [ and ] represent the selection, must result:
53 // <b>This is </b>[some text to show the]<b> problem</b>
54 // The strategy is simple, we just break the partial nodes before the
55 // removal logic, having something that could be represented this way:
56 // <b>This is </b>[<b>some text</b> to show <b>the</b>]<b> problem</b>
57
58 var breakParent = function( node ) {
59 // Let's start checking the start boundary.
60 var path = editor.elementPath( node ),
61 pathElements = path.elements;
62
63 for ( var i = 1, pathElement; pathElement = pathElements[ i ]; i++ ) {
64 if ( pathElement.equals( path.block ) || pathElement.equals( path.blockLimit ) )
65 break;
66
67 // If this element can be removed (even partially).
68 if ( tagsRegex.test( pathElement.getName() ) && filter( editor, pathElement ) )
69 node.breakParent( pathElement );
70 }
71 };
72
73 breakParent( startNode );
74 if ( endNode ) {
75 breakParent( endNode );
76
77 // Navigate through all nodes between the bookmarks.
78 currentNode = startNode.getNextSourceNode( true, CKEDITOR.NODE_ELEMENT );
79
80 while ( currentNode ) {
81 // If we have reached the end of the selection, stop looping.
82 if ( currentNode.equals( endNode ) )
83 break;
84
85 if ( currentNode.isReadOnly() ) {
86 // In case of non-editable we're skipping to the next sibling *elmenet*.
87
88 // We need to be aware that endNode can be nested within current non-editable.
89 // This condition tests if currentNode (non-editable) contains endNode. If it does
90 // then we should break the filtering
91 if ( currentNode.getPosition( endNode ) & CKEDITOR.POSITION_CONTAINS ) {
92 break;
93 }
94
95 currentNode = currentNode.getNext( isElement );
96 continue;
97 }
98
99 // Cache the next node to be processed. Do it now, because
100 // currentNode may be removed.
101 var nextNode = currentNode.getNextSourceNode( false, CKEDITOR.NODE_ELEMENT ),
102 isFakeElement = currentNode.getName() == 'img' && currentNode.data( 'cke-realelement' );
103
104 // This node must not be a fake element, and must not be read-only.
105 if ( !isFakeElement && filter( editor, currentNode ) ) {
106 // Remove elements nodes that match with this style rules.
107 if ( tagsRegex.test( currentNode.getName() ) )
108 currentNode.remove( 1 );
109 else {
110 currentNode.removeAttributes( removeAttributes );
111 editor.fire( 'removeFormatCleanup', currentNode );
112 }
113 }
114
115 currentNode = nextNode;
116 }
117 }
118
119 range.moveToBookmark( bookmark );
120 }
121
122 // The selection path may not changed, but we should force a selection
123 // change event to refresh command states, due to the above attribution change. (#9238)
124 editor.forceNextSelectionCheck();
125 editor.getSelection().selectRanges( ranges );
126 }
127 }
128 },
129
130 // Perform the remove format filters on the passed element.
131 // @param {CKEDITOR.editor} editor
132 // @param {CKEDITOR.dom.element} element
133 filter: function( editor, element ) {
134 // If editor#addRemoveFotmatFilter hasn't been executed yet value is not initialized.
135 var filters = editor._.removeFormatFilters || [];
136 for ( var i = 0; i < filters.length; i++ ) {
137 if ( filters[ i ]( element ) === false )
138 return false;
139 }
140 return true;
141 }
142};
143
144/**
145 * Add to a collection of functions to decide whether a specific
146 * element should be considered as formatting element and thus
147 * could be removed during `removeFormat` command.
148 *
149 * **Note:** Only available with the existence of `removeformat` plugin.
150 *
151 * // Don't remove empty span.
152 * editor.addRemoveFormatFilter( function( element ) {
153 * return !( element.is( 'span' ) && CKEDITOR.tools.isEmpty( element.getAttributes() ) );
154 * } );
155 *
156 * @since 3.3
157 * @member CKEDITOR.editor
158 * @param {Function} func The function to be called, which will be passed a {CKEDITOR.dom.element} element to test.
159 */
160CKEDITOR.editor.prototype.addRemoveFormatFilter = function( func ) {
161 if ( !this._.removeFormatFilters )
162 this._.removeFormatFilters = [];
163
164 this._.removeFormatFilters.push( func );
165};
166
167/**
168 * A comma separated list of elements to be removed when executing the `remove
169 * format` command. Note that only inline elements are allowed.
170 *
171 * @cfg
172 * @member CKEDITOR.config
173 */
174CKEDITOR.config.removeFormatTags = 'b,big,cite,code,del,dfn,em,font,i,ins,kbd,q,s,samp,small,span,strike,strong,sub,sup,tt,u,var';
175
176/**
177 * A comma separated list of elements attributes to be removed when executing
178 * the `remove format` command.
179 *
180 * @cfg
181 * @member CKEDITOR.config
182 */
183CKEDITOR.config.removeFormatAttributes = 'class,style,lang,width,height,align,hspace,valign';
184
185/**
186 * Fired after an element was cleaned by the removeFormat plugin.
187 *
188 * @event removeFormatCleanup
189 * @member CKEDITOR.editor
190 * @param {CKEDITOR.editor} editor This editor instance.
191 * @param data
192 * @param {CKEDITOR.dom.element} data.element The element that was cleaned up.
193 */