Bug#211113: marked as done (libgtk2.0-0: GtkCellRenderPixbuf problem)

Debian Bug Tracking System owner@bugs.debian.org
Tue, 08 Jun 2004 16:03:07 -0700


Your message dated Wed, 09 Jun 2004 00:54:35 +0200
with message-id <1086735275.21125.15.camel@seb128>
and subject line Bug#211113: libgtk2.0-0: GtkCellRenderPixbuf problem
has caused the attached Bug report to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what I am
talking about this indicates a serious mail system misconfiguration
somewhere.  Please contact me immediately.)

Debian bug tracking system administrator
(administrator, Debian Bugs database)

--------------------------------------
Received: (at submit) by bugs.debian.org; 15 Sep 2003 23:45:16 +0000
>From djdeath@gmx.fr Mon Sep 15 18:45:14 2003
Return-path: <djdeath@gmx.fr>
Received: from mail.gmx.net [213.165.64.20] 
	by master.debian.org with smtp (Exim 3.35 1 (Debian))
	id 19z31t-0001uV-00; Mon, 15 Sep 2003 18:45:13 -0500
Received: (qmail 18928 invoked by uid 65534); 15 Sep 2003 23:45:12 -0000
Received: from ALagny-109-1-21-203.w81-248.abo.wanadoo.fr (EHLO traktopel) (81.248.86.203)
  by mail.gmx.net (mp023) with SMTP; 16 Sep 2003 01:45:12 +0200
X-Authenticated: #12859812
Received: from djdeath by traktopel with local (Exim 4.22)
	id 19z332-0002n7-CN; Tue, 16 Sep 2003 01:46:24 +0200
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
From: Dj-Death <djdeath@gmx.fr>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: libgtk2.0-0: GtkCellRenderPixbuf problem
X-Mailer: reportbug 2.28
Date: Tue, 16 Sep 2003 01:46:24 +0200
Message-Id: <E19z332-0002n7-CN@traktopel>
Delivered-To: submit@bugs.debian.org
X-Spam-Status: No, hits=-5.0 required=4.0
	tests=HAS_PACKAGE
	version=2.53-bugs.debian.org_2003_9_14
X-Spam-Level: 
X-Spam-Checker-Version: SpamAssassin 2.53-bugs.debian.org_2003_9_14 (1.174.2.15-2003-03-30-exp)

Package: libgtk2.0-0
Version: 2.2.4-1
Severity: normal


Hi,
I often use GTK+ in my developments, and I had started
to write my own cell renderers.
I think I found a kind of bug in the GtkCellRendererPixbuf but
under specials conditions.
By using the "stock_id" property to displqy stock icons, I
found that if you set this one cell with the linked porperty
to NULL, it will draws an icon anyway. Using the last used icon.

I know this is hard to understand as described here. So I had
made a little example to explain the problem showing clearly
what's wrong.

This example could be found at http://djdeath.dyndns.org/~djdeath/pixbuf_render.c

In this example I create a window containing a GtkTreeView. The GtkTreeView
is displaying only one column which contains strings describing icons from the
stock. The first row has a string set to NULL and the first time the cell renderer
is called, nothing is displayed. But the second time, when the cell renderer needs
to redraw the cell, it displays an icon. And this is the bug.

How to fix ?

The problem is this one :
When giving information to the cell renderer, the icon is set to
the GtkCellRendererPixbuf get the icon from the stock and store it in
cellpixbuf->pixbuf (the stock id is stored in cellpixbuf->stock_id),
but when switching to the next cell to redraw, the GtkCellRendererPixbuf
doesn't clear his variables. So when it check if (cellpixbuf->pixbuf != NULL)
it's TRUE ! And so it redraw the cell with the previous pixbuf, even if
cellpixbuf->stock_id is NULL.
Note that if you have the "pixbuf" property linked you won't have this problem,
because cellpixbuf->pixbuf is set for every cell, even if you don't explicitly
specify his value in the GtkTreeStore.

Hopping this little bug will be fixed soon.
Thx.


-- System Information:
Debian Release: testing/unstable
Architecture: i386
Kernel: Linux traktopel 2.4.22-ck2 #7 lun sep 15 03:42:31 CEST 2003 i686
Locale: LANG=fr_FR@euro, LC_CTYPE=fr_FR@euro

Versions of packages libgtk2.0-0 depends on:
ii  libatk1.0-0                   1.2.4-1    The ATK accessibility toolkit
ii  libc6                         2.3.2-6    GNU C Library: Shared libraries an
ii  libfontconfig1                2.2.1-2    generic font configuration library
ii  libfreetype6                  2.1.4-5    FreeType 2 font engine, shared lib
ii  libglib2.0-0                  2.2.3-1    The GLib library of C routines
ii  libgtk2.0-common              2.2.4-1    Common files for the GTK+ graphica
ii  libjpeg62                     6b-8       The Independent JPEG Group's JPEG 
ii  libpango1.0-0                 1.2.5-1    Layout and rendering of internatio
ii  libpng12-0                    1.2.5.0-4  PNG library - runtime
ii  libtiff3g                     3.5.7-2    Tag Image File Format library
ii  libxft2                       2.1.1-2    advanced font drawing library for 
ii  xlibs                         4.2.1-11   X Window System client libraries
ii  zlib1g                        1:1.1.4-14 compression library - runtime

-- no debconf information


---------------------------------------
Received: (at 211113-done) by bugs.debian.org; 8 Jun 2004 22:55:07 +0000
>From seb128@debian.org Tue Jun 08 15:55:07 2004
Return-path: <seb128@debian.org>
Received: from smtp2.wanadoo.fr (mwinf0202.wanadoo.fr) [193.252.22.29] 
	by spohr.debian.org with esmtp (Exim 3.35 1 (Debian))
	id 1BXpUp-0006Ra-00; Tue, 08 Jun 2004 15:55:07 -0700
Received: from seb128 (ALille-208-1-22-109.w81-51.abo.wanadoo.fr [81.51.24.109])
	by mwinf0202.wanadoo.fr (SMTP Server) with ESMTP id 0AD9EA40017A
	for <211113-done@bugs.debian.org>; Wed,  9 Jun 2004 00:54:36 +0200 (CEST)
Received: from seb128 by seb128 with local (Exim 3.36 #1 (Debian))
	id 1BXpUJ-0002U3-00
	for <211113-done@bugs.debian.org>; Wed, 09 Jun 2004 00:54:35 +0200
Subject: Re: Bug#211113: libgtk2.0-0: GtkCellRenderPixbuf problem
From: Sebastien Bacher <seb128@debian.org>
To: 211113-done@bugs.debian.org
In-Reply-To: <20040608224321.GA3313@gmx.fr>
References: <1086469666.2483.10.camel@seb128> <20040608224321.GA3313@gmx.fr>
Content-Type: text/plain; charset=ISO-8859-15
Content-Transfer-Encoding: quoted-printable
Date: Wed, 09 Jun 2004 00:54:35 +0200
Message-Id: <1086735275.21125.15.camel@seb128>
Mime-Version: 1.0
X-Mailer: Evolution 1.5.8 
Sender: Sebastien Bacher <seb128@debian.org>
Delivered-To: 211113-done@bugs.debian.org
X-Spam-Checker-Version: SpamAssassin 2.60-bugs.debian.org_2004_03_25 
	(1.212-2003-09-23-exp) on spohr.debian.org
X-Spam-Status: No, hits=-4.8 required=4.0 tests=BAYES_00,FROM_ENDS_IN_NUMS,
	HAS_BUG_NUMBER autolearn=no version=2.60-bugs.debian.org_2004_03_25
X-Spam-Level: 

Le mer, 09/06/2004 =E0 00:43 +0200, [ATR]Dj-Death a =E9crit :

> Tested with GTK+ 2.4.1. Doesnt bug anymore ;)

Ok, so bug closed :)


> I join the test file.

Thanks


Cheers,

Sebastien Bacher