ui: New style for tab bar in status view

This commit is contained in:
Eberhard Graether
2018-03-20 01:46:23 +01:00
parent 166d82b44f
commit 7783695d8d
7 changed files with 82 additions and 42 deletions
+13 -3
View File
@@ -473,9 +473,18 @@
<tab>
<background>#494949</background>
<active>#D4D4D4</active>
<hover>#878787</hover>
<text>#878787</text>
<bar>
<background>#808080</background>
<border>#BEBEBE</border>
<button>
<text>white</text>
<background>
<normal>#808080</normal>
<hover>#505050</hover>
<press>#494949</press>
</background>
</button>
</bar>
</tab>
<table>
@@ -497,6 +506,7 @@
<screen_search>
<background>#808080</background>
<border>#BEBEBE</border>
<box>
<background>#494949</background>
<text>#D4D4D4</text>
+13 -3
View File
@@ -434,9 +434,18 @@
<tab>
<background>white</background>
<active>black</active>
<hover>#878787</hover>
<text>#878787</text>
<bar>
<background>#E0E0E0</background>
<border>#BEBEBE</border>
<button>
<text>black</text>
<background>
<normal>#E0E0E0</normal>
<hover>#F0F0F0</hover>
<press>#FFFFFF</press>
</background>
</button>
</bar>
</tab>
<table>
@@ -458,6 +467,7 @@
<screen_search>
<background>#E0E0E0</background>
<border>#BEBEBE</border>
<box>
<background>white</background>
<text>black</text>
+15 -5
View File
@@ -444,20 +444,29 @@
<tab>
<background>#272728</background>
<active>white</active>
<hover>#878787</hover>
<text>#878787</text>
<bar>
<background>#555555</background>
<border>#BEBEBE</border>
<button>
<text>white</text>
<background>
<normal>#555555</normal>
<hover>#2F2F2F</hover>
<press>#272728</press>
</background>
</button>
</bar>
</tab>
<table>
<background>#272728</background>
<table>white</table>
<table>#C5C5C5</table>
<text>
<normal>white</normal>
<active>black</active>
</text>
<table_line_1>
<normal>darkgrey</normal>
<normal>#272728</normal>
<active>#969696</active>
</table_line_1>
<table_line_2>
@@ -468,6 +477,7 @@
<screen_search>
<background>#555555</background>
<border>#BEBEBE</border>
<box>
<background>#272728</background>
<text>#F7F7F7</text>
+37 -24
View File
@@ -1,38 +1,56 @@
QTabWidget::pane {
background-color: <color:tab/background>;
border-top: <setting:font_size+15>px solid <color:tab/bar/background>;
top: -<setting:font_size+15>px;
}
QTabWidget::tab-bar {
alignment: left;
left: 7px;
bottom: -1px;
}
QTabBar::tab {
background-color: <color:tab/background>;
color: <color:tab/text>;
padding: 12px 75px 5px 12px;
border: 0px;
border-bottom: 4px solid <color:tab/background>;
background-color: <color:tab/bar/button/background/normal>;
border-top: 1px solid <color:tab/bar/button/background/normal>;
border-bottom: 1px solid <color:tab/bar/border>;
border-top-left-radius: 7px;
border-top-right-radius: 7px;
color: <color:tab/bar/button/text>;
font-size: <setting:font_size>px;
height: <setting:font_size+8>;
margin-left: 4px;
margin-right: 1px;
margin-top: 4px;
width: 100px;
}
QTabBar::tab:hover {
border-bottom: 4px solid <color:tab/hover>;
margin-left: 3px;
margin-right: 0px;
background-color: <color:tab/bar/button/background/hover>;
border: 1px solid <color:tab/bar/border>;
}
QTabBar::tab:selected {
border-bottom: 4px solid <color:tab/active>;
color: <color:tab/active>;
QTabBar::tab:selected, QTabBar::tab:pressed {
margin-left: 3px;
margin-right: 0px;
background-color: <color:tab/bar/button/background/press>;
border: 1px solid <color:tab/bar/border>;
border-bottom: 1px solid <color:tab/bar/button/background/press>;
}
QTabWidget::pane {
top: 0px;
background: <color:tab/background>;
color: <color:tab/text>;
border: 0px;
margin: 0px;
padding: 0px;
QTabWidget #tab_content {
border-top: 1px solid <color:tab/bar/border>;
background-color: <color:tab/background>;
}
QTableView {
color: <color:table/text/normal>;
background-color: <color:table/table_line_1/normal>;
alternate-background-color: <color:table/table_line_2/normal>;
border-radius: 10px;
border-radius: 7px;
border-bottom-left-radius: 0px;
border-bottom-right-radius: 0px;
border: 1px solid <color:table/table>;
@@ -40,10 +58,6 @@ QTableView {
font-size: <setting:font_size>px;
}
QFrame {
background-color: <color:tab/background>;
}
QTableView::item {
border-left: 1px solid <color:table/table>;
}
@@ -89,16 +103,15 @@ QHeaderView::section:vertical {
QTableView QTableCornerButton::section {
background-color: <color:table/background>;
border-bottom: 1px solid <color:table/table>;
border-top-left-radius: 10px;
border-top-left-radius: 7px;
}
QCheckBox {
color: <color:table/text/normal>;
font-size: <setting:font_size>px;
}
#help_button {
background: transparent;
border: none;
/*margin: none;*/
/*padding: none;*/
}
-4
View File
@@ -8,10 +8,6 @@ TabbedView::TabbedView(ViewLayout* viewLayout, const std::string& name)
{
}
TabbedView::~TabbedView()
{
}
const std::vector<View*>& TabbedView::getViews() const
{
return m_views;
+1 -2
View File
@@ -11,9 +11,8 @@ class TabbedView
, public ViewLayout
{
public:
TabbedView(ViewLayout* viewLayout, const std::string& name);
virtual ~TabbedView();
virtual ~TabbedView() = default;
const std::vector<View*>& getViews() const;
+3 -1
View File
@@ -47,7 +47,9 @@ void QtTabbedView::refreshView()
void QtTabbedView::addViewWidget(View* view)
{
m_widget->addTab(QtViewWidgetWrapper::getWidgetOfView(view), view->getName().c_str());
QWidget* tabWidget = QtViewWidgetWrapper::getWidgetOfView(view);
tabWidget->setObjectName("tab_content");
m_widget->addTab(tabWidget, view->getName().c_str());
setStyleSheet();
}