Re: ListStore and cell rendering
- From: Ron Lockwood-Childs <rchilds vctlabs com>
- To: gtk-app-devel-list gnome org
- Subject: Re: ListStore and cell rendering
- Date: Fri, 05 Mar 2004 17:39:10 -0800
Why don't you just concatenate the strings you have to a single
string?
Good question. Well, the column as it stands today _is_ a single
string. I'm using GTK2 as a memory display tool. The TreeView contains
address and data information, and there is a templating feature that
labels bit fields with structure members. Here's an example (hopefully
you're viewing this in a fixed-width font!):
Column 1 Column 2 Column 3
Address Data Binary
a_struct |v|status |data |
d0000000 ffff 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
I don't wish to make the binary column much wider, but there's a problem
if two different single-bit fields in the structure start with the same
letter (the code truncates the name to fit). The end user would like to
see the original bit field name if it's been truncated, and one way to
do that would be to have a tooltip that appears over the 'v' (in this
example) and displays "valid". That's where the multiple labels come
in, since there can only be one tooltip per widget. The templates can
be added at run-time, which is why I won't know in advance how many of
these labels I'd need for a given row. I suppose I could re-create the
TreeView column every time a new template gets added.. not a pleasant
option.
So, how soon until 2.6 comes out??
Cheers -Tim
PS: http://scentric.net/tutorial/treeview-tutorial.html
Thanks for the link! I have my web browser open to the tutorial while
writing this. I'm not too familiar with MVC design and was having a bit
of trouble learning about it from reading the TreeView API reference :).
--
Ron Lockwood-Childs
VCT Labs, Inc.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]