nonmodal dialog, additional main windows



Folks,

Would really appreciate your help with the following. If its not obvious, I'm a neophyte with gtkmm.

I would like to create a nonmodal (nonblocking) dialog. I can create a dialog by subclassing Gtk::Dialog and using the run method of the subclass to show it. This works fine but the dialog is modal. I have tried making it nonmodal by calling show() instead of run() but then it doesn't appear at all. I have also tried making it nonmodal by calling the constructor of the superclass (ie Dialog) with the modal argument set to false, in the initialization list of my subclass' constructor, but this doesn't seem to change anything.

I thought perhaps I should subclass Gtk::Window instead of Gtk::Dialog to get around the problem. But I don't seem to be able to show a second main window. I show the first with Gtk::Main.run() and tried to show a second with its show() method, but it doesn't appear.

I apologize if these questions have simple answers. I'm mostly a java programmer and this stuff works quite differently in java, which may explain my confusion. Thanks in advance for your help.

Dermite


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]