2015-03-22 18:09:22 +01:00
/ *
Copyright ( c ) 2003 - 2010 , CKSource - Frederico Knabben . All rights reserved .
For licensing , see LICENSE . html or http : //ckeditor.com/license
* /
CKEDITOR . editorConfig = function ( config )
{
// Define changes to default configuration here.
// http://docs.cksource.com/CKEditor_3.x/Developers_Guide
// http://docs.cksource.com/ckeditor_api/symbols/CKEDITOR.config.html
config . enterMode = CKEDITOR . ENTER _BR ;
config . resize _enabled = false ;
//config.resize_maxHeight = 3000;
//config.resize_maxWidth = 3000;
//config.height = '300px';
//config.resize_dir = 'vertical'; // horizontal, vertical, both
config . removePlugins = 'elementspath,save' ; // config.removePlugins = 'elementspath,save,font';
2017-07-09 22:30:19 +02:00
//config.extraPlugins = 'docprops,scayt,showprotected';
2015-03-22 18:09:22 +01:00
config . removeDialogTabs = 'flash:advanced' ; // config.removeDialogTabs = 'flash:advanced;image:Link';
config . protectedSource . push ( /<\?[\s\S]*?\?>/g ) ; // Prevent PHP Code to be formatted
2018-07-26 19:05:34 +02:00
//config.menu_groups = 'clipboard,table,anchor,link,image'; // for context menu 'clipboard,form,tablecell,tablecellproperties,tablerow,tablecolumn,table,anchor,link,image,flash,checkbox,radio,textfield,hiddenfield,imagebutton,button,select,textarea'
2015-03-22 18:09:22 +01:00
//config.language = 'de';
//config.defaultLanguage = 'en';
//config.contentsLanguage = 'fr';
config . fullPage = false ; // Not a full html page string, just part of it
config . dialog _backgroundCoverColor = 'rgb(255, 254, 253)' ;
//config.contentsCss = '/css/mysitestyles.css';
config . image _previewText = ' ' ; // Must no be empty
2017-07-09 20:31:27 +02:00
//config.autoParagraph = false;
//config.removeFormatTags = 'b,big,code,del,dfn,em,font,i,ins,kbd'; // See also rules on this.dataProcessor.writer.setRules
//config.forcePasteAsPlainText = true;
2018-07-26 19:05:34 +02:00
2015-03-22 18:09:22 +01:00
config . toolbar _Full =
[
2016-07-14 11:46:32 +02:00
[ 'Templates' , 'NewPage' ] ,
[ 'Save' ] ,
2017-10-21 19:39:25 +02:00
[ 'Maximize' , 'Preview' ] ,
[ 'PasteText' , 'PasteFromWord' , '-' , 'Print' , 'SpellChecker' , 'Scayt' ] , // 'Cut','Copy','Paste','-', are useless, can be done with right click, even on smarpthone
2015-03-22 18:09:22 +01:00
[ 'Undo' , 'Redo' , '-' , 'Find' , 'Replace' , '-' , 'SelectAll' , 'RemoveFormat' ] ,
2017-04-07 14:18:04 +02:00
[ 'CreateDiv' , 'ShowBlocks' ] ,
2015-03-22 18:09:22 +01:00
[ 'Form' , 'Checkbox' , 'Radio' , 'TextField' , 'Textarea' , 'Select' , 'Button' , 'ImageButton' , 'HiddenField' ] ,
2018-08-08 17:09:51 +02:00
[ 'Bold' , 'Italic' , 'Underline' , 'Strike' , 'Superscript' ] , // 'Subscript'
2017-04-07 14:18:04 +02:00
[ 'NumberedList' , 'BulletedList' , '-' , 'Outdent' , 'Indent' , 'Blockquote' ] ,
2015-03-22 18:09:22 +01:00
[ 'JustifyLeft' , 'JustifyCenter' , 'JustifyRight' , 'JustifyBlock' ] ,
[ 'BidiLtr' , 'BidiRtl' ] ,
[ 'Link' , 'Unlink' , 'Anchor' ] ,
2016-09-16 01:00:24 +02:00
[ 'Image' , 'Table' , 'HorizontalRule' , 'Smiley' , 'SpecialChar' , 'PageBreak' , 'Iframe' ] ,
2015-03-22 18:09:22 +01:00
[ 'Styles' , 'Format' , 'Font' , 'FontSize' ] ,
2017-10-21 19:39:25 +02:00
[ 'TextColor' , 'BGColor' ] ,
[ 'Source' ]
2015-03-22 18:09:22 +01:00
] ;
// Used for mailing fields
2018-07-26 19:05:34 +02:00
config . toolbar _dolibarr _mailings =
2015-03-22 18:09:22 +01:00
[
2017-10-21 19:39:25 +02:00
[ 'Maximize' , 'Preview' ] ,
[ 'SpellChecker' , 'Scayt' ] ,
2015-03-22 18:09:22 +01:00
[ 'Undo' , 'Redo' , '-' , 'Find' , 'Replace' ] ,
2017-10-21 19:39:25 +02:00
[ 'CreateDiv' , 'ShowBlocks' ] ,
2015-03-22 18:09:22 +01:00
[ 'Format' , 'Font' , 'FontSize' ] ,
2018-08-08 17:09:51 +02:00
[ 'Bold' , 'Italic' , 'Underline' , 'Strike' , 'Superscript' , '-' , 'TextColor' , 'RemoveFormat' ] ,
2017-10-21 19:39:25 +02:00
[ 'NumberedList' , 'BulletedList' , 'Outdent' , 'Indent' ] ,
2015-03-22 18:09:22 +01:00
[ 'JustifyLeft' , 'JustifyCenter' , 'JustifyRight' , 'JustifyBlock' ] ,
2017-10-21 19:39:25 +02:00
[ 'Link' , 'Unlink' , 'Anchor' , 'Image' , 'Table' , 'HorizontalRule' , 'SpecialChar' ] ,
[ 'Source' ]
2015-03-22 18:09:22 +01:00
] ;
2018-07-26 19:05:34 +02:00
2015-03-22 18:09:22 +01:00
// Used for notes fields
config . toolbar _dolibarr _notes =
[
2017-10-21 19:39:25 +02:00
[ 'Maximize' ] ,
2017-04-07 14:18:04 +02:00
[ 'SpellChecker' , 'Scayt' ] , // 'Cut','Copy','Paste','-', are useless, can be done with right click, even on smarpthone
2015-03-22 18:09:22 +01:00
[ 'Undo' , 'Redo' , '-' , 'Find' , 'Replace' ] ,
[ 'Format' , 'Font' , 'FontSize' ] ,
2018-08-08 17:09:51 +02:00
[ 'Bold' , 'Italic' , 'Underline' , 'Strike' , 'Superscript' , '-' , 'TextColor' , 'RemoveFormat' ] ,
2015-03-22 18:09:22 +01:00
[ 'NumberedList' , 'BulletedList' , 'Outdent' , 'Indent' ] ,
[ 'JustifyLeft' , 'JustifyCenter' , 'JustifyRight' , 'JustifyBlock' ] ,
2017-10-21 19:39:25 +02:00
[ 'Link' , 'Unlink' , 'Image' , 'Table' , 'HorizontalRule' , 'SpecialChar' ] ,
[ 'Source' ]
2015-03-22 18:09:22 +01:00
] ;
2018-07-26 19:05:34 +02:00
2015-03-22 18:09:22 +01:00
// Used for details lines
config . toolbar _dolibarr _details =
[
2017-10-21 19:39:25 +02:00
[ 'Maximize' ] ,
2017-04-07 14:18:04 +02:00
[ 'SpellChecker' , 'Scayt' ] , // 'Cut','Copy','Paste','-', are useless, can be done with right click, even on smarpthone
2017-12-12 10:13:48 +01:00
[ 'Format' , 'FontSize' ] ,
2017-10-21 19:39:25 +02:00
[ 'Bold' , 'Italic' , 'Underline' , 'Strike' , '-' , 'TextColor' , 'RemoveFormat' ] , // ,'Subscript','Superscript' useless
2015-03-22 18:09:22 +01:00
[ 'NumberedList' , 'BulletedList' , 'Outdent' , 'Indent' ] ,
[ 'JustifyLeft' , 'JustifyCenter' , 'JustifyRight' , 'JustifyBlock' ] ,
2017-10-21 19:39:25 +02:00
[ 'Link' , 'Unlink' , 'SpecialChar' ] ,
[ 'Source' ]
2015-03-22 18:09:22 +01:00
] ;
2018-07-26 19:05:34 +02:00
2015-03-22 18:09:22 +01:00
// Used for mailing fields
config . toolbar _dolibarr _readonly =
[
2017-10-21 19:39:25 +02:00
[ 'Maximize' ] ,
[ 'Find' ] ,
[ 'Source' ]
2018-07-26 19:05:34 +02:00
] ;
2015-03-22 18:09:22 +01:00
} ;