|
The GTK docs suggest: get_toplevel will return the topmost widget you're inside, whether or not it's a window, thus the is_toplevel check. Yeah something is mis-named since the code above does a "get_toplevel()" then an immediate "is_toplevel()" (most likely, get_toplevel() should be called something else). | |||
|
Though gtk_widget_get_toplevel should work, you may also give a try to the code below. It should get the parent gtk window for the given widget and print it's title. hope this helps, regards | |||
|