[pygtk] Enabling markup for a TreeViewColumn

Bryant Huang 735115 at gmail.com
Thu Mar 8 02:50:00 WST 2007


Hi Kurt,

THANK YOU!!!! Yes, that did it. I did try setting only markup=3Dcolumn_id, =
but
didn't know to take the text=3Dcolumn_id out. I think I get it now -- you s=
et
either text if you want plain text or markup if you want Pango markup, and
you give it the column ID you want it to apply to. That's what I get for
copying and pasting without understanding what it was doing!

Thanks,
Bryant

On 3/6/07, Kurt Symanzik <kurt at kbsymanzik.org> wrote:
>
> Bryant Huang wrote:
> > Hello,
> >
> > I've spent the last 3 hours trying to figure out how to highlight text
> > in a TreeView cell. I found the example at
> >
> http://www.pygtk.org/pygtk2tutorial/sec-CellRenderers.html#sec-CellRender=
erTextMarkup
> > but have been unable to replicate the same behavior in my own project.
> >
>
> I may have spoken too soon.  You may also need to not use the text
> field.  For example, change:
>
> column =3D gtk.TreeViewColumn(title, renderer, text=3Dcolumn_id, markup=
=3D0)
>
> to this:
>
> column =3D gtk.TreeViewColumn(title, renderer, markup=3Dcolumn_id)
>
> Hope that solves it.
>
> Kurt
>
> --
> Kurt Symanzik
> kurt at kbsymanzik.org
> Skype id: ksymanzik
> http://kbsymanzik.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.daa.com.au/pipermail/pygtk/attachments/20070307/95ecd1ac/at=
tachment.htm


More information about the pygtk mailing list