Re: padding cleanup


On Thu, Sep 2, 2010 at 6:14 PM, Matthias Clasen
<matthias clasen gmail com> wrote:
> Of course, this only handles the size_request side of things.
> It would be up to individual containers to respect the h/v-align in
> their size_allocate (basically replacing their current child
> properties), correct ?

Couldn't we do it in gtk_widget_size_allocate ?

I can just try this patch and any reason it won't work may become clear quickly

> One thing that is not addressed yet is how we will split this between
> application control and theme control. To illustrate the point, here
> is the list of 'layout' properties we have currently:
> GtkAlignment::bottom-padding
> GtkAlignment::left-padding
> GtkAlignment::right-padding
> GtkAlignment::top-padding
> GtkContainer::border-width
> GtkMisc::xalign
> GtkMisc::yalign
> GtkMisc::xpad
> GtkMisc::ypad

The above would all be replaced by GtkWidget props I think

> GtkBox::spacing
> GtkButtonBox::layout-style
> GtkTable::column-spacing
> GtkTable::row-spacing
> GtkExpander::spacing

These would remain as container-specific probably (though I don't
really know what Expander::spacing is and didn't look)

> And here are some of the 'layout' style properties:

I think we could add style props on GtkWidget that would modify the
padding on the widget (I don't know if they'd just replace the
programmer-set padding, or be an adjustment to it?). That would be
simple once GtkWidget has padding, I think.

I don't know if the widget style props would replace most of these
though - it looks like most of these paddings and spacings are
somewhere inside a widget, not on the border.


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