On 12/31/05, Alex Lau <[EMAIL PROTECTED]> wrote:
> Dear all
> Happy New Year !!
>
> Mike Emmel wrote:
> > On 12/29/05, Alex Lau <[EMAIL PROTECTED]> wrote:
> >> Dear all
> >> long time no see
> >> and wonderful work with the GTK2.8!!  :)
> >> I get vte and scim running on top of it displaying and inputing
> >> chinese and everything.
> >>
> >> Since gtk is working I'm also trying out the unique with gtk and of
> >> course  :)  I will try to see I can submit some upgrade on the window
> >> manager but there are couple questions I would like to ask here ...
> >>
> >> Will unique going to be a full features wm?
> >> Or back porting gnome desktop? and let gnome take care of it?
> >>
> > Gnome won't supply the window manager it uses the X11 window manager
> > so you still need a directfb window manager.
> > I'd suggest that you branch the unique window manager and make your
> > own that fits your needs. I'm not sure what platform your targeting.
> > You could consider  the metacity window manager
> > http://ftp.gnome.org/pub/gnome/sources/metacity/2.4/
> > You would need to port it to directfb.
> >
> I'm new to the window manager concept, any thing I can read from?
> If I'm going to port metacity do I need to extend unique first?
> if I'm going to extend unique  .... do I still need metacity?
> Thanks I'm a little unclear about the relationship, please forgive me.
>

On any multi windowed platform there is a need to manage the windows.
In the simplest case there needs to be a single list some where to
manage the stacking order.

Window Managers do a few things.

1.) Maintain a list of all the windows open for all apps.
2.) Dispatch key and mouse events to the active window plus manage the
active window
3.) Some also manage drawing the decoration around the active window
this is generally done by actually adding a new window that the
application window is a child of.

4.) Window managers generally only manage whats called the top level
windows these can be defined as windows that can overlap or cover the
windows of another application and that have as there parent the root
window or a window manager provided decoration window.

Unique is a good one to study since directfb really simplifies wm
design. Another is twm
most X11 window managers are derivatives of twm.

My sugesttion to port meta city is to simply use the theme handling
with a deriviative of
unique not the internals of a  X11 window manager.

I looked at meta-city its pretty simple for a X11 window manager.

I'd say the key method your intrested in is
meta_frames_manage_window  in frames.c
Thats where you would want to start porting everything below here is
pretty x11 specific
and above should be okay.
The key call is
gdk_window_foreign_new

In our case that would be a native DirectFB window.



> >> Then is a more important issue to me  :)
> >> I'm also trying put scim (a input method) into directfb/gtk since there
> >> isn't any default wm layer for me to put in the input, I can only do
> >> some kind of hack for it but that will break the directfb api or limit
> >> the scim ability. However if unique is availible then we can add a
> >> plugins to the input layer.
> >> Then I can really run directfb app with chinese input :)
> >>
> >
> > There is a root window.
> >  In   gdkwindow-directfb.c see  the _gdk_parent_root variable
> > its set in the function _gdk_windowing_window_init
> >
> > You should  get it from the public api.
> > gdk_get_default_root_window
> >
> > Then you need the headers right now and the following code snippet
> >
> >   GdkWindowObject       *private;
> >   GdkWindowImplDirectFB *impl;
> >
> >   g_return_if_fail (GDK_IS_WINDOW (window));
> >
> >   private = GDK_WINDOW_OBJECT (window);
> >   impl = GDK_WINDOW_IMPL_DIRECTFB (private->impl);
> >
> > impl->window
> >
> > Is the DirectFB window.
> > I did not find a exported function to get to the window but
> > we can add one if needed just let me know if this suites your needs
> > and you can add a function to gdkwindow-directfb.c or I can.
> >
> >
> Actually I can run scim directly with gtk app on directfb now by using
> gtk im module directly.
> except I can't test it on console, it crash all the time :)
> but in SDL it seem to be a bit more stable
>
> Another funny thing is when I start the input panel first with directfb
> then start the gtk app ( even on X or directfb ) I can get the input
> panel display correctly ( pretty much ), however if I start the gtk
> directfb app directly ( immodule will start the input panel if it is
> not started ), the input panel will not draw correctly ... right hand
> side of the panel will be corrupted.
> I'm not sure exactly why :)
>
I'm seeing that too right now it seems to be caused by apps that use
the older clist and ctree
widgets not the newer tree widgets.  I'm working on it.
Also you may want to read the cvs log email I'm doing a lot of work on
gtk over the next few weeks hopefully I can fix any bugs that cause
you problems.

In any case if you start on the project I'm willing to help. My time
is limited but I once wrote a X11 window manager in java  :) And I've
written numerous embbeded window managers.

Mike

>

_______________________________________________
directfb-dev mailing list
[email protected]
http://mail.directfb.org/cgi-bin/mailman/listinfo/directfb-dev

Reply via email to