Re: GtkImage changes



on 6/28/00 5:14 PM, Havoc Pennington at hp@redhat.com wrote:

>> It's particularly inconvenient to use the to save and restore the image from
>> a GtkImage with an arbitrary representation, but perhaps that's not a common
>> thing to want to do.
> 
> What do you mean by "save and restore"? To disk? Why would you do that?

I'm referring to the case where you want to temporarily change the image and
then change it back; the need to save and then later restore. Perhaps this
is not a common thing to want to do, as I said, but I find that this sort of
thing does come up in many other contexts.

>> I'd like to see more use of g_return_if_fail in these functions. Many of the
>> new functions don't validate their parameters and it's an easy thing to add.
> 
> I'll look over it. In most cases NULL is allowed though.

I'm not talking about checking for NULL, I'm talking about checking the
object, like this for something that can take a NULL or a valid pixmap.

    g_return_if_fail (pixmap == NULL || GDK_IS_PIXMAP (pixmap));

I thought this sort of checking was de rigeur in Gtk.

>> [...] This does cause an inconsistency
> 
> What's the inconsistency you mean?

That was the half-written comment I tried to retract with a subsequent
message :-)

    -- Darin





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