0
votes

So we have custom QSS for tabs, and i want to recreate this look from standard tabs and for some reason im having trouble recreating it. I want the selected tab to look like its on top and go straight into the pane.

I have the borders of the tabs working when selected or not selected, but what i cant figure out is how you get the line at the top that spans the top of the pane but does not go under the tabs.

This is what i want it to look like with the line only going from the right most tab to the edge of the tabbar/pane.

enter image description here

This is what happens obviously when i try setting my QTabWidget::Pane border-top

enter image description here

When my tab is selected i dont want that blue line going across the bottom of the selected tab.

How do i keep the line from going all the way across my tab. Im sure this is a very simple task but for some reason i just cant figure out what property i need to be changing.

1
have a look at this maybe useful . - Redanium

1 Answers

0
votes

The answer was hidden in the QT documentation

By setting

position: absolute;
top: -2px;

On my QTabWidget::Pane, i can shift the pane top border upwards by 2 pixels, which is the width of my top border, so it goes behind my buttons and gives the proper effect.