Hi,

well actually the visibility behaviour of the GtkWindows changed from glade1 to glade2 ... I just was used to use .Show() and was suprised, that the windows are visibile per default now ... and late in the night, I didn't think of such a simple thing like checking the visibility setting :|

Martin
--------- Original Message --------
From: "Christian Reis" <[EMAIL PROTECTED]>
To: "Martin Preishuber" <[EMAIL PROTECTED]>
Cc: "Johan Dahlin" <[EMAIL PROTECTED]>, [EMAIL PROTECTED]
Subject: Re: [pygtk] applets & libglade
Date: 06/03/03 14:07


On Wed, Mar 05, 2003 at 11:57:24PM +0100, Martin Preishuber wrote:
> > > 2.) I create some windows with glade (pygtk2 1.99.15), to use it I do
> > > something like:
> > >
> > > xml = gtk.glade.XML(gladefile)
> > >
> > > this works fine, but it immidiately shows the window ... is there any
> > > way to load it invisible and set it to visible manually later ? I need
> > > to fill some parts of the window before it is visible.
> >
> > Go into glade, mark the window, go the Common tab, uncheck Visible.
>
> thanks again ... how comes, that I feel somehow stupid now ? :|

You shouldn't. This is a very common problem when using liglade to build
a complex application -- the parse of the file has the side-effect of
rendering the window when it's marked as visible.

I've discussed this before, and I'm not sure there is a good solution to
the problem. On one hand, you could ignore the visible attribute for
top-level windows, but that would be violating the 1-1 correspondence
between gladefile and libglade tree which is expected. On the other
hand, you could have Glade make GtkWindows not visible my default; but
then you have a consistency issue between windows and other widgets.

I don't see solutions (beyond stuff like

GladeXML("foo.glade", invisible_windows=1)

which I don't like very much). But maybe somebody else does.

Take care,
--
Christian Reis, Senior Engineer, Async Open Source, Brazil.
http://async.com.br/~kiko/ | [+55 16] 261 2331 | NMFL
_______________________________________________
pygtk mailing list [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/




_______________________________________________ pygtk mailing list [EMAIL PROTECTED] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/

Reply via email to