6 let window = GWindow.dialog ~title: "dialog"
7 ~border_width: 10 ~width: 300 ~height: 300 () in
8 window#connect#destroy ~callback:Main.quit;
10 let scrolled_window = GBin.scrolled_window
11 ~border_width: 10 ~hpolicy: `AUTOMATIC ~packing: window#vbox#add ()
14 let table = GPack.table ~rows:10 ~columns:10
15 ~row_spacings: 10 ~col_spacings: 10
16 ~packing: scrolled_window#add_with_viewport ()
21 let label = Printf.sprintf "button (%d,%d)\n" i j in
22 GButton.toggle_button ~label
23 ~packing:(table#attach ~left: i ~top: j ~expand: `BOTH) ()
28 GButton.button ~label: "close" ~packing: window#action_area#add () in
29 button#connect#clicked ~callback: Main.quit;
30 button#grab_default ();