Memory measurement via the task manager is like asking a baby the yield of a certain nuclear bomb :-)
It doesn't tell you the real information you want.
Nevertheless I believe you when your program starts using more and more memory. I also enjoyed using the list and tree widgets of windows.
Your understanding that using QStandardItemModel will reduce QTreeView to QTreeWidget isn't correct. QTreeWidget manages the items itself. Using a QTreeView together with QStandardItemModel changes nothing. It's a standard view and a standard model.
For SQL queries I suggest you look into one of the QSql...Model classes. Try it first with one of these and see if you still get big memory consumptions.
For a personal project I need to display thousands of items from a database in a treeview, and the memory consumption is minimal.
Bookmarks