[Glade-users] Realize event problem

On Thu, Oct 4, 2012 at 11:04 AM, John Coppens <john at jcoppens.com> wrote:
Hi all.

A newbie question (I don't use C++ too often, so this may be a lack of
experience). Composed with Glade (3.12, I believe):

- I have a window with a notebook.
- A (different) ScrolledWindow with a TextView in each page.
- Connected a function to the ...realize event of each, before
 calling the .run() method of the main program.

Page 1 and 2 receive the realize event. Page 0 doesn't. I suppose this
is because the textview is rendered on startup, and the events to page
1 and 2 only appear on changing pages.

But how can I get the realize event from page 0?
Does Gtk::Builder::create_from_file actually show() all the widgets
too? And even so, are the widgets realized before the kit.run() call?

Make sure your toplevel window defined in Glade has it's
"visible" property explicitly set to FALSE.

Otherwise it will be shown and it's contents realized before
gtk_builder_add_from_[somthing]() returns.


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