Re: gtk_container_new_child (was Re: Wrapping Box Container)

2010-09-06 Thread Havoc Pennington
I forgot that GtkWidget::parent already works: g_object_new (TYPE_FOO, parent, box, blah, 42, NULL) This is a pretty nice solution I think. You don't even have to save a pointer to the new object if you aren't doing anything other than adding it to parent and setting a couple of props. Havoc

Re: gtk_container_new_child (was Re: Wrapping Box Container)

2010-09-01 Thread Tristan Van Berkom
On Tue, 2010-08-31 at 18:32 -0400, Havoc Pennington wrote: Hi, On Mon, Aug 30, 2010 at 9:51 PM, Havoc Pennington h...@pobox.com wrote: With my proposed padding cleanup though that issue goes away: child = g_object_new(TYPE_MYCHILD, padding, 5, h-align, GTK_ALIGN_FILL_HORIZONTAL, NULL);

gtk_container_new_child (was Re: Wrapping Box Container)

2010-08-31 Thread Havoc Pennington
Hi, On Mon, Aug 30, 2010 at 9:51 PM, Havoc Pennington h...@pobox.com wrote: With my proposed padding cleanup though that issue goes away: child = g_object_new(TYPE_MYCHILD, padding, 5, h-align, GTK_ALIGN_FILL_HORIZONTAL, NULL); insert_child(layout, child, 2, GTK_WRAP_BOX_PACK_Y_EXPAND);