/*hover样式*/ QPushButton:hover{ background-color: rgb(155,155,155); } /*pressed样式*/ QPushButton:pressed{ background-color: rgb(180,238,180); } QPushButton{ background-color:rgb(50,50,50); color:rgb(255,255,255); border-radius: 2px; border: 1px groove gray; border-style: outset; font: 12pt "Microsoft YaHei UI"; } QGroupBox{ color:rgb(153,255,153); font-family:Consolas; font-size:12pt; } /*设置TabWidget中tab_1的样式*/ #tab_1.QWidget{ background-color: rgb(50, 50, 50); } #tab_2.QWidget{ background-color: rgb(50, 50, 50); } #tab_3.QWidget{ background-color: rgb(50, 50, 50); } #tab_4.QWidget{ background-color: rgb(50, 50, 50); } #tab_5.QWidget{ background-color: rgb(50, 50, 50); } #tab_6.QWidget{ background-color: rgb(50, 50, 50); } /*设置TabWidget中QTabBar的样式*/ QTabBar::tab{ background-color: #0B0E11; font-family:Consolas; /*设置tab中的文本的字体*/ font-size:12pt; color:rgb(255,255,255); /*设置tab中的文本的颜色*/ border-top-left-radius: 5px; /*设置tab的边框的圆角(左上圆角)*/ border-top-right-radius: 5px; /*设置tab的边框的圆角(右上圆角)*/ min-width: 12px; padding: 5px; background-color: rgb(50, 50, 50); } /*设置TabWidget中QTabBar的tab被选中时的样式*/ QTabBar::tab:selected{ background-color: rgb(204, 229, 255); color: rgb(50, 50, 50); } /*设置TabWidget中鼠标悬浮在QTabBar的tab上,但未选中该Tab的样式*/ QTabBar::tab:hover:!selected { background-color: rgb(224, 224, 224); color: rgb(50, 50, 50); } /*设置TabWidget的边框的样式*/ QTabWidget::pane { border: 1px solid rgb(108, 117, 125); } /*当打开多个tab,右侧出现,点击后,可以向前向后的按钮的样式*/ QTabBar QToolButton { border: none; color: rgb(255, 206, 6); background-color: #0b0e11; } QTabBar QToolButton:hover { background-color: rgb(50, 50, 50); } /*QLabel设置*/ QLabel{ color: rgb(255, 255, 255); font-family:Consolas; font-size:11pt; } QComboBox{ color: rgb(0, 0, 0); background-color: rgb(250, 250, 250); border-color:rgb(255, 255, 255);/*边框颜色*/ font-size:11pt; }