using System; using Gnome; using Gtk; using GtkSharp; class X { static void Main () { Application.Init (); Window window = new Window ("This is just a window"); window.DeleteEvent += new DeleteEventHandler (Window_Delete); Button button = new Button ("Click here to open an About box"); button.Clicked += new EventHandler (About_Box); window.Add (button); window.ShowAll (); Application.Run (); } static void Window_Delete (object o, DeleteEventArgs args) { Application.Quit (); args.RetVal = true; } static void About_Box (object o, EventArgs args) { string [] authors = new string [] { "Duncan Mak (duncan@ximian.com)" }; string [] documenters = new string [] {}; Gnome.About about = new Gnome.About ("This is an example", "0.1", "Copyright (C) 2002 \nDuncan Mak, Ximian Inc.", "This is a sample", authors, documenters, "", new Gdk.Pixbuf ()); about.Show (); } }