bar update
This commit is contained in:
parent
df1e4f5cdd
commit
254fc9e27c
@ -1,5 +1,6 @@
|
||||
from PySide6.QtWidgets import QPushButton, QLabel, QVBoxLayout, QWidget
|
||||
from PySide6.QtCore import Qt
|
||||
from PySide6.QtGui import QFont
|
||||
|
||||
|
||||
class NavButton(QPushButton):
|
||||
@ -9,19 +10,21 @@ class NavButton(QPushButton):
|
||||
self.setObjectName("NavBtn")
|
||||
self.setCheckable(False)
|
||||
self.setCursor(Qt.PointingHandCursor)
|
||||
self.setMinimumHeight(80)
|
||||
|
||||
self._wrap = QWidget()
|
||||
wrap_layout = QVBoxLayout(self._wrap)
|
||||
wrap_layout.setContentsMargins(0, 0, 0, 0)
|
||||
wrap_layout.setSpacing(6)
|
||||
wrap_layout.setSpacing(8)
|
||||
|
||||
self._label = QLabel(text)
|
||||
self._label.setAlignment(Qt.AlignCenter)
|
||||
self._label.setFont(QFont("", 16, 600))
|
||||
|
||||
self._underline = QWidget()
|
||||
self._underline.setObjectName("NavUnderline")
|
||||
self._underline.setFixedHeight(3)
|
||||
self._underline.setFixedWidth(36)
|
||||
self._underline.setFixedHeight(4)
|
||||
self._underline.setFixedWidth(44)
|
||||
self._underline.setStyleSheet("background: transparent; border-radius: 2px;")
|
||||
|
||||
wrap_layout.addStretch(1)
|
||||
|
||||
@ -73,9 +73,10 @@ class MainWindow(QMainWindow):
|
||||
# Bottom bar (nav)
|
||||
self.bottombar = QWidget()
|
||||
self.bottombar.setObjectName("BottomBar")
|
||||
self.bottombar.setMinimumHeight(100)
|
||||
bottom = QHBoxLayout(self.bottombar)
|
||||
bottom.setContentsMargins(16, 8, 16, 8)
|
||||
bottom.setSpacing(10)
|
||||
bottom.setContentsMargins(16, 12, 16, 12)
|
||||
bottom.setSpacing(12)
|
||||
|
||||
self.nav_buttons = [
|
||||
NavButton("HOME"),
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user