]> matita.cs.unibo.it Git - helm.git/blob - helm/DEVEL/lablgtk/lablgtk_20000829-0.1.0/examples/hello.ml
"Final" commit that patches termViewer while still enabling XML Diffing.
[helm.git] / helm / DEVEL / lablgtk / lablgtk_20000829-0.1.0 / examples / hello.ml
1 (* $Id$ *)
2
3 open GMain
4
5 let window = GWindow.window ~border_width: 10 ()
6
7 let button = GButton.button ~label:"Hello World" ~packing: window#add ()
8
9 let main () =
10   window#event#connect#delete 
11     ~callback:(fun _ -> prerr_endline "Delete event occured"; true);
12   window#connect#destroy ~callback:Main.quit;
13   button#connect#clicked ~callback:(fun () -> prerr_endline "Hello World");
14   button#connect#clicked ~callback:window#destroy;
15   window#show ();
16   Main.main ()
17
18 let _ = Printexc.print main ()