Re: Question about gtk/metacity



On Tue, Apr 01, 2003 at 02:45:44PM -0800, Loban A Rahman wrote:
> On Tue, 2003-04-01 at 12:19, Bob Smith wrote:
> > Its a hack, but why not just disable the event handler when you change the
> > border, then reenable it when your done?
> 
> That seems like the way to do it. However, there is still one caveat.
> the set_decorated() function returns immediately, (I think because all
> it does is set a window-manager-hint). Hence, merely wrapping the
> function call with handler_block() and handler_unblock() won't work. How
> will I know when the window-manager is done decorating the window?
>

You don't. Plus there are other race conditions here, such as whether
the window ends up focused at all after all the chaos sorts out.
  
> Or is this just impossible?

I think if you want windows with a border that comes and goes, you'd
need to do that entirely within the window manager.

Metacity themes can actually already support an 0-size frame
(different from undecorated, where there's no frame) and have
different-size frame for focused and unfocused windows, I believe.  So
from an implementation standpoint it's just a matter of adding a new
window type and then having themes support that.

However, I'd want to see the UI team sign off on the window type and 
see the window type added to the EWMH spec, so that's the harder part.

I don't actually understand why you need to do this - I mean, either
the window has a frame or it doesn't. Having it only when focused is
just strange.

Havoc




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]