Make trees/search consistent again using background role setter
This commit is contained in:
@@ -201,6 +201,7 @@ class GuiNovelToolBar(QWidget):
|
|||||||
iSz = SHARED.theme.baseIconSize
|
iSz = SHARED.theme.baseIconSize
|
||||||
|
|
||||||
self.setContentsMargins(0, 0, 0, 0)
|
self.setContentsMargins(0, 0, 0, 0)
|
||||||
|
self.setBackgroundRole(QPalette.ColorRole.Base)
|
||||||
self.setAutoFillBackground(True)
|
self.setAutoFillBackground(True)
|
||||||
|
|
||||||
# Novel Selector
|
# Novel Selector
|
||||||
@@ -270,10 +271,6 @@ class GuiNovelToolBar(QWidget):
|
|||||||
self.tbRefresh.setThemeIcon("refresh", "green")
|
self.tbRefresh.setThemeIcon("refresh", "green")
|
||||||
self.tbMore.setThemeIcon("more_vertical")
|
self.tbMore.setThemeIcon("more_vertical")
|
||||||
|
|
||||||
qPalette = self.palette()
|
|
||||||
qPalette.setBrush(QPalette.ColorRole.Window, qPalette.base())
|
|
||||||
self.setPalette(qPalette)
|
|
||||||
|
|
||||||
# StyleSheets
|
# StyleSheets
|
||||||
buttonStyle = SHARED.theme.getStyleSheet(STYLES_MIN_TOOLBUTTON)
|
buttonStyle = SHARED.theme.getStyleSheet(STYLES_MIN_TOOLBUTTON)
|
||||||
self.tbNovel.setStyleSheet(buttonStyle)
|
self.tbNovel.setStyleSheet(buttonStyle)
|
||||||
|
|||||||
@@ -245,6 +245,7 @@ class GuiProjectToolBar(QWidget):
|
|||||||
iSz = SHARED.theme.baseIconSize
|
iSz = SHARED.theme.baseIconSize
|
||||||
|
|
||||||
self.setContentsMargins(0, 0, 0, 0)
|
self.setContentsMargins(0, 0, 0, 0)
|
||||||
|
self.setBackgroundRole(QPalette.ColorRole.Base)
|
||||||
self.setAutoFillBackground(True)
|
self.setAutoFillBackground(True)
|
||||||
|
|
||||||
# Widget Label
|
# Widget Label
|
||||||
@@ -351,10 +352,6 @@ class GuiProjectToolBar(QWidget):
|
|||||||
|
|
||||||
def updateTheme(self) -> None:
|
def updateTheme(self) -> None:
|
||||||
"""Update theme elements."""
|
"""Update theme elements."""
|
||||||
qPalette = self.palette()
|
|
||||||
qPalette.setBrush(QPalette.ColorRole.Window, qPalette.base())
|
|
||||||
self.setPalette(qPalette)
|
|
||||||
|
|
||||||
buttonStyle = SHARED.theme.getStyleSheet(STYLES_MIN_TOOLBUTTON)
|
buttonStyle = SHARED.theme.getStyleSheet(STYLES_MIN_TOOLBUTTON)
|
||||||
self.tbQuick.setStyleSheet(buttonStyle)
|
self.tbQuick.setStyleSheet(buttonStyle)
|
||||||
self.tbMoveU.setStyleSheet(buttonStyle)
|
self.tbMoveU.setStyleSheet(buttonStyle)
|
||||||
|
|||||||
@@ -71,6 +71,7 @@ class GuiProjectSearch(QWidget):
|
|||||||
self._blocked = False
|
self._blocked = False
|
||||||
self._map: dict[str, tuple[int, float]] = {}
|
self._map: dict[str, tuple[int, float]] = {}
|
||||||
|
|
||||||
|
self.setContentsMargins(0, 0, 0, 0)
|
||||||
self.setBackgroundRole(QPalette.ColorRole.Base)
|
self.setBackgroundRole(QPalette.ColorRole.Base)
|
||||||
self.setAutoFillBackground(True)
|
self.setAutoFillBackground(True)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user