X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;f=_source%2Fplugins%2Fjustify%2Fplugin.js;h=82c1fccff5e1cf80b40d3879646a181fd80f0ec2;hb=e73319a12b56100b29ef456fd74114fe5519e01c;hp=695f91010eceb77ba08f49a380c882b385b9c1f0;hpb=48b1db88210b4160dce439c6e3e32e14af8c106b;p=ckeditor.git diff --git a/_source/plugins/justify/plugin.js b/_source/plugins/justify/plugin.js index 695f910..82c1fcc 100644 --- a/_source/plugins/justify/plugin.js +++ b/_source/plugins/justify/plugin.js @@ -49,6 +49,9 @@ For licensing, see LICENSE.html or http://ckeditor.com/license function onSelectionChange( evt ) { + if ( evt.editor.readOnly ) + return; + var command = evt.editor.getCommand( this.name ); command.state = getState.call( this, evt.editor, evt.data.path ); command.fire( 'state' ); @@ -237,3 +240,14 @@ For licensing, see LICENSE.html or http://ckeditor.com/license requires : [ 'domiterator' ] }); })(); + + /** + * List of classes to use for aligning the contents. If it's null, no classes will be used + * and instead the corresponding CSS values will be used. The array should contain 4 members, in the following order: left, center, right, justify. + * @name CKEDITOR.config.justifyClasses + * @type Array + * @default null + * @example + * // Use the classes 'AlignLeft', 'AlignCenter', 'AlignRight', 'AlignJustify' + * config.justifyClasses = [ 'AlignLeft', 'AlignCenter', 'AlignRight', 'AlignJustify' ]; + */