Content-Type: text/plain; charset="iso-8859-1" From: Stalkern 2 Reply-To: stalkern2 at tin.it To: lablgtk at kaba.or.jp Subject: Re: Tree and Entry in a file viewer Date: Wed, 22 Jan 2003 17:49:18 +0100 References: <200301221333.27831.stalkern2 at tin.it> <200301221451.28097.stalkern2 at tin.it> <20030122155346.28e64617.maxence.guesdon at inria.fr> In-Reply-To: <20030122155346.28e64617.maxence.guesdon at inria.fr> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Message-Id: <200301221749.18377.stalkern2 at tin.it> Il Wednesday 22 January 2003 15:53, Maxence Guesdon ha scritto: [...] > > I wonder whether this is related to the lazyness of the evaluation of > > code. How could I come out of this issue? I would prefer not to call out > > the label by its position in the children list, both because I've some > > alignments that would be severely affected by changes between positions > > and because I regret to mix up lists and fixed positions in lists. > > Here the children of tree_item are Gtk.widget Gtk.obj, not label widgets > (which are a subclass of Gtk.obj IIRC). You could force it with a Obj.magic > but it would be really ugly and dangerous : > ((Obj.magic aWidget) #text) OK, so I set everything in order to have an Alignment as the first and sole child of the Tree_item , and then a label as a child of the Alignment. The problem now is that I can't get the child of the Alignment using method #children; Alignment is recognized to be a GObj.widget and so I can't use method #children. How can I tell Lablgtk that Alignment is a single-child Container, and that I need the child? I'm completely stuck, is it because I'm starting GTK from the ocaml side? Is there any book that you could suggest to me, apart from the super-heavy GTK tutorial and the not-so-commented GTK API? Ernesto PS I'm getting crazy >8-O