Re: Desktop as transient window

2015-08-10 Thread Igor Korot
Jasper, On Sun, Aug 9, 2015 at 7:19 PM, Jasper St. Pierre jstpie...@mecheye.net wrote: The desktop is not a window. It could be in some desktop environments, but is not always. In fact, in some desktop environments, there is no desktop window or desktop concept at all. There is no standard

Re: Desktop as transient window

2015-08-10 Thread Igor Korot
Paul, On Mon, Aug 10, 2015 at 12:33 PM, Paul Davis p...@linuxaudiosystems.com wrote: On Mon, Aug 10, 2015 at 12:31 PM, Igor Korot ikoro...@gmail.com wrote: Jasper, On Sun, Aug 9, 2015 at 7:19 PM, Jasper St. Pierre jstpie...@mecheye.net wrote: The desktop is not a window. It could be in

Re: Desktop as transient window

2015-08-10 Thread Paul Davis
On Mon, Aug 10, 2015 at 12:31 PM, Igor Korot ikoro...@gmail.com wrote: Jasper, On Sun, Aug 9, 2015 at 7:19 PM, Jasper St. Pierre jstpie...@mecheye.net wrote: The desktop is not a window. It could be in some desktop environments, but is not always. In fact, in some desktop environments,

Re: Desktop as transient window

2015-08-10 Thread Paul Davis
On Mon, Aug 10, 2015 at 12:42 PM, Paul Davis p...@linuxaudiosystems.com wrote: On Mon, Aug 10, 2015 at 12:40 PM, Igor Korot ikoro...@gmail.com wrote: IIUC, in this specific case I should create the main frame, hide it and then set the parent for my options dialog to be this main frame. you

Re: Desktop as transient window

2015-08-10 Thread Paul Davis
On Mon, Aug 10, 2015 at 12:40 PM, Igor Korot ikoro...@gmail.com wrote: IIUC, in this specific case I should create the main frame, hide it and then set the parent for my options dialog to be this main frame. you do not need to set the parent, and in almost all cases you should not set the

Re: Desktop as transient window

2015-08-10 Thread Jasper St. Pierre
The important thing is that we can tie a dialog back to context for the user -- we really want it on DEs like GNOME, and I've heard that KDE wants to get rid of transient-less dialogs as well, since they can just randomly show up to the user. When it's attached to a transient, then we raise the

Re: Desktop as transient window

2015-08-10 Thread Paul Davis
On Mon, Aug 10, 2015 at 12:57 PM, Jasper St. Pierre jstpie...@mecheye.net wrote: Hi Paul, In recent GTK+ versions, GtkDialog emits a warning when it is mapped without a parent, saying that it is discouraged. See https://git.gnome.org/browse/gtk+/tree/gtk/gtkdialog.c#n776 I should my

Re: Desktop as transient window

2015-08-10 Thread Jasper St. Pierre
Hi Paul, In recent GTK+ versions, GtkDialog emits a warning when it is mapped without a parent, saying that it is discouraged. See https://git.gnome.org/browse/gtk+/tree/gtk/gtkdialog.c#n776 On Mon, Aug 10, 2015 at 9:43 AM, Paul Davis p...@linuxaudiosystems.com wrote: On Mon, Aug 10, 2015 at

Re: Desktop as transient window

2015-08-10 Thread richard boaz
hi, i think this is a case when the warning, (which can be ignored), is meant for the developer, and not the end-user. i would trap the error, ignore it, and definitely not forward to the end-user; following the dictum avoid confusing them as much as possible... richard On Mon, Aug 10, 2015 at

Re: Desktop as transient window

2015-08-10 Thread Jasper St. Pierre
You can either ignore the warning, or simply use a window that isn't marked as a dialog as that first window. On Mon, Aug 10, 2015 at 9:31 AM, Igor Korot ikoro...@gmail.com wrote: Jasper, On Sun, Aug 9, 2015 at 7:19 PM, Jasper St. Pierre jstpie...@mecheye.net wrote: The desktop is not a

Desktop as transient window

2015-08-09 Thread Igor Korot
Hi, ALL, There is a function in GTK - gtk_window_set_transient_for() - which sets the parent window for the current one. Now the question I have is: is it possible to set the parent to become a Desktop? Let's say I have an application class and I want to make sure that I already have a TLW to

Re: Desktop as transient window

2015-08-09 Thread Jasper St. Pierre
The default transient window is NULL, so you don't have to do anything. On Sun, Aug 9, 2015 at 11:59 AM, Igor Korot ikoro...@gmail.com wrote: Hi, ALL, There is a function in GTK - gtk_window_set_transient_for() - which sets the parent window for the current one. Now the question I have is:

Re: Desktop as transient window

2015-08-09 Thread Igor Korot
Jasper, On Sun, Aug 9, 2015 at 6:39 PM, Jasper St. Pierre jstpie...@mecheye.net wrote: As mentioned, dialogs are designed to be parented to a specific window. As the warning says, this is discouraged (and might cause things like Wayland not to work correctly). You can ignore the warning if

Re: Desktop as transient window

2015-08-09 Thread Igor Korot
Hi, Jasper, On Sun, Aug 9, 2015 at 3:00 PM, Jasper St. Pierre jstpie...@mecheye.net wrote: The default transient window is NULL, so you don't have to do anything. OK, I did call gtk_window_set_transient_for( dlg, NULL );, but still got the warning GtkDialog mapped without a transient parent:

Re: Desktop as transient window

2015-08-09 Thread Jasper St. Pierre
The desktop is not a window. It could be in some desktop environments, but is not always. In fact, in some desktop environments, there is no desktop window or desktop concept at all. There is no standard protocol to fetch the desktop window if it exists, either. The reason that unparented dialogs

Re: Desktop as transient window

2015-08-09 Thread Jasper St. Pierre
As mentioned, dialogs are designed to be parented to a specific window. As the warning says, this is discouraged (and might cause things like Wayland not to work correctly). You can ignore the warning if you want. On Sun, Aug 9, 2015 at 3:34 PM, Igor Korot ikoro...@gmail.com wrote: Hi, Jasper,