[pygtk] Bold-Face line in a TreeView with glib2.10

Nemesis nemesis2001 at gmx.it
Sun May 28 00:02:22 WST 2006


On Sat, 27 May 2006 09:01:04 -0700
Brian <dol-sen at telus.net> wrote:

[problems with weight-set]

> It's working for my app just fine.  Currently at glib-2.10.2
[...]

>     def cell_data_func(self, column, renderer, model, iter, data):
>             """function to render the package name according
>                to whether it is in the world file or not"""
>             #full_name = model.get_value(iter, 0)
>             color = model.get_value(iter, 5)
>             if model.get_value(iter, 4):
>                 renderer.set_property("weight", pango.WEIGHT_BOLD)
>             else:
>                 renderer.set_property("weight", pango.WEIGHT_NORMAL)

But you aren't using 'weight-set', you are setting the weight property
each time to WEIGHT_BOLD or WEIGHT_NORMAL.

-- 
 
 |\ |       |HomePage   : http://nem01.altervista.org
 | \|emesis |XPN (my nr): http://xpn.altervista.org


More information about the pygtk mailing list