On Mon, 28 Oct 2002 15:05:05 +1100 Carsten Haitzler <[EMAIL PROTECTED]> wrote:
> > this isn't x's job. the wm should handle this. ie it should be a state > machine > and only evaluate its when it goes idle. since X is a buffered > protocol, what > shoudl be happening is > > loop: > read_events() > move... > move... > move... > move... > move... > move... > end_read_events() > move_window() > wait_for_events() > > so all the move events come in in 1 read, since they are buffered. the > window > move only happens when all the events have been read and processed and > the wm > has evaluated its current state. this way the system never fal;ls > behind the > user on processing events and 2, will only update as fast as the system > is able > to handle > > (disclaimer: the above loop is an overly simplified version of the > event loop. > it's missing other state processing, other event handling and > synchronization at > idle handling) > > now there are a LOT of window managers. do you want to add the check to > all of > them? and what's the point? 10 mouse events come in. they result in 1 > window > move (if the wm is written well). all events are buffered in a pipeline > of > protocol requests/replies. > > same applies to resizes. often applications and some widget sets aren't > well > written and don't compress configurenotify events sent by the wm and > only > re-evaluate their redraw on idle. apps should do things this way for > optimum > performance. this is more a result of lack of knowledge of how x really > works > and how to best work within its design to achieve optimal results. > I understand what you say. I agree the real problem is that many application (even window managers) are not behaving the way they should. I have experimented with lwm (light weight window manager) and have noticed that compressing the event queue of the wm doesn't help. That's because drawing the window frame and title bar is very fast, and the window manager can easily keep up with mouse events, so no events get ignored. Client applications use much more time to redraw their window which causes poor performance. I understand applications should compress configurenotify and expose events, however there are a lot of applications that don't do that. So I think it is easier to change (at least some) window managers then all the other applications. From my experience limiting window movement to 50Hz makes a big difference, at least on my system. I think limiting the movement rate is a good idea in any case, because it doesn't make any sense to animate windows faster then that. Jouni _______________________________________________ Render mailing list [EMAIL PROTECTED] http://XFree86.Org/mailman/listinfo/render
