QTabWidget/QTabBar Unique Background Images

  • I'm looking to modify the tabs on a QTabBar of a QTabWidget to have a unique background per tab. I have tried using QSS but that sets the same image on all tabs. I also want the appearance of the tabs to be more like a button, i.e. you don't see the tab edges, there are just images lined up with each other.

    Any tips/ideas how to do this? Can this be done in the designer?

  • It would be doable I think by subclassing QTabBar and/or using a proxy style, but not using designer.

  • Any links/examples I can look at? The closest I've seen is a custom QTabWidget that gives access to tabBars->setPallete() but that sets the same image to all tabs.

Log in to reply

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.