const ScreenInfo *info = OBDisplay::screenInfo(getScreen());
_xftdraw = XftDrawCreate(OBDisplay::display, getWindow(), info->getVisual(),
info->getColormap());
-
- setTexture(getStyle()->getLabelFocus());
- setUnfocusTexture(getStyle()->getLabelUnfocus());
+ setStyle(getStyle());
}
OtkFocusLabel::~OtkFocusLabel()
XftDrawDestroy(_xftdraw);
}
+
+void OtkFocusLabel::setStyle(Style *style)
+{
+ OtkFocusWidget::setStyle(style);
+
+ setTexture(getStyle()->getLabelFocus());
+ setUnfocusTexture(getStyle()->getLabelUnfocus());
+}
+
+
void OtkFocusLabel::update(void)
{
if (_dirty) {
_xftdraw = XftDrawCreate(OBDisplay::display, getWindow(), info->getVisual(),
info->getColormap());
- setTexture(getStyle()->getLabelUnfocus());
+ setStyle(getStyle());
}
OtkLabel::~OtkLabel()
XftDrawDestroy(_xftdraw);
}
+void OtkLabel::setStyle(Style *style)
+{
+ OtkWidget::setStyle(style);
+
+ setTexture(getStyle()->getLabelUnfocus());
+}
+
+
void OtkLabel::update(void)
{
if (_dirty) {