Re: GtkTextView PROP_TABS problem.



Jeff Franks <jcf tpg com au> writes:

>   Hi,
> 
> I think there is are two problems with the PROP_TABS property code in
> GtkTextview.
> 
> 1. The property is installed with the 'g_param_spec_boxed' type but
> GtkTextView's get_property and set_property functions get and set the
> PROP_TABS value by calling g_value_set_object and
> g_value_get_object. Shouldn't the function calls be to
> g_value_set_boxed and g_value_get_boxed since PangoTabArray is a boxed
> type.

Yes, this was wrong. Fixed.
 
> 2. Other boxed types like PROP_TABS and PROP_FONT_DESC in GtkTextTag
> and PROP_FONT_DESC in GtkCellRendererText all make  a copy of the
> boxed type in the set_property function and return a pointer to this
> copy in the get_property function. However, GtkTextView's PROP_TABS
> property returns a new copy.

Yes, there was a memory leak here, also fixed.

Thanks,
                                        Owen



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