Killed "size-request" [was Re: 3.0 refactoring issues]



On Wed, 2010-10-27 at 13:24 +0900, Tristan Van Berkom wrote:
> On Tue, 2010-10-26 at 21:43 -0400, Matthias Clasen wrote:
> > On Tue, Oct 26, 2010 at 8:26 PM, Matthias Clasen
> > <matthias clasen gmail com> wrote:
> > 
> > > Proposed plan:
> > >
> > > 1. nuke size-request in GTK+
> > > 2. deprecate size-request in 2.91.3 (we can't use #ifdef deprecation
> > > for vfuncs, but maybe we can arrange things so that having a non-NULL
> > > size_request vfunc will trigger a runtime warning)
> > > 3. write patches for the rest of gnome (at least the 'core' desktop)
> > > 4. remove size-request in 2.91.4
> > >
> > > does that sound doable to you ?
> > >
> > 
> > I've pushed a kill-size-request branch that has the beginnings of 1.
> 
> Great that sounds very doable.
> 

I just landed the "kill-size-request" branch on master.

Current state is that all size_request vfuncs in GTK+ except
for the one on GtkWidgetClass has been removed, "size-request"
signal and vfunc is to be considered deprecated but as Matthias
mentioned we cant use #ifdef deprecation guards.

Currently any class that implements the size_request vfunc
will fire a runtime warning at request time.

It's important to migrate size_request implementations now,
either by using true height-for-width apis or by simply
falling back to a previously written static size_request 
function in your code and calling it from ->get_preferred_width()
and ->get_preferred_height().

The next step will be to remove the deprecated:
   - gtk_widget_size_request() function/api
   - GtkWidgetClass->size_request vfunc
   - GtkWidgetClass::size-request signal
   - Apply patch to stop invoking size requests from 
     height-for-width apis:
       https://bugzilla.gnome.org/show_bug.cgi?id=633324

Cheers all,
    -Tristan




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