Nested Paned Windows



When working with nested paned windows, to restore the look what do I needs to
be saved?  

I've tried saving the paned windows geometry and restoring it with
gtk_paned_set_position, and I have saved the geometry information of the nested
widget's inside the paned window. But whether I restore one or the other or
both, I can not get the same original look.

I'm saving the changed geometry information by using a callback on each
object's "size_allocate" like:

void workspace_vpane_resize_cb(GtkWidget * panel, GtkAllocation * alloc) {
    Config.set("workspace_vpane_size", alloc->height);
    return;
}

and then restoring by:

sscanf(Config.getCString("workspace_vpane_size", "300"), "%i",&size);
gtk_paned_set_position(GTK_PANED(GET_CHILD_WIDGET(MainWdgt,"workspace_vpane")),
        size);


I understand that some of my problem may come from not totally understanding
Gtk's packing methodology, but surely if I tell each object a height or width
or both, the same look will return.

As for the information I am saving, I save the leaf object of the paned window
and the paned window.  Do I also need to save/restore the intermediate objects
as well?

Regards,

Chris

-----
Chris Freeze                                     Email: cfreeze@cs.clemson.edu
Computer Science Dept.                          Office: Jordan G-06 
Clemson University                               Phone: (864) 656-2636 
http://www.cs.clemson.edu/~cfreeze
-----




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