YangNing Posted April 13, 2015 Share Posted April 13, 2015 I set the fonts of TUniHTMLMemo: function afterCreate(sender) { Ext.apply(sender,{fontFamilies:["宋体","黑体"]}); } But, the default font is "helvetica". Quote Link to comment Share on other sites More sharing options...
Sherzod Posted April 13, 2015 Share Posted April 13, 2015 Hi, One of the solutions, try (may help): works correctly, if at the beginning uniHTMLMemo is empty! function beforeInit(sender) { sender.listeners = { initialize: function(field) { field.relayCmd('fontname', 'verdana'); //the font name must be all lowercase } } } Best regards! Quote Link to comment Share on other sites More sharing options...
YangNing Posted April 18, 2015 Author Share Posted April 18, 2015 Thanks! But it dont work. Quote Link to comment Share on other sites More sharing options...
YangNing Posted April 18, 2015 Author Share Posted April 18, 2015 function afterrender(sender, eOpts) { sender.textareaEl.setStyle("font-family","宋体"); } it works correctly. Quote Link to comment Share on other sites More sharing options...
Sherzod Posted April 18, 2015 Share Posted April 18, 2015 Fine! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.