PDA

View Full Version : make each row of table widget not editable??



darpan
16th October 2006, 09:36
Hi,
how to make each row of table widget not editable.
Through qt designer or through coding.


Thanks and Regards

jpn
16th October 2006, 09:43
Pass an appropriate combination of flags to QTableWidgetItem::setFlags(), leaving Qt::ItemIsEditable out.

darpan
16th October 2006, 10:56
Hi,
I read all the flags which flag i have to use to make tablewidget item editable.

Thanks and Regards

darpan
16th October 2006, 11:00
Hi,
sorry, i want to make items in table widget not editable, by default items in table widge is editable.

Thanks and Regards

jpn
16th October 2006, 11:22
// this gives you a selectable and enabled, but non-editable item
item->setFlags(Qt::ItemIsSelectable | Qt::ItemIsEnabled);