[comp.windows.x] Help building table of text/label widgets

mdv@comtst.UUCP (Mike Verstegen) (12/11/90)

I'm trying to build a table that looks like this with about 10 rows
of a label plus three columns of data as shown below.

                 Col1Hdg    Col2Hdg    Col3Hdg
Row1Label       R1C1data   R1C2data   R1C3data
Row2Label       R2C1data   R2C2data   R2C3data
Row3Label       R3C1data   R3C2data   R3C3data
...

Note that the Row labels and column headings are of differing width
than each other and different than the width of the data.

I've tried the following approaches with varying degrees of success.

  - XmForm with each cell attached to the cell above and to the left
    using (XmLeftAttachment = XmATTACH_WIDGET, etc.). This seems to be
    too "brute force" because there are 44 cells which would take 88
    attachments. 

  - XmRowColumn using XmPACK_COLUMN but since that RowXLabel is much
    wider than the data, the table is too wide.
  
  - XmRowColumn with XmNorientation = XmVERTICAL where each item in the
    column is another XmHORIZONTAL XmRowColumn containing each row. The
    problem with this is that the columns won't line up because the
    RowXLabels are of differing width without hardcoding in the XmNwidth
    of the RowXLabels by trial and error (seems non-portable, particularly
    with respect to font changes).

This seems to be something that has been done before, and after beating
my head against the wall too long, I'll finally ask if someone has a
better solution to this problem.

Configuration: Motif 1.0, X11R3, ISC Unix 2.0.2

Thanks,
Mike
-- 
Mike Verstegen          Domain Systems, Inc           Voice +1 407 686-7911
..!uunet!comtst!mdv     5840 Corporate Way #100       Fax   +1 407 478-2542
mdv@domain.com          West Palm Beach, FL 33407