Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!batcomputer!munnari.oz.au!mel.dit.csiro.au!yarra!melba.bby.oz.au!gnb From: gnb@bby.oz.au (Gregory N. Bond) Newsgroups: comp.windows.x Subject: Wcl Table widget containing composite widgets.... Message-ID: <1991Apr8.055237.19247@melba.bby.oz.au> Date: 8 Apr 91 05:52:37 GMT Sender: usenet@melba.bby.oz.au (news READER id) Distribution: comp Organization: Burdett, Buckeridge and Young Ltd. Lines: 71 Nntp-Posting-Host: leo-gw I am confused about the behaviour of the table widget distributed with WCL when some of the table contents are composite widgets. I have an app I am prototyping that contains a line of buttons along the top and two output areas (AtPlotter widgets, but any composite would do). I want the first one to be 3/4 of the available space and the second one to be 1/4 of the space. This I can do by specifying the layout correctly. I also want to be able to unmanage the 2nd layout area and have the 1st one cover the whole window, and then re-manage the second widget and have the area split up in the 3-1 ratio again. If the two output widgets are simple widgets (e.g. Labels) then everything works exactly as expected. Stretching, shrinking, everything; including the mapping and unmapping of the second widget. If the output widgets are composite widgets (AtPlotter in my real app, Box has the same problem), then stretching works OK, shrinkage almost works, and unmapping/mapping fails miserably (the new window is mapped but the first one is never resized, and you have top expand the main window to uncover it.) The size of the composite subwidgets never seems to be allowed to shrink. Is this a bug in my brain or a bug in the table widget? Does anyone have a suggested workaround? Attatched is a resource file that, when run under Ari, will demonstrate the problem. Greg. -- ! ! An AD file to test table expose/resize semantics ! Ari.wcChildren: table *table.wcClassName: Table *table.wcChildren: left, middle, right, one, two *table.Layout: left 0 0 lhwHW; middle 1 0 hwHW ; right 2 0 lhwHW ; one 0 1 3 3 ; two 0 4 3 1 *left.Label: quit *left.callback: WcExitCB(0) *left.wcClassName: Command *right.Label: hide two *right.callback: WcUnmanageCB(*two) *right.wcClassName: Command *middle.Label: show two *middle.callback: WcManageCB(*two) *middle.wcClassName: Command ! ! with these definitions of one and two, it fails.... ! *one.wcClassName: Box *one.wcChildren: onelabel *onelabel.wcClassName: Label *two.wcClassName: Box *two.wcChildren: twolabel *twolabel.wcClassName: Label ! ! With simple labels for one and two it works. ! !*one.wcClassName: Label !*two.wcClassName: Label -- Gregory Bond, Burdett Buckeridge & Young Ltd, Melbourne, Australia Internet: gnb@melba.bby.oz.au non-MX: gnb%melba.bby.oz@uunet.uu.net Uucp: {uunet,pyramid,ubc-cs,ukc,mcvax,prlb2,nttlab...}!munnari!melba.bby.oz!gnb