home *** CD-ROM | disk | FTP | other *** search
- Xref: sparky comp.windows.x.motif:8445 comp.windows.x.intrinsics:734
- Newsgroups: comp.windows.x.motif,comp.windows.x.intrinsics
- Path: sparky!uunet!zaphod.mps.ohio-state.edu!howland.reston.ans.net!usc!rpi!batcomputer!cornell!uw-beaver!cs.ubc.ca!unixg.ubc.ca!kakwa.ucs.ualberta.ca!scott
- From: scott@ee.ualberta.ca (Scott Stephens)
- Subject: Resizing Widgets within Code
- Message-ID: <1993Jan8.173014.23896@kakwa.ucs.ualberta.ca>
- Sender: news@kakwa.ucs.ualberta.ca
- Nntp-Posting-Host: scooter.ee.ualberta.ca
- Organization: University Of Alberta, Edmonton Canada
- Distribution: na
- Date: Fri, 8 Jan 1993 17:30:14 GMT
- Lines: 52
-
-
- I'm having trouble with some geometry management of Motif widgets. First
- let me describe the hierarchy of the widgets. I have the following.
-
- topLevelShell
- |
- v
- mainWindow
- |
- v
- panedWindow
- |
- v
- form
- |
- v
- scrolledWindow & scale separated horizontally (scrollers are
- | managed but unmapped)
- v
- drawingArea
-
- plus some menus which are unimportant to this discussion. I have chosen
- this so that the scale and scrolled window can be resized automatically
- when changing the pane sizes, with the scale acting something like a
- scroller, but not changing the viewing area, just changing a gain
- parameter. but I also want to be able to add copies of the form on down to
- the panedWindow. I also want to limit the height of the window to the size
- of the screen
-
- If I add a copy of the form on down which would exceed the height of the
- screen, I would like to be able to have the program resize all the forms
- in the panes to be roughly the same size (give or take a pixel or two).
- The new form gets added ok, and at the default height, but one of the
- other forms gets resized to XmNpaneMinimum (set at 50 pix).
-
- So here's the problem. After adding a new form, I have tried to adjust the
- sizes of each form, but this doesn't seem to resize them properly, and the
- drawingArea doesn't always get resized to match the size it should be
- within the scrolled window. I try resizing with XtMakeResizeRequest,
- followed by a second request if the result is XtGeometryAlmost (with the
- returned values of course).
-
- My question is, in what order should I make these requests, and when? I
- could probably hack it together (as I did before I had the form and scale
- in here), but I'd rather do it properly so I don' run into problems.
-
- Your help in this matter would be greatly appreciated, and thanks in
- advance to any and all who respond
-
- R. Scott Stephens
- scott@ee.ualberta.ca
-
-