How Do I Get a Pointer to the Current Window

Hsuan Chang hsc at vuse.vanderbilt.edu
Wed Jan 4 01:20:31 AEST 1989


You may get a /dev/win? sort of pointer by using

	getenv("WINDOW_ME")

and then obtain an fd to it.  Sun has provided a set of win_* routines to
access (via fd) attributes of the window.  For instance, 

	win_getrect(fd, &rect)

gets you the size and location of the window, where rect is

	Rect rect;

I don't know if it's worth to develop your own menu pulling mechamism.
You may find it necessary to read the SunView System Programmer's Guide,
and the definitions in basetools.h and othertools.h under
/usr/src/sun/suntool.  

Hope this helps.

Hsuan Chang
Image Processing Lab
Computer Science Department
Vanderbilt University
Nashville, Tn 37235
(615) 322-0962
hsc at vuse.vanderbilt.edu



More information about the Comp.sys.sun mailing list