Post
by pops45042 » Fri Dec 22, 2006 4:46 pm
How in the world to I select an entire row given a QTreeView item. Its already got a data model associated with it. I can select the first item in the first column by doing:
Code: Select all
QItemSelectionModel *selection = new QItemSelectionModel( qTV->model() );
QModelIndex index = qTV->model()->index(0,0, QModelIndex() );
selection->select(index, QItemSelectionModel::Select);
qTV->setSelectionModel( selection);
I couldn't find a "row" selection and I don't know how many columns the view will contain.
any ideas,
Paul
Last edited by
pops45042 on Fri Dec 22, 2006 5:43 pm, edited 1 time in total.
"That which does not kill me only postpones the inevitable"
Laugh at my old system!
AMD Opteron 165@ 2750Mhz, 2gig 400mhz Cas2 Crucial Ballistix, Abit NF8 Ultra MB, WD 80gig (system), WD 120gig (storage), Geforce 8800GTS 320MB, Mushkin 550W PS