Re: [gtk-list] Re: Does gtk+ support motion compression?

Robert Minsk <> writes: 
>   Looking at the event dispatching in gtk_main_do_event motion
> compression does not seem that hard to implement.  Heck, it's already
> compressing enter/leave events.  The main difference is it would
> have to check the widget to see if it wants motion compression.
> The next line after enter/leave compression is looking up the widget.
> So thats pretty much done.  You can pretty much rip off the compression
> code from the Xt tree.  Also there are plenty of bits left in the
> GdkEventMask.
>   The hard part, if you decide to implement it, is to go back and
> change the old widgets to use motion compression instead of
> explicitly getting the mouse position where applicable.  Second is
> the documentation.  Allot people are going to use the book for
> documentation which was published before this could be a feature.
> That's what release notes are for ;-)

Well, there's no need to change the old widgets immediately, they
wouldn't actually be affected as long as motion compression has to be
turned on explicitly. As far as I can tell anyway.

What you're saying sounds reasonable to me, it sounds like a trivial
patch: add a new flag to GtkWidget, check flag in do_event, compress 
motion events if appropriate. Maybe do a patch and send it to
gtk-devel-list and see what people think?


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