protected override bool OnExposeEvent(Gdk.EventExpose evnt)
{
if (evnt.Window != GdkWindow || State == StateType.Insensitive) {
return true;
}
int x, y;
x = Allocation.X + (int)Math.Round ((Allocation.Width - layout_width) / 2.0);
y = Allocation.Y + (int)Math.Round ((Allocation.Height - layout_height) / 2.0);
if (HasFocus) {
GdkWindow.DrawLine (Style.ForegroundGC (StateType.Normal),
x + 2, y + layout_height - 2,
x + layout_width - 4, y + layout_height - 2);
}
Gtk.Style.PaintLayout (Style, GdkWindow, State, false,
evnt.Area, this, null, x, y, layout);
return true;
}