[Gtk-sharp-list] custom widget
Michael Gebhart
lists at miketech.net
Wed Mar 8 11:21:41 EST 2006
Hi,
hm I wanted to write such a component on my own to learn Gtk# a bit more
in detail.
With DrawingArea I got it working. Is this here the right way to do it?
public class PaintWidget : Gtk.DrawingArea
{
public PaintWidget() : base()
{
Events = (Gdk.EventMask)Gdk.EventMask.ButtonPressMask;
}
protected override bool OnButtonPressEvent(Gdk.EventButton evnt)
{
Console.WriteLine("huhu");
return true;
}
}
Or is there a better way?
Greetings
Mike
More information about the Gtk-sharp-list
mailing list