Unanswered: How to change background color of sencha gxt ToolTip.??
Hi,Please provide me the solution for changing the background color of ToolTip Config class.com.sencha.gxt.widget.core.client.tips.ToolTipConfig I have to change the background color to yellow.
What have you tried? Are you using the themer, and is theme.details.tip.backgroundColor not working? Are you making your own appearance and can't change the style? Are you writing CSS and it isn't applying to the tooltip's background?
I have tried first through CSS but I found that in ToolTipConfig there is no such method like setStylename() or addStylename() where I can set my styles. After that I tried to make one CustomToolTip class that extends ToolTipConfig and implements Tip.Appearance interface. I have implemented the method of Tip.Appearance & tried to set the style in few of its method like getElementText(Xlement parent ) but it also didn't work. Could you please tell the possible way to solve the issue.
Can you share the custom appearance you made? That is one possible valid strategy, and should work correctly. The best way here is probably to extend the existing implementation and add your own styles to it. Check out how com.sencha.gxt.theme.base.client.field.ErrorTipDefaultAppearance extends com.sencha.gxt.theme.base.client.tips.TipDefaultAppearance and changes a few details, without changing behavior.
You can also call getTooltip() on a component and then use addStyleName as you described. What CSS did you try?
Finally, as I described in my first post, you can use the new theme builder and customize the tip section to use your specific background color. Did this not work? Did you get an error, or did it just not change the color correctly? What does your theme config file look like?
Tags for this Thread