Javascript 行高度选项不显示在CKEDIT中,甚至不添加插件

Javascript 行高度选项不显示在CKEDIT中,甚至不添加插件,javascript,jquery,css,ckeditor,Javascript,Jquery,Css,Ckeditor,我已经下载了相同的额外插件,并通过插件到插件文件夹。ckeditor/plugins/lineheight和ckeditor/plugins/language。 并在config.js中启用。但对于行高和语言选项,则不会在ckeditor中显示 config.extraPlugins = 'lineheight'; config.extraPlugins = 'language'; CKEDITOR.editorConfig = function( config ) { // Defin

我已经下载了相同的额外插件,并通过插件到插件文件夹。ckeditor/plugins/lineheight和ckeditor/plugins/language。 并在config.js中启用。但对于行高和语言选项,则不会在ckeditor中显示

config.extraPlugins = 'lineheight';
config.extraPlugins = 'language';
CKEDITOR.editorConfig = function( config )
{
    // Define changes to default configuration here. For example:
    // config.language = 'fr';
    // config.uiColor = '#AADC6E';
};

通过做双重作业

config.extraPlugins = 'lineheight';
config.extraPlugins = 'language';
您基本上覆盖了
config.extraPlugins
属性,因此它等于
'language'
。改为这样做:

config.extraPlugins = 'lineheight,language';
确定

\ckeditor\config.js中的config.removeButtons中未提及线宽

config.removeButtons ="lineheight"

我知道这是一个老帖子,但我只想分享解决方案,供将来参考

假设您正确添加了extraPlugin,您的配置中还需要以下内容:

CKEDITOR.editorConfig = function( config ) {
    // Define changes to default configuration here.
    // For complete reference see:
    // https://ckeditor.com/docs/ckeditor4/latest/api/CKEDITOR_config.html

    // The toolbar groups arrangement, optimized for a single toolbar row.
    config.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', 'blocks', 'align', 'bidi' ] },
        { name: 'links' },
        { name: 'insert' },
        { name: 'styles' },
        { name: 'colors' },
        { name: 'tools' },
        { name: 'others' },
        { name: 'about' }
    ];

    // The default plugins included in the basic setup define some buttons that
    // are not needed in a basic editor. They are removed here.
    config.removeButtons = 'Cut,Copy,Paste,Undo,Redo,Anchor,Underline,Strike,Subscript,Superscript';

    // Dialog windows are also simplified.
    config.removeDialogTabs = 'link:advanced';
};

大多数选项都是可选的,但{name:'styles'}是必需的。

可能是缓存问题。CKEditor不擅长缓存..我清除浏览器数据并检查所有浏览器。但对于“不显示线高度”选项也是如此。我正在尝试这个@SukhadaKedare你好,欢迎来到SO,谢谢你尝试回答这个问题,不过,一些解释会很好。
CKEDITOR.editorConfig = function( config ) {
    // Define changes to default configuration here.
    // For complete reference see:
    // https://ckeditor.com/docs/ckeditor4/latest/api/CKEDITOR_config.html

    // The toolbar groups arrangement, optimized for a single toolbar row.
    config.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', 'blocks', 'align', 'bidi' ] },
        { name: 'links' },
        { name: 'insert' },
        { name: 'styles' },
        { name: 'colors' },
        { name: 'tools' },
        { name: 'others' },
        { name: 'about' }
    ];

    // The default plugins included in the basic setup define some buttons that
    // are not needed in a basic editor. They are removed here.
    config.removeButtons = 'Cut,Copy,Paste,Undo,Redo,Anchor,Underline,Strike,Subscript,Superscript';

    // Dialog windows are also simplified.
    config.removeDialogTabs = 'link:advanced';
};