Welcome to the NewToggleButton widget for Motif!
This is version 0.91b.

PLEASE READ THE FOLLOWING INFORMATION CAREFULLY!

QUESTION:
- Can't your customers tell the difference between a square shaped and a
    diamond shaped indicator toggle buttons usually display?
- Or can't your customers distinguish when an indicator is in the "on" state?
- Can't your bear the toggle button's outer appearance?

ANSWER:
Just get rid of XmToggleButtons and use the free XmNewToggleButton widget
class instead. This new widget class offers all the things the
XmToggleButton widget class provide together with a much better look.
Now your customers easily recognize (and remark!) the difference between
toggle buttons used for either exclusive or multiple choice.

One big mistake the OSF made was to use rectangular shapes for both
selection modes (XmONE_OF_MANY, XmN_OF_MANY). This results in a somewhat
cumbersome recognizing process on beside of the user - not a good design
goal with graphical user interfaces that are always claiming the
opposite.

Thus a XmNewToggleButton displays a checkbox whenever it is part of a
multiple choice selection. When in exclusive mode the new toggle button
widget class draws a round button instead which looks much like the
buttons known from old radios.

For compatibility reasons the new toggle button replacement also
features a "tri state" mode known from other GUIs.

!!!NOTE!!!
The OSF claims that sublassing existing widget classes is almost
impossible (with the exception of XmPrimitive and XmManager). I've
found out (on my PLB: Yet Another Acronym for "Personal Linux Box")
that this doesn't seem to be that much worse. I tested the code with
Motif 1.2.3 and got very good results. At this time there is only one
bug concerning keyboard traversal whenever a XmNewToggleButton sits in
a pulldown or popup menu. If at the time of popup the mouse cursor
"sits" on top of the new toggle button, moving the keyboard focus with
the cursor keys will hide the popup menu.

I I don't know to some extend whether the code works on Motif 1.1. When
I tried to test it with SGI's Motif 1.1(.1) the demo enters an endless
recursion loop caused by Motif's internal geometry management. Seems
that the OSF made a mistake in the ToggleB.Initialize procedure. But
there is good chance that they corrected the mistake with later 1.1
revisons. But you can't use it with Motif 1.1 in menu panes (with the
0.91b XmNewToggleButton version).

To test the new widget class edit the Makefile, then just do a make and run
./demo
afterwards if the code compiles successfully.

Please report any bugs/problems/efforts you encounter/made.


DISCLAIMER:
THIS PROGRAM IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER
EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS
WITH YOU.  SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.

Please read the file COPYING for more details.

(c) 1994 Harald Albrecht
Institut fuer Geometrie und Praktische Mathematik
Rheinisch-Westfaelische Technische Hochschule Aachen
D-52056 Aachen, Germany
albrecht@igpm.rwth-aachen.de
