I want to create a Qt widget that looks like a QTabWidget
but where the list of tabs is drawn from a (Qt Model View architecture) data model, like QListView
etc. Since QTabWidget has to have separate widgets on each page, this will probably be something like a QTabBar
and a single set of widgets under it (eg some buttons and a QTreeView
).
- Can
QTabBar
get its list of tabs from a data model? I'm pretty sure not. - Is there an equivalent widget that can?
- Can you for example make a
QListView
withflow=LeftToRight
look like a tab bar?
Using Qt4 at the moment. Will consider Qt5.
I'm using PyQt but C++ examples would be fine.