diff --git a/win-linux/res/styles/styles.qss b/win-linux/res/styles/styles.qss index e8582ac3a..67d2c9f32 100644 --- a/win-linux/res/styles/styles.qss +++ b/win-linux/res/styles/styles.qss @@ -191,6 +191,10 @@ QPushButton#toolButtonDownload::menu-indicator { background-color: #404040; } +#mainPanel[uitheme=theme-dark] #labelAppTitle { + color: #d9d9d9; +} + #mainPanel[uitheme=theme-dark] QPushButton#toolButtonMain { border-right-color: #505050; } diff --git a/win-linux/src/win/csinglewindow.cpp b/win-linux/src/win/csinglewindow.cpp index 86f24a070..5f3a9ab74 100644 --- a/win-linux/src/win/csinglewindow.cpp +++ b/win-linux/src/win/csinglewindow.cpp @@ -265,9 +265,9 @@ LRESULT CALLBACK CSingleWindow::WndProc(HWND hWnd, UINT message, WPARAM wParam, PAINTSTRUCT ps; HDC hDC = ::BeginPaint(hWnd, &ps); HPEN hpenOld = static_cast(::SelectObject(hDC, ::GetStockObject(DC_PEN))); - ::SetDCPenColor(hDC, RGB(136, 136, 136)); + ::SetDCPenColor(hDC, AscAppManager::themes().colorRef(CThemes::ColorRole::ecrWindowBorder)); - HBRUSH hBrush = ::CreateSolidBrush(WINDOW_BACKGROUND_COLOR); + HBRUSH hBrush = ::CreateSolidBrush(AscAppManager::themes().colorRef(CThemes::ColorRole::ecrWindowBackground)); HBRUSH hbrushOld = static_cast(::SelectObject(hDC, hBrush)); ::Rectangle(hDC, rect.left, rect.top, rect.right, rect.bottom); @@ -486,12 +486,14 @@ void CSingleWindow::setScreenScalingFactor(uchar factor) QWidget * CSingleWindow::createMainPanel(QWidget * parent, const QString& title, bool custom, QWidget * view) { QWidget * mainPanel = new QWidget(parent); -// mainpanel->setObjectName("mainPanel"); + mainPanel->setObjectName("mainPanel"); + mainPanel->setProperty("uitheme", QString::fromStdWString(AscAppManager::themes().current())); QGridLayout * mainGridLayout = new QGridLayout(); mainGridLayout->setSpacing(0); mainGridLayout->setMargin(0); mainPanel->setLayout(mainGridLayout); + mainPanel->setStyleSheet(AscAppManager::getWindowStylesheets(m_dpiRatio)); // Central widget