Hi, i want to customize a QTableWidgetItem after created but i get segmentation faults when retrieving the currentItem from a QTableWidget like this
aList->setItem(aList->rowCount()-2,
1,
aList
->currentItem
()->setForeground
(QBrush(Qt
::darkRed));
aList->setItem(aList->rowCount()-2,
1,
new QTableWidgetItem(tr("TOTAL :: ")));
aList->currentItem()->setForeground(QBrush(Qt::darkRed));
To copy to clipboard, switch view to plain text mode
why i can't use the QTWI returned by currentItem()? is there any way to do what im pretending the short way instead of creating the QTWI pointer and defining it before calling setItem()?
thanks
Bookmarks