/* --------------------------------------------------------------------------- WARNING! File created programmatically. All changes made in this file will be lost! Created by the qtsass compiler v0.3.0 The definitions are in the "qdarkstyle.qss._styles.scss" module --------------------------------------------------------------------------- */ /* Light Style - QDarkStyleSheet ------------------------------------------ */ /*See Qt documentation: - https://doc.qt.io/qt-5/stylesheet.html - https://doc.qt.io/qt-5/stylesheet-reference.html - https://doc.qt.io/qt-5/stylesheet-examples.html --------------------------------------------------------------------------- */ /* Reset elements ------------------------------------------------------------ Resetting everything helps to unify styles across different operating systems --------------------------------------------------------------------------- */ /* 颜色 ------------------------------------------------------------ 测试颜色: #ff0000 基本背景色: #e1e1e1 不可选背景色: #d9d9d9 内嵌正常背景色: #e1e1e1 内嵌悬停背景色: #c4c8e1 内嵌选中背景色: #aab0ce 内嵌不可点击背景色: #c5c5c5 实线边框颜色: #aaaaaa soild 沟壑边框颜色: #dadada groove 内嵌边框颜色: #e5e5e5 inset 悬停时边框颜色: #3c3c3c 选中时背景色: #6655cc 选中时描边色: #27214f 可点击字体颜色: #161616 不可点击字体颜色: #a5a5a5 不可点击且选中时颜色: #8c82cd 分割线正常时: #afafaf 分割线悬停时: #463c55 状态栏背景色: #d9d9d9 文本编辑器背景色: #bfbfbf 文本编辑器选中字体背景: #6f412f 文本编辑器选中字体颜色: 同正常字体色 --------------------------------------------------------------------------- */ /* 组件 方便定位 ------------------------------------------------------------ 可拖动窗口分割线 QMainWindow::separator 工具按钮悬浮提示 QToolTip 状态栏 QStatusBar 复选框 QCheckBox 分组框 QGroupBox 单选按钮 QRadioButton 菜单 QMenu 控制面板相关 QAbstractItemView 滚动条 QScrollBar 文本编辑器 QTextEdit 窗口大小控制器 QSizeGrip 堆叠窗口 QStackedWidget 选值框 QAbstractSpinBox 标签 QLabel 图形视图 QGraphicsView 日历组件 QCalendarWidget 液晶屏数字 QLCDNumber 进度条 QProgressBar 按钮 QPushButton 工具按钮 QToolButton 命令链接按钮 左边有个icon QCommandLinkButton 下拉列表 QComboBox 滑动条 QSlider 单行文本输入框 QLineEdit 选项卡 QTabWidget 标签栏 QTabBar 悬浮窗口 QDockWidget 树相关 QTreeView 表头 QHeaderView 抽屉 QToolBox 边框 QFrame 切分窗口 QSplitter 日期编辑器 QDateEdit 抽象视图 QAbstractView 图标视图 PlotWidget 表格视图 QTableWidget 表格 QTableView 列表视图 QListWidget 树窗口 QTreeWidget --------------------------------------------------------------------------- */ * { padding: 0px; margin: 0px; border: 0px; border-style: none; border-image: none; outline: 0; font-family:"Alibaba PuHuiTi"; /*font-family:"Microsoft Yahei";*/ } /* tool bar由ribbonBar 重新定义 */ /* QToolBar * { margin: 0px; padding: 0px; } */ /* QWidget ---------------------------------------------------------------- --------------------------------------------------------------------------- */ QWidget { background-color: #e1e1e1; border: 1px solid #aaaaaa; padding: 0px; color: #161616; /* 选中时背景色 不适合做渐变色,文件树UI会分层*/ /* selection-background-color: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #fedc45, stop: 1.0 #fb7099); */ selection-background-color:#6655cc; selection-color: #161616; } QWidget#QStatusBarLabelWidget { background-color: transparent; border: none; } QWidget:disabled { background-color: #e1e1e1; color: #a5a5a5; selection-background-color: #8c82cd; selection-color: #a5a5a5; } QWidget::item:selected { background-color: #6655cc; border: 1px solid #27214f; } QWidget::item:hover:!selected { background-color: #6655cc; } /* QMainWindow ------------------------------------------------------------ This adjusts the splitter in the dock widget, not qsplitter https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qmainwindow --------------------------------------------------------------------------- */ /* 可拖动窗口分割线 */ QMainWindow::separator { background-color: #afafaf; border: 0px solid #19232D; spacing: 0px; padding: 0px; } QMainWindow::separator:hover { background-color: #5193bd; border: 0px solid #1A72BB; } QMainWindow::separator:horizontal { width: 5px; margin-top: 1px; margin-bottom: 1px; image: url(":/rc/move_vertical.png"); } QMainWindow::separator:vertical { height: 5px; margin-left: 1px; margin-right: 1px; image: url(":/rc/move_horizontal.png"); } /* QToolTip --------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qtooltip --------------------------------------------------------------------------- */ /* 工具按钮悬浮提示 */ QToolTip { background-color: #6655cc; /* If you remove the border property, background stops working on Windows */ border: 1px solid #27214f; color: #161616; /* Remove padding, for fix combo box tooltip */ padding: 0px; /* Remove opacity, fix #174 - may need to use RGBA */ /* 0 - 255 */ opacity: 255; } /* QStatusBar ------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qstatusbar --------------------------------------------------------------------------- */ /* 状态栏 */ QStatusBar { border: none; /* Fixes Spyder #9120, #9121 */ background: #d9d9d9; /* background-color: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #fedc45, stop: 1.0 #d9d9d9); */ /* Fixes #205, white vertical borders separating items */ border-top: 0px solid #aaaaaa; border-left: 1px solid #aaaaaa; border-right: 1px solid #aaaaaa; border-bottom: 1px solid #aaaaaa; } QStatusBar::item { border: none; } QStatusBar QLabel { /* Fixes Spyder #9120, #9121 */ background: transparent; } /* QCheckBox -------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qcheckbox --------------------------------------------------------------------------- */ /* 复选框 */ QCheckBox { spacing: 4px; outline: none; padding-top: 4px; padding-bottom: 4px; border: none; } QCheckBox:focus { border: none; } QCheckBox QWidget:disabled { color: #a5a5a5; border: none; } QCheckBox::indicator { margin-left: 2px; height: 14px; width: 14px; } QCheckBox::indicator:unchecked { image: url(":/rc/checkbox_unchecked.png"); } QCheckBox::indicator:unchecked:hover, QCheckBox::indicator:unchecked:focus, QCheckBox::indicator:unchecked:pressed { border: none; image: url(":/rc/checkbox_unchecked_focus.png"); } QCheckBox::indicator:unchecked:disabled { image: url(":/rc/checkbox_unchecked_disabled.png"); } QCheckBox::indicator:checked { image: url(":/rc/checkbox_checked.png"); } QCheckBox::indicator:checked:hover, QCheckBox::indicator:checked:focus, QCheckBox::indicator:checked:pressed { border: none; image: url(":/rc/checkbox_checked_focus.png"); } QCheckBox::indicator:checked:disabled { image: url(":/rc/checkbox_checked_disabled.png"); } QCheckBox::indicator:indeterminate { image: url(":/rc/checkbox_indeterminate.png"); } QCheckBox::indicator:indeterminate:disabled { image: url(":/rc/checkbox_indeterminate_disabled.png"); } QCheckBox::indicator:indeterminate:focus, QCheckBox::indicator:indeterminate:hover, QCheckBox::indicator:indeterminate:pressed { image: url(":/rc/checkbox_indeterminate_focus.png"); } QGroupBox QCheckBox { background-color:transparent; } /* QGroupBox -------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qgroupbox --------------------------------------------------------------------------- */ /* 分组框 */ QGroupBox { font-weight: bold; border: 3px groove #dadada; border-radius: 4px; padding: 2px; margin-top: 6px; margin-bottom: 4px; background-color: #313131; } QGroupBox::title { subcontrol-origin: margin; subcontrol-position: top left; left: 4px; padding-left: 2px; padding-right: 4px; padding-top: -4px; } QGroupBox::indicator { margin-left: 2px; margin-top: 2px; padding: 0; height: 14px; width: 14px; } QGroupBox::indicator:unchecked { border: none; image: url(":/rc/checkbox_unchecked.png"); } QGroupBox::indicator:unchecked:hover, QGroupBox::indicator:unchecked:focus, QGroupBox::indicator:unchecked:pressed { border: none; image: url(":/rc/checkbox_unchecked_focus.png"); } QGroupBox::indicator:unchecked:disabled { image: url(":/rc/checkbox_unchecked_disabled.png"); } QGroupBox::indicator:checked { border: none; image: url(":/rc/checkbox_checked.png"); } QGroupBox::indicator:checked:hover, QGroupBox::indicator:checked:focus, QGroupBox::indicator:checked:pressed { border: none; image: url(":/rc/checkbox_checked_focus.png"); } QGroupBox::indicator:checked:disabled { image: url(":/rc/checkbox_checked_disabled.png"); } /* QRadioButton ----------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qradiobutton --------------------------------------------------------------------------- */ /* 单选按钮 */ QRadioButton { background-color: transparent; spacing: 4px; padding-top: 4px; padding-bottom: 4px; border: none; outline: none; } QRadioButton:focus { border: none; } QRadioButton:disabled { background-color: transparent; color: #a5a5a5; border: none; outline: none; } QRadioButton QWidget { background-color: transparent; spacing: 0px; padding: 0px; outline: none; border: none; } QRadioButton::indicator { border: none; outline: none; margin-left: 2px; height: 14px; width: 14px; } QRadioButton::indicator:unchecked { image: url(":/rc/radio_unchecked.png"); } QRadioButton::indicator:unchecked:hover, QRadioButton::indicator:unchecked:focus, QRadioButton::indicator:unchecked:pressed { border: none; outline: none; image: url(":/rc/radio_unchecked_focus.png"); } QRadioButton::indicator:unchecked:disabled { image: url(":/rc/radio_unchecked_disabled.png"); } QRadioButton::indicator:checked { border: none; outline: none; image: url(":/rc/radio_checked.png"); } QRadioButton::indicator:checked:hover, QRadioButton::indicator:checked:focus, QRadioButton::indicator:checked:pressed { border: none; outline: none; image: url(":/rc/radio_checked_focus.png"); } QRadioButton::indicator:checked:disabled { outline: none; image: url(":/rc/radio_checked_disabled.png"); } /* QMenuBar --------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qmenubar --------------------------------------------------------------------------- */ /* 已使用ribbonBar替换 */ /* QMenuBar { background-color: #ff0000; padding: 2px; border: 1px solid #ff0000; color: #ff0000; selection-background-color: #1A72BB; } QMenuBar:focus { border: 1px solid #ff0000; } QMenuBar::item { background: transparent; padding: 4px; } QMenuBar::item:selected { padding: 4px; background: transparent; border: 0px solid #455364; background-color: #1A72BB; } QMenuBar::item:pressed { padding: 4px; border: 0px solid #455364; background-color: #1A72BB; color: #ff0000; margin-bottom: 0px; padding-bottom: 0px; } */ /* QMenu ------------------------------------------------------------------ https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qmenu --------------------------------------------------------------------------- */ /* 菜单 */ QMenu { background-color: #e1e1e1; border: 1px solid #aaaaaa; padding: 0px; color: #161616; /* 选中时背景色 不适合做渐变色,文件树UI会分层*/ /* selection-background-color: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #fedc45, stop: 1.0 #fb7099); */ selection-background-color:#6655cc; selection-color: #161616; } QMenu::separator { height: 1px; background-color: #aaaaaa; color: #161616; } QMenu::item { background-color: transparent; padding: 4px 24px 4px 10px; /* Reserve space for selection border */ border: none; } QMenu::item:selected { color: #161616; background-color: #6655cc; } QMenu::item:pressed { background-color: #27214f; } QMenu::icon { padding-left: 10px; width: 14px; height: 14px; } QMenu::indicator { padding-left: 8px; width: 12px; height: 12px; /* non-exclusive indicator = check box style indicator (see QActionGroup::setExclusive) */ /* exclusive indicator = radio button style indicator (see QActionGroup::setExclusive) */ } QMenu::indicator:non-exclusive:unchecked { image: url(":/rc/checkbox_unchecked.png"); } QMenu::indicator:non-exclusive:unchecked:hover, QMenu::indicator:non-exclusive:unchecked:focus, QMenu::indicator:non-exclusive:unchecked:pressed { border: none; image: url(":/rc/checkbox_unchecked_focus.png"); } QMenu::indicator:non-exclusive:unchecked:disabled { image: url(":/rc/checkbox_unchecked_disabled.png"); } QMenu::indicator:non-exclusive:checked { image: url(":/rc/checkbox_checked.png"); } QMenu::indicator:non-exclusive:checked:hover, QMenu::indicator:non-exclusive:checked:focus, QMenu::indicator:non-exclusive:checked:pressed { border: none; image: url(":/rc/checkbox_checked_focus.png"); } QMenu::indicator:non-exclusive:checked:disabled { image: url(":/rc/checkbox_checked_disabled.png"); } QMenu::indicator:non-exclusive:indeterminate { image: url(":/rc/checkbox_indeterminate.png"); } QMenu::indicator:non-exclusive:indeterminate:disabled { image: url(":/rc/checkbox_indeterminate_disabled.png"); } QMenu::indicator:non-exclusive:indeterminate:focus, QMenu::indicator:non-exclusive:indeterminate:hover, QMenu::indicator:non-exclusive:indeterminate:pressed { image: url(":/rc/checkbox_indeterminate_focus.png"); } QMenu::indicator:exclusive:unchecked { image: url(":/rc/radio_unchecked.png"); } QMenu::indicator:exclusive:unchecked:hover, QMenu::indicator:exclusive:unchecked:focus, QMenu::indicator:exclusive:unchecked:pressed { border: none; outline: none; image: url(":/rc/radio_unchecked_focus.png"); } QMenu::indicator:exclusive:unchecked:disabled { image: url(":/rc/radio_unchecked_disabled.png"); } QMenu::indicator:exclusive:checked { border: none; outline: none; image: url(":/rc/radio_checked.png"); } QMenu::indicator:exclusive:checked:hover, QMenu::indicator:exclusive:checked:focus, QMenu::indicator:exclusive:checked:pressed { border: none; outline: none; image: url(":/rc/radio_checked_focus.png"); } QMenu::indicator:exclusive:checked:disabled { outline: none; image: url(":/rc/radio_checked_disabled.png"); } QMenu::right-arrow { margin: 5px; padding-left: 12px; image: url(":/rc/arrow_right.png"); height: 12px; width: 12px; } /* QAbstractItemView ------------------------------------------------------ https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qcombobox --------------------------------------------------------------------------- */ /* 控制面板相关 */ QAbstractItemView { alternate-background-color: #e1e1e1; color: #161616; border: none; /* border: 15px solid #455364; */ border-radius: 4px; } QAbstractItemView QLineEdit { padding: 2px; } /* QAbstractScrollArea ---------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qabstractscrollarea --------------------------------------------------------------------------- */ /* 好想主要是设置滚动区域背景,下面参数反而使得一些UI显示异常,暂不配置使用widget参数显示 */ /* QAbstractScrollArea { background-color: transparent; border: 0px solid #455364; border-radius: 4px; padding: 2px; color: #161616; } QAbstractScrollArea:disabled { color: #161616; } */ /* QScrollArea ------------------------------------------------------------ --------------------------------------------------------------------------- */ /* 暂时不知道作用对象,不使用 */ /* QScrollArea QWidget QWidget:disabled { background-color: #19232D; } */ /* QScrollBar ------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qscrollbar --------------------------------------------------------------------------- */ /* 滚动条 */ QScrollBar:horizontal { height: 12px; border: 0px solid #455364; border-radius: 0px; background-color: #414141; } QScrollBar:vertical { width: 12px; border: 0px solid #455364; border-radius: 0px; background-color: #414141; } QScrollBar::handle:horizontal { background-color: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #818181, stop: 1.0 #535353); border: none; border-radius: 0px; margin: 1px 12px 1px 12px; min-width: 8px; } QScrollBar::handle:horizontal:hover { background-color: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #a3a3a3, stop: 1.0 #6c6c6c); } QScrollBar::handle:vertical { background-color: qlineargradient(x1: 0, y1: 0, x2: 1, y2: 0,stop: 0 #818181, stop: 1.0 #535353); border: none; border-radius: 0px; margin: 12px 1px 12px 1px; min-height: 8px; } QScrollBar::handle:vertical:hover { background-color: qlineargradient(x1: 0, y1: 0, x2: 1, y2: 0,stop: 0 #a3a3a3, stop: 1.0 #6c6c6c); } QScrollBar::add-line:horizontal { margin: 0px 0px 0px 0px; border-image: url(":/rc/arrow_right_disabled.png"); height: 10px; width: 10px; subcontrol-position: right; subcontrol-origin: margin; } QScrollBar::add-line:horizontal:hover, QScrollBar::add-line:horizontal:on { border-image: url(":/rc/arrow_right.png"); height: 10px; width: 10px; subcontrol-position: right; subcontrol-origin: margin; } QScrollBar::add-line:vertical { margin: 0px 0px 0px 0px; border-image: url(":/rc/arrow_down_disabled.png"); height: 10px; width: 10px; subcontrol-position: bottom; subcontrol-origin: margin; } QScrollBar::add-line:vertical:hover, QScrollBar::add-line:vertical:on { border-image: url(":/rc/arrow_down.png"); height: 10px; width: 10px; subcontrol-position: bottom; subcontrol-origin: margin; } QScrollBar::sub-line:horizontal { margin: 0px 0px 0px 0px; border-image: url(":/rc/arrow_left_disabled.png"); height: 10px; width: 10px; subcontrol-position: left; subcontrol-origin: margin; } QScrollBar::sub-line:horizontal:hover, QScrollBar::sub-line:horizontal:on { border-image: url(":/rc/arrow_left.png"); height: 10px; width: 10px; subcontrol-position: left; subcontrol-origin: margin; } QScrollBar::sub-line:vertical { margin: 0px 0px 0px 0px; border-image: url(":/rc/arrow_up_disabled.png"); height: 10px; width: 10px; subcontrol-position: top; subcontrol-origin: margin; } QScrollBar::sub-line:vertical:hover, QScrollBar::sub-line:vertical:on { border-image: url(":/rc/arrow_up.png"); height: 10px; width: 10px; subcontrol-position: top; subcontrol-origin: margin; } QScrollBar::up-arrow:horizontal, QScrollBar::down-arrow:horizontal { background: none; } QScrollBar::up-arrow:vertical, QScrollBar::down-arrow:vertical { background: none; } QScrollBar::add-page:horizontal, QScrollBar::sub-page:horizontal { background: none; } QScrollBar::add-page:vertical, QScrollBar::sub-page:vertical { background: none; } /* QTextEdit -------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-specific-widgets --------------------------------------------------------------------------- */ /* 文本编辑器 */ QTextEdit { background-color: #bfbfbf; color: #161616; border-radius: 4px; border: 1px solid #aaaaaa; selection-background-color:#6f412f; selection-color: #161616; } /* QPlainTextEdit --------------------------------------------------------- --------------------------------------------------------------------------- */ /* 好像没有用到这个,暂不启用 */ /* QPlainTextEdit { background-color: #19232D; color: #161616; border-radius: 4px; border: 1px solid #455364; } QPlainTextEdit:focus { border: 1px solid #1A72BB; } QPlainTextEdit:selected { background: #346792; color: #455364; } */ /* QSizeGrip -------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qsizegrip --------------------------------------------------------------------------- */ /* 窗口大小控制器 */ QSizeGrip { background: transparent; width: 10px; height: 10px; image: url(":/rc/window_grip.png"); border:none; } /* QStackedWidget --------------------------------------------------------- --------------------------------------------------------------------------- */ /* 堆叠窗口,工程树那块 */ QStackedWidget { padding: 2px; border: 1px solid #aaaaaa; } /* QToolBar --------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qtoolbar --------------------------------------------------------------------------- */ /* 使用ribbonBar替换,设置无效 */ /* QToolBar { background-color: #455364; border-bottom: 1px solid #19232D; padding: 1px; font-weight: bold; spacing: 2px; } QToolBar:disabled { background-color: #455364; } QToolBar::handle:horizontal { width: 16px; image: url(":/rc/toolbar_move_horizontal.png"); } QToolBar::handle:vertical { height: 16px; image: url(":/rc/toolbar_move_vertical.png"); } QToolBar::separator:horizontal { width: 16px; image: url(":/rc/toolbar_separator_horizontal.png"); } QToolBar::separator:vertical { height: 16px; image: url(":/rc/toolbar_separator_vertical.png"); } QToolButton#qt_toolbar_ext_button { background: #455364; border: 0px; color: #161616; image: url(":/rc/arrow_right.png"); } */ /* QAbstractSpinBox ------------------------------------------------------- --------------------------------------------------------------------------- */ /* 选值框 */ QAbstractSpinBox { background-color: #e1e1e1; border: 2px inset #e5e5e5; color: #161616; /* This fixes 103, 111 */ padding-top: 2px; /* This fixes 103, 111 */ padding-bottom: 2px; padding-left: 4px; padding-right: 4px; border-radius: 4px; /* min-width: 5px; removed to fix 109 */ selection-background-color:#6f412f; } QAbstractSpinBox:up-button { background-color: transparent #19232D; subcontrol-origin: border; subcontrol-position: top right; border:none; margin: 1px; width: 12px; margin-bottom: -1px; } QAbstractSpinBox::up-arrow, QAbstractSpinBox::up-arrow:disabled, QAbstractSpinBox::up-arrow:off { image: url(":/rc/arrow_up_disabled.png"); height: 8px; width: 8px; } QAbstractSpinBox::up-arrow:hover { image: url(":/rc/arrow_up.png"); } QAbstractSpinBox:down-button { background-color: transparent #19232D; subcontrol-origin: border; subcontrol-position: bottom right; border:none; margin: 1px; width: 12px; margin-top: -1px; } QAbstractSpinBox::down-arrow, QAbstractSpinBox::down-arrow:disabled, QAbstractSpinBox::down-arrow:off { image: url(":/rc/arrow_down_disabled.png"); height: 8px; width: 8px; } QAbstractSpinBox::down-arrow:hover { image: url(":/rc/arrow_down.png"); } QAbstractSpinBox:hover { background-color: #c4c8e1; } QAbstractSpinBox:focus { background-color: #aab0ce; } QAbstractSpinBox:disabled { background-color: #c5c5c5; } /* ------------------------------------------------------------------------ */ /* DISPLAYS --------------------------------------------------------------- */ /* ------------------------------------------------------------------------ */ /* QLabel ----------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qframe --------------------------------------------------------------------------- */ /* 标签 */ QLabel { background-color: transparent; border: none; padding: 2px; margin: 0px; color: #161616; } QLabel:disabled { background-color: transparent; border: none; color: #9DA9B5; } /* QGraphicsView ---------------------------------------------------------- --------------------------------------------------------------------------- */ /* 图形视图 暂时没有用到 先屏蔽 */ /* QGraphicsView { background-color: #19232D; border: 1px solid #455364; color: #161616; border-radius: 4px; } QGraphicsView:disabled { background-color: #19232D; border: 1px solid #455364; color: #9DA9B5; border-radius: 4px; } QGraphicsView:hover, QGraphicsView:!hover, QGraphicsView:selected, QGraphicsView:pressed { border: 1px solid #455364; } */ /* QCalendarWidget -------------------------------------------------------- --------------------------------------------------------------------------- */ /* 日历组件 */ /* QCalendarWidget { border: 1px solid #455364; border-radius: 4px; } QCalendarWidget:disabled { background-color: #19232D; color: #9DA9B5; } */ /* QLCDNumber ------------------------------------------------------------- --------------------------------------------------------------------------- */ /* 液晶屏数字 */ /* QLCDNumber { background-color: #19232D; color: #161616; } QLCDNumber:disabled { background-color: #19232D; color: #9DA9B5; } */ /* QProgressBar ----------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qprogressbar --------------------------------------------------------------------------- */ /* 进度条 */ QProgressBar { text-align: center; background-color: #e1e1e1; border: 2px inset #e5e5e5; border-radius: 4px; } QProgressBar::chunk { border-radius: 4px; background-color: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #c872f2, stop: 1.0 #f772d1); } /* QPushButton ------------------------------------------------------------ https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qpushbutton --------------------------------------------------------------------------- */ /* 按钮 */ QPushButton { background-color: transparent; /* padding-top:2px; padding-bottom:2px; padding-right:8px; padding-left:8px; */ border-width: 4px 4px 4px 4px; border-image:url(:/rc/btn_normal.png)4 4 4 4 stretch stretch; } QPushButton:disabled { color: #ffffff; border-image:url(:/rc/btn_disable.png)4 4 4 4 stretch stretch; } /* 选中状态,等待下一个操作 */ QPushButton:checked { border-image:url(:/rc/btn_checked.png)4 4 4 4 stretch stretch; } QPushButton:checked:disabled { color: #9DA9B5; border-image:url(:/rc/btn_checked_disable.png)4 4 4 4 stretch stretch; } QPushButton:checked:hover { border-image:url(:/rc/btn_checked_above.png)4 4 4 4 stretch stretch; } QPushButton:hover { border-image:url(:/rc/btn_above.png)4 4 4 4 stretch stretch; } QPushButton:pressed { border-image:url(:/rc/btn_clicked.png)4 4 4 4 stretch stretch; } QPushButton:selected { background: #60798B; color: #161616; border-image:url(:/rc/btn_clicked.png)4 4 4 4 stretch stretch; } QPushButton::menu-indicator { subcontrol-origin: padding; subcontrol-position: bottom right; bottom: 4px; } QDialogButtonBox QPushButton { /* Issue #194 #248 - Special case of QPushButton inside dialogs, for better UI */ min-width: 100px; } /* 红色按钮 */ QPushButton#pushButtonDelete{ background-color: transparent; /* padding-top:2px; padding-bottom:2px; padding-right:8px; padding-left:8px; */ border-width: 4px 4px 4px 4px; border-image:url(:/rc/btn_normal_red.png)4 4 4 4 stretch stretch; } QPushButton#pushButtonDelete:disabled { color: #ffffff; border-image:url(:/rc/btn_disable.png)4 4 4 4 stretch stretch; } QPushButton#pushButtonDelete:hover { border-image:url(:/rc/btn_above_red.png)4 4 4 4 stretch stretch; } QPushButton#pushButtonDelete:pressed { border-image:url(:/rc/btn_clicked_red.png)4 4 4 4 stretch stretch; } /* QToolButton ------------------------------------------------------------ https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qtoolbutton --------------------------------------------------------------------------- */ /* 工具按钮 */ QToolButton { background-color: transparent; outline: none; padding: 2px; border-radius: 2px; border:none; /* The subcontrols below are used only in the DelayedPopup mode */ /* The subcontrols below are used only in the MenuButtonPopup mode */ /* The subcontrol below is used only in the InstantPopup or DelayedPopup mode */ } QToolButton:disabled { background-color: #d9d9d9; color: #a5a5a5; border:1px solid #aaaaaa; } QToolButton:checked { background-color: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #556bb2, stop: 1.0 #00697f); border:none; } QToolButton:checked:hover { background-color: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #556bb2, stop: 1.0 #00697f); border:1px solid #3c3c3c; } QToolButton:hover { background-color: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #333a51, stop: 1.0 #253c41); border:1px solid #3c3c3c; } QToolButton:pressed { background-color: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #333a51, stop: 1.0 #253c41); border:1px solid #aaaaaa; } QToolButton:selected { background-color: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #556bb2, stop: 1.0 #00697f); border:none; } QToolButton[popupMode="0"] { /* Only for DelayedPopup */ padding-right: 2px; } QToolButton[popupMode="1"] { /* Only for MenuButtonPopup */ padding-right: 20px; } QToolButton[popupMode="1"]::menu-button { border: none; } QToolButton[popupMode="1"]::menu-button:hover { border: none; border-left: 1px solid #455364; border-radius: 0; } QToolButton[popupMode="2"] { /* Only for InstantPopup */ padding-right: 2px; } QToolButton::menu-button { padding: 2px; border-radius: 4px; width: 12px; border: none; outline: none; } QToolButton::menu-button:hover { border: 1px solid #346792; } QToolButton::menu-button:checked:hover { border: 1px solid #346792; } QToolButton::menu-indicator { image: url(":/rc/arrow_down.png"); height: 8px; width: 8px; top: 0; /* Exclude a shift for better image */ left: -2px; /* Shift it a bit */ } QToolButton::menu-arrow { image: url(":/rc/arrow_down.png"); height: 8px; width: 8px; } QToolButton::menu-arrow:hover { image: url(":/rc/arrow_down_focus.png"); } /* QCommandLinkButton ----------------------------------------------------- --------------------------------------------------------------------------- */ /* 命令链接按钮 左边有个icon的按钮 */ QCommandLinkButton { background-color: transparent; border: none; border-radius: 4px; padding: 0px; margin: 0px; } QCommandLinkButton:disabled { background-color: transparent; color: #a5a5a5; } /* ------------------------------------------------------------------------ */ /* QComboBox -------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qcombobox --------------------------------------------------------------------------- */ /* 下拉列表 */ QComboBox { /* min-height: 1.5em; min-width: 75px; */ padding-left: 4px; padding-right: 4px; /* padding-right = 36; 4 + 16*2 See scrollbar size */ /* changed to 4px to fix #239 */ /* Fixes #103, #111 */ border-width: 4px 4px 4px 4px; border-image:url(:/rc/combieBoxBg.png)4 4 4 4 stretch stretch; /* 设置下拉框弹出样式为windowsVista */ combobox-popup: 0; } QComboBox QAbstractItemView { border: 1px solid #b5a86d; border-top: 0px solid #b5a86d; border-radius:0px; background-color: #3f3829; selection-background-color: #7f5701; } QComboBox QAbstractItemView:hover { /* background-color: #604200; */ } QComboBox QAbstractItemView:selected { /* background: #ff0000; */ } QComboBox QAbstractItemView:alternate { /* background: #7f5701; */ } QComboBox:disabled { color: #9DA9B5; border-image:url(:/rc/combieBoxBg_disable.png)4 4 4 4 stretch stretch; } QComboBox:hover { border-image:url(:/rc/combieBoxBg_hover.png)4 4 4 4 stretch stretch; } QComboBox:focus { /* border: 1px solid #1A72BB; */ } QComboBox:on { /* selection-background-color: #7f5701; */ } QComboBox::indicator { border: none; border-radius: 0; background-color: transparent; selection-background-color: transparent; color: transparent; selection-color: transparent; } QComboBox::indicator:alternate { /* background: #ff0000; */ } QComboBox::item { padding:4px 2px 2px 2px; } QComboBox::item:alternate { /* background: #ff0000; */ } QComboBox::drop-down { background-color:transparent; border:none; subcontrol-origin: padding; subcontrol-position: top right; width: 12px; } QComboBox::down-arrow { background-color:transparent; border:none; image: url(":/rc/arrow_down.png"); height: 8px; width: 8px; } QComboBox::down-arrow:on, QComboBox::down-arrow:hover, QComboBox::down-arrow:focus { image: url(":/rc/arrow_down.png"); } /* QSlider ---------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qslider --------------------------------------------------------------------------- */ /* 滑动条 */ QSlider{ border:none; min-height:20px; } QSlider::groove:horizontal{ left: 0px; right: 0px; height: 8px; border: 1px solid #9b9b9b; border-radius:4px; } QSlider::handle:horizontal{ width: 16px; height: 8px; margin-top: -4px; margin-left: -1px; margin-bottom: -4px; margin-right: -1px; border-image:url(":/rc/slider.png"); } QSlider::add-page:horizontal{ background: #808080; border-top-left-radius:0px; border-top-right-radius:2px; border-bottom-right-radius:2px; border-bottom-left-radius:0px; margin-top: 2px; margin-left: 2px; margin-bottom: 2px; margin-right: 2px; } QSlider::sub-page:horizontal{ background-color: qlineargradient(x1: 0, y1: 0, x2: 1, y2: 0,stop: 0 #64c6db, stop: 1.0 #5ea930); border-top-left-radius:2px; border-top-right-radius:0px; border-bottom-right-radius:0px; border-bottom-left-radius:2px; margin-top: 2px; margin-left: 2px; margin-bottom: 2px; margin-right: 2px; } /* QLineEdit -------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qlineedit --------------------------------------------------------------------------- */ /* 单行文本输入框 */ QLineEdit { background-color: #e1e1e1; border: 2px inset #e5e5e5; color: #161616; /* This fixes 103, 111 */ padding-top: 2px; /* This fixes 103, 111 */ padding-bottom: 2px; padding-left: 4px; padding-right: 4px; border-radius: 4px; /* min-width: 5px; removed to fix 109 */ selection-background-color:#6f412f; } QLineEdit:disabled { background-color: #c5c5c5; color: #9DA9B5; } QLineEdit:hover { background-color: #c4c8e1; } QLineEdit:focus { background-color: #aab0ce; } QLineEdit:selected { background-color: #346792; color: #455364; } /* QTabWidget -------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qtabwidget-and-qtabbar --------------------------------------------------------------------------- */ /* 选项卡 */ .QTabWidget { padding: 2px; selection-background-color: transparent; } QTabWidget .QWidget { /* Fixes #189 */ border-radius: 4px; } QTabWidget::pane { border: 0px solid #455364; border-radius: 4px; margin: 0px; /* Fixes double border inside pane with pyqt5 */ padding: 0px; } QTabWidget::pane:selected { background-color: transparent; border: 0px solid #346792; } /* QTabBar ---------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qtabwidget-and-qtabbar --------------------------------------------------------------------------- */ /* 标签栏 */ QTabBar, QDockWidget QTabBar { border-radius: 0px; margin: 0px; padding: 2px; border: 0px solid #346792; /* left: 5px; move to the right by 5px - removed for fix */ } /* 目前标签栏是没有关闭按钮 */ QTabBar::close-button, QDockWidget QTabBar::close-button { border: 0; margin: 0; padding: 4px; image: url(":/rc/window_close.png"); } QTabBar::close-button:hover, QDockWidget QTabBar::close-button:hover { image: url(":/rc/window_close_focus.png"); } QTabBar::close-button:pressed, QDockWidget QTabBar::close-button:pressed { image: url(":/rc/window_close_pressed.png"); } QTabBar::tab:top:selected, QDockWidget QTabBar::tab:top:selected { color: #000000; } QTabBar::tab:top:!selected, QDockWidget QTabBar::tab:top:!selected { color: #535353; } /* 暂时使用widget样式,统一风格,后续考虑优化 */ /* QTabBar::tab, QDockWidget QTabBar::tab { } QTabBar::tab:top:selected:disabled, QDockWidget QTabBar::tab:top:selected:disabled { border-bottom: 3px solid #26486B; color: #9DA9B5; background-color: #455364; } QTabBar::tab:bottom:selected:disabled, QDockWidget QTabBar::tab:bottom:selected:disabled { border-top: 3px solid #26486B; color: #9DA9B5; background-color: #455364; } QTabBar::tab:left:selected:disabled, QDockWidget QTabBar::tab:left:selected:disabled { border-right: 3px solid #26486B; color: #9DA9B5; background-color: #455364; } QTabBar::tab:right:selected:disabled, QDockWidget QTabBar::tab:right:selected:disabled { border-left: 3px solid #26486B; color: #9DA9B5; background-color: #455364; } QTabBar::tab:top:!selected:disabled, QDockWidget QTabBar::tab:top:!selected:disabled { border-bottom: 3px solid #19232D; color: #9DA9B5; background-color: #19232D; } QTabBar::tab:bottom:!selected:disabled, QDockWidget QTabBar::tab:bottom:!selected:disabled { border-top: 3px solid #19232D; color: #9DA9B5; background-color: #19232D; } QTabBar::tab:left:!selected:disabled, QDockWidget QTabBar::tab:left:!selected:disabled { border-right: 3px solid #19232D; color: #9DA9B5; background-color: #19232D; } QTabBar::tab:right:!selected:disabled, QDockWidget QTabBar::tab:right:!selected:disabled { border-left: 3px solid #19232D; color: #9DA9B5; background-color: #19232D; } QTabBar::tab:top:!selected, QDockWidget QTabBar::tab:top:!selected { border-bottom: 2px solid #19232D; margin-top: 2px; } QTabBar::tab:bottom:!selected, QDockWidget QTabBar::tab:bottom:!selected { border-top: 2px solid #19232D; margin-bottom: 2px; } QTabBar::tab:left:!selected, QDockWidget QTabBar::tab:left:!selected { border-left: 2px solid #19232D; margin-right: 2px; } QTabBar::tab:right:!selected, QDockWidget QTabBar::tab:right:!selected { border-right: 2px solid #19232D; margin-left: 2px; } QTabBar::tab:top, QDockWidget QTabBar::tab:top { background-color: #455364; margin-left: 2px; padding-left: 4px; padding-right: 4px; padding-top: 2px; padding-bottom: 2px; min-width: 5px; border-bottom: 3px solid #455364; border-top-left-radius: 4px; border-top-right-radius: 4px; } QTabBar::tab:top, QDockWidget QTabBar::tab:top { background-color: #455364; margin-left: 2px; padding-left: 4px; padding-right: 4px; padding-top: 2px; padding-bottom: 2px; min-width: 5px; border-bottom: 3px solid #455364; border-top-left-radius: 4px; border-top-right-radius: 4px; } QTabBar::tab:top:selected, QDockWidget QTabBar::tab:top:selected { background-color: #54687A; border-bottom: 3px solid #259AE9; border-top-left-radius: 4px; border-top-right-radius: 4px; } QTabBar::tab:top:!selected:hover, QDockWidget QTabBar::tab:top:!selected:hover { border: 1px solid #1A72BB; border-bottom: 3px solid #1A72BB; padding-left: 3px; padding-right: 3px; } QTabBar::tab:bottom, QDockWidget QTabBar::tab:bottom { border-top: 3px solid #455364; background-color: #455364; margin-left: 2px; padding-left: 4px; padding-right: 4px; padding-top: 2px; padding-bottom: 2px; border-bottom-left-radius: 4px; border-bottom-right-radius: 4px; min-width: 5px; } QTabBar::tab:bottom:selected, QDockWidget QTabBar::tab:bottom:selected { background-color: #54687A; border-top: 3px solid #259AE9; border-bottom-left-radius: 4px; border-bottom-right-radius: 4px; } QTabBar::tab:bottom:!selected:hover, QDockWidget QTabBar::tab:bottom:!selected:hover { border: 1px solid #1A72BB; border-top: 3px solid #1A72BB; padding-left: 3px; padding-right: 3px; } QTabBar::tab:left, QDockWidget QTabBar::tab:left { background-color: #455364; margin-top: 2px; padding-left: 2px; padding-right: 2px; padding-top: 4px; padding-bottom: 4px; border-top-left-radius: 4px; border-bottom-left-radius: 4px; min-height: 5px; } QTabBar::tab:left:selected, QDockWidget QTabBar::tab:left:selected { background-color: #54687A; border-right: 3px solid #259AE9; } QTabBar::tab:left:!selected:hover, QDockWidget QTabBar::tab:left:!selected:hover { border: 1px solid #1A72BB; border-right: 3px solid #1A72BB; margin-right: 0px; padding-right: -1px; } QTabBar::tab:right, QDockWidget QTabBar::tab:right { background-color: #455364; margin-top: 2px; padding-left: 2px; padding-right: 2px; padding-top: 4px; padding-bottom: 4px; border-top-right-radius: 4px; border-bottom-right-radius: 4px; min-height: 5px; } QTabBar::tab:right:selected, QDockWidget QTabBar::tab:right:selected { background-color: #54687A; border-left: 3px solid #259AE9; } QTabBar::tab:right:!selected:hover, QDockWidget QTabBar::tab:right:!selected:hover { border: 1px solid #1A72BB; border-left: 3px solid #1A72BB; margin-left: 0px; padding-left: 0px; } */ /* QDockWiget ------------------------------------------------------------- --------------------------------------------------------------------------- */ /* 悬浮窗口 */ QDockWidget { outline: 1px solid #aaaaaa; /* 悬停时的背景 */ background-color: #1d6995; border: 1px solid #aaaaaa; border-radius: 4px; color:#161616; } QDockWidget::title { /* Better size for title bar */ padding: 3px; spacing: 4px; border: none; background-color: #455364; color:#161616; } QDockWidget::close-button { icon-size: 12px; border: none; background: transparent; background-image: transparent; border: 0; margin: 0; padding: 0; image: url(":/rc/window_close.png"); } QDockWidget::close-button:hover { image: url(":/rc/window_close_focus.png"); } QDockWidget::close-button:pressed { image: url(":/rc/window_close_pressed.png"); } QDockWidget::float-button { icon-size: 12px; border: none; background: transparent; background-image: transparent; border: 0; margin: 0; padding: 0; image: url(":/rc/window_undock.png"); } QDockWidget::float-button:hover { image: url(":/rc/window_undock_focus.png"); } QDockWidget::float-button:pressed { image: url(":/rc/window_undock_pressed.png"); } /* QTreeView QListView QTableView ----------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qtreeview https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qlistview https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qtableview --------------------------------------------------------------------------- */ /* 树相关 */ QTreeView:branch:selected, QTreeView:branch:hover { background: url(":/rc/transparent.png"); } QTreeView:branch:has-siblings:!adjoins-item { border-image: url(":/rc/branch_line.png") 0; } QTreeView:branch:has-siblings:adjoins-item { border-image: url(":/rc/branch_more.png") 0; } QTreeView:branch:!has-children:!has-siblings:adjoins-item { border-image: url(":/rc/branch_end.png") 0; } QTreeView:branch:has-children:!has-siblings:closed, QTreeView:branch:closed:has-children:has-siblings { border-image: none; image: url(":/rc/branch_closed.png"); } QTreeView:branch:open:has-children:!has-siblings, QTreeView:branch:open:has-children:has-siblings { border-image: none; image: url(":/rc/branch_open.png"); } QTreeView:branch:has-children:!has-siblings:closed:hover, QTreeView:branch:closed:has-children:has-siblings:hover { image: url(":/rc/branch_closed_focus.png"); } QTreeView:branch:open:has-children:!has-siblings:hover, QTreeView:branch:open:has-children:has-siblings:hover { image: url(":/rc/branch_open_focus.png"); } QTreeView::indicator:checked, QListView::indicator:checked, QTableView::indicator:checked, QColumnView::indicator:checked { image: url(":/rc/checkbox_checked.png"); } QTreeView::indicator:checked:hover, QTreeView::indicator:checked:focus, QTreeView::indicator:checked:pressed, QListView::indicator:checked:hover, QListView::indicator:checked:focus, QListView::indicator:checked:pressed, QTableView::indicator:checked:hover, QTableView::indicator:checked:focus, QTableView::indicator:checked:pressed, QColumnView::indicator:checked:hover, QColumnView::indicator:checked:focus, QColumnView::indicator:checked:pressed { image: url(":/rc/checkbox_checked_focus.png"); } QTreeView::indicator:unchecked, QListView::indicator:unchecked, QTableView::indicator:unchecked, QColumnView::indicator:unchecked { image: url(":/rc/checkbox_unchecked.png"); } QTreeView::indicator:unchecked:hover, QTreeView::indicator:unchecked:focus, QTreeView::indicator:unchecked:pressed, QListView::indicator:unchecked:hover, QListView::indicator:unchecked:focus, QListView::indicator:unchecked:pressed, QTableView::indicator:unchecked:hover, QTableView::indicator:unchecked:focus, QTableView::indicator:unchecked:pressed, QColumnView::indicator:unchecked:hover, QColumnView::indicator:unchecked:focus, QColumnView::indicator:unchecked:pressed { image: url(":/rc/checkbox_unchecked_focus.png"); } QTreeView::indicator:indeterminate, QListView::indicator:indeterminate, QTableView::indicator:indeterminate, QColumnView::indicator:indeterminate { image: url(":/rc/checkbox_indeterminate.png"); } QTreeView::indicator:indeterminate:hover, QTreeView::indicator:indeterminate:focus, QTreeView::indicator:indeterminate:pressed, QListView::indicator:indeterminate:hover, QListView::indicator:indeterminate:focus, QListView::indicator:indeterminate:pressed, QTableView::indicator:indeterminate:hover, QTableView::indicator:indeterminate:focus, QTableView::indicator:indeterminate:pressed, QColumnView::indicator:indeterminate:hover, QColumnView::indicator:indeterminate:focus, QColumnView::indicator:indeterminate:pressed { image: url(":/rc/checkbox_indeterminate_focus.png"); } /* 使用widget设置 */ /* QTreeView, QListView, QTableView, QColumnView { background-color: #e1e1e1; border: 1px solid #455364; color: #161616; gridline-color: #455364; border-radius: 4px; } QTreeView:disabled, QListView:disabled, QTableView:disabled, QColumnView:disabled { background-color: #e1e1e1; color: #9DA9B5; } QTreeView:selected, QListView:selected, QTableView:selected, QColumnView:selected { background-color: #346792; color: #455364; } QTreeView:focus, QListView:focus, QTableView:focus, QColumnView:focus { border: 1px solid #1A72BB; } QTreeView::item:pressed, QListView::item:pressed, QTableView::item:pressed, QColumnView::item:pressed { background-color: #346792; } QTreeView::item:selected:active, QListView::item:selected:active, QTableView::item:selected:active, QColumnView::item:selected:active { background-color: #346792; } QTreeView::item:selected:!active, QListView::item:selected:!active, QTableView::item:selected:!active, QColumnView::item:selected:!active { color: #161616; background-color: #37414F; } QTreeView::item:!selected:hover, QListView::item:!selected:hover, QTableView::item:!selected:hover, QColumnView::item:!selected:hover { outline: 0; color: #161616; background-color: #37414F; } QTableCornerButton::section { background-color: #19232D; border: 1px transparent #455364; border-radius: 0px; } */ /* QHeaderView ------------------------------------------------------------ https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qheaderview --------------------------------------------------------------------------- */ /* 表头 */ /* 采用widget设置 */ /* QHeaderView { background-color: #455364; border: 0px transparent #455364; padding: 0; margin: 0; border-radius: 0; } QHeaderView:disabled { background-color: #455364; border: 1px transparent #455364; } QHeaderView::section { background-color: #455364; color: #161616; border-radius: 0; text-align: left; font-size: 13px; } QHeaderView::section::horizontal { padding-top: 0; padding-bottom: 0; padding-left: 4px; padding-right: 4px; border-left: 1px solid #19232D; } QHeaderView::section::horizontal::first, QHeaderView::section::horizontal::only-one { border-left: 1px solid #455364; } QHeaderView::section::horizontal:disabled { color: #9DA9B5; } QHeaderView::section::vertical { padding-top: 0; padding-bottom: 0; padding-left: 4px; padding-right: 4px; border-top: 1px solid #19232D; } QHeaderView::section::vertical::first, QHeaderView::section::vertical::only-one { border-top: 1px solid #455364; } QHeaderView::section::vertical:disabled { color: #9DA9B5; } QHeaderView::down-arrow { background-color: #455364; border: none; height: 12px; width: 12px; padding-left: 2px; padding-right: 2px; image: url(":/rc/arrow_down.png"); } QHeaderView::up-arrow { background-color: #455364; border: none; height: 12px; width: 12px; padding-left: 2px; padding-right: 2px; image: url(":/rc/arrow_up.png"); } */ /* QToolBox -------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qtoolbox --------------------------------------------------------------------------- */ /* 抽屉 */ /* QToolBox { padding: 0px; border: 0px; border: 1px solid #455364; } QToolBox:selected { padding: 0px; border: 2px solid #346792; } QToolBox::tab { background-color: #19232D; border: 1px solid #455364; color: #161616; border-top-left-radius: 4px; border-top-right-radius: 4px; } QToolBox::tab:disabled { color: #9DA9B5; } QToolBox::tab:selected { background-color: #60798B; border-bottom: 2px solid #346792; } QToolBox::tab:selected:disabled { background-color: #455364; border-bottom: 2px solid #26486B; } QToolBox::tab:!selected { background-color: #455364; border-bottom: 2px solid #455364; } QToolBox::tab:!selected:disabled { background-color: #19232D; } QToolBox::tab:hover { border-color: #1A72BB; border-bottom: 2px solid #1A72BB; } QToolBox QScrollArea QWidget QWidget { padding: 0px; border: 0px; background-color: #19232D; } */ /* QFrame ----------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qframe https://doc.qt.io/qt-5/qframe.html#-prop https://doc.qt.io/qt-5/qframe.html#details https://stackoverflow.com/questions/14581498/qt-stylesheet-for-hline-vline-color --------------------------------------------------------------------------- */ /* .QFrame { border-radius: 4px; border: 1px solid #455364; } .QFrame[frameShape="0"] { border-radius: 4px; border: 1px transparent #455364; } .QFrame[frameShape="4"] { max-height: 2px; border: none; background-color: #455364; } .QFrame[frameShape="5"] { max-width: 2px; border: none; background-color: #455364; } */ /* QSplitter -------------------------------------------------------------- https://doc.qt.io/qt-5/stylesheet-examples.html#customizing-qsplitter --------------------------------------------------------------------------- */ /* 切分窗口 */ /* 使用默认 */ /* QSplitter { background-color: #455364; spacing: 0px; padding: 0px; margin: 0px; } QSplitter::handle { background-color: #455364; border: 0px solid #19232D; spacing: 0px; padding: 1px; margin: 0px; } QSplitter::handle:hover { background-color: #9DA9B5; } QSplitter::handle:horizontal { width: 5px; image: url(":/rc/line_vertical.png"); } QSplitter::handle:vertical { height: 5px; image: url(":/rc/line_horizontal.png"); } */ /* QDateEdit, QDateTimeEdit ----------------------------------------------- --------------------------------------------------------------------------- */ /* 日期编辑器 */ /* QDateEdit, QDateTimeEdit { selection-background-color: #346792; border-style: solid; border: 1px solid #455364; border-radius: 4px; padding-top: 2px; padding-bottom: 2px; padding-left: 4px; padding-right: 4px; min-width: 10px; } QDateEdit:on, QDateTimeEdit:on { selection-background-color: #346792; } QDateEdit::drop-down, QDateTimeEdit::drop-down { subcontrol-origin: padding; subcontrol-position: top right; width: 12px; border-left: 1px solid #455364; } QDateEdit::down-arrow, QDateTimeEdit::down-arrow { image: url(":/qss_icons/dark/rc/arrow_down_disabled.png"); height: 8px; width: 8px; } QDateEdit::down-arrow:on, QDateEdit::down-arrow:hover, QDateEdit::down-arrow:focus, QDateTimeEdit::down-arrow:on, QDateTimeEdit::down-arrow:hover, QDateTimeEdit::down-arrow:focus { image: url(":/qss_icons/dark/rc/arrow_down.png"); } QDateEdit QAbstractItemView, QDateTimeEdit QAbstractItemView { background-color: #19232D; border-radius: 4px; border: 1px solid #455364; selection-background-color: #346792; } */ /* QAbstractView ---------------------------------------------------------- --------------------------------------------------------------------------- */ /* 抽象视图 */ /* QAbstractView:hover { border: 1px solid #346792; color: #161616; } QAbstractView:selected { background: #346792; color: #455364; } */ /* PlotWidget ------------------------------------------------------------- --------------------------------------------------------------------------- */ /* 图标视图 */ PlotWidget { /* Fix cut labels in plots #134 */ padding: 0px; } /* tableWidget ------------------------------------------------------------- --------------------------------------------------------------------------- */ /* 表格视图 */ QTableWidget,QTableView{ background-color: #bfbfbf; border: 1px solid #aaaaaa; border-radius: 0px; } /* QListWidget ------------------------------------------------------------- --------------------------------------------------------------------------- */ /* 列表视图 */ QListWidget { background-color: #bfbfbf; border: 1px solid #aaaaaa; border-radius: 0px; } QListWidget::item { padding-top:2px; padding-bottom:2px; } /* Line ------------------------------------------------------------- --------------------------------------------------------------------------- */ /* 线 */ QFrame#line { background-color: #aaaaaa; } /* 嵌套在GroupBox中的listView ------------------------------------------------------------- --------------------------------------------------------------------------- */ /* 列表视图 */ /* 子选择器 */ QGroupBox QListWidget , QGroupBox QListView { background-color: #2a2b31; border: 2px solid #aaaaaa; border-radius: 0px; } /* ------------------------------------------------------ 树窗口 */ QTreeWidget::item{ height:20px; }