【发布时间】:2020-11-17 13:52:56
【问题描述】:
我正在尝试在 EXTJS htmleditor 字段中更改 tinymce 编辑器的内容样式。该应用程序具有系统设置,您可以在其中选择文本字段或数字字段的字体大小。 现在我想为 extjs htmleditor 字段设置一个默认系统设置字体大小,但这是由 tinymce 覆盖使用的。 我如何向保存系统设置的前端发送请求?然后tinymce覆盖应该改变他的字体大小设置。
This is the HTMLEDITOR with tinymce
Ext.define('GETS.form.field.tinymce.TinyMceField', {
extend : 'Ext.form.field.TextArea',
alias : [ 'widget.tinymce', 'widget.tinymcefield' ],
editor : null,
readOnly : false,
_isRemoving : false,
editorConfig : {
skin : 'small',
icons : 'thin',
plugins : [ 'advcode advlist anchor autolink charmap codesample directionality emoticons fullpage fullscreen help hr image imagetools insertdatetime link lists mentions nonbreaking noneditable pagebreak powerpaste preview print save searchreplace tabfocus table template textpattern toc visualblocks visualchars wordcount noneditable attributes calculation images translations msword' ],
toolbar1 : 'code fullscreen preview visualblocks removeformat | undo redo | bold italic underline strikethrough subscript superscript | alignleft aligncenter alignright alignjustify | formatselect fontselect fontsizeselect | bullist numlist | outdent indent | link unlink insertdatetime | forecolor backcolor | table searchreplace pagebreak nonbreaking | hr charmap emoticons | insertAttribute editAttribute insertEditCalculation insertImage image translateText | insertPageNumber insertPageXOfY | print fullpage | help',
font_formats : 'Andale Mono=andale mono,times; Arial=arial,helvetica,sans-serif; Arial Black=arial black,avant garde; Book Antiqua=book antiqua,palatino; Calibri=calibri; Comic Sans MS=comic sans ms,sans-serif; Courier New=courier new,courier; Georgia=georgia,palatino; Helvetica=helvetica; Impact=impact,chicago; Symbol=symbol; Tahoma=tahoma,arial,helvetica,sans-serif; Terminal=terminal,monaco; Times New Roman=times new roman,times; Trebuchet MS=trebuchet ms,geneva; Verdana=verdana,geneva; Webdings=webdings; Wingdings=wingdings,zapf dingbats',
fontsize_formats : '8pt 9pt 10pt 11pt 12pt 13pt 14pt 15pt 16pt 17pt 18pt 19pt 20pt 22pt 24pt 26pt 28pt 36pt 48pt 72pt',
**content_style : '.mce-content-body {font-size:12pt;font-family:Arial,sans-serif;} p,ul,li** {margin:0}',
browser_spellcheck : true,
relative_urls : false,
remove_script_host : false,
convert_urls : false,
resize : false,
【问题讨论】:
标签: extjs tinymce tinymce-plugins