PDA

View Full Version : Transparency with text



rkrausse
3 Jan 2011, 5:45 AM
I would like to place some text in a panel that is INSIDE another panel. the first panel would have the gradient and the second panel would hold the text. The problem is that my panel with text (btw, I assume this is the best way to place some text on the screen) is not transparent and the gradient doesn't come through.

Anyone?

thx
Ralph

happy new year..

steffenk
3 Jan 2011, 6:05 AM
you can change the classes of the panel (body) as you like with properties, look for all properties with "cls"

rkrausse
3 Jan 2011, 6:10 AM
Sorry but I have no idea what that means...

steffenk
3 Jan 2011, 6:13 AM
http://dev.sencha.com/deploy/dev/docs/?class=Ext.Panel&member=bodyCssClass
http://dev.sencha.com/deploy/dev/docs/?class=Ext.Component&member=cls
etc

rkrausse
3 Jan 2011, 6:18 AM
Thank you, I will check that out BUT after tinkering a bit, I may have a different issue. IF I remove background-color: #fff in .x-panel-body, my gradient blends through. That makes sense. So a question, I could remove it from the css class but that would effect all elements so can I just remove that during runtime? I know I could copy and paste that class in css but was wondering if I could do it the other way, remove that style during runtime.

thx
r

steffenk
3 Jan 2011, 8:13 AM
sure you can manipulate that on run time.

var el = myPanel.getEl();
el.removeClass('foo');
el.addClass('bar')