RichTextEditor 属性
一组只读属性,可用于获取与编辑器相关的对象。
| 属性 | 说明 |
|---|---|
| editor.document | 编辑器内容所在的 document。调用 insertElement() 之前,请用它创建节点。 |
| editor.window | 编辑区域的内容 window。 |
| editor.input | 编辑器保持同步的隐藏表单输入框(如果存在)。 |
| editor.formatter | Formatter 接口,其命名与 TinyMCE 的 tinymce.Formatter 一致,方便从 TinyMCE 迁移的集成者沿用同一套词汇:register、unregister、get、has、apply、remove、toggle、match、matchAll、matchNode、closest、canApply、getCssText 和 formatChanged。 |
| editor.snippets | 代码片段展开所使用的已注册片段定义。 |
| editor.toolbarFactoryMap | 把工具栏项名称映射到其工厂函数。插件在这里注册自定义工具栏项。 |
| editor.config | 保存此编辑器实例的所有配置。 |
| editor.container | 返回包含编辑器实例的外部 <div> 元素。 |
| editor.iframe | 返回编辑器实例的 iframe 对象。 |
| editor.document | 返回编辑器实例当前活动的编辑器 document 对象。 |
| editor.window | 返回编辑器实例当前活动的编辑器 window 对象。 |
| editor.selection | 返回编辑器实例的 selection 对象。 |