As I previously said, you should call to gtk_main_iteration after you do a
GUI change (update the gtk_statusbar, update a label, whatever...). If not,
the GUI will be updated when the control is out of the callback (and you
call to real_operation() from a callback)

Try with the links I posted before.

Regards

On 6/30/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
> I'm new in gtk develop...so i'll need a bit more help!!
>
> Where do i've to include this part of code??
>
> this is mine...
> on_button1_activete
> {
> ....
> ....
> novd=real_opration(file);
> }
>
> int real_operation_file
> {
>   fgets(fp,200,registro)  /*read number1*/
>   gtk_statusbar_push(...."reading numeber1")
>   gtk_statusbar_pop()
>
>   fgets(fp,200,registro)  /*read number2*/
>   gtk_statusbar_push(...."reading numeber2")
>   gtk_statusbar_pop()
>
>   fgets(fp,200,registro)  /*read operation*/
>   if(strstr(operation,"sum")
>   {
>         suma=num1+num2
>   gtk_statusbar_push(...."operating..")
> }
>
> it onmy writes in the status bar "operating..."
>
> pleas,help me!!
>
>
> Mensaje citado por Fernando Apesteguía <[EMAIL PROTECTED]>:
>
> > That's because you are calling real_opration() from the button callback.
> So
> > the event loop is not running and it can't update your GUI. You should
> call
> > gtk_main_iteration while gtk_events_pending==true
> >
> > more at
> >
>
> http://developer.gnome.org/doc/API/2.0/gtk/gtk-General.html#gtk-events-pending
> > and
> > http://developer.gnome.org/doc/GGAD/sec-mainloop.html
> >
> > Regards
> >
> > On 6/29/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> > >
> > >
> > >
> > > Hi everyone!
> > >
> > > I built a gtk_application with glade,it's a main window with menu.Wheni
> > > select
> > > a menu option, my program opens a new window with entries and buttons.
> > > In  the entry i write the name of a file to open.
> > >
> > > This file has the structure:
> > >
> > > number1   (ex.25)
> > > number 2   (ex.34)
> > > operation   (product)
> > >
> > > after writing the name,i push the button and it's called the function
> > > real_opration()
> > > This function mekes a lot of things,but the first one is read the
> numbers
> > > of
> > > entry_file and the opration.
> > > i'd like that in the status bar of this window(not main_window),it'll
> be
> > > written...
> > >
> > > reading number 1...
> > > reading number 2...
> > > operating..........
> > > End
> > >
> > > i tried but only is written End.
> > > How can i change the content of statusbar,during reading the
> entry_file??
> > >
> > > thanks a lot
> > >
> > > _______________________________________________
> > > gtk-app-devel-list mailing list
> > > gtk-app-devel-list@gnome.org
> > > http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
> > >
> >
>
>
>
>
>
_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Reply via email to