The Qt View/Model uses different principle to display and edit (DisplayRole and EditRole) items.
The Delegate classes are easy in providing Editing widgets. But for display it provide "paint()" method to be implemented in subclass, which I feel a real pain to implement.
How would one achieve both Display and Edit by same kind of Widget in a nicer way.
For example, how to make QTableView to DISPLAY a QString using QLineEdit and also EDIT it by using same kind of Widget (QLineEdit).
Similarly, how to make QTableView to DISPLAY a bool using QCheckBox and also EDIT it by using same kind of Widget (QCheckBox).
Thanks in advance.
Bookmarks