How can i set background of the inactive QTabWidget to transparent?
-

Workspace should be transparent instead of white.
I tried this but it didn't work:
objectTab->setStyleSheet("QTabWidget::pane { background-color: transparent; }"); workspaceTab->setStyleSheet("QTabWidget::pane { background-color: transparent; }"); tabWidget->setStyleSheet("QTabWidget::pane { background-color: transparent; }"); -

Workspace should be transparent instead of white.
I tried this but it didn't work:
objectTab->setStyleSheet("QTabWidget::pane { background-color: transparent; }"); workspaceTab->setStyleSheet("QTabWidget::pane { background-color: transparent; }"); tabWidget->setStyleSheet("QTabWidget::pane { background-color: transparent; }");@StudentScripter
QTabWidget::paneis the selector for the contents of tab widget i.e. the space beneath the tab bar. QTabWidget is a compound widget consisting of a QTabBar and a stack widget. To style the tabs you need a selector for the tab in a tab bar.tabWidget->setStyleSheet("QTabBar::tab:!selected { background-color: transparent; }"); -
@StudentScripter
QTabWidget::paneis the selector for the contents of tab widget i.e. the space beneath the tab bar. QTabWidget is a compound widget consisting of a QTabBar and a stack widget. To style the tabs you need a selector for the tab in a tab bar.tabWidget->setStyleSheet("QTabBar::tab:!selected { background-color: transparent; }");@Chris-Kawa Ah thank you very much. :) With all those properties its quite easy to get confused. May another question i have the tab widgets set to be movable. They are embedded in a dockwidget. However if ich drag very far to left or right the tab before releasing it shortly disapears behind the border. Is there a way to fix this?


-
@Chris-Kawa Ah thank you very much. :) With all those properties its quite easy to get confused. May another question i have the tab widgets set to be movable. They are embedded in a dockwidget. However if ich drag very far to left or right the tab before releasing it shortly disapears behind the border. Is there a way to fix this?


@StudentScripter That functionality is not exposed in the API much beyond enabling/disabling, so I guess you'd have to subclass QTabBar and provide your own implementation of drag/drop of the tabs or modify Qt itself if the license you chose accommodates that.
-
@StudentScripter That functionality is not exposed in the API much beyond enabling/disabling, so I guess you'd have to subclass QTabBar and provide your own implementation of drag/drop of the tabs or modify Qt itself if the license you chose accommodates that.
@Chris-Kawa Ok thank you very much, gonna have a look at that than. :)
Have a nice day.