Problems with Gtk::Expander



I have created a toplevel window like this:

<window>
  <vbox>
    <expander>
      <treeview>
    <table>
      <label><entry>
      <label><entry>
      ...

The glade file is available on my website [1].

The labels and entries in the table have a fixed height. Thus, resizing the window should change the size of the treeview (if it's not hidden by the expander of course). But it doesn' work the way I want it.

The window starts with the expander collapsed. When I use the arrow to expand it, the arrow changes its state, but the treeview remains invisible. See screenshot [2]. Only when I enlarge the toplevel window, I can make the treeview visible. It seems like the initial height of the treeview is zero? If I replace the treeview with another widget like a button, it is shown instantly (e.g. without enlarging the toplevel window).

Now, if I collapse again, the treeview disappears like it should, but the space where it used to be remains empty. See screenshot [3]. And that's not certainly not what I wanted. This empty space should be gone and the toplevel window should shrink. How can I do that?

[1] http://users.telenet.be/sacn/tmp/expander.glade
[2] http://users.telenet.be/sacn/tmp/expander_1.png
[3] http://users.telenet.be/sacn/tmp/expander_2.png




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