Make tab appearance nicer in locked mode

This commit is contained in:
Kovid Goyal 2023-04-03 10:21:20 +05:30
parent 9b8dce3034
commit b4fa38612b
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -383,8 +383,21 @@ QTabBar::tab:selected {
border-top-left-radius: 4px; border-top-left-radius: 4px;
border-top-right-radius: 4px; border-top-right-radius: 4px;
border-bottom-width: 0; border-bottom-width: 0;
padding: 2px; padding: 2px 8px;
padding-left: 0.5em; margin-left: -4px;
margin-right: -4px;
}
QTabBar::tab:first:selected {
margin-left: 0; /* the first selected tab has nothing to overlap with on the left */
}
QTabBar::tab:last:selected {
margin-right: 0; /* the last selected tab has nothing to overlap with on the right */
}
QTabBar::tab:only-one {
margin: 0; /* if there is only one tab, we don't want overlapping margins */
} }
''' '''
app.setStyleSheet(ss) app.setStyleSheet(ss)