To: lablgtk at kaba.or.jp Subject: Re: filling data in glade-2 generated code References: <871xl74rpw.fsf at fbigm.here> <20040526.172709.07272526.garrigue@kurims.kyoto-u.ac.jp> <20040526.104507.13918277.andrieu@ijm.jussieu.fr> From: Friedrich Dominicus Organization: Q Software Solutions GmbH Date: Fri, 28 May 2004 11:49:58 +0200 In-Reply-To: <20040526.104507.13918277.andrieu at ijm.jussieu.fr> (Olivier Andrieu's message of "Wed, 26 May 2004 10:45:07 +0200 (CEST)") Message-ID: <87aczsev95.fsf at fbigm.here> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Olivier Andrieu writes: > > Note that store of list will only provide you with a single column > > list. If this is enough for you, then you just have to do > > > > let w1 = new window1 () > > let (store, column) = GTree.store_of_list Gobject.Data.string currencies > > let () = > > w1#to_cur#set_model (Some(store :> GTree.model)); > > w1#to_cur#append_column column; > > w1#from_cur#set_model (Some(store :> GTree.model)); > > w1#from_cur#append_column column; > > ... > > Hum no, there's a bit more code to write because the column returned > by store_of_list is a GTree.column, not a GtkViewColumn. > > let w1 = new window1 () > let (store, column) = GTree.store_of_list Gobject.Data.string > currencies Well that will probably put me on the righ track, just at the moment I get: lablgtk2 -verbose exchange_rate.ml myocaml -w s -I /usr/lib/ocaml/3.07/lablgtk2 -I +lablGL -I +xstr -I +pcre unix.cma lablgl.cma lablgtk.cma lablgtkgl.cma lablglade.cma lablgnomecanvas.cma lablgnomeui.cma lablpanel.cma lablrsvg.cma gtkInit.cmo exchange_rate.ml File "exchange_rate.ml", line 227, characters 30-49: Unbound value GTree.store_of_list Don't know why it does not find the proper function. Will try to figure out . Regards Friedrich