SunView and Canvases help

Knudsen knudsen at ihlpl.att.com
Thu Mar 23 18:22:12 AEST 1989


noamb at tybalt.caltech.edu (Noam Bernstein) writes:

> I'm looking for help from anyone who has used SunView on a Sun 386i The
> following program is copied almost straight out of the manual.
> Unfortunately, it doesn't seem to work.  It hangs on the window_main_loop
> and waits for me to either type ^C or close the window to continue.

[program code deleted]

Well, I've only written applications for a few months, but just looking at
your very familiar code leaves me witht he question:

Just what do expect it to do but hang?

Window_main_loop() means to await mouse or keyboard events and do
something with them, using notify procedures.  You haven't registered any
such procedures, nor defined any panel buttons etc. to trigger them.

Assuming that your pw-vector() draws its line, your program is working
correctly as given.

Look for more manuial examples on creating a little panel with a QUIT
button and a notify procedure; then you can punch it with the mouse and
have yet another way to exit the program.  No joke intended; once you get
this working you'll be able to build panels and really get into SUnview
applications.

Mike Knudsen  Bell Labs(AT&T)   att!ihlpl!knudsen



More information about the Comp.sys.sun mailing list