[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Re: Widget flags WX11BypassWM
From:       Alexander Neundorf <alexander.neundorf () gmx ! net>
Date:       2002-12-23 9:02:51
[Download RAW message or body]

On Monday 23 December 2002 03:06, Shamyl Zakariya wrote:
> All,
> I've been working on an app which doesn't use window borders and as such
> relies heavily on internal calculations for top level window positioning
> and resizing. To get an idea of what I'm walking about see this screenshot:
>
> http://home.earthlink.net/~zakariya/files/carddesk/carddesk2.png

Nice :-)

> Now, up until recently, the WFlags I had set in the top-level widget's
> constructor included W11BypassWM and the performance was great. I had fast
> dragging, resising, etc etc. But, in doing so, I couldn't reliably get
> mouse focus. So I decided to give a shot at turning on and off that flag
> when it was necessary -- e.g., when I'm animating or resizing, I turn that
> flag on, and then turn it back off when I'm done such that I can get
> reliable focus and dnd events. So I made simple method:
>
> void CardBase::enableWindowManagement( bool yes )
> {
> 	if ( yes )
> 	{
> 		clearWFlags(Qt::WX11BypassWM);
> 	}
> 	else
> 	{
> 		setWFlags(getWFlags() | Qt::WX11BypassWM);
> 	}
> }
>
> In the case of my card's resize gripper I call
> enableWindowManagement(false) on the mousePressEvent, let it be during
> mouseMoveEvent() and then set enableWindowManagement(true) on
> mouseReleaseEvent(). But, this has no effect whatsoever. I expected
> otherwise ;)
>
> Is this a matter of KWin getting the message asynchronously? Is there some
> way I can force KWin to process its message queue and handle my change in
> WFlags before I start resizing and moving my windows?

I think the flags have to be set when the widget is created. There is also 
something like recreate() or reparent() which can set the flags.
Simply setting the flags withoput doing anything else has AFAIK no effect.

Bye
Alex


 
>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic