diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/interface-gtk/interface-gtk.cpp | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/interface-gtk/interface-gtk.cpp b/src/interface-gtk/interface-gtk.cpp index 920f01b..ca04a6e 100644 --- a/src/interface-gtk/interface-gtk.cpp +++ b/src/interface-gtk/interface-gtk.cpp @@ -185,8 +185,8 @@ InterfaceGtk::get_options(void) /* * Parsing the option context with the Gtk option group - * will automatically initialize Gtk, so gtk_init() - * does not have to be called. + * will automatically initialize Gtk, but we do not yet + * open the default display. */ GOptionGroup *group = gtk_get_option_group(FALSE); @@ -215,6 +215,14 @@ InterfaceGtk::init(void) gdk_threads_init(); /* + * gtk_init() is not necessary when using gtk_get_option_group(), + * but this will open the default display. + * FIXME: Perhaps it is possible to defer this until we initialize + * interactive mode!? + */ + gtk_init(NULL, NULL); + + /* * Register clipboard registers. * Unfortunately, we cannot find out which * clipboards/selections are supported on this system, |