Как удалить кнопки из CKeditor 4 в Django с помощью settings.py
Я пытаюсь удалить кнопки из панели инструментов CKeditor 4 из файла settings.py в Django
Я добавил следующую строку в CKEDITOR_CONFIGS, но это не сработало
'removeButtons' : ['Underline,JustifyCenter'],
Строки CKEDITOR_CONFIGS:
CKEDITOR_CONFIGS = {
'default': {
'skin': 'moono',
# 'skin': 'office2013',
'toolbar_Basic': [
['Source', '-', 'Bold', 'Italic']
],
'toolbar': 'YourCustomToolbarConfig', # put selected toolbar config here
'toolbarGroups': [
# { 'name': 'document', 'groups': [ 'mode', 'document', 'doctools' ] },
# { 'name': 'clipboard', 'groups': [ 'clipboard', 'undo' ] },
# { 'name': 'editing', 'groups': [ 'find', 'selection', 'spellchecker' ] },
# { 'name': 'forms' },
{ 'name': 'basicstyles', 'groups': [ 'basicstyles', 'cleanup' ] },
{ 'name': 'paragraph', 'groups': [ 'list', 'indent','align' ] },
{ 'name': 'links' },
{ 'name': 'insert' },
{ 'name': 'styles'},
# { 'name': 'colors' },
# { 'name': 'tools' },
# { 'name': 'others' },
# { 'name': 'about' }
],
# 'removeButtons' : ['Underline,JustifyCenter'],
# 'height': 291,
# 'width': '100%',
# 'filebrowserWindowHeight': 725,
# 'filebrowserWindowWidth': 940,
# 'toolbarCanCollapse': True,
# 'mathJaxLib': '//cdn.mathjax.org/mathjax/2.2-latest/MathJax.js?config=TeX-AMS_HTML',
'tabSpaces': 4,
'extraPlugins': ','.join([
'uploadimage', # the upload image feature
# your extra plugins here
'div',
'autolink',
'autoembed',
'embedsemantic',
'autogrow',
# 'devtools',
'widget',
'lineutils',
'clipboard',
'dialog',
'dialogui',
'elementspath'
]),
}
}
Я пытаюсь сохранить только форматирование абзацев из "стилей"