mattc
5th January 2010, 18:13
Hello,
I am wondering what's the difference between
myTableWidgetItem->setData(Qt::DisplayRole, "hello");
and
myTableWidgetItem->setText("hello");
when adding new items to a QTableWidget... I tried both approaches and cannot tell the difference. Which one should I choose?
(edit: also, it looks like setTextAlignment() works on both)
Thank you
I am wondering what's the difference between
myTableWidgetItem->setData(Qt::DisplayRole, "hello");
and
myTableWidgetItem->setText("hello");
when adding new items to a QTableWidget... I tried both approaches and cannot tell the difference. Which one should I choose?
(edit: also, it looks like setTextAlignment() works on both)
Thank you