[Mono-list] Interception X11 events

Diego Nunes diego.nunes.br at gmail.com
Wed Aug 16 13:56:31 EDT 2006


So, XplatUIdriver must be an OwnerEventHandler, that can be attached
for an handler method, to treat other kind of messages

Diego.

On 8/16/06, Chris Toshok <toshok at ximian.com> wrote:
> On Wed, 2006-08-16 at 12:45 -0300, Diego Nunes wrote:
> > Sure, XMapWindow doesn't correspond to WM_CREATE, buts XMapRequest does.
> > On win32, WM_PARENTNOTIFY with fwEvent = WM_CREATE is sent when a
> > child is created.
>
> That's just it - by the time XMapRequest is generated the window is
> already created.  It just hasn't been mapped.
>
> XMapRequest is closer in spirit to WM_SHOWWINDOW.  WM_CREATE is
> equivalent to a (nonexistant) event generated by the XCreateWindow call.
>
> > So, if I'll not use translations from mono (I think that all events
> > must be translated)
>
> MWF's (actually XplatUIX11.cs's) goal isn't to provide its users with
> every X11 event that gets generated.  It's goal is to emulate win32
> semantics on top of X11.
>
> I'm not saying a window manager in MWF isn't a interesting project, but
> it is also well outside the scope of our goals with MWF, which is to
> provide a means for writing cross platform applications, and to allow
> migration of applications from windows to linux.
>
> That said, patches will of course be considered.
>
> > Just for note: Qt library has a function SetX11EventFilter() for this.
>
> Qt controls their api - we don't.
>
> Chris
>
> > On 8/16/06, Chris Toshok <toshok at ximian.com> wrote:
> > > You're probably better off writing your own event handling/translating
> > > for a window manager.  The purpose of XplatUIX11.cs is to provide the
> > > win32 semantics MWF needs (and only what it needs) in an X11 world.  The
> > > additional events (all the *Request events) have no mapping in the win32
> > > world, and you'll end up having to set the RedirectRequest flags on
> > > native X windows anyway.  Also, there's no way in SWF to read X window
> > > properties.
> > >
> > > If you're looking to draw on window frames using S.D, you can do that
> > > without pulling in SWF.  Check out gtk-sharp/gtkdotnet/Graphics.cs for
> > > an example of how to do it with a Gdk.Window.
> > >
> > > Chris
> > >
> > > On Wed, 2006-08-16 at 11:17 -0300, Diego Nunes wrote:
> > > > A windows manager "knows" when a new window application rises by
> > > > receiving a Maprequest event.
> > > > This event informs about handle, location and dimension of new window,
> > > > so the WindowManager can Paint the Title Bar, borders and Minimize,
> > > > maximize and close buttons.
> > > > Looking at the source of XplatUI, this event is ignored.
> > > > I'm thinking in 2 solutons:
> > > > a) Mono changes the source and translate Maprequest to WM_USER with
> > > > additional info.
> > > > b) Rewrite (derivating) Application (Run method), XplatUI and
> > > > XplatUIX11 classes for this job.
> > > >
> > > > Diego.
> > > >
> > > > On 8/16/06, Peter Dennis Bartok <Peter at novonyx.com> wrote:
> > > > > Uhm, I'm not sure what you're asking. You want us to do exactly what? Show
> > > > > you how to decode the maprequest, or translate the maprequest into some
> > > > > win32 message (not sure which one that would be). The XplatUI class is
> > > > > internal anyways, unless you're using reflection you won't get that anything
> > > > > in there.
> > > > >
> > > > > Peter
> > > > >
> > > > > -----Original Message-----
> > > > > From: "Diego Nunes" <diego.nunes.br at gmail.com>
> > > > > To: <mono-list at lists.ximian.com>
> > > > > Date: Tuesday, August 15, 2006 20:03
> > > > > Subject: [Mono-list] Interception X11 events
> > > > >
> > > > >
> > > > > >I need get X11 event MapRequest, that isn't translated for w32 event.
> > > > > >In the file XplatUIX11.cs there isn't any handler for this message (in
> > > > > >GetMessage method)
> > > > > >
> > > > > >I need this cos I'm coding a Window Manager (or Desktop Manager) for X11.
> > > > > >
> > > > > >Some can help me?
> > > > > >
> > > > > >Thanks,
> > > > > >Diego.
> > > > > >_______________________________________________
> > > > > >Mono-list maillist  -  Mono-list at lists.ximian.com
> > > > > >http://lists.ximian.com/mailman/listinfo/mono-list
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > > _______________________________________________
> > > > Mono-list maillist  -  Mono-list at lists.ximian.com
> > > > http://lists.ximian.com/mailman/listinfo/mono-list
> > >
> > >
>
>


More information about the Mono-list mailing list