[Gtk-sharp-list] Resizing Gtk.Table Dynamically

benji benoror at gmail.com
Wed Mar 7 14:36:09 EST 2007


I'm trying to make an app to dynamically resize a Gtk.Table, by adding or
removing columns. I've created a method to add columns and it works fine,
but when I want to remove the last columns nothing happens. Here is the
code:

    public void ResizeTable(uint n) {

        main_table.Resize(n,main_table.NRows);

        for(uint i=0;i<n;i++) {
            main_table.Attach(new Label("col["+i+"]"), i, i+1, 0, 1);
        }

        main_table.ShowAll();
    }


Also this code is kind of buggy because it "redraws" the labels in each
column.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/gtk-sharp-list/attachments/20070307/cee6edc0/attachment.html 


More information about the Gtk-sharp-list mailing list