5

I style my QTabWidget and got a weird line on top of the tab bar. It only happens when it has multi tabs.

QTabWidget::pane {
    border-top: 1px solid #c4c4c4;
    top: -1px;
}

QTabWidget::tab-bar {
    left: 5px;
}

enter image description here

enter image description here

Any advice to fix this? Thanks.

mozart
  • 129
  • 11

1 Answers1

10

You need to turn off the base in the QTabBar:

QTabBar {
    qproperty-drawBase: 0;
}
Daniele Pantaleone
  • 2,657
  • 22
  • 33
  • 1
    FINALLY! God I spent way too long trying to figure this out with qss (I have a ton of styling going on in this app). – Spencer Jun 14 '18 at 00:39