[Interest] QInputDialog as item delegate?

Matthew Woehlke mwoehlke.floss at gmail.com
Tue Nov 12 21:45:46 CET 2019


I have a QTreeView. For one of the columns, rather than editing the data
in-place, I want to pop up a QTextEdit. (For now, I'm hoping I'll be
able to use QInputDialog, but I may end up needing to roll my own.)

Is it reasonable to execute the dialog (QDialog::exec()) in an override
of QAbstractItemDelegate::createEditor, or do I need to hook
itemActivated or some such? (Maybe QAbstractItemDelegate::editorEvent
would be better?)

What is the best way to trigger the editor?

-- 
Matthew


More information about the Interest mailing list