ok.... Strange I missed it ><
However how do I use this? I tried doing something like:
void MainInterface::DoubleClickInputTree(const QModelIndex& index) {
QStandardItem * t
= reinterpret_cast<QStandardItem
*>
(index.
internalPointer());
auto f(t->font());
f.setBold(true);
t->setFont(f);
}
void MainInterface::DoubleClickInputTree(const QModelIndex& index) {
QStandardItem * t = reinterpret_cast<QStandardItem *>(index.internalPointer());
auto f(t->font());
f.setBold(true);
t->setFont(f);
}
To copy to clipboard, switch view to plain text mode
So on double clicking an item it ought to be "bolded" - however this doesn't seem to work???? - How do I get the item corresponding to the qmodelindex?
EDIT:Nvm lol.. just after posting this I remembered reading "itemfromindex" somewhere so that helped me finding the correct function (auto t(model.itemFromIndex(index))
Bookmarks