[add] settings for styles

This commit is contained in:
Marcel Paffrath 2017-09-07 10:59:09 +02:00
parent 7e39593b05
commit bab34a23c4
3 changed files with 254 additions and 0 deletions

1
pylot/styles/__init__.py Normal file
View File

@ -0,0 +1 @@
# -*- coding: utf-8 -*-

209
pylot/styles/dark.qss Normal file
View File

@ -0,0 +1,209 @@
QMainWindow{
background-color: qlineargradient(spread:reflect, x1:0, y1:0, x2:0, y2:0.5, stop:0 rgba(70, 70, 80, 255), stop:1 rgba(60, 60, 70, 255));
color: rgba(255, 255, 255, 255);
}
QWidget{
background-color: qlineargradient(spread:reflect, x1:0, y1:0, x2:0, y2:0.5, stop:0 rgba(70, 70, 80, 255), stop:1 rgba(60, 60, 70, 255));
color: rgba(255, 255, 255, 255);
}
QComboBox{
background-color: rgba(80, 80, 90, 255);
color: rgba(255, 255, 255, 255);
}
QComboBox *{
background-color: rgba(80, 80, 90, 255);
color: rgba(255, 255, 255, 255);
}
QMenuBar{
background-color: qlineargradient(spread:pad, x1:0, y1:0, x2:0, y2:1, stop:0 rgba(70, 70, 80, 255), stop:1 rgba(60, 60, 70, 255));
padding:1px;
}
QMenuBar::item{
background-color: qlineargradient(spread:pad, x1:0, y1:0, x2:0, y2:1, stop:0 rgba(70, 70, 80, 255), stop:1 rgba(60, 60, 70, 255));
color: rgba(255, 255, 255, 255);
padding:3px;
}
QMenu{
background-color: qlineargradient(spread:pad, x1:0, y1:0, x2:0, y2:1, stop:0 rgba(70, 70, 80, 255), stop:1 rgba(60, 60, 70, 255));
color: rgba(255, 255, 255, 255);
padding:0;
}
QMenu::item:selected{
color: rgba(255, 255, 255, 255);
background-color: rgba(200, 210, 230, 255);
}
QToolBar{
background-color: qlineargradient(spread:reflect, x1:0, y1:0, x2:0, y2:0.5, stop:0 rgba(70, 70, 80, 255), stop:1 rgba(60, 60, 70, 255));
border-style:solid;
border-color:rgba(70, 70, 80, 255);
border-width:1px;
}
QToolBar *{
background-color: qlineargradient(spread:reflect, x1:0, y1:0, x2:0, y2:0.5, stop:0 rgba(70, 70, 80, 255), stop:1 rgba(60, 60, 70, 255));
}
QFileDialog QLabel{
color: rgba(0, 0, 0, 255);
}
QFileDialog QPushButton{
background-color: rgba(210, 210, 210, 255);
color: rgba(0, 0, 0, 255);
}
QMessageBox{
background-color: rgba(60, 60, 70, 255);
color: rgba(255, 255, 255, 255);
}
QTableWidget{
background-color: rgba(70, 70, 80, 255);
color:rgba(255, 255, 255, 255);
border-color:rgba(255, 255, 255, 255);
selection-background-color: rgba(200, 210, 230, 255);
}
QHeaderView::section{
background-color:qlineargradient(spread:pad, x1:0, y1:0, x2:1, y2:0, stop:0 rgba(60, 60, 70, 255), stop:1 rgba(70, 70, 80, 255));
border:none;
border-top-style:solid;
border-width:1px;
border-top-color:qlineargradient(spread:pad, x1:0, y1:0, x2:1, y2:0, stop:0 rgba(60, 60, 70, 255), stop:1 rgba(70, 70, 80, 255));
color:rgba(255, 255, 255, 255);
padding:5px;
}
QHeaderView{
background-color:qlineargradient(spread:pad, x1:0, y1:0, x2:1, y2:0, stop:0 rgba(60, 60, 70, 255), stop:1 rgba(70, 70, 80, 255));
border:none;
border-top-style:solid;
border-width:1px;
border-top-color:rgba(70, 70, 80, 255);
color:rgba(255, 255, 255, 255);
}
QListWidget{
background-color:rgba(200, 200, 200, 255);
color:rgba(255, 255, 255, 255);
}
QStatusBar{
background-color:rgba(60, 60, 70, 255);
color:rgba(255, 255, 255, 255);
}
QPushButton{
background-color:rgba(70, 70, 80, 255);
color:rgba(255, 255, 255, 255);
}
QPushButton:pressed{
background-color: rgba(70, 70, 80, 255);
}
QTabBar{
background-color:transparent
}
QTabBar::tab{
background-color:qlineargradient(spread:pad, x1:0, y1:0, x2:0, y2:1, stop:0 rgba(70, 70, 80, 255), stop:1 rgba(60, 60, 70, 255));
color: rgba(255, 255, 255, 255);
border-style:solid;
border-color:rgba(60, 60, 70, 255);
border-bottom-color: transparent;
border-width:1px;
padding:5px;
}
QTabBar::tab:selected{
background-color:rgba(80, 80, 90, 255);
color: rgba(255, 255, 255, 255);
border-style:solid;
border-color:rgba(80, 80, 90, 255);
border-bottom-color: transparent;
border-width:1px;
padding:5px;
}
QTabWidget{
background-color:transparent;
}
QTabWidget::pane{
background-color:rgba(255, 255, 255, 255);
border-style:solid;
border-color:rgba(80, 80, 90, 255);
border-width:1px;
}
QTabWidget::tab{
background-color:rgba(60, 60, 70, 255);
}
QTabWidget > QWidget{
background-color: rgba(60, 60, 70, 255);
color: rgba(255, 255, 255, 255);
}
QScrollArea{
background: transparent;
}
QScrollArea>QWidget>QWidget{
background: transparent;
}
QLabel{
color: rgba(255, 255, 255, 255);
background-color: transparent;
}
QTextEdit{
color: rgba(255, 255, 255, 255);
background-color: rgba(80, 80, 90, 255);
}
QSpinBox{
color: rgba(255, 255, 255, 255);
background-color: rgba(80, 80, 90, 255);
}
QDoubleSpinBox{
color: rgba(255, 255, 255, 255);
background-color: rgba(80, 80, 90, 255);
}
QLineEdit{
background-color: rgba(80, 80, 90, 255);
border-radius:0;
}
QListWidget{
background-color:rgba(60, 60, 70, 255)
}
QProgressBar{
border-radius:0;
text-align:center;
color:rgba(255, 255, 255, 255);
background-color:rgba(60,60,80,255);
border: 2px solid #e3a21a;
border-radius:7px;
font: 75 12pt "Open Sans";
}
QProgressBar::chunk{
background-color:rgba(60, 60, 70, 255);
width:10px;
}

44
pylot/styles/settings.py Normal file
View File

@ -0,0 +1,44 @@
# -*- coding: utf-8 -*-
# Set base phase colors for manual and automatic picks
# together with a modifier (r, g, or b) used to alternate
# the base color
phasecolors = {
'manual': {
'P':{
'rgba': (0, 0, 255, 255),
'modifier': 'g'},
'S':{
'rgba': (255, 0, 0, 255),
'modifier': 'b'}
},
'auto':{
'P':{
'rgba': (140, 0, 255, 255),
'modifier': 'g'},
'S':{
'rgba': (255, 140, 0, 255),
'modifier': 'b'}
}
}
# Set plot colors and stylesheet for each style
stylecolors = {
'default':{
'wf':{
'rgba': (0, 0, 0, 255)},
'background': {
'rgba': (255, 255, 255, 255)},
'stylesheet': {
'filename': None}
},
'dark':{
'wf':{
'rgba': (255, 255, 255, 255)},
'background':{
'rgba': (50, 50, 60, 255)},
'stylesheet': {
'filename': 'styles/dark.qss'}
}
}