I have the following definition :
Code:
icaMail.quickBtn = new Ext.Action({
iconCls: 'icon-mail-unread',
text: '',
handler: function() {
// blah
}
});
and used like this
Code:
tbar: new Ext.Toolbar({
items: [
new Ext.Button(icaMail.quickBtn)
]
}),
Initially the button appears properly with just the icon. However when i issue
Code:
icaMail.quickBtn.setText('(1)');
The text '(1)' appears OVER the icon .
There appears to be some quirks in the text rendering and you can replicate some problems at will with the Action interactive example 'change text' feature. You can change the text fine - but try entering a 'space' and see what happens. The icon rendering screws up a bit.
Kev