UEditor文档-定制工具栏图标

动态 0
网站在线工具,网站抓取工具
cjl 2018-06-05 21:24:40
回复

定制工具栏图标

UEditor 工具栏上的按钮列表可以自定义配置,只需要通过修改配置项就可以实现需求

配置项修改说明

修改配置项的方法: 1. 方法一:修改 ueditor.config.js 里面的 toolbars 2. 方法二:实例化编辑器的时候传入 toolbars 参数

var ue = UE.getEditor('container');

其他配置项:配置项说明

简单列表

toolbars: [
    ['fullscreen', 'source', 'undo', 'redo', 'bold']]

多行列表

toolbars: [
    ['fullscreen', 'source', 'undo', 'redo'],
    ['bold', 'italic', 'underline', 'fontborder', 'strikethrough', 'superscript', 'subscript', 'removeformat', 'formatmatch', 'autotypeset', 'blockquote', 'pasteplain', '|', 'forecolor', 'backcolor', 'insertorderedlist', 'insertunorderedlist', 'selectall', 'cleardoc']]

工具栏按钮分割线

配置项里用竖线 '|' 代表分割线

完整的按钮列表

toolbars: [
    [
        'anchor', //锚点
        'undo', //撤销
        'redo', //重做
        'bold', //加粗
        'indent', //首行缩进
        'snapscreen', //截图
        'italic', //斜体
        'underline', //下划线
        'strikethrough', //删除线
        'subscript', //下标
        'fontborder', //字符边框
        'superscript', //上标
        'formatmatch', //格式刷
        'source', //源代码
        'blockquote', //引用
        'pasteplain', //纯文本粘贴模式
        'selectall', //全选
        'print', //打印
        'preview', //预览
        'horizontal', //分隔线
        'removeformat', //清除格式
        'time', //时间
        'date', //日期
        'unlink', //取消链接
        'insertrow', //前插入行
        'insertcol', //前插入列
        'mergeright', //右合并单元格
        'mergedown', //下合并单元格
        'deleterow', //删除行
        'deletecol', //删除列
        'splittorows', //拆分成行
        'splittocols', //拆分成列
        'splittocells', //完全拆分单元格
        'deletecaption', //删除表格标题
        'inserttitle', //插入标题
        'mergecells', //合并多个单元格
        'deletetable', //删除表格
        'cleardoc', //清空文档
        'insertparagraphbeforetable', //"表格前插入行"
        'insertcode', //代码语言
        'fontfamily', //字体
        'fontsize', //字号
        'paragraph', //段落格式
        'simpleupload', //单图上传
        'insertimage', //多图上传
        'edittable', //表格属性
        'edittd', //单元格属性
        'link', //超链接
        'emotion', //表情
        'spechars', //特殊字符
        'searchreplace', //查询替换
        'map', //Baidu地图
        'gmap', //Google地图
        'insertvideo', //视频
        'help', //帮助
        'justifyleft', //居左对齐
        'justifyright', //居右对齐
        'justifycenter', //居中对齐
        'justifyjustify', //两端对齐
        'forecolor', //字体颜色
        'backcolor', //背景色
        'insertorderedlist', //有序列表
        'insertunorderedlist', //无序列表
        'fullscreen', //全屏
        'directionalityltr', //从左向右输入
        'directionalityrtl', //从右向左输入
        'rowspacingtop', //段前距
        'rowspacingbottom', //段后距
        'pagebreak', //分页
        'insertframe', //插入Iframe
        'imagenone', //默认
        'imageleft', //左浮动
        'imageright', //右浮动
        'attachment', //附件
        'imagecenter', //居中
        'wordimage', //图片转存
        'lineheight', //行间距
        'edittip ', //编辑提示
        'customstyle', //自定义标题
        'autotypeset', //自动排版
        'webapp', //百度应用
        'touppercase', //字母大写
        'tolowercase', //字母小写
        'background', //背景
        'template', //模板
        'scrawl', //涂鸦
        'music', //音乐
        'inserttable', //插入表格
        'drafts', // 从草稿箱加载
        'charts', // 图表
    ]]


回帖
  • 消灭零回复
最新评论 Latest comments
大大们,帮看下,网站想改版,有什么好办法.可报价 2614
请问官方有没有官网群呢?有时候想和大大们聊以下都没办法 5329
申请贵站友链。 1821
建议增加微信支付通道 5826
换友联的直接回复 1640
Django框架是当前python语言比较热门的一个框架 6514
【伪原创】自动采集文章兼发布文章,可否加入PBOOTCMS的采集功能 6857
百度站长在添加站点后,提示error":401,"message":"site sid is empty或者推送链接错误 10334
生成sitemap.xml网站地图工具 7984
近期推出的文字合成语音 - 在线文字合成mp3语音文件-在线工具 6448
为什么关键词排名做不上百度首页 6102
python 环境用哪个好 2690
百度站长后台的主动推送中的更新数据接口没有条数? 7547
lmcjl在线工具一直追求用户体验至上 7876
今天优化了链接抓取功能,增加mip网站链接抓取 7719
相关评论 Related comments
JetBrains IDE 远程代码执行和本地文件泄露 0
新浪微博错误代码详解 0
微信错误代码(全局返回码)的说明 0
editor.md 配置参数和使用方法 0
Python2和Python3的区别 0
Python获取数据库表保存为excel并发送到邮箱 0
新搭建的新网站要怎么样才能快速进入百度首页 0
轻松解除网页防复制 0
JetBrains IDE workspace.xml文件泄露 0
黑客十大常用工具介绍 0
thinkphp5 getshell漏洞修复的艰辛过程 2
WebSocket connection to 'wss://域名:7272/' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED 3
python使用list和tuple 0
Python三大Web框架Django、Flask、Tornado的部署 0
说说redis缓存+workerman通讯+vue.js这方面的感悟 0