ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> php-gtk-general
php-gtk-general
Re: [PHP-GTK] Problem with filechooser (defined with Glade)
by Bernard Fouche other posts by this author
Jul 25 2007 3:48AM messages near this date
Re: [PHP-GTK] Problem with filechooser (defined with Glade) | Re: [PHP-GTK] Problem with filechooser (defined with Glade)
Thanks Bob for your answer. Using show() and hide() fix the problem when 
I use the 'Cancel' button or select a file, but not for the delete event:

I can't 'connect_simple' on 'delete' for the FileChooser, Php reports 
that this signal is unknown.

However I can connect_simple() to the 'destroy' signal and my called 
method calls hide() and then returns 'true'. In that case I have the 
same problem I had with set_visible() but in a slightly different way: 
when I call show() again, the file chooser window will appear and then 
disappear very fast, showing only the title bar for this window.

    Bernard

bob majdak jr wrote:
>  grr. reposting to the list. grr.
> 
>  What if you use hide() and show() instead of set_visible()?
> 
>  Also, are you returning true from the callback for the delete-event 
>  (clicking the X)? If you do not dominos keep toppling over and smashes 
>  the insides to bits, creating the effect of losing your innards when 
>  you try and reshow the window.
> 
>  - bob.
> 
>  Bernard Fouch wrote:
> > Hi list.
> >
> > I'm new to PHP-GTK and try to use it with Glade-2. (PHP version is 
> > 5.2.2 and PHP-GTK module is 2.0.0beta). I run Linux F7.
> >
> > In Glade, I define a main window with some children and a FileChooser 
> > set to be invisible until I need it. When the user chooses 'Open' in 
> > the menu bar of the main window, I call 
> > $FileChooser->set_visible(true) and it works.
> >
> > When the FileChooser is closed, I call 
> > $FileChooser->set_visible(false) and it works also. However the next 
> > call to $FileChooser->set_visible(true) won't correctly redraw the 
> > file chooser widget: only the background of the widget is drawn. If I 
> > do a pair of set_visible(false)/(true) again on it, only the title of 
> > the file chooser window is drawn.
> >
> > I'm new to GUI and PHP-GTK so I probably miss something obvious, or 
> > my way of using Glade and the filechooser is wrong.. Any hint welcome!
> >
> > Thanks!
> >
> >  Bernard
> >
> 

-- 
PHP-GTK General Mailing List (http://gtk.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Thread:
Bernard Fouche
Bob Majdak Jr
Bernard Fouche
Malk0
Bernard Fouche
Malk0
Bob Majdak Jr
Malk0
Bernard Fouche

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved