Re: Glade XML and TreeView



On Sun, 2008-02-17 at 12:28 -0500, Ryan Lovelett wrote:
> 
> Hello,
> 
> I subscribed to this mailing list last week in hopes of seeing
> something similar asked and solved so I could apply it to my project.
> I didn't so here is my question.
> 
> I'm creating a TreeView from within Glade 3 (so I'm getting an XML
> file).  I load and display the designed UI just fine from my
> kit.run(*MainDialog) call.  Now, I want to start adding stuff to the
> TreeView at runtime (in otherwords user input data, etc).  So I've set
> up the ModelColumns as described in
> (http://www.gtkmm.org/docs/gtkmm-2.4/docs/tutorial/html/chapter-treeview.html#sec-treeview-model).  They display just fine and I see my column headings.  Superb!
> 
> Now my problem.  If I am to understand how you add new columns you
> call:
> 
> Gtk::TreeModel::Row row = *(instanceofTreeModel->append());
> row[ModelColumnInstance.col] = "TextToDisplay";
> 
> Super, but nothing ever gets displayed on the screen after appending
> the new information to the TreeStore.  If I put that call before my
> kit.run(*MainDialog); it displays the information as expected.  It's
> almost like the TreeView widget needs to be re-drawn on screen for the
> data to show.  Is there some call that needs to be made that forces
> the re-draw of the TreeView?  Also, if you need and or want to see the
> full code just ask.

I think that in order to make any informed recommendations we'd need to
see some code.  If possible, the code sample should be as simple as
possible (and in paring down your example to a simple test case, you
might even find the problem somewhere)
-- 
Jonner



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