XDrawRectangle - drawing on the whole desktop

This forum is read only. No new submissions are accepted.

Questions about motif? Contact us

2 posts / 0 new
Last post
XDrawRectangle - drawing on the whole desktop

Submitted by Anonymous on Wed, 04/24/2002 - 14:29. Developers
Hi everyone.

I want to draw a rectangle which I can put anywhere on screen,
independant from any window. The technique is used in the
XiStretchWidget, and I wonder how they do that.

My problem is that I need to get a drawable for the whole screen.
Anyone could help me?

Thanks

ICS_support

If I recall correctly -- having written the XiStretchWidget some 12 years ago -- the trick is to use IncludeInferiors in the GC setting for subwindow_mode (http//www.motifzone.com/resources/man/XCreateGC.html). The drawable for the whole screen is the root window (see RootWindowOfScreen in http//www.motifzone.com/resources/man/BlackPixelOfScreen.html) . This assumes colormaps and everything else match correctly. Note that the sources are probably part of the extended Motif release 2.2.