GtkTreeView is a widget for displaying both trees and lists. It is part of the GTK library.
Questions tagged [gtktreeview]
217 questions
1
vote
2 answers
How to correlate gtk.ListStore items with my own models
I have a list of Project objects, that I display in a GtkTreeView. I am trying to open a dialog with a Project's details when the user double-clicks on the item's row in the TreeView.
Right now I get the selected value from the TreeView (which is…

Victor Stanciu
- 12,037
- 3
- 26
- 34
1
vote
1 answer
How to truncate a text in a custom GtkCellRenderer?
I trying to create custom GtkCellRenderer with some text. And I want this text truncated, when a size of GtkCellRenderer is smaller than size of text. For example:
alt text
How can I do this? Is this some property of CellRenderer or PangoLayout or I…

troorl
- 1,579
- 1
- 15
- 20
1
vote
1 answer
Gtk# TreeView set a single cell to have a different renderer?
OK this is probably insane, but I want to be able to have a check box at the very top of every row in my tree view. This box will "disable" or "enable" the ability to use the column. Oh I think it should be mentioned that I'm using a ListStore and…

David Stocking
- 1,200
- 15
- 26
1
vote
2 answers
Catch PyGTK TreeView reorder
I have a simple gtk.TreeView with a gtk.ListStore model and set_reorderable(True), I want to catch the signal/event emited when the user reorder through drag&drop the list, but the documentation does not help much:
"The application can listen to…

Htechno
- 5,901
- 4
- 27
- 37
1
vote
1 answer
How to render custom columns with a GenericTreeModel
I have to display some data in a treeview. The "real" data model is huge and I cannot copy all the stuff in a TreeStore, so I guess I should use a GenericTreeModel to act like a virtual treeview. Btw, the first column is the classic icon+text style…

Giorgio Gelardi
- 993
- 4
- 13
- 29
1
vote
1 answer
Gtk.TreeView:Python How to set background color row selected when lost focus of treeview
I have trouble in python gtk.TreeView: when a row selected on treeview it has background Blue, and then after that I changed focus to another object (example textbox) then the row was selected changed color to gray. I don't want change it to gray, I…

Cau Vo
- 11
- 2
1
vote
1 answer
How to list directory hierarchy in GtkTreeView widget?
I am trying to generate a hierarchical directory listing in pyGTK.
Currently, I have this following directory tree:
/root
folderA
- subdirA
- subA.py
- a.py
folderB
- b.py
I have written a function that…

sqram
- 7,069
- 8
- 48
- 66
1
vote
1 answer
How to read all gtk.TreeModelRow (in Python)
I have a gtkTreeView with this model structure:
Row One
.. Child One
....Grandson On
....Grandson Two
Row Two
..Child One
I need to read each one of this rows.
How can I do?
I'm a new bee in gtk.

Eduardo
- 1,698
- 4
- 29
- 48
1
vote
1 answer
Python - Gtk.TreeView with CheckBox
I need to store items in a Gtk TreeView and when interacting with this TreeView, the user will can select one or more items in the list.
Because I'm new to GTK, I managed to populate the treeview and display a checkbox as the code below shows. But…

Eduardo
- 1,698
- 4
- 29
- 48
1
vote
0 answers
In Gtk#, why might VALID_ITER fail even after I check it with IterIsValid?
I have a convenience function in my TreeView that looks something like this:
Card GetCardFromPath (TreePath path)
{
TreeIter iter;
if (path == null || !Model.GetIter (out iter, path))
return null;
if ((Model as…

Matthew
- 28,056
- 26
- 104
- 170
1
vote
2 answers
GtkTreeView's row-activated and cursor-changed signals
I have a treeview and I am watching for the cursor-changed and row-activated signals. The problem is that in order to trigger the row-activate I first have to click on the row (triggering cursor-changed) and then do the double click, requiring 3…

Rob
- 2,511
- 2
- 20
- 31
1
vote
1 answer
GObject Subclassing in Ruby for custom CellRenderer in GtkTreeView
I am trying to implement a customized CellRenderer in Ruby/GTK, and I've already found this suggestion:
GObject subclassing in Ruby
However, when I try the following:
class CellRendererCustom < Gtk::CellRendererText
type_register #register within…

genericus666
- 21
- 2
1
vote
1 answer
How to add different color to odd and even rows in a pygtk TreeView
I have created a pygtk TreeView and wanted to add different colors between each line. I went here and it says that there exists a TreeView Style property that does exactly the same.The property is called 'odd-row-color' and 'even-row-color'. So went…

Apostolos
- 7,763
- 17
- 80
- 150
1
vote
1 answer
GtkCellRendererText: "editable-set" set to FALSE does not deactivate editability?
If I use for example
g_object_set (renderer, "background", "red", "background-set", FALSE, NULL);
for a text renderer, the background color of a row inside a treeview is not set to red, as intended.
If I try something similar for the editability…

GTK 1.2.6 fanboy
- 839
- 1
- 5
- 20
1
vote
1 answer
gtktreeview works fine in the example but stops once copied into application
I have the following problem. I'm developing an application which uses gtktreeview for displaying data retrieved from MySQL database.
I've already done few examples of gtktreeview, I was able to add, clear, remove from the list. Now I wanted to…

Marek
- 1,413
- 2
- 20
- 36