[Glade-users] Widget choice, part II
- From: johnp martianrock com (John (J5) Palmieri)
- Subject: [Glade-users] Widget choice, part II
- Date: 01 Jun 2003 14:14:23 -0400
On Sat, 2003-05-31 at 14:42, Rich Shepard wrote:
I went to the API section of the GTK+ Web site and read the description of
the list/tree view widget. I understand the tree view, but I'm not sure if
the list view is the better widget for my contact manager than the combo box
+ text entry pair.
Accessability and flexability. GtkListStore was made to do what you
want to do. It has a model/view design so you can store all your data
in a GtkListStore and display, sort, drag and drop your data from a
GtkTreeView. The TreeView allows you to manipulate and display your
data better. A11y navigation is also correct in the ListView. Even if
you don't need these features now the TreeView stuff is so easy to work
with and gives you the power in the future should you need it.
If I use the list view, can I have the two columns display
telephone/e-mail information like this:
Office 123-456-7890
Fax 123-456-7891
Mobile 123-654-0987
E-mail username domain com
? And, if so, do they all display at once or can they be placed in a combo
box so only one is visible at a time?
I don't understand your question. GtkTreeViews when used with the GtkListStore
display in a table so you would have your headers and data under them:
Office Fax Mobile E-Mail
123-456-7890 123-456-7891 123-654-0987 username domain com
You could do what you are thinking of but then you lose all the sorting
functionality. Just set your columns to strings and you could do
somethig like this:
Contact Type Data
Office 123-456-7890
Fax 123-456-7891
Mobile 123-654-0987
E-mail username domain com
Also, could the list view hold wrapped text in the right-side column,
associated with a single entry in the left-side column? For example:
2003-06-12 Csdfeiwj eor w. Dxxx xx xpppx weriodf
owerjii asoeirj \]wlelrkejc oeraeoer.
Yes. Tree Views can hold any type of widget in their cells so if you
wanted automatic wrapping you could put one of the text widgets in and
make it so it is not editable.
Hope this helps somewhat.
--
J5
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]