SGI GUI library info...
    michael sweet 
    sweetmr at sct60a.sunyct.EDU
       
    Sun Dec  9 12:33:54 AEST 1990
    
    
  
Due to a VERY large interest in the user-interface library I am developing, 
I might as well give everyone some details on its use....
First, the library is officially called the Gadget library (I know, really
original. :)  When you compile a program that uses it, you will just need
to include its header file, and link with '-lgadget'.  Also, you have to use
C (Fortran could be possible also, but I am not a Fortran programmer...)
Ok, once you have opened up a window, you have to initialize the library:
 GadgetInit();
 
Tough, eh?  Window redrawing is done from a central point, so the next thing 
you have to do is specify what the window's redraw function is:
 SetRedraw(window_id,redraw_function)
 
Normally, you would then add the devices you want queued (with qdevice().)
With the gadget library, you do the following:
 QDevice(device);
Similarly, you use UnQDevice() in place of unqdevice(), and QRead() in place 
of qread().
Buttons (and the other stuff) are held in simple data structures.  To show
a button, you would have code something like this:
BUTTON my_button = {......};
...
 ShowButtons(&my_button,1);
In the main event loop in you program, you would then have a call to the
button handler:
 n=DoEvent(&my_button,1,dev,val);
If a button gets clicked on, 'n' would equal the button # clicked.  Otherwise,
-1 is returned (much like dopup(). )
-------------------------------------------------------
This library should be done, documented, and available before Christmas...
 -Mike Sweet
  sweetmr at sct60a.sunyct.edu
  
    
    
More information about the Comp.sys.sgi
mailing list