Re: GTKMM: Adding Gtk::TextView member doesn't allow me to bring up the GUI anymore.



On Fri, 21 Aug 2009 20:30:05 -0700
jbu <jtb3f virginia edu> wrote:
> Hi all,
> 
> I'm a GTKMM and C++ newb, so this may be a very stupid mistake.
> 
> My problem is that adding the line "Gtk::TextView textView;" to my
> header causes my GUI not to display anymore.   Without that line, it
> comes up fine.  Note, that I have not included my source in this
> email/post because I did not change anything in the source.  The only
> change is that one line to the header as well as its corresponding
> "#include <gtkmm/textview.h" include statement. The GUI  just no
> longer comes up.  The program terminates/returns immediately without
> any error.  Also note that this compiles fine without warning.
> 
> I am using eclipse to develop as well as gtkmm 2.4 and I have ubuntu's
> gtk2.x package installed.

I am not sure what 'adding the line "Gtk::TextView textView;" to my
header' means, but probably you meant that you have defined a global
textview object.  You cannot do that because it will cause the textview
object to be created before main() is entered, which will be before
you have called the Gtk::Main constructor to initialise GTK+.

Chris


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