添加自定义字体到 jquery CLeditor

add a custom font to jquery CLeditor

我在我的项目中使用 http://premiumsoftware.net/cleditor 并且在字体下拉列表中默认显示了一些字体,现在我有一个字体并且想在 cleditor 字体列表中使用该字体以及当用户选择该字体时字体 css 适用于它。

与大多数插件一样,有一些选项公开,fonts 是一个 属性,您可以在初始化插件时设置

$("#input").cleditor({               
            fonts: // font names in the font popup
                "Arial,Arial Black,Comic Sans MS,Courier New,Narrow,Garamond," +
                "Georgia,Impact,Sans Serif,Serif,Tahoma,Trebuchet MS,Verdana"
})

参见Getting STarted

中的可选参数