a
/|\
/ | \
b c d
/| | \
/ | | \
e f k j
Now I am using XawTreewidget. It turns out widgets overlap each other. I
wish you would find the mistakes in my code. Those label widgets cannot
relate each other by XtNtreeParent. Those parameters will be removed
later. They are here just for debugging purpose. Here is that part of
code:
trw[0] = XtCreateManagedWidget("trw0",
treeWidgetClass,
parserform31, NULL, ZERO);
XtVaSetValues(trw[0],
XtNgravity, NorthGravity,
// XtNtreeParent, 0,//I set this paramenter on and off try
//to see if it is the problem
XtNheight, 500,
XtNwidth, 500,
XtNborderWidth, 5,
NULL);
trl[0] = XtCreateManagedWidget("BEGIN",
labelWidgetClass,
trw[0], NULL, ZERO);
XtVaSetValues(trl[0],
XtNlineWidth, 5,
XtNtreeParent, 0,
XtNheight, 50,
XtNborderWidth, 5,
XtNlabel, "S",
XtNwidth, 150,
NULL);
trl[1] = XtCreateManagedWidget("BEGIN",
labelWidgetClass,
trw[0], NULL, ZERO);
XtVaSetValues(trl[1],
XtNtreeParent, trl[0],
XtNheight, 40,
XtNborderWidth, 5,
XtNlabel, "A",
XtNwidth, 30,
NULL);
trl[2] = XtCreateManagedWidget("BEGIN",
labelWidgetClass,
trw[0], NULL, ZERO);
XtVaSetValues(trl[2],
XtNtreeParent, trl[0],
XtNheight, 20,
XtNborderWidth, 5,
XtNlabel, "B",
XtNwidth, 20,
NULL);
XtResizeWidget(form31, 345, 400, 0);
XtResizeWidget(parserform31, 3000, 3000, 5);
The result is like:
_________________________
| | | ||
| A | | B ||
| | | ||
|----- S |-----|
| |
| |
| |
________________________
There is a Xaw documentation from x.org but it does not have an example.
The resources for Xaw is inadequate. Your help is important to me. If you
feel my question is confusing or not specific enough, please let me know.
I will experss myself more carefully.
Thank you in advance.
Edwin Tsang
Internet: ed...@cs.duke.edu
--
__________________________
ed...@cs.duke.edu