Re: [Gtk-osx-users] GTK-OSX not clipping between non-toplevel sibling widgets



I said:

    Hello -- We have a cross-platform windowing system written in lisp,
    which on the Linux platform is built on top of GTK, where it works
    fine.  Now I'm trying to bring it up on GTK-OSX, and there's a basic
    problem.  It comes up and runs, but from what I'm seeing on the
    screen, it appears that it's not doing basic clipping between
    non-top-level windows (GTK widgets), and so a window often gets drawn
    over sibling or cousin windows that are in front of it.
    ...

John Ralls said:

  Sorry, I haven't any idea -- I don't even understand what you mean by
  "clipping".  You'll have to try the GTK list
  (http://mail.gnome.org/mailman/listinfo/gtk-list ).

The problem is specific to GTK-OSX (since our code works fine on GTK on
X), so my question doesn't seem suitable for the general GTK list.  This
is a question for whoever ported GTK at a low level from the X window
system to Quartz for the Mac.  Is this the right list for that?

By clipping I mean the general technique where a windowing system
prevents content from being drawn outside the window that it's being
drawn in, or where other windows are in front of the window that's being
drawn.  GTK-OSX does appear to be successfully avoiding drawing the
contents of a widget over that widget's child widgets that are in front
of it, but is not avoiding drawing content over sibling or cousin
widgets that are in front of it.

GTK prefers a "packing" model where it fits sibling widgets
side-by-side, and so sibling widgets typically do not overlap each other
in a GTK app.  Our windowing system that we ported to GTK several years
ago, on the other hand, was designed long ago on a different model where
an application places windows explicitly at arbitrary positions and with
arbitrary overlap between siblings.  So we use the GtkFixed class for
our generic windows.  We also call gtk_fixed_set_has_window on each one,
passing TRUE, which causes each GtkFixed widget to use a real X window,
and I assume that it's the underlying X window system that's doing the
clipping between the sibling X windows.

So my guess is that GTK-OSX (GTK on Quartz) is not doing something
similar to achieve clipping between sibling widgets.  Maybe
gtk_fixed_set_has_window isn't creating a Quartz window for the GtkFixed
widget, or maybe non-top-level Quartz windows don't automatically do
clipping between siblings.  But I don't know Quartz at all, and so I
don't have a good guess about that.  I didn't have much success googling
for that info.

Ken Cheetham                          cheetham franz com
Franz Inc.                            Voice: (510) 452-2000 x124
2201 Broadway, Suite 715              Fax:   (510) 452-0182
Oakland, CA  94612                    Web:   http://www.franz.com/ 




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