Re: Function 2 Function Problem.
| From: | Francisco barrio | Date: | Thu, 10 Mar 2005 16:38:57 +0000 |
| Subject: | Re: Function 2 Function Problem. | ||
| References: | 1 2 3 4 | Groups: | php.gtk.general |
| Request: | Send a blank email to php-gtk-general+get-5631@lists.php.net to get a copy of this message | ||
Well thats right that is not defined.
but my problem is that when you click on envolve, and then make a calculation on the new window, the application. closes instead of working like the calculo.php-gtk
Thats the problem.
:(
Thanks in advice.
----- Original Message ----- From: "Jayesh Sheth" <jayeshsh@ceruleansky.com>
To: <php-gtk-general@lists.php.net>
Sent: Thursday, March 10, 2005 1:32 PM
Subject: Re: [PHP-GTK] Function 2 Function Problem.
Hello Francisco, I think the problem lies on lines 83 and 84 of imagen_prueba.php-gtk: $vbox_left->pack_start($mailist,FALSE,FALSE,0); $vbox_left->pack_start($but_frame,FALSE,FALSE,0); $mailist and $but_frame are not defined (i.e. not instantiated as GTK widgets) in anywhere in your script. The errors I got were: ______________________________________________________________________ C:\>c:\php4\php.exe c:\normal_programs\php2\function_gtk\imagen_prueba.php-gtk Warning: pack_start() expects argument 1 to be GtkWidget, null given in c:\norma l_programs\php2\function_gtk\imagen_prueba.php-gtk on line 83 Warning: pack_start() expects argument 1 to be GtkWidget, null given in c:\norma l_programs\php2\function_gtk\imagen_prueba.php-gtk on line 84 Warning: pack_start() expects argument 1 to be GtkWidget, null given in c:\norma l_programs\php2\function_gtk\imagen_prueba.php-gtk on line 85 Warning: pack_start() expects argument 1 to be GtkWidget, null given in c:\norma l_programs\php2\function_gtk\imagen_prueba.php-gtk on line 86 (imagen_prueba.php-gtk:2960): Gdk-WARNING **: Creating pixmap from xpm with NULL window and colormap Warning: attach() expects argument 1 to be GtkWidget, null given in c:\normal_pr ograms\php2\function_gtk\imagen_prueba.php-gtk on line 132 ________________________________________________________________________ I think the other errors that followed resulted from the initial errors listed above, but I may be wrong on this. On line 82 (right before the errors begin) you have the following line: $vbox_left->pack_start($separator,FALSE,FALSE,0); and it works because you defined / made $separator an instance of GtkHSeparator: $separator=&new GtkHSeparator(); So, I think you have to do the same for $mailist and $but_frame, depending on what kind of widgets you want them to be. ( I cannot tell from their names). Hope that helps. - Jay Sheth Francisco barrio wrote:Hello PPL. I have a problem.. I modify some code to make work graphics buttons.. thats ok its working. now i try to add a function that calls to another function but its not working.. i cannot manage the result. i know that its a silly thing..i hope that someone can help me. the problem its the function evolve() (line 109) that get the results when it calls to function calcula() (line 180) i hope that someone can help me.... because this one: function inside funcions i will use it a lot. Thanks !! PS: the program its imagen_prueba.php-gtk and you have to click on envolve. i send the calculo.php-gtk that is the function calcula() alone. that works ! Download all files: http://www.globaldesignfactory.com.ar/function_gtk.zip Thanks in advice.-- PHP-GTK General Mailing List (http://gtk.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php