VEI
VEI

Reputation: 1

How to set font style for extjs emptyText?

Would like to set the font style for extjs emptyText to italic rather than normal. This link suggests that style is inherited from com.extjs.gxt.ui.client.widget.BoxComponent but I can't find where.

http://www.sencha.com/helpcenter/index.jsp?topic=/com.extjs.gxt.help/html/reference/uml-api/com/extjs/gxt/ui/client/widget/form/Field.html

From this same help topic: The following 4 methods inherited from UIObject (setSize, setWidth, setHeight, setPixelSize) have been overridden and do nothing. Any component whose size can change should subclass BoxComponent.

Any advice much appreciated.

Upvotes: 0

Views: 6382

Answers (2)

liss.sb
liss.sb

Reputation: 351

You must change the .x-form-empty-field. to do must change the cls to the form.

In the line 14 I change the cls to "newCSS" and in the css i add the .x-form-empty-field to newCSS

.newCSS .x-form-empty-field{
    font-style : italic;
}

this is the fiddle with the changes

http://jsfiddle.net/lisssb/ySf52/1/

I hope this help

Upvotes: 1

secretAgentB
secretAgentB

Reputation: 1279

emptyCls might help you with your problem

http://docs.sencha.com/extjs/4.2.0/#!/api/Ext.form.field.Text-cfg-emptyCls

Upvotes: 0

Related Questions