Archive-name: motif-faq/part8
Last-modified: JULY 14, 1996
Posting-Frequency: monthly
Organization: Century Computing, Inc. <URL: http://www.cen.com/>
Version: 5.3


-----------------------------------------------------------------------------
Subject: 232)  Can bugs in Sun's OpenWindows server cause Motif clients to
crash?

[Last modified: Oct 95]

Answer:  Yes.  Patch 100444-73 (or later) from Sun fixes most of these bugs.
Alternatively, you can compile and run the X11R6 sample server from MIT.  See
the SunSolve web page:

        http://sunsolve1.sun.com/pub-cgi/patchpage.pl

Thanks to Ken Lee, kenton@rahul.net, with an update from Bob Cox,
rwcox@mcw.edu.

-----------------------------------------------------------------------------
Subject: 233)  Why does Motif on Linux crash when I open a file selection box?

[Last modified: Oct 95]

Answer:  Make sure you use libc version 4.6.27 or later.  Linux Motif's are
very sensitive about this.

Thanks to Ken Lee, kenton@rahul.net

-----------------------------------------------------------------------------
Subject: 234)  How can I install Motif on my PC?

[Last modified: Jan 96]

Answer:  There's a paper on this in the September issue of *The X Advisor*:
http://landru.unx.com/DD/advisor/index.shtml

        Motif Development on Your Home PC
        http://landru.unx.com/DD/advisor/docs/sep95/sep95.klee.shtml

Thanks to Ken Lee, kenton@rahul.net, http://www.rahul.net/kenton/index.shtml

-----------------------------------------------------------------------------
Subject: 235)  TOPIC: KEYSYMS

-----------------------------------------------------------------------------
Subject: 236)  What is causing the messages "unknown keysym osfDown..."?  It
happens when I run an application under Motif 1.1

Answer:  There is an OSF supplied addition to the /usr/lib/X11/XKeysymDB file.
It is found on the release tape and should have been automatically installed
if the installation procedure was followed in the Release Notes.

You have to copy (or append) lib/Xm/XKeysymDB into /usr/lib/X11.  This may
require root permission.  It is not clear how to fix the problem if you can't
do this.  The error comes from Xt translation table parsing and can't be fixed
in Motif, so if you can't get root permission you may be stuck.  The file is
not copyrighted so you can install it on other systems.

If X has been built so that XKeysymDB is not in this directory, and you don't
know where it is looking, run 'strings libX11.a | grep XKeysymDB' to find the
path.

On a Sun running openwin with shared libraries, you may need to put the path
for the library containing XKeysymDB *first* in the path list in
LD_LIBRARY_PATH, or it may find the wrong XKeysymDB in the wrong directory.

XKeysymDB simply contains the registered keysym values for the OSF keysyms.
The OSF values are server-independent.  And, all registered keysyms will be
included in an XKeysymDB file to be shipped with X11R5.

In the meantime (till all systems are X11R5+), a list of the registered
keysyms can be found in the X11R4 release in mit/doc/Registry/Xregistry.

Also note the XKEYSYMDB environment variable. Setting this to point to the
XKeysymDB file often helps, but not always...


-----------------------------------------------------------------------------
Subject: 237)  What happens if I can't install Motif Keysyms?

tessi!george@nosun.West.Sun.COM (George Mitchell) wrote:

Here's what appears to happen if you don't have XKeysymDB in place to define
OSF's virtual keysyms:

1. At class initialize time, for a widget (such as XmText) that uses virtual
keysyms in its event translation table, all entries which refer to those
keysyms fail to parse correctly.  In the case of XmText, instead of ending up
with a translation table with roughly 90 entries, you end up with one that has
29.

2. XKeysymDB doesn't exist, so you'd assume that KeyPress events will get
translated to plain vanilla keysyms, right?  WRONG!  All Motif widgets install
a virtual keysym translator ANYWAY!  Consequently, the backspace key (for
example) gets translated to the keysym osfBackSpace.

3. Therefore, if you augment or override your widget's translations with
translations that refer to plain vanilla BackSpace, they will never be
triggered, because you will NEVER see plain vanilla BackSpace, only
osfBackSpace.

4. But you can't use osfBackSpace in an event translation entry, because you
don't have XKeysymDB installed!

Here's how I'm "dealing" with the problem right now: Motif installs its
virtual keysym translator by calling XtSetKeyTranslator every time a
VendorShell (or subclass) widget is created.  So every time I create a shell,
I immediately call XtSetKeyTranslator (display, XtTranslateKey) to restore the
default translator.  No more funny virtual keysyms!  Now I can reinstall non-


                                    - 11 -


osfKeySym translations and have them work the way I expect.


-----------------------------------------------------------------------------
Subject: 238)  Why has OSF introduced Keysyms into Motif 1.1?  They weren't
there in Motif 1.0.

Answer:  ellis@osf.org wrote:

Virtual Keysyms are meant to provide a consistent keyboard model for Motif
applications running in a heterogeneous environment in which proprietary (i.e.
vendor specific) non-Motif applications may also be running.

First of all, for the sake of the rest of the readers, let's explain why this
is an issue:

It would be lovely if Motif's translation tables could just use the obvious
keysyms predefined by X.  For example, there are keysyms for XK_BackSpace,
XK_Delete, XK_Left, XK_Right, etc.  Shouldn't these be the ones that are used
in our translations?  Unfortunately, the problem is not so simple.  Some
specific examples:

   While most vendors bind XK_BackSpace to the key at the top right
   of the standard keyboard (often engraved with a leftwards
   pointing arrow), not all do.  In fact, some vendors (including DEC)
   bind that key to XK_Delete.

   While most vendors bind the arrow keys to XK_Up, etc, a number of
   vendors (including Sun, on some servers) bind them to function key
   keysyms.

A simplistic solution would require the use of xmodmap to change the offending
bindings.  That would work swell in an all Motif environment.  However, OSF's
goal (not always perfectly achieved) is interoperability.  That is, we'd like
to make sure that both Motif and non-Motif programs can happily run in the
same environment.

It is expected that a vendor may have a wide variety of existing X-based
software that uses the keysyms as established by that vendor for specific
purposes.  It is expected that these applications may run at the same time as
Motif-based software.  Using xmodmap to change keysyms on the server side
could "break" the existing applications (or at the very least their
documentation) by making some keys unavailable, or by moving the location.

So, we chose not to use xmodmap.  By the way, though OpenLook uses a different
implementation (they recompile their virtual translation tables into actual
translation tables), they basically adopted the same approach, presumably for
similar reasons.

To work properly, the virtual keysym model we implemented depends on Xlib
finding XKeysymDB installed appropriately (which standard Motif installation
does).  This simply defines the keysyms (not the key they are bound to).  This
unfortunate piece of stupidity is necessary because MIT only includes standard
keysyms in keysymdef.h.  It should be said that our lives would be made easier
if MIT would also see fit to include registered keysyms in keysymdef.h as
well.

Motif applications determine how to bind virtual to actual keys by looking for
either a resource or a property on the root window which describes what to do.
Note that this information is on the server side, so that all applications use
the same virtual bindings regardless of where they are running.  Mwm will
happily create the property if it finds a .motifbind file in your home
directory when it starts up.  (Actually, things generally work even if none of
this is done, since if all else fails, the Motif toolkit chooses a virtual
bindings table to use based on the identification of the server).

The actual implementation of virtual keys is made possible by a hook in the
Intrinsics.  Undoubtably, the implementation would be simpler and cleaner if
virtual key support was more directly supported by the Intrinsics.  We will be
exploring this possibility in the future.

  -- Ellis

-----------------------------------------------------------------------------
Subject: 239)  Why do accented characters not work with Motif applications
linked with X11R6? What is the Compose file?

[Last modified: June 95]

Answer:  Note: The list of codes below _should_ contain a backslash before
every numeric value. My FAQ maintainence tools have been stripping the
backslash.  Sorry for the confusion...ksall@cen.com.

Roman Czyborra (czyborra@cs.tu-berlin.de) writes:

I've xmodmapped a few accented characters onto my keyboard. They've worked
fine in most every window, but were dead in the Motif applications linked with
X11R6.  My LC_CTYPE has always been set to iso_8859_1, so that was not the
problem.  It turns out that I can activate the keys by patching
$XLOCALEDIR/iso8859-1/Compose to also include the lines listed below.

<nobreakspace>          : "240"
<exclamdown>            : "241"
<cent>                  : "242"
<sterling>              : "243"
<currency>              : "244"
<yen>                   : "245"
<brokenbar>             : "246"
<section>               : "247"
<diaeresis>             : "250"
<copyright>             : "251"
<ordfeminine>           : "252"
<guillemotleft>         : "253"
<notsign>               : "255"
<hyphen>                : "255"
<registered>            : "256"
<macron>                : "257"
<degree>                : "260"
<plusminus>             : "261"
<twosuperior>           : "262"
<threesuperior>         : "263"
<acute>                 : "264
<mu>                    : "265"
<paragraph>             : "266"
<periodcentered>        : "267"
<cedilla>               : "240"
<onesuperior>           : "271"
<masculine>             : "272"
<guillemotright>        : "273"
<onequarter>            : "274"
<onehalf>               : "275"
<threequarters>         : "276"
<questiondown>          : "277"
<Agrave>                : "300"
<Aacute>                : "301"
<Acircumflex>           : "302"
<Atilde>                : "303"
<Adiaeresis>            : "304"
<Aring>                 : "305"
<AE>                    : "306"
<Ccedilla>              : "307"
<Egrave>                : "310"
<Eacute>                : "311"
<Ecircumflex>           : "312"
<Ediaeresis>            : "313"
<Igrave>                : "314"
<Iacute>                : "315"
<Icircumflex>           : "316"
<Idiaeresis>            : "317"
<ETH>                   : "320"
<Ntilde>                : "321"
<Ograve>                : "322"
<Oacute>                : "323"
<Ocircumflex>           : "324"
<Otilde>                : "325"
<Odiaeresis>            : "326"
<multiply>              : "327"
<Ooblique>              : "330"
<Ugrave>                : "331"
<Uacute>                : "332"
<Ucircumflex>           : "333"
<Udiaeresis>            : "334"
<Yacute>                : "335"
<THORN>                 : "336"
<ssharp>                : "337"
<agrave>                : "340"
<aacute>                : "341"
<acircumflex>           : "342"
<atilde>                : "343"
<adiaeresis>            : "344"
<aring>                 : "345"
<ae>                    : "346"
<ccedilla>              : "347"
<egrave>                : "350"
<eacute>                : "351"
<ecircumflex>           : "352"
<ediaeresis>            : "353"
<igrave>                : "354"
<iacute>                : "355"
<icircumflex>           : "356"
<idiaeresis>            : "357"
<eth>                   : "360"
<ntilde>                : "361"
<ograve>                : "362"
<oacute>                : "363"
<ocircumflex>           : "364"
<otilde>                : "365"
<odiaeresis>            : "366"
<division>              : "367"
<oslash>                : "370"
<ugrave>                : "371"
<uacute>                : "372"
<ucircumflex>           : "373"
<udiaeresis>            : "374"
<yacute>                : "375"
<thorn>                 : "376"
<ydiaeresis>            : "377"


-----------------------------------------------------------------------------
Subject: 240)  TOPIC: UIL

[NOTE: As you can see, this is a new topic area. Send me your ideas for
answered questions pertaining to this topic.]

-----------------------------------------------------------------------------
Subject: 241)  What is UIL and why is it so popular?

[Last modified: Sept 94]

Answer:

UIL is the acronym for "User Interface Language", a Motif standard which
permits separation of the user interface from application code.  UIL is a
textual description of the user interface which is compiled into binary form
called UID ("User Interface Definition") using the Motif-provided compiler
called "uil".

It is important to realize that UIL is a static description of the UI in that
connections between buttons and the dialogs they invoke, for example, is not
expressed here; dynamic UI behavior appears in C code.

The Period Table of Widgets, called "periodic" (delivered by many Motif
vendors) is an example of a UIL application.

There are many advantages and disadvantages of UIL applications.  A few of the
advantages are:

    UIL is a standard format which encourages separation of the
    user interface from application code.

    UIL can be read and/or written by many of the GUI builders and UIMS
    tools mentioned elsewhere in this FAQ, making your interface portable
    (to a degree) across builder tools.

    UIL is a much better language than C for defining a widget
    hierarchy: in C, the widget hierarchy is expressed "linearly"
    by referencing a previously-created parent widget when creating
    a child widget; in UIL, widget trees are defined more naturally
    using nesting.

    With UIL, you separate the definition of the widget tree from
    the application.  You can make major changes to the look-and-feel
    without re-building the application.

    It is possible to write a "general-purpose" application that defines
    a library of callbacks.  The application may "execute" any UIL file
    that references callbacks from the library.


For a good UIL reference, see "Motif Programming Manual", Volume 6A, published
by O'Reilly and Associates. [See "BOOKS" for details.]

-----------------------------------------------------------------------------
Subject: 242)  What is Mrm?

[Last modified: Nov 94]

Answer:  Mrm is the "Motif Resource Manager", a set of functions (whose names
begin with Mrm, such as MrmFetchWidget and MrmRegisterNames) in libMrm.a which
retrieve the widget hierarchy from the UID file, associate callbacks, and
create the widgets.

Mrm is usually discussed in books which cover UIL.

    Motif Programming Manual, Volume 6A
    OSF/Motif Programmers Guide
    OSF/Motif Programmers Reference Manual

See the BOOKS section for detailed references.

-----------------------------------------------------------------------------
Subject: 243)  How do I specify a search path for ".uid" files?  Answer:  Use
the UIDPATH environment variable.  It is documented on the MrmOpenHierarchy()
man page.

-----------------------------------------------------------------------------
Subject: 244)  Can I specify callback functions in resource files?

Answer:  To specify callbacks, you must use UIL in addition to or in place of
resource files.  You can, however, specify translations in resource files,
which give you most of the same functionality as callback functions.

Thanks to Ken Lee, kenton@rahul.net

-----------------------------------------------------------------------------
Subject: 245)  How can I set a multiline label in UIL?

[Last modified: Sept 94]

Answer:  In UIL, you have to explicitly create a compound string with a
separator.  Here's what W. Scott Meeks suggests:

value nl : compound_string('', seperate=true);

object my_label : XmLabel
{
    arguments
    {
        XmNlabelString = 'Here' & nl & 'is' & nl & 'the' & nl & 'Label';
    };
};


-----------------------------------------------------------------------------
Subject: 246)  Is there a program that can convert a UIL file to tclMotif?  I
have an old Motif program that I used on SCO unix. Now that I switched to
Linux, I would like to "reprogram" it without the Motif libraries under Linux.

[Last modified: Aug 95]

Answer:  Jan Newmarch (jan@ise.canberra.edu.au) writes:

The latest version of tclMotif (v 1.3) will allow you to load uil files
(actually, the uid files output from the uil compiler) directly into tclMotif.
So you don't need to convert at all.

The source is available at ftp.x.org. This, plus a Linux binary are also at
ftp://ftp.canberra.edu.au/pub/motif/tclMotif (Thanks to Ben Elliston
(ben@ise.canberra.edu.au) for correcting this URL.)

-----------------------------------------------------------------------------
Subject: 247)  Why does my SCO UIL application fail to open 60 UID files?

[Last modified: Sept 95]

Answer:  Make sure that you call MrmCloseHierarchy. There is no need to keep
the file open after you fetch the widgets from it.

Thanks to Tom Schutter (tom@platte.com)

-----------------------------------------------------------------------------
Subject: 248)  TOPIC: ICONIFICATION and DE-ICONIFICATION

Iconification/de-iconification is a co-operative process between a client and
a window manager.  The relevant standards are set by ICCCM.  Mwm is ICCCM
compliant.  The toplevel (non-override-redirect) windows of an application may
be in three states: WithdrawnState (neither the window nor icon visible),
NormalState (the window visible) or IconicState (the icon window or pixmap
visible).  This information is contained in the WM_STATE property but ordinary
clients are not supposed to look at that (its values have not yet been
standardised).  Movement between the three states is standardised by ICCCM.

-----------------------------------------------------------------------------
Subject: 249)  How can I keep track of changes to iconic/normal window state?

Answer:  You can look at the WM_STATE property, but this breaks ICCCM
guidelines.  ICCCM compliant window managers will map windows in changing them
to normal state and unmap them in changing them to iconic state. Look for
StructureNotify events and check the event type:

        XtAddEventHandler (toplevel_widget,
                        StructureNotifyMask,
                        False,
                        StateWatcher,
                        (Opaque) NULL);
        ....
        void StateWatcher (w, unused, event)
        Widget w;
        caddr_t unused;
        XEvent *event;
        {
                if (event->type == MapNotify)
                        printf ("normal\n");
                else if (event->type == UnmapNotify)
                        printf ("iconified\n");
                else    printf ("other event\n");
        }


If you insist on looking at WM_STATE, here is some code (from Ken Sall) to do
it:

        /*
        ------------------------------------------------------------------
        Try a function such as CheckWinMgrState below which returns one of
        IconicState | NormalState | WithdrawnState | NULL :
        ------------------------------------------------------------------
        */
        #define WM_STATE_ELEMENTS 1

        unsigned long *CheckWinMgrState (dpy, window)
        Display *dpy;
        Window window;
        {
          unsigned long *property = NULL;
          unsigned long nitems;
          unsigned long leftover;
          Atom xa_WM_STATE, actual_type;
          int actual_format;
          int status;

            xa_WM_STATE = XInternAtom (dpy, "WM_STATE", False);

            status = XGetWindowProperty (dpy, window,
                          xa_WM_STATE, 0L, WM_STATE_ELEMENTS,
                          False, xa_WM_STATE, &actual_type, &actual_format,
                          &nitems, &leftover, (unsigned char **)&property);

            if ( ! ((status == Success) &&
                        (actual_type == xa_WM_STATE) &&
                        (nitems == WM_STATE_ELEMENTS)))
                {
                if (property)
                    {
                    XFree ((char *)property);
                    property = NULL;
                    }
                }
            return (property);
        } /* end CheckWinMgrState */


One problem with testing WM_STATE is that a race condition is possible;
immediately after testing it, it could change, and the logic proceeds to
behave as if it were in the old state.

-----------------------------------------------------------------------------
Subject: 250)  How can I check if my application has come up iconic?  I want
to delay initialization code and other processing.

Answer:  Use XtGetValues and check for the XmNinitialState value of the
toplevel shell just before XtMainLoop. -- IconicState is iconic, NormalState
is not iconic.


-----------------------------------------------------------------------------
Subject: 251)  How can I start my application in iconic state?

Answer:  Try this from the command line:

        application -iconic

Using the resource mechanism, set the resource XmNinitialState to IconicState
of the toplevel shell widget (the one returned from XtInitialise).

-----------------------------------------------------------------------------
Subject: 252)  How can an application iconify itself?

Answer:  In R4 and later, use the call XIconifyWindow. Ken Lee
(kenton@rahul.net) adds "Set XmNiconic on your shell.  This should work in
X11R6 and later patch levels of X11R5."

For R3, send an event to the root window with a type of WM_CHANGE_STATE and
data IconicState.

        void
        IconifyMe (dpy, win)
        Display *dpy;
        Window win;     /* toplevel window to iconify */
        {
                Atom xa_WM_CHANGE_STATE;
                XClientMessageEvent ev;

                xa_WM_CHANGE_STATE = XInternAtom (dpy,
                                        "WM_CHANGE_STATE", False);

                ev.type = ClientMessage;
                ev.display = dpy;
                ev.message_type = xa_WM_CHANGE_STATE;
                ev.format = 32;
                ev.data.l[0] = IconicState;
                ev.window = win;

                XSendEvent (dpy,
                        RootWindow (dpy, DefaultScreen(dpy)),
                        True,
                        (SubstructureRedirectMask | SubstructureNotifyMask),
                        &ev);
                XFlush (dpy);
        }


-----------------------------------------------------------------------------
Subject: 253)  How can an application de-iconify itself?

Answer:  XMapWindow (XtDisplay (toplevel_widget), XtWindow (toplevel_widget)).

-----------------------------------------------------------------------------
Subject: 254)  Why doesn't MWM display an iconify button on my dialog windows?

[Last modified: May 95]

Answer:  MWM (and some other window managers) does not allow transient windows
to be iconified.  Transients are automatically unmapped when the main shell is
iconified and they are re-mapped when the main shell is restored.  If you do
not want this transient behavior, you should use top a TopLevelShell widget
instead of a XmDialogShell widget for your windows.

Thanks to Ken Lee, kenton@rahul.net

-----------------------------------------------------------------------------
Subject: 255)  TOPIC: SPECIALIZED WIDGETS

[Last modified: Jan 95]

This section describes a few specialized widgets people have asked about.  A
_far_ more comprehensive illustrated list is maintained by John L. Cwikla
(cwikla@wri.com).  His list covers these widget categories:

        Complete Listing
        Composite Widgets
        Non-Composite Widgets
        Motif 1.1 Compatible
        Motif 1.2 Compatible
        Athena Compatible
        FWF Widget Set
        By Author
        Shareware Widgets
        Commercial Widgets

For John L. Cwikla's Widget FAQ Home Page, WWW users should see:

        http://www.wri.com/~cwikla/widget.html

The Widget FAQ is also available in ASCII as:

        ftp://ftp.x.org/contrib/faqs/Widget.FAQ.Z

The Widget FAQ contains a listing of widgets:

        http://www.wri.com/~cwikla/cats/listing.html

If you don't have access to the World Wide Web, Cwikla's Widget FAQ (sans
pictures) can be obtained from ftp.x.org:

        /contrib/faqs/Widget.FAQ.Z


-----------------------------------------------------------------------------
Subject: 256)  Where can I get a Table widget? Matrix widget? Spreadsheet
widget?

[Last modified: June 95]

Answer:  XRT/table from KL Group allows you to easily display and manipulate
tables and forms in Motif applications. Every feature of the table is
accessible through standard resources. It also supports UIL and C++ interfaces
and can be easily integrated into popular GUI builder tools. It supports
compound strings, widgets in cells, images in cells, spanned cells, PostScript
output and efficient handling of large tables. For more information email
info@klg.com or visit http://www.klg.com/ or contact KL Group Inc., 260 King
Street East, Third floor, Toronto, Ontario Canada M5A 1K3. Phone (800)663-4723
or (416)594-1026.


Microline Software sells a widget library which includes a Grid widget.
Unlike other tabular widgets, keyboard traversal is intuitive using the arrow
keys, PageUp, PageDown, etc. It includes advanced features such as cell
spanning, pixmap images in cells, cut/paste, drag/drop (with Motif 1.2), fixed
columns on the top, bottom, left and right, a number of selection policies
(browse, single-row, multiple-row, cell, etc), interactive row and column
sizing, etc. See URL http://www.mlsoft.com for more details and to download
demos. (Microline URL change: July 1995)

In the Xbae README, Andrew Wason (aw@bae.bellcore.com) writes:  XbaeMatrix is
a Motif widget which presents an editable array of string data to the user in
a scrollable table similar to a spreadsheet. The rows and columns of the
Matrix may optionally be labeled. Also, a number of "fixed" leading rows or
columns may be specified - these behave similarly to the labels. While
XbaeMatrix looks and acts like a grid of XmTextField widgets, it actually
contains only one XmTextField.  This means that XbaeMatrix widgets with
hundreds or thousands of rows have much less overhead than they would if they
used an XmTextField for each cell. XbaeMatrix has callbacks for doing field
validation and customizing traversal. It allows cells to be assigned
independent colors.  It allows rows, columns and regions of cells to be
selected (highlighted).  The matrix can be dynamically grown or shrunk by
adding and deleting rows and columns at any position.

For Xbae code and documentation via ftp, see the various files
ftp.x.org:/contrib/widgets/motif/Xbae-*.  Or from the URL:
ftp://ftp.x.org/contrib/widgets/motif/ , get xbae.tgz and Xbae-3.8-*.

Kee Hinckley (nazgul@utopia.com) recently informed this FAQ maintainer that he
will put the Table widget on ftp at ftp.utopia.com _approximately_ at the end
of September or early October, 1994. He is in the process of addressing some
issues concerning Motif 1.2 and higher with respect to the Table widget.  The
Widget Creation Library (Wcl) also has a version of the Table widget.

Expert Database Systems, Inc., 377 Rector Place, Suite 3L New York, NY 10280.
Phone: (212) 783-6981

has a very comprehensive table widget that uses both Motif scrollbars or a
"virtual" scrollbar showing a miniature version of the entire spreadsheet.
Allows for different width columns, changing colors in each cell.  Only one
X-Window is used so as to reduce the amount of system resources used.  Contact
Ken Jones email:  ken@mr_magoo.sbi.com)

-----------------------------------------------------------------------------
Subject: 257)  Where can I get a bar graph widget?

[Last modified: June 95]

Answer:  You can fake one by using for each bar a scroll bar or even a label
which changes in size, put inside a container of some kind.

Try the StripChart widget in the Athena widget set. Set the XtNupdate resource
to 0 to keep it from automatically updating.

The comp.windows.x FAQ mentions a bar graph widget.

Expert Database Systems, Inc.  sells a bar graph widget as well as a multi-
line graph with automatic scaling, a 3-D surface graph, and a high/Low graph
with two lines for moving averages.  Contact Ken Jones Expert Database
Systems, Inc., 377 Rector Place, Suite 3L New York, NY 10280.  Phone: (212)
783-6981


The Xtra XWidget library by Graphical Software Technology is no longer
available (as of May, 1995).


KL Group sells two graphing widgets which both do bar charts. Greg Kiessling
of KL Group writes:

XRT/graph displays 2-D data in virtually any type of bar chart, X-Y plot, pie
chart, area graph, financial graph or logarithmic scientific chart.  It has
over 200 resources to fine-tune the graph's appearance and behavior.  Other
features include fast-updates, text areas, 3D-look on bars and pies, time-
axis, user-interaction hooks and a graph builder tool.

XRT/3d displays 3-D data in surface plots, contour graphs and bar charts. It
has over 140 resources, and will automatically contour and zone 3-D data using
custom or default distribution tables. Users can automatically rotate, zoom
and scale views. Other features include 4-D graphs, projections, histograms,
text areas and user-interaction hooks.

Both XRT/graph and XRT/3d can be programmed using resources, UIL and C++.
They are easily integrated into popular GUI Builder tools. They both support
PostScript output. There are no run-time, distribution or royalty fees for
distributing end-user applications. For more information email info@klg.com or
visit http://www.klg.com/ or contact KL Group Inc., 260 King Street East,
Third floor, Toronto Ontario Canada M5A 1K3. Phone (800)663-4723 or (416)594-
1026.


The product Xmath, made by Integrated Systems Inc. is a product which has
interactive 2d and 3d graphics for bar,strip,line,symbol,
surface,contour,etc...also has complete numerics capabilities, an easy to use
debugger, a complete high level language, a spreadsheet, a motif gui access
capability, and much more all created on top of motif.

You can either email to xmath-info@isi.com or call (408)980-1500.

Digital Equipment Corporation (DEC) provides the following product NetEd: "The
network editor widget is a Motif toolkit conforming widget that applications
can use to express complex interrelationships graphically in the form of
networks or graphs. The network editor supports interactive or application-
controlled creation and editing of directed graphs or networks."


ACE/gr is an X based XY plotting tool implemented with a point 'n click
paradigm.  A few of its features are:

   * Plots up to 10 graphs with 30 data sets per graph.
   * Data read from files and/or pipes.
   * Graph types XY, log-linear, linear-log, log-log, bar,
        stacked bar charts.

it is available from

        ftp.ccalmr.ogi.edu (presently amb4.ccalmr.ogi.edu)

with IP address 129.95.72.34. The XView version (xvgr) will be found in
/CCALMR/pub/acegr/xvgr-2.09.tar.Z and the Motif version (xmgr) in
/CCALMR/pub/acegr/xmgr-2.09.tar.Z.  Comments, suggestions, bug reports to
pturner@amb4.ccalmr.ogi.edu (if mail fails, try pturner@ese.ogi.edu). Due to
time constraints, replies will be few and far between.

Caterpillar, Inc. sells the ENGOTS (Engineering Graphic Object Tool Set)
widget set for Motif.  The library includes interactive plotting, built in
units conversion, copy-cut-past, postscript output, ... :


    XY/contour Plot (configurable to Bar plots)
    XY/contour Strip Charts
    Polar Plot
    Custom Interactive Drawing (using provided Drawing Package)
    float/int data entry (Motif Text "Look and Feel") with range checking


Contact Paul Mauschbaugh, Caterpillar, Inc. at 309-578-4084 (mush@cat.com) for
more information.

-----------------------------------------------------------------------------
Subject: 258)  Is there a graph widget in which you can add vertices and edges
and get automatic updating?

[Last modified: March 93]

Answer:  The XUG FAQ in comp.windows.x includes information on graph display
widgets.  There is also an implementation in the Asente/Swick book.

  From Martin Janzen: "You could have a look at DataViews, from V.I.
   Corporation.  This package is used mainly to display a variety of graph
   drawings (eg. bar, line, pie, high/low, and other charts), and to update
   the graphs as information is received from "data sources" such as files,
   processes (through pipes), or devices.

   However, it also provides "node" and "edge" objects which can be used
   when working with network graphs.  The DV-Tools function library
   provides routines which traverse a graph, count visits to each node or
   edge, mark nodes or edges of interest, and so on.  A node or edge object
   can have an associated "geometry object" (such as a symbol or a line),
   which represents that node or edge.

   Drawbacks: There's no automatic positioning algorithm; when you add a
   node or edge, you have to create and position its geometry object
   yourself.  Also, this isn't a set of add-on widgets; you can either have
   DataViews create an X window (ie. a separate shell), or you can create
   your own XmDrawingArea and use DataViews to update its window when
   expose events are received.  Finally, the package is quite expensive,
   and there is a run-time charge.

   The vendor's address is:
     V.I. Corporation,
     47 Pleasant Street,
     Northampton, MA  01060,
            Email: vi@vicorp.com, Phone: (413) 586-4144, Fax:   (413) 584-2649

   or

     V.I. Corporation (Europe) Ltd.,
     First Base, Beacontree Plaza,
     Gillette Way,                      Email: viesales@eurovi.uucp
     Reading, Berkshire  RG2 0BP"
   Phone: +44 734 756010,      Fax:   +44 734 756104

Craig Timmerman wrote:  Just wanted others to know that there is a third
competitor in what may be come a big market for generic APIs.  The product is
called Open Interface and Neuron Data is the vendor.  Neuron has added some
extra, more complex widgets to their set.  The two most notable are a table
and network widget.  [...]  I believe that the network widget got its name
from its ability to display expert system networks that Neuron's AI tools
needed.  It would be more aptly named the graph widget.  It can display and
manipulate graphs of various types (trees, directed graphs, etc).  Contact is

        Neuron Data
        156 University Avenue
        Palo Alto,  CA  94301
        (415) 321-4488


prism!gt3273b@gatech.edu  (RENALDS,ANDREW THEODORE) posted a set of public
domain routines for graph drawing.  Contact him for a later set.

Ramon Santiago (santiago@fgssu1.fgs.slb.com) wrote:  HP has released source
code for XmGraph and XmArc, part of the InterWorks library, which does exactly
this. The sources can be obtained by contacting Dave Shaw,
librarian@iworks.ecn.uiowa.edu. A few trivial source code changes need to be
made to get these widgets to compile under Motif 1.2.

Free DAG - directed acyclic graph drawing software in motif environment is
available. Please send a note to address below if you want it:

Budak Arpinar, TUBITAK Software Research & Development Center, Ankara,
TURKIYE, E-mail : C51881@TRMETU.BITNET


-----------------------------------------------------------------------------
Subject: 259)* Is there a help system or Motif hypertext system available?

[Last modified: July 96]

Answer:  There are many hypertext-like help systems.

Eric.Ayers@compgen.com writes:  Computer Generation Incorporated's  HView
widget displays HTML 2.0 standard text and images and HTML 3.0 tables. The
widget was developed to provide an imbedded on-line help facility. It offers a
light weight, portable, and robust browser for HTML documents without having
to distribute a separate Web Browser with your applications. A special feature
allows links from HTML source files into arbitrary text files.

        http://www.compgen.com/widgets/
        Computer Generation Incorporated
        Building G, 4th Floor
        5775 Peachtree Dunwoody Road
        Atlanta, Georgia 30342 USA
        +1 404 705 2800
        Fax: +1 404 705 2805

Other help systems include:

Libhelp:  http://vasarely.informatik.uni-stuttgart.de/software/libhelp.html

Libhelp is a comprehensive hypertext help system library for OSF/Motif(tm)
applications. It adds a help browser window to OSF/Motif(tm) applications
which can be accessed by a single interface function. It is suitable for menu
help and context sensitive help. Also it can run as a standalone application
(xmhelp).

Libhelp documents can be written in HTML (HyperText Markup Language) and can
have hypertext links, different fonts, inlined images and a lot of more
elements known from www (world wide web) browsers. Libhelp implements its own
history, index, caching and search path schemes.

Libhelp is a derivative work of NCSA Mosaic(tm) and not the original NCSA
Mosaic(tm) distributed by the University of Illinois and is available for
academic and individual use only. It is NOT available for commercial use.

Thanks to Matthew M. Freedman (mattf@cac.washington.edu) for the libhelp
pointer.


HTML Widget from NCSA:

The NCSA Mosaic for X package contains an HTML widget which is freely
available and is the main vehicle for viewing HTML documents in the Mosaic
program. It has callbacks for anchor hits, selections, etc and many many
resources for customizing the viewing area of your hypertext documents.  See
"Where can I get the HTML widget" above.

GWHIS:

There is a product from Quadralay Corporation, called the Global-Wide Help &
Information Systems (GWHIS).

from a press release:  AUSTIN, TX (March 3, 1994) Quadralay Corporation today
announced its newest software development tool, Global Wide Help & Information
System (GWHIS).  GWHIS allows third party application developers to add online
documentation and context sensitive help to their applications like never
before.  This documentation may consist of plain text, rich format text,
hypertext, images, audio, and/or video animation and may easily be distributed
either locally or over a wide area network such as the Internet.

GWHIS consists of two primary components.  An application programming
interface (API), and a hypermedia viewer (based on technology licensed from
the NCSA Mosaic project).  Several ancillary conversion programs are also
available allowing end users to easily convert existing documentation into
GWHIS' native HTML format.

GWHIS is available on the following platforms: SPARC SunOS 4.1.x, SPARC
Solaris 2.x, INTEL SCO Open Desktop, INTEL Solaris 2.x, HP 9000/700, and the
RS/6000. Support for additional platforms (including MS Windows and Macintosh)
is under consideration.  Fully functional evaluation copies of this software
are available upon request or via anonymous ftp from ftp.quadralay.com.

Brian Combs Quadralay Corporation combs@quadralay.com


Bristol Technology have a hypertext system HyperHelp with the look-and-feel of
Motif.  HyperHelp 4.0 is available now and includes support for MIF, RTF (Word
6.0) and SGML.  (The OpenLook look-and-feel is no longer supported).

        Bristol Technology, Inc.
        241 Ethan Allen Highway
        Ridgefield, CT  06877
        (203) 438-6969 (phone)
        (203) 438-5013 (fax)
        info@bristol.com

Demos are available by anonymous ftp from ftp.bristol.com (192.246.192.2) in
/pub/Demos/HyperHelp.

There was a posting of a motif hypertext-widget to comp.sources.x (Author:
B.Raoult ( mab@ecmwf.int ) ).  It had the facility to read in helptext from a
file.

Francois Felix Ingrand (felix@idefix.laas.fr) wrote:  I have translated the
Info AW (originally written by Jordan Hubbard) to Motif. It is a Widget to
browse Info files (format used by GNU for their various documentations). I use
it as the help system of various tool I wrote. The corrected URL, thanks to
Hal DeVore (hdevore@erehwon.bmc.com), is:

        ftp://ftp.laas.fr/pub/ria/felix/prs/xinfo-motif.tar.gz


Form Scott Raney (raney@metacard.com) MetaCard is a commercial package that
can be used to implement hypertext help.  The text fields support multiple
typefaces, sizes, styles, colors, subscript/superscript, and hypertext links.
It has a Motif interface, and a template for calling it from an Xt/Motif
application is included.  You can FTP a save-disabled distribution from
ftp.metacard.com or from world.std.com.  For more info, email to
info@metacard.com.


The Motifation GbR also provides a hypertext-helpsystem named 'XpgHelp'.
(Motif look-and-feel / features like those known from MS Windows Help )
Information about XpgHelp and a free demo version can be obtained via:
http://www.uni-paderborn.de/fachbereich/AG/szwillus/xpghelp/index.html

XpgHelp is distributed by:

           Motifation GbR
           Geroldstrasse 38
           33098 Paderborn
           Germany
           +49 (0) 5251 25633 (phone)
           email: griebel@uni-paderborn.de


XpgHelp has nearly the same features like HyperHelp: (multiple fonts, graphics
in b&w and color, different styles, tabs, links, short links, notepad, ...)


                                    - 12 -


The Interface Builder MOTIFATION uses XpgHelp as its hypertext helpsystem.

-----------------------------------------------------------------------------
Subject: 260)  Is there a canvas widget or drawing widget for graphical
display?

[Last modified: Jan 96]

Answer:  Groupe Bull - Koala Project has a Motif Canvas [Knvas] Widget.  This
widget is intended to provide graphical display (lines, rectangles, icons,...)
and direct manipulation services (select, move, resize,...) for Xt based
applications. This widget is intended to be include in a MOTIF application,
but you can generate an Athena widget (though demos are only using MOTIF). The
widget is shipped with an objects library based on a C object oriented model
called KLONE (use of the Xt object model would dramaticaly increase
application load time and KLONE provides garbage collection).  Features:

- uses an improved C small object-oriented model (garbage col. + polymorphism)
- multi-view: an object may be shared between two views (canvases)
- Multi-display: two views may be on different displays / screens
- double buffering for smooth animations
- easy to use "just know how to use widgets"
- small objects
- garbage collection
- Tag object to define graphical object appearance
- define tag's attributes with Xt resources
- dispatch mechanism uses Xt -> you can set Xt translations on a graphic obj
- Interactor objects to define a complete behavior
- unlimited Zoom / Unzoom
- classes: Line, Rect, Filled rect, Xpm Icon, Group, Ellipse, Anchor, Link
- mouse interactors: select, move, resize

More info available at:

        http://www.inria.fr/koala/jml/widgets/knvas.html
        ftp://avahi.inria.fr/pub/widgets/knvas-1.13.2.tar.gz

Requirements: MOTIF, XPM

Thanks to Jean-Michel.Leon@sophia.inria.fr.  Thanks to Joachim Fabini
(jo@vmars.tuwien.ac.at) for updating me on the name change from "canvas" to
"knvas" and the version change.

-----------------------------------------------------------------------------
Subject: 261)  How can I create a transparent widget?

[Last modified: June 95]

Answer:  The simplest way is probably to use the SHAPE protocol extension.
The xeyes, xlogo, and oclock demo programs in X11R5 (and later) are good
examples of using SHAPE with widgets. You should be able to use the same
techniques with your Motif widget subclasses.

Thanks to Ken Lee, kenton@rahul.net

Ken Sall (ksall@cen.com) adds: The official name for this extension is "X11
Nonrectangular Window Shape Extension". If you have X11R5 source, the Shape
extension document is $TOP/mit/hardcopy/extensions/shape.PS or
$TOP/mit/doc/extensions/shape.ms. In X11R6, see
$TOP/xc/doc/hardcopy/Xext/shape.PS or $TOP/xc/doc/specs/Xext/shape.ms.  There
is also a terse man page: $TOP/mit/man/Xext/XShape.man (X11R5) and
$TOP/xc/doc/man/Xext/XShape.man (X11R6).

-----------------------------------------------------------------------------
Subject: 262)  TOPIC: CREATING WIDGETS

[This section is for widget writers.]

-----------------------------------------------------------------------------
Subject: 263)  What are some good references for creating widgets (subclassing
widgets)?

[Last modified: Feb 95]

Answer:  Ken Sall (ksall@cen.com) writes:

If you have Motif 2.0, see the new document provided by OSF called "OSF/Motif
Widget Writer's Guide" in the directory:  doc/widgetGuide/Output/draft/ps.

If you have Motif 1.*, try these references (details in the BOOKS topic):

    Asente, Paul J., and Swick, Ralph R.,
    X Window System Toolkit, The Complete Programmer's Guide and Specification.

    Nye, Adrian & O'Reilly, Tim,
    X Toolkit Intrinsics Programming Manual.Motif Edition, Volume 4M

    Flanagan, David, Editor,
    X Toolkit Intrinsics Reference Manual, Volume 5


Alex Fridman (alex@genlogic.com) writes:

For graphical widgets, you may try the Generic Logic Toolkit (GLG Widgets). It
allows custom graphical widgets (such as Graphs and Controls) to be created
interactively from the supplied templates using the GLG 3D Graphical Editor. A
Demo is available by ftp from:

   ftp://ftp.netcom.com/pub/glg/

David Suller of Generic Logic, Inc. adds:

When used in an application, a GLG Widget may be animated with real-time data
via the resource mechanism or used as a graphical server receiving and
displaying data from several local or remote processes using the built-in
Inter-Client Communication Server.

David Suller                  phone:  (617)254-4153
Generic Logic, Inc.           FAX:    (617) 254-2746
P.O. Box 35606                email:  glg@genlogic.com
Brighton, MA 02135-0006       ftp:    ftp.netcom.com:/pub/glg/


joe shelby (jshelby@autometric.com) writes:

Alastair Gourlay (alastair.gourlay@eng.sun.com), a member of the technical
staff at Sun Microsystems and a former member of the Motif Development group
at OSF, has written 2 articles for _The X Resource_, published by O'Reilly and
Associates.

The first, "Writing Motif Widgets : A Pragmatic Approach" can be found in
Issue 6.  It covers writing a XmPrimitive-derived widget, deriving from that
widget, and writing a XmManager-derived widget.  Also included are brief
summaries of several _Xm private functions for widget writers, how to use the
Motif 1.2 Representation Type functions, and adding the widgets to Mrm/Uil.

The second, "The One-Minute Manager : Custom Motif Layout Widgets Made Easy"
can be found in Issue 10.  It expands and greatly simplifies creating
composite widgets for Motif.  Gourlay has created and released a new widget,
the XmpGeometry widget that handles all of the geometry management issues for
you and provides convenience functions for determiningparent and child
widgets' perfered sizes.  All the programmer has to do to derive from this
widget is create the new resources and constraints and implement 2 new class
methods to override the XmpGeometry's methods.  Included with the XmpGeometry
class are 3 example derived widgets.

The code for these widgets is available at

ftp://ftp.uu.net/published/oreilly/xresource/issue6/Subclassing.tar.Z
ftp://ftp.uu.net/published/oreilly/xresource/issue10/OneMinuteManagers.tar.Z

Donald L. McMinds and Joseph P. Whitty have written a book, _Writing Your Own
OSF/Motif Widgets_, published by Prentice Hall for Hewlett-Packard
Professional Books.  Both authors work at HP's Workstation Systems Division,
and have been involved with Motif developement since its beginnings.  The book
(which is mostly code with explanations) gives details on writing
XmPrimitive-derived, XmManager-derived, and XmGadget-derived widgets, with one
example widget for each.  In addition, the book provides "man-pages" for
several _Xm private functions for programmer convenience.

The code for these widgets is available at

        ftp://hpcvaal.cv.hp.com/readonly/book_files/wr_widgets.tar.Z

-----------------------------------------------------------------------------
Subject: 264)+ How can I achieve binary compatibility using the
XmResolvePartOffset API?

[Last modified: July 96]

Answer:  Daniel Dardailler (daniel@x.org) recently provided the following URL:

        http://www.x.org/people/daniel/xmresolve
        Achieving Binary Compatibility using the XmResolvePartOffset API

which addresses the problem caused by the fact that many widget writers "never
used the XmResolvePartOffsets API in their subclass code, therefore ensuring
it will break when dynamically relinked with newer version of libXm".

-----------------------------------------------------------------------------
Subject: 265)  TOPIC: MISCELLANEOUS

-----------------------------------------------------------------------------
Subject: 266)  How can an application be informed of signals?

[Last modified: Mar 96]

Answer:  The answer differs depending on whether you're using X11R5 or X11R6.
For those using X11R6, Ken Lee (kenton@rahul.net) writes:  In X11R6, the Xt
library has the new XtAppAddSignal() function. Ken Lee's December, 1995 *The X
Advisor* column has an example:

    http://www.unx.com/DD/advisor/docs/dec95/dec95.klee.shtml

For those using X11R5, these older responses apply:

blackman@hodgkin.med.upenn.edu (David Blackman) writes:

According to comp.windows.x FAQ, you shouldn't make Xt/Xlib calls from a Unix
signal handler:

    "You can work around the problem by setting a flag in the
    interrupt handler and later checking it with a work procedure
    or a timer event which has previously been added."

Kaleb KEITHLEY (fedora.x.org!kaleb) adds:

Xt is not reentrant and it is not safe to call any Xt functions from a signal
handler...  I think [the signaling] technique is covered in the [X] FAQ. On
most POSIX-type systems write(2) is guaranteed to be reentrant and atomic. If
you establish a simple pipe with the pipe(2) system call, and add it as an
XtInput with XtAppAddInput(), then you can write to the pipe in the signal
handler. Xt will notice that input is available and call the input-handler
proc. This technique is inherently better than setting the flag because the
write to the pipe will result in XtAppNextEvent returning immediately without
the latency you observe in using the flag technique.  In R6 you can use the
XtAppAddSignal function.

Ken Sall (ksall@cen.com) adds:  See the "Signal Handling" chapter of "Motif
Programming Manual" by Heller and Ferguson, listed in the BOOKS topic.

Paul Davey (pd@uit.co.uk) adds:  The write and XtAppAddInput input method is
often the best - but be warned it does not work on some SVR3 based Unixes,
where a pipe may not be selected on. SCO Unix exhibits this behaviour so here
the external flag method should be used.

-----------------------------------------------------------------------------
Subject: 267)  How do I control the repeat rate on a SUN keyboard?

Answer:

     [...]

     -ar1 milliseconds
             This option specifies amount of time in milliseconds
             before   which   a   pressed  key  should  begin  to
             autorepeat.

     -ar2 milliseconds
             This option specifies the interval  in  milliseconds
             between autorepeats of pressed keys.

Of course this presumes you're using a server based on the MIT sample server.

Thanks to kaleb@x.org (Kaleb Keithley)

-----------------------------------------------------------------------------
Subject: 268)  How can I identify the children of a manager widget?

Answer:  Use XtGetValues() on XmNchildren (array of widget IDs) and
XmNnumChildren (number of widgets in array).

-----------------------------------------------------------------------------
Subject: 269)  What functions can an application use to change the size or
position of a widget?

Answer:  Applications should set the values of the XmNx, XmNy, XmNwidth, and
XmNheight resources.

Note that many manager widgets ignore the XmNx and XmNy resources of their
children, relying instead on their internal layout algorithms.  If you really
want specific positions, you must use a manager widget that allows them, e.g.,
XmBulletinBoard.

Also note that some manager widgets reject size change requests from their
children when certain resources are set (e.g., XmNresizable on XmForm).
Others allow the the children to resize, but clip the results (e.g.,
XmNallowShellResize on shell widgets).  Make sure you have these resources set
to the policy you want.

Due to bugs, some widgets (third party widgets) do not respond to changes in
their width and height.  Sometimes, you can get them to respond correctly by
unmanaging them, setting the resources, then managing them again.

Under no circumstances should applications use routines like
XtConfigureWidget() or XtResizeWidget().  These routines are reserved for
widget internals and will seriously confuse many widgets.

Thanks to Ken Lee, kenton@rahul.net

-----------------------------------------------------------------------------
Subject: 270)  What widgets give the look of push buttons, but behavior of
toggle buttons?

Answer:  Use the XmToggleButton widget, setting XmNindicatorOn to False and
XmNshadowThickness to 2.

Thanks to Ken Lee, kenton@rahul.net

Also set XmNfillOnSelect to True. Otherwise, the background color of the
button will not stay in the "armed" state.

thanks to Glenn McMillen, mcmillen@meadow.mdso.vf.ge.com

In Motif 1.2 (and later), if you specify a XmNselectColor and set
XmNindicatorOn to False, then you need to set XmNfillOnSelect to True.
XmNfillOnSelect is not necessary if you are not setting a XmNselectColor.

Thanks to Ken Lee, kenton@rahul.net

-----------------------------------------------------------------------------
Subject: 271)  Can I use XtAddTimeOut, XtAddWorkProc, and XtAddInput with
XtAppMainLoop?

Answer:  On many systems, the obsolete XtAdd*() functions are not compatible
with the XtAppMainLoop().  Instead, you should use newer XtAppAddTimeOut(),
XtAppAddWorkProc(), and XtAppAddInput() functions with XtAppMainLoop()

Thanks to Ken Lee, kenton@rahul.net

-----------------------------------------------------------------------------
Subject: 272)  Why does XtGetValues for XmNx and XmNwidth return extremely
large values?

Answer:  You must use the 16 bit "Dimension" and "Position" data types for
your arguments.  If you use 32 bit integers, some implementations will fill
the remaining 16 bits with invalid data, causing incorrect return values.  The
*Motif Programmer's Manual* and the widget man pages specify the correct data
type for each resource.

Thanks to Ken Lee, kenton@rahul.net

-----------------------------------------------------------------------------
Subject: 273)  Can I use XmGetPixmap() with widgets that have non-default
visual types?

Answer:  XmGetPixmap() assumes that you are using the default screen depth.
If you're using a different depth, use XmGetPixmapByDepth() instead.

Thanks to Ken Lee, kenton@rahul.net

-----------------------------------------------------------------------------
Subject: 274)  How can I determine the item selected in a option menu or a
RadioBox?

Answer:  The value of the XmNmenuHistory resource of the XmRowColumn parent is
the widget ID of the last selected item.  It works the same way for all menus
and radio boxes.

Thanks to Ken Lee, kenton@rahul.net

-----------------------------------------------------------------------------
Subject: 275)  What is the matter with Frame in Motif 1.2?

[Last modified: November 92]

Answer:  This announcement has been made by OSF:

"IMPORTANT NOTICE

We have discovered two problems in the new 1.2 child alignment resources in
XmFrame. Because some vendors may have committed, or are soon to commit to
field releases of Motif 1.2 and 1.2.1, OSF's options for fixing them are
limited. We are trying to deal with these in a way that does not cause
hardship for application developers who will develop applications against
various point versions of Motif. OSF's future actions for correction are
summarized.

WHAT YOU SHOULD DO AND KNOW

1. Mark the following change in your documentation.

On page 1-512 of the OSF/Motif Programmer's Reference, change the descriptions
under XmNchildVerticalAlignment as follows (what follows is the CORRECT
wording to match the current implementation):

XmALIGNMENT_WIDGET_TOP
        Causes the BOTTOM edge of the title area to align
        vertically with the top shadow of the Frame.

XmALIGNMENT_WIDGET_BOTTOM
        Causes the TOP edge of the title area to align
        vertically with the top shadow of the Frame.

2. Note the following limitation on resource converters for Motif 1.2 and
1.2.1 implementations.

The rep types for XmFrame's XmNentryVerticalAlignment resource were
incorrected implemented, which means that converters will not work properly.
The following resource settings will not work from a resource file in 1.2 and
1.2.1:

        *childVerticalAlignment: alignment_baseline_bottom
        *childVerticalAlignment: alignment_baseline_top
        *childVerticalAlignment: alignment_widget_bottom
        *childVerticalAlignment: alignment_widget_top

If you wish to set these values for these resources (note they are new
constraint resources in XmFrame) you will have to set them directly in C or
via uil.

WHAT WE WILL DO

The problem described in note #1 above will not be fixed in the OSF/Motif
implementation until the next MAJOR release of Motif.  At that time we will
correct the documentation and modify the code to match those new descriptions,
but we will preserve the existing enumerated values and their behavior for
backward compatibility for that release.

The fix for the problem described in note #2 will be shipped by OSF in Motif
1.2.2.

SUMMARY

We are sorry for any difficulty this causes Motif users.  If you have any
questions or flames (I suppose I deserve it) please send them directly to me.
We sincerely hope this proactive response is better for our customers than you
having to figure it out yourselves!

Libby


-----------------------------------------------------------------------------
Subject: 276)* What is IMUG and how do I join it?

[Last modified: July 96]

Answer:  CAUTION: As of March, 1996, IMUG could not be contacted. If anyone is
aware of the status of IMUG, please send mail to me (ksall@cen.com).  Thanks
to Lou Farho (farho@harris.com) for this update.

IMUG is the International Motif User Group founded by Quest Windows
Corporation and co-sponsored by FedUNIX.  IMUG is a non-profit organization
working to keep users informed on technical and standards issues, to
strengthen user groups on a local level, to increase communication among users
internationally, and to promote the use of an international conference as a
forum for sharing and learning more about Motif.  You can join it by

 1.  Pay the annual membership fee of $20 USD directly to IMUG.  Contact

     IMUG
     5200 Great America Parkway
     Santa Clara,  CA  95054
     (408) 496-1900
     imug@quest.com

 2.  Register at the International Motif User Conference, and automatically
     become an IMUG member.

 3.  Donate a pd widget, widget tool or widget builder to the IMUG Widget
     Depository and receive a free one year IMUG membership.

-----------------------------------------------------------------------------
Subject: 277)  How do I set the title of a top level window?

[Last modified: September 92]

Answer:  Set XmNtitle (and optionally XmNtitleEncoding) for TopLevelShells.
(Note that this is of type String rather than XmStrin.)  Ypu can also set
XmNiconName if you want its icon to show this title.  For XmDialogShells, set
the XmNdialogTitle of its immediate child, assuming it's a BulletinBoard
subclass.  These can also be set in resource files.

-----------------------------------------------------------------------------
END OF PART EIGHT
