def text_view_bg_expose(self, widget, event): '''draw text view bg''' cr = widget.window.cairo_create() rect = widget.allocation text_pixbuf = app_theme_get_dynamic_pixbuf('image/share/text_view.png').get_pixbuf() draw.draw_pixbuf(cr, text_pixbuf, rect.x, rect.y)
def create_ico_image(self, name): ''' create image from file''' pix1 = app_theme_get_dynamic_pixbuf('image/share/%s.png' % name).get_pixbuf() pix2 = app_theme_get_dynamic_pixbuf('image/share/%s_no.png' % name).get_pixbuf() return (pix1, pix2)