经验分享

百度编辑器toolbarstoolbars工具条功能按钮参考

我的站长站 2019-06-13 人阅读

修改ueditor.config.js里面的toolbars,以下是默认的toolbars代码

toolbars:[ 
            ['fullscreen', 'source', '|', 'undo', 'redo', '|', 
                'bold', 'italic', 'underline', 'fontborder', 'strikethrough', 'superscript', 'subscript', 'removeformat', 'formatmatch', 'autotypeset', 'blockquote', 'pasteplain', '|', 'forecolor', 'backcolor', 'insertorderedlist', 'insertunorderedlist', 'selectall', 'cleardoc', '|', 
                'rowspacingtop', 'rowspacingbottom', 'lineheight', '|', 
                'customstyle', 'paragraph', 'fontfamily', 'fontsize', '|', 
                'directionalityltr', 'directionalityrtl', 'indent', '|', 
                'justifyleft', 'justifycenter', 'justifyright', 'justifyjustify', '|', 'touppercase', 'tolowercase', '|', 
                'link', 'unlink', 'anchor', '|', 'imagenone', 'imageleft', 'imageright', 'imagecenter', '|', 
                'insertimage', 'emotion', 'scrawl', 'insertvideo', 'music', 'attachment', 'map', 'gmap', 'insertframe','insertcode', 'webapp', 'pagebreak', 'template', 'background', '|', 
                'horizontal', 'date', 'time', 'spechars', 'snapscreen', 'wordimage', '|', 
                'inserttable', 'deletetable', 'insertparagraphbeforetable', 'insertrow', 'deleterow', 'insertcol', 'deletecol', 'mergecells', 'mergeright', 'mergedown', 'splittocells', 'splittorows', 'splittocols', 'charts', '|', 
                'print', 'preview', 'searchreplace', 'help', 'drafts'] 
        ]

下面是网上收藏的toolbars中文参考表,方便修改。

, toolbars: [[
‘link‘, //超链接
‘unlink‘, //取消链接
‘|‘,
‘forecolor‘, //字体颜色
‘backcolor‘, //背景色
‘fontfamily‘, //字体
‘fontsize‘, //字号        
‘|‘,        
‘bold‘, //加粗
‘italic‘, //斜体
‘underline‘, //下划线
‘strikethrough‘, //删除线
‘|‘,
‘formatmatch‘, //格式刷
‘removeformat‘, //清除格式
‘|‘,
‘insertorderedlist‘, //有序列表
‘insertunorderedlist‘, //无序列表
‘|‘,
‘inserttable‘, //插入表格
‘paragraph‘, //段落格式
‘simpleupload‘, //单图上传
‘imagecenter‘, //居中
‘attachment‘, //附件   
‘|‘,
‘justifyleft‘, //居左对齐
‘justifycenter‘, //居中对齐
‘horizontal‘, //分隔线
‘|‘,
‘blockquote‘, //引用
‘insertcode‘, //代码语言      
‘|‘,
‘source‘, //源代码
‘preview‘, //预览
‘fullscreen‘, //全屏
]]

不需要的工具按钮删掉就可以了

相关专题
编辑器
编辑器
2021-05-14 237

编辑器是网站开发与内容发布的必备核心工具。本专题精心整理多款常用网页编辑器资源,涵盖各大主流CMS适配编辑器插件、开源HTML可视化编辑器源码、富文本编辑组件...

IT开发经验分享标签