Restyle tabbar
This commit is contained in:
parent
11bd966e1e
commit
fb9ac1bc4c
1
THANKS
1
THANKS
@ -24,6 +24,7 @@ valuable ones:
|
||||
- andrean
|
||||
- chelmuth
|
||||
- quark
|
||||
- Bleeding Fingers
|
||||
|
||||
Thanks to these people for helpful bits and pieces in the Qt bugtracker and IRC
|
||||
channel:
|
||||
|
@ -497,18 +497,22 @@ DATA = OrderedDict([
|
||||
|
||||
('tab.fg',
|
||||
SettingValue(types.Color(), "white"),
|
||||
"Foreground color of the tabbar."),
|
||||
"Foreground color of tabs."),
|
||||
|
||||
('tab.bg',
|
||||
SettingValue(types.Color(), "grey"),
|
||||
"Background color of the tabbar."),
|
||||
"Background color of unselected tabs."),
|
||||
|
||||
('tab.bg.selected',
|
||||
SettingValue(types.Color(), "black"),
|
||||
"Background color of the tabbar for the selected tab."),
|
||||
"Background color of selected tabs."),
|
||||
|
||||
('tab.bg.bar',
|
||||
SettingValue(types.Color(), "#555555"),
|
||||
"Background color of the tabbar."),
|
||||
|
||||
('tab.seperator',
|
||||
SettingValue(types.Color(), "white"),
|
||||
SettingValue(types.Color(), "#555555"),
|
||||
"Color for the tab seperator."),
|
||||
|
||||
('hints.fg',
|
||||
|
@ -33,9 +33,6 @@ class TabWidget(QTabWidget):
|
||||
STYLESHEET: The stylesheet template to be used.
|
||||
"""
|
||||
|
||||
# FIXME there is still some ugly 1px white stripe from somewhere if we do
|
||||
# background-color: grey for QTabBar...
|
||||
|
||||
STYLESHEET = """
|
||||
QTabWidget::pane {{
|
||||
position: absolute;
|
||||
@ -44,6 +41,7 @@ class TabWidget(QTabWidget):
|
||||
|
||||
QTabBar {{
|
||||
{font[tabbar]}
|
||||
{color[tab.bg.bar]}
|
||||
}}
|
||||
|
||||
QTabBar::tab {{
|
||||
@ -53,9 +51,6 @@ class TabWidget(QTabWidget):
|
||||
padding-right: 5px;
|
||||
padding-top: 0px;
|
||||
padding-bottom: 0px;
|
||||
}}
|
||||
|
||||
QTabBar::tab:first, QTabBar::tab:middle {{
|
||||
border-right: 1px solid {color[tab.seperator]};
|
||||
}}
|
||||
|
||||
@ -71,6 +66,7 @@ class TabWidget(QTabWidget):
|
||||
set_register_stylesheet(self)
|
||||
self.setDocumentMode(True)
|
||||
self.setElideMode(Qt.ElideRight)
|
||||
self.tabBar().setDrawBase(False)
|
||||
self._init_config()
|
||||
|
||||
def _init_config(self):
|
||||
|
Loading…
Reference in New Issue
Block a user