Path: utzoo!attcan!uunet!tut.cis.ohio-state.edu!ucbvax!allegra.tempo.nj.att.com!bill From: bill@allegra.tempo.nj.att.com (Bill Schell) Newsgroups: comp.soft-sys.andrew Subject: help needed with arb/createcon (ADEW) problem Message-ID: Date: 22 Mar 90 18:42:25 GMT Sender: daemon@ucbvax.BERKELEY.EDU Organization: The Internet Lines: 45 Hi there. Perhaps someone could help me out with a problem I'm having using tree/treev objects with arb and createcon? I can get trees to display themselves using the procedure laid out in the first chapter of Nathanial Borenstein's book, but can't get more than a blank window when I try to do it using the code generated by createcon. Here's what I do: 1) I fire up arb and create a new window with an lset object in it 2) I pick 'Add Object' from the Arbcon menu and type 'tree treev' to get a tree-treev inset which I paste into the lset object. I save everything. 3) I run createcon to get the files infuse.ch and infuse.c. 4) I edit infuse.c and after the call to FindSelf() in the infuse_go function, I add a call to the following routine: draw_tree(self) struct infuse *self; { struct tree_node *node; self->tree = tree_New(); self->treeView = treev_New(); treev_SetDataObject(self->treeView, self->tree); node = tree_CreateRootNode(self->tree, "Root Node", 0); tree_CreateChildNode(self->tree, "Child 1", 1, node); tree_CreateChildNode(self->tree, "Child 2", 2, node); } However, after compiling and running this code, all I get is a blank window. I know this code makes a proper tree, because if I put: { struct im *im = im_Create(NULL); im_SetView(im, self->treeView); } at the end, I get a second window with the tree in it. Can someone give me a clue as to what I'm doing wrong here and how to set up proper view tree? This is the first Andrew based application I've written. I'd like to use arb/createcon for my application instead of writing the glue code myself, as the eventual user interface will have tree views, text views, button views, etc. in it and is likely to change fairly often in the beginning. Thanks, Bill Schell AT&T Bell Labs, Murray Hill, NJ bill@allegra.att.com or allegra!bill