I still think that GtkDialog are much better suited for the goals you have in mind.
Otherwise, you could use gtk_widget_set_sensitive
to "gray out" some widgets.
And I don't understand your
install1 = gtk_label_new("[*] Verifica Mysql Server [ OK ]");
this seems really something which should be a dialog...
Otherwise, if you really want just text, use a GtkTextBuffer
and a GtkTextView
like explained in the Text Widget Overview
. You can have various textual appearance and behavior thru GtkTextTag
If you really want to hide a widget, use gtk_widget_hide
My guess is that you have not yet a clear view of Gtk basic concepts. Maybe you should try to re-read the Gtk tutorial
(but some details might have changed in Gtk 3) ?
Are you fully aware that a GUI
program is event driven
, so basically built around a loop (i.e. gtk_main
etc... in Gtk)? So pedantically, your programming style becomes continuation passing style
In other words, your program should be made of small steps, each implemented by a function which is a Gtk signal
handler. If you really want to show a widget from a callback
(i.e. a Gtk signal handler), that callback should return immediately after calling gtk_widget_show
and have set something so that other callbacks -or timeout routines (thru g_timeout_add
) or idle routines (thru g_idle_add
), etc... could do the further steps. Some important things (notably actually showing widgets) happen only inside the main loop executed by gtk_main
, not inside your callbacks.
But I still don't understand what you want exactly to achieve, and why you don't use Gtk dialogs or text views.
I would like to do an installer. This installer should print on every action (check mysql, java, and copy files to dir) to a new label.
Perhaps each of your elementary action or step should be a callback (which might set an idle function doing the next step, etc.).
-s could be useful to you, since they offer a multi-user step machinery.P.S. I did take care to add web links to many references. I'm sure they will help you! So take time to follow the links!