Hi,
JSCall('execCmd', ['bold']);
JSCall('execCmd', ['italic']);
JSCall('execCmd', ['FontSize', 5]); // 0-7
1. htmlMemo... -> UniEvents
function beforeInit(sender, config)
{
this.setColor = function(color) {
this.execCmd('forecolor', Ext.isWebKit || Ext.isIE ? '#'+color : color);
this.deferFocus();
};
this.setBGColor = function(color) {
if (Ext.isGecko) {
this.execCmd('useCSS', false);
this.execCmd('hilitecolor', color);
this.execCmd('useCSS', true);
this.deferFocus();
} else {
this.execCmd(Ext.isOpera ? 'hilitecolor' : 'backcolor', Ext.isWebKit || Ext.isIE ? '#' + color : color);
this.deferFocus();
}
}
}
2. Usage:
UniHTMLMemo1.JSInterface.JSCall('setColor', ['FF0000']);
UniHTMLMemo1.JSInterface.JSCall('setBGColor', ['FF0000']);