textitem disabled css

i have a disabled textitem and depending on certain conditions I need to change the css to italics but it does not seem to be working for disabled test items. please help, i am using version smartclient 7.x

here is how i am trying to do.

I defined a css
.showInItalics{
font-style:italic !important;
}

if any condition x is true.

//textItemDisabled is also defined and uses same as of textItem
var styleClass = “textItemDisabled showInItalics”;

textIitem.textBoxStyle = styleClass;
testItem.updateState();

See FormItemBaseStyle.

thanks for the reply, however i could not make out anything out of type FormItemBaseStyle.

my requirement is that i need to show the font as italics first and then will need to enable/disable the textitem conditionally. though the item changes to disable/enabled state but it loses its italic font, please note that enabled textitems preserve italic fonts. please help.

OK, FormItemBaseStyle tells you how to define CSS styles to affect every state of the FormItem. So you should be all set.