01659@AECLCR.BITNET (Greg Csullog) (02/26/89)
I have been experimenting with programming using GEM calls and I ran into a problem I cannot resolve. I tried to set up a dialog box as follows: -------------------------------------- <-- Obj_Type=G_BOX Obj_Flag=NONE Obj_State=NORMAL ---------------- Click Here <-- Obj_Type=G_BOXTEXT -------------------------------------- Obj_Flag=EXIT Obj_State=NORMAL The G_BOX object is the ROOT where: Obj_Next=-1 Obj_Head=1 Obj_Tail=1 The G_BOXTEXT is the child where: Obj_Next=0 Obj_Head=-1 Obj_Tail=-1 I want to display messages within the dialog box and have the user skip to the next message by clicking on the G_BOXTEXT object. The problem I am having is that I cannot figure out the parent-child- sibling relationship of the G_TEXT objects that I will have to place within the G_BOX object. Would the new G_TEXT objects be children of G_BOX? What values for Obj_Next, Obj_Head and Obj_Tail would I use for these additional objects? HELP, I am stuck!
rjung@nunki.usc.edu (Robert allen Jung) (02/27/89)
In article <8902260313.AA04419@ucbvax.Berkeley.EDU> 01659@AECLCR.BITNET (Greg Csullog) writes: > [Dialog box diagram deleted] > >The G_BOX object is the ROOT where: > Obj_Next=-1 Obj_Head=1 Obj_Tail=1 > >The G_BOXTEXT is the child where: > Obj_Next=0 Obj_Head=-1 Obj_Tail=-1 > >I want to display messages within the dialog box and have the user >skip to the next message by clicking on the G_BOXTEXT object. The >problem I am having is that I cannot figure out the parent-child- >sibling relationship of the G_TEXT objects that I will have to >place within the G_BOX object. Would the new G_TEXT objects be >children of G_BOX? What values for Obj_Next, Obj_Head and >Obj_Tail would I use for these additional objects? HELP, I am >stuck! First piece of advice: Use a resource construction program (RCP). Building GEM resources by hand is a mind-numbing experience that's no fun for the average human being. Now, if you were to have many G_TEXT objects (strings for your messages) in your root box, they would be children of the root (since they are _inside_ the box). The G_BOXTEXT button would be another sibling to them. Basically, your object tree would look something like: Root box (G_BOX) ____________/ \_______________ | | v v First G_TEXT <--> Next G_TEXT <--:--> G_BOXTEXT string string button The numeric order doesn't really make a difference. --R.J. B-) P.S. I'm not a guru with the inner mechanics of GEM dialogs; I prefer to stay in the stratosphere of the RCP. However, I'm pretty sure of what I have up there. ============================================================================= Disclaimer: This message was written with my authorization # ## # # ## # Mailing address: rjung@nunki.usc.edu ## ## ## (It's easier to just use the reply function, tho) #### ## ####