[vox-tech] "bring to front" X-window command

Jonathan Stickel jjstickel at sbcglobal.net
Sat Oct 2 14:06:24 PDT 2004


Peter Jay Salzman wrote:
<snip>
> Jon, your xlib calls are:
> 
>    XRaiseWindow(Display *display, Window w);
> 
>    XLowerWindow(Display *display, Window w);
> 

Finally got around to trying this, and it does work directly in "simple" 
windows managers (tested in openbox).  However, it doesn't quite work in 
KDE.  Rather than the window coming to the top, the window's entry in 
the taskbar just flashes at me.  A little googling tells me something 
about the "override-redirect attribute" and that it might help if it was 
set to true.  I tried this, and now nothing happens with the window at 
all. :(  Here is the relevant code:

   Display *dpy;
   Window win;
...
<code to get dpy and win>
...
   // set the override-redirect attribute to True
   XSetWindowAttributes set_att;
   set_att.override_redirect = 1;
   XChangeWindowAttributes( dpy, win, CWOverrideRedirect, &set_att);
   XRaiseWindow( dpy, win );

Anyone able to help?

Thanks,
Jonathan


More information about the vox-tech mailing list