+ self.vbox.show_all()
+
+ def _expose(self, event):
+ cr = self.window.cairo_create()
+
+ # draw rounded rect
+ width, height = self.allocation[2], self.allocation[3]
+
+ #/* a custom shape, that could be wrapped in a function */
+ x0 = 0 #/*< parameters like cairo_rectangle */
+ y0 = 0
+
+ radius = min(15, width/2, height/2) #/*< and an approximate curvature radius */
+
+ x1 = x0 + width
+ y1 = y0 + height
+
+ cr.move_to (x0, y0 + radius)
+ cr.arc (x0 + radius, y0 + radius, radius, 3.14, 1.5 * 3.14)
+ cr.line_to (x1 - radius, y0)
+ cr.arc (x1 - radius, y0 + radius, radius, 1.5 * 3.14, 0.0)
+ cr.line_to (x1 , y1 - radius)
+ cr.arc (x1 - radius, y1 - radius, radius, 0.0, 0.5 * 3.14)
+ cr.line_to (x0 + radius, y1)
+ cr.arc (x0 + radius, y1 - radius, radius, 0.5 * 3.14, 3.14)
+
+ cr.close_path ()
+
+ fg_color = get_color("ActiveTextColor")
+
+ if self.processing :
+ bg_color=fg_color
+ else :
+ bg_color=gtk.gdk.color_parse('#000000')
+
+ cr.set_source_rgba (bg_color.red / 65535.0, bg_color.green/65535.0, bg_color.blue/65535.0, 0.7)
+ cr.fill_preserve ()
+
+ cr.set_source_rgba (fg_color.red / 65535.0, fg_color.green / 65535.0, fg_color.blue / 65535.0, 0.5)
+ cr.stroke ()
+
+ def do_expose_event(self, event):
+ self.chain(event)
+ self._expose (event)
+ self.vbox.do_expose_event (self, event)
+