On 2018-05-08 14:20 Luca Bacci wrote:
>- Use Cell Data Func for ultimate flexibility
That is the signature
Gtk.TreeCellDataFunc(tree_column, cell, tree_model, iter, data)
But how do I know which cell (row and column) is affected?
I can extrat the row with tree_model[iter] but not the column
To have empty int cells, you can either
- use strings, instead of ints, in ListStore as you said
- make place for a third value in ListStore, of type bool, and control
the "visible" property of the first Cell Renderer with it (see code below)
- Use Cell Data Func for ultimate flexibili
Hello!
You can achieve what you want with the "xalign" property of CellRenderers
col_b = Gtk.TreeViewColumn('str',
Gtk.CellRendererText(xalign=1),
text=1)
xalign takes a value between 0 and 1.
xalign=0 -> left-justified
xalign=1 -> right-just