Results 1 to 7 of 7
Is there a good website that is a how to on GTK+? I know about the reference manual and things, but they do not contains good howtos on some things....
- 10-03-2006 #1Just Joined!
- Join Date
- Oct 2006
- Posts
- 7
GTK+ how to
Is there a good website that is a how to on GTK+? I know about the reference manual and things, but they do not contains good howtos on some things.
- 10-03-2006 #2Flies of a particular kind, i.e. time-flies, are fond of an arrow.
Registered Linux User #408794
- 10-03-2006 #3Just Joined!
- Join Date
- Oct 2006
- Posts
- 7
Thank you for your response. This is a great website, but unfortunately doesnt answer the question that I have in specific. I am looking for how to force the focus on a certain window. For example, I have a window pop up when there is an error and there is an OK button on that window. I do not want focus on anyother object until that OK button is pressed.
- 10-03-2006 #4
Try looking up information on window modality.
Flies of a particular kind, i.e. time-flies, are fond of an arrow.
Registered Linux User #408794
- 10-03-2006 #5Just Joined!
- Join Date
- Oct 2006
- Posts
- 7
I tried using gtk_window_set_modal but it didnt work. Let me show you exactly what I am trying to do.
on_buttonWindowOneOK_clicked(GtkButton *button, gpointer user_data) {
if(checkVariables()) {
do stuff....
} else {
windowTwo = create_windowTwo();
gtk_widget_show(windowTwo);
gtk_window_set_modal(GTK_WINDOW(windowTwo), TRUE);
}
}
I also tried FALSE just in case I didnt understand the documentation. I want windowTwo to be on top of windowOne until the OK button in windowTwo closes windowTwo, but set_modal didnt seem to work. I also tried set_focus.
I really appreciate any help on the matter and I am sorry if I am being a pain.
- 10-03-2006 #6
http://developer.gnome.org/doc/API/2...ndow-set-modal
Read the part about transient windows; that's probably what you have to do. I'm not sure; I've never even used GTK (only straight Xlib for me).Flies of a particular kind, i.e. time-flies, are fond of an arrow.
Registered Linux User #408794
- 10-03-2006 #7Just Joined!
- Join Date
- Oct 2006
- Posts
- 7
Same damn result with
gtk_set_transient_for(GTK_WINDOW(windowTwo), GTK_WINDOW(windowOne));


Reply With Quote
