ccreated base of open pype style

This commit is contained in:
iLLiCiTiT 2021-05-28 10:04:19 +02:00
parent 8e778b774e
commit ba6d55014d
9 changed files with 809 additions and 0 deletions

118
openpype/style/__init__.py Normal file
View file

@ -0,0 +1,118 @@
import os
import json
import collections
from openpype import resources
from avalon.vendor import qtawesome
class ResourceCache:
colors = {
"standard": "#333333",
"new": "#2d9a4c",
"warning": "#c83232"
}
icons = None
@classmethod
def get_icon(cls, *keys):
output = cls.get_icons()
for key in keys:
output = output[key]
return output
@classmethod
def get_icons(cls):
if cls.icons is None:
cls.icons = {
"asset": {
"default": qtawesome.icon(
"fa.folder",
color=cls.colors["standard"]
),
"new": qtawesome.icon(
"fa.folder",
color=cls.colors["new"]
),
"invalid": qtawesome.icon(
"fa.exclamation-triangle",
color=cls.colors["warning"]
),
"removed": qtawesome.icon(
"fa.trash",
color=cls.colors["warning"]
)
},
"task": {
"default": qtawesome.icon(
"fa.check-circle-o",
color=cls.colors["standard"]
),
"new": qtawesome.icon(
"fa.check-circle",
color=cls.colors["new"]
),
"invalid": qtawesome.icon(
"fa.exclamation-circle",
color=cls.colors["warning"]
),
"removed": qtawesome.icon(
"fa.trash",
color=cls.colors["warning"]
)
},
"refresh": qtawesome.icon(
"fa.refresh",
color=cls.colors["standard"]
)
}
return cls.icons
@classmethod
def get_color(cls, color_name):
return cls.colors[color_name]
@classmethod
def style_fill_data(cls):
output = {}
for color_name, color_value in cls.colors.items():
key = "color:{}".format(color_name)
output[key] = color_value
return output
def load_stylesheet():
from . import qrc_resources
qrc_resources.qInitResources()
current_dir = os.path.dirname(os.path.abspath(__file__))
style_path = os.path.join(current_dir, "style.css")
with open(style_path, "r") as style_file:
stylesheet = style_file.read()
data_path = os.path.join(current_dir, "data.json")
with open(data_path, "r") as data_stream:
data = json.load(data_stream)
data_deque = collections.deque()
for item in data.items():
data_deque.append(item)
fill_data = {}
while data_deque:
key, value = data_deque.popleft()
if isinstance(value, dict):
for sub_key, sub_value in value.items():
new_key = "{}:{}".format(key, sub_key)
data_deque.append((new_key, sub_value))
continue
fill_data[key] = value
for key, value in fill_data.items():
replacement_key = "{" + key + "}"
stylesheet = stylesheet.replace(replacement_key, value)
return stylesheet
def app_icon_path():
return resources.pype_icon_filepath()

27
openpype/style/data.json Normal file
View file

@ -0,0 +1,27 @@
{
"color": {
"font": "#bfccd6",
"font-hover": "#eff3f5",
"font-disabled": "#737c85",
"font-view-selection": "black",
"bg": "#282C34",
"bg-inputs": "#21252B",
"bg-buttons": "#313741",
"bg-inputs-disabled": "#282C34",
"bg-buttons-disabled": "#4e5565",
"bg-view": "#313741",
"bg-view-alternate": "#282C34",
"bg-view-disabled": "#4e5565",
"bg-view-alternate-disabled": "#282C34",
"bg-view-selection": "rgba(77, 120, 204, 127)",
"border": "#464b54",
"border-hover": "#5d636f",
"border-focus": "#52acd7",
"active_1": "#48c896",
"active_2": "#52acd7"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 166 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 165 B

View file

@ -0,0 +1,105 @@
# -*- coding: utf-8 -*-
# Resource object code
#
# Created by: The Resource Compiler for PyQt5 (Qt v5.15.2)
#
# WARNING! All changes made in this file will be lost!
from PyQt5 import QtCore
qt_resource_data = b"\
\x00\x00\x00\xa5\
\x89\
\x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\
\x00\x00\x09\x00\x00\x00\x06\x08\x04\x00\x00\x00\xbb\xce\x7c\x4e\
\x00\x00\x00\x01\x73\x52\x47\x42\x00\xae\xce\x1c\xe9\x00\x00\x00\
\x02\x62\x4b\x47\x44\x00\x9c\x53\x34\xfc\x5d\x00\x00\x00\x09\x70\
\x48\x59\x73\x00\x00\x0b\x13\x00\x00\x0b\x13\x01\x00\x9a\x9c\x18\
\x00\x00\x00\x07\x74\x49\x4d\x45\x07\xdc\x08\x17\x0b\x02\x04\x6d\
\x98\x1b\x69\x00\x00\x00\x29\x49\x44\x41\x54\x08\xd7\x63\x60\xc0\
\x00\x8c\x0c\x0c\xff\xcf\xa3\x08\x18\x32\x32\x30\x20\x0b\x32\x1a\
\x32\x30\x30\x42\x98\x10\x41\x46\x43\x14\x13\x50\xb5\xa3\x01\x00\
\xd6\x10\x07\xd2\x2f\x48\xdf\x4a\x00\x00\x00\x00\x49\x45\x4e\x44\
\xae\x42\x60\x82\
\x00\x00\x00\xa6\
\x89\
\x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\
\x00\x00\x09\x00\x00\x00\x06\x08\x04\x00\x00\x00\xbb\xce\x7c\x4e\
\x00\x00\x00\x01\x73\x52\x47\x42\x00\xae\xce\x1c\xe9\x00\x00\x00\
\x02\x62\x4b\x47\x44\x00\xff\x87\x8f\xcc\xbf\x00\x00\x00\x09\x70\
\x48\x59\x73\x00\x00\x0b\x13\x00\x00\x0b\x13\x01\x00\x9a\x9c\x18\
\x00\x00\x00\x07\x74\x49\x4d\x45\x07\xdc\x08\x17\x08\x15\x3b\xdc\
\x3b\x0c\x9b\x00\x00\x00\x2a\x49\x44\x41\x54\x08\xd7\x63\x60\xc0\
\x00\x8c\x0c\x0c\x73\x3e\x20\x0b\xa4\x08\x30\x32\x30\x20\x0b\xa6\
\x08\x30\x30\x30\x42\x98\x10\xc1\x14\x01\x14\x13\x50\xb5\xa3\x01\
\x00\xc6\xb9\x07\x90\x5d\x66\x1f\x83\x00\x00\x00\x00\x49\x45\x4e\
\x44\xae\x42\x60\x82\
"
qt_resource_name = b"\
\x00\x08\
\x06\xc5\x8e\xa5\
\x00\x6f\
\x00\x70\x00\x65\x00\x6e\x00\x70\x00\x79\x00\x70\x00\x65\
\x00\x06\
\x07\x03\x7d\xc3\
\x00\x69\
\x00\x6d\x00\x61\x00\x67\x00\x65\x00\x73\
\x00\x12\
\x01\x2e\x03\x27\
\x00\x63\
\x00\x6f\x00\x6d\x00\x62\x00\x6f\x00\x62\x00\x6f\x00\x78\x00\x5f\x00\x61\x00\x72\x00\x72\x00\x6f\x00\x77\x00\x2e\x00\x70\x00\x6e\
\x00\x67\
\x00\x1b\
\x03\x5a\x32\x27\
\x00\x63\
\x00\x6f\x00\x6d\x00\x62\x00\x6f\x00\x62\x00\x6f\x00\x78\x00\x5f\x00\x61\x00\x72\x00\x72\x00\x6f\x00\x77\x00\x5f\x00\x64\x00\x69\
\x00\x73\x00\x61\x00\x62\x00\x6c\x00\x65\x00\x64\x00\x2e\x00\x70\x00\x6e\x00\x67\
"
qt_resource_struct_v1 = b"\
\x00\x00\x00\x00\x00\x02\x00\x00\x00\x01\x00\x00\x00\x01\
\x00\x00\x00\x00\x00\x02\x00\x00\x00\x01\x00\x00\x00\x02\
\x00\x00\x00\x16\x00\x02\x00\x00\x00\x02\x00\x00\x00\x03\
\x00\x00\x00\x28\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\
\x00\x00\x00\x52\x00\x00\x00\x00\x00\x01\x00\x00\x00\xa9\
"
qt_resource_struct_v2 = b"\
\x00\x00\x00\x00\x00\x02\x00\x00\x00\x01\x00\x00\x00\x01\
\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x00\x02\x00\x00\x00\x01\x00\x00\x00\x02\
\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x16\x00\x02\x00\x00\x00\x02\x00\x00\x00\x03\
\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x28\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\
\x00\x00\x01\x76\x41\x9d\xa2\x35\
\x00\x00\x00\x52\x00\x00\x00\x00\x00\x01\x00\x00\x00\xa9\
\x00\x00\x01\x76\x41\x9d\xa2\x35\
"
qt_version = [int(v) for v in QtCore.qVersion().split('.')]
if qt_version < [5, 8, 0]:
rcc_version = 1
qt_resource_struct = qt_resource_struct_v1
else:
rcc_version = 2
qt_resource_struct = qt_resource_struct_v2
def qInitResources():
QtCore.qRegisterResourceData(
rcc_version, qt_resource_struct, qt_resource_name, qt_resource_data
)
def qCleanupResources():
QtCore.qUnregisterResourceData(
rcc_version, qt_resource_struct, qt_resource_name, qt_resource_data
)

View file

@ -0,0 +1,84 @@
# Resource object code (Python 3)
# Created by: object code
# Created by: The Resource Compiler for Qt version 5.15.2
# WARNING! All changes made in this file will be lost!
from PySide2 import QtCore
qt_resource_data = b"\
\x00\x00\x00\xa5\
\x89\
PNG\x0d\x0a\x1a\x0a\x00\x00\x00\x0dIHDR\x00\
\x00\x00\x09\x00\x00\x00\x06\x08\x04\x00\x00\x00\xbb\xce|N\
\x00\x00\x00\x01sRGB\x00\xae\xce\x1c\xe9\x00\x00\x00\
\x02bKGD\x00\x9cS4\xfc]\x00\x00\x00\x09p\
HYs\x00\x00\x0b\x13\x00\x00\x0b\x13\x01\x00\x9a\x9c\x18\
\x00\x00\x00\x07tIME\x07\xdc\x08\x17\x0b\x02\x04m\
\x98\x1bi\x00\x00\x00)IDAT\x08\xd7c`\xc0\
\x00\x8c\x0c\x0c\xff\xcf\xa3\x08\x18220 \x0b2\x1a\
200B\x98\x10AFC\x14\x13P\xb5\xa3\x01\x00\
\xd6\x10\x07\xd2/H\xdfJ\x00\x00\x00\x00IEND\
\xaeB`\x82\
\x00\x00\x00\xa6\
\x89\
PNG\x0d\x0a\x1a\x0a\x00\x00\x00\x0dIHDR\x00\
\x00\x00\x09\x00\x00\x00\x06\x08\x04\x00\x00\x00\xbb\xce|N\
\x00\x00\x00\x01sRGB\x00\xae\xce\x1c\xe9\x00\x00\x00\
\x02bKGD\x00\xff\x87\x8f\xcc\xbf\x00\x00\x00\x09p\
HYs\x00\x00\x0b\x13\x00\x00\x0b\x13\x01\x00\x9a\x9c\x18\
\x00\x00\x00\x07tIME\x07\xdc\x08\x17\x08\x15;\xdc\
;\x0c\x9b\x00\x00\x00*IDAT\x08\xd7c`\xc0\
\x00\x8c\x0c\x0cs> \x0b\xa4\x08020 \x0b\xa6\
\x08000B\x98\x10\xc1\x14\x01\x14\x13P\xb5\xa3\x01\
\x00\xc6\xb9\x07\x90]f\x1f\x83\x00\x00\x00\x00IEN\
D\xaeB`\x82\
"
qt_resource_name = b"\
\x00\x08\
\x06\xc5\x8e\xa5\
\x00o\
\x00p\x00e\x00n\x00p\x00y\x00p\x00e\
\x00\x06\
\x07\x03}\xc3\
\x00i\
\x00m\x00a\x00g\x00e\x00s\
\x00\x12\
\x01.\x03'\
\x00c\
\x00o\x00m\x00b\x00o\x00b\x00o\x00x\x00_\x00a\x00r\x00r\x00o\x00w\x00.\x00p\x00n\
\x00g\
\x00\x1b\
\x03Z2'\
\x00c\
\x00o\x00m\x00b\x00o\x00b\x00o\x00x\x00_\x00a\x00r\x00r\x00o\x00w\x00_\x00d\x00i\
\x00s\x00a\x00b\x00l\x00e\x00d\x00.\x00p\x00n\x00g\
"
qt_resource_struct = b"\
\x00\x00\x00\x00\x00\x02\x00\x00\x00\x01\x00\x00\x00\x01\
\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x00\x00\x02\x00\x00\x00\x01\x00\x00\x00\x02\
\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00\x16\x00\x02\x00\x00\x00\x02\x00\x00\x00\x03\
\x00\x00\x00\x00\x00\x00\x00\x00\
\x00\x00\x00(\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\
\x00\x00\x01vA\x9d\xa25\
\x00\x00\x00R\x00\x00\x00\x00\x00\x01\x00\x00\x00\xa9\
\x00\x00\x01vA\x9d\xa25\
"
def qInitResources():
QtCore.qRegisterResourceData(
0x03, qt_resource_struct, qt_resource_name, qt_resource_data
)
def qCleanupResources():
QtCore.qUnregisterResourceData(
0x03, qt_resource_struct, qt_resource_name, qt_resource_data
)

View file

@ -0,0 +1,32 @@
import Qt
initialized = False
resources = None
if Qt.__binding__ == "PySide2":
from . import pyside2_resources as resources
elif Qt.__binding__ == "PyQt5":
from . import pyqt5_resources as resources
def qInitResources():
global resources
global initialized
if resources is not None and not initialized:
initialized = True
resources.qInitResources()
def qCleanupResources():
global resources
global initialized
if resources is not None:
initialized = False
resources.qCleanupResources()
__all__ = (
"resources",
"qInitResources",
"qCleanupResources"
)

View file

@ -0,0 +1,6 @@
<RCC>
<qresource prefix="/openpype">
<file>images/combobox_arrow.png</file>
<file>images/combobox_arrow_disabled.png</file>
</qresource>
</RCC>

437
openpype/style/style.css Normal file
View file

@ -0,0 +1,437 @@
/*
Enabled vs Disabled logic in most of stylesheets
- global font color
Enabled - should be same globalle except placeholders
Disabled - font color is greyed out
- global active/hover
Enabled - color motive of borders and bg color
- combobox, slider, views, buttons, checkbox, radiobox, inputs
- QLineEdit, QTextEdit, QPlainTextEdit, QSpinBox
Enabled - bg has lighter or darked color
Disabled - bg has same color as background
- QComboBox, QPushButton, QToolButton
Enabled - slightly lighter color
Disabled - even lighter color
*/
QWidget {
color: {color:font};
background: {color:bg};
border-radius: 0px;
}
QWidget:disabled {
color: {color:font-disabled};
}
/* Inputs */
QSpinBox, QLineEdit, QPlainTextEdit, QTextEdit {
border: 1px solid {color:border};
border-radius: 0.3em;
background: {color:bg-inputs};
padding: 0.1em;
}
QSpinBox:disabled, QLineEdit:disabled, QPlainTextEdit:disabled, QTextEdit:disabled {
background: {color:bg-inputs-disabled};
}
QSpinBox:hover, QLineEdit:hover, QPlainTextEdit:hover, QTextEdit:hover{
border-color: {color:border-hover};
}
QSpinBox:focus, QLineEdit:focus, QPlainTextEdit:focus, QTextEdit:focus{
border-color: {color:border-focus};
}
/* Buttons */
QPushButton {
text-align:center center;
border: 1px solid {color:border};
border-radius: 0.2em;
padding: 3px;
background: {color:bg-buttons};
}
QPushButton:hover {
background: #333840;
border-color: {color:border-hover};
color: {color:font-hover};
}
QPushButton:pressed {
border-color: {color:border-focus};
}
QPushButton:disabled {
background: {color:bg-buttons-disabled};
}
QToolButton {
border: 1px solid #aaaaaa;
border-radius: 0.2em;
background: {color:bg-buttons};
}
QToolButton:hover {
background: #333840;
border-color: {color:border-hover};
}
QToolButton:disabled {
background: {color:bg-buttons-disabled};
}
/* QMenu */
QMenu {
border: 1px solid #555555;
background: {color:bg-inputs};
}
QMenu::item {
padding: 5px 10px 5px 5px;
border-left: 3px solid {color:bg-view};
}
QMenu::right-arrow {
min-width: 10px;
}
QMenu::separator {
border-left: 3px solid {color:bg-view};
background: black;
height: 2px;
margin-right: 5px;
}
QMenu::item:selected {
border-left-color: {color:active_1};
background: {color:bg-view-selection};
}
/* Combobox */
QComboBox {
border: 1px solid {color:border};
border-radius: 3px;
padding: 1px 18px 1px 3px;
background: {color:bg-buttons};
}
QComboBox:hover {
border-color: {color:border-hover};
}
QComboBox:disabled {
background: {color:bg-buttons-disabled};
}
/* QComboBox must have explicitly set Styled delegate! */
QComboBox QAbstractItemView {
border: 1px solid {color:border};
background: {color:bg-inputs};
outline: none;
}
QComboBox QAbstractItemView::item {
padding: 2px 4px 2px 4px;
border-left: 3px solid {color:bg-view};
}
QComboBox QAbstractItemView::item:selected {
border-left-color: {color:active_1};/*rgb(84, 209, 178);*/
background: {color:bg-view-selection};
color: {color:font};
}
QComboBox::drop-down {
subcontrol-origin: padding;
subcontrol-position: center right;
width: 15px;
border-style: none;
border-left-style: solid;
border-left-color: {color:border};
border-left-width: 1px;
}
QComboBox::down-arrow, QComboBox::down-arrow:on, QComboBox::down-arrow:hover, QComboBox::down-arrow:focus
{
image: url(:/openpype/images/combobox_arrow.png);
}
/* SLider */
QSlider::groove {
border: 1px solid #464b54;
border-radius: 0.3em;
background: {color:bg-inputs};
}
QSlider::groove:horizontal {
height: 8px;
}
QSlider::groove:vertical {
width: 8px;
}
QSlider::groove:hover {
border-color: {color:border-hover};
}
QSlider::groove:disabled {
background: {color:bg-inputs-disabled};
}
QSlider::groove:focus {
border-color: {color:border-focus};
}
QSlider::handle {
background: qlineargradient(
x1: 0, y1: 0.5,
x2: 1, y2: 0.5,
stop: 0 {color:active_1},
stop: 1 {color:active_2}
);
border: 1px solid #5c5c5c;
width: 10px;
height: 10px;
border-radius: 5px;
}
QSlider::handle:horizontal {
margin: -2px 0;
}
QSlider::handle:vertical {
margin: 0 -2px;
}
QSlider::handle:disabled {
background: qlineargradient(
x1:0, y1:0,
x2:1, y2:1,
stop:0 {color:bg-buttons},
stop:1 {color:bg-buttons-disabled}
);
}
/* Tab widget*/
QTabWidget::pane {
border-top-style: none;
}
/* move to the right to not mess with borders of widget underneath */
QTabWidget::tab-bar {
left: 2px;
}
QTabBar::tab {
border-top-left-radius: 4px;
border-top-right-radius: 4px;
padding: 5px;
}
QTabBar::tab:selected {
background: qradialgradient(
cx:0.5, cy:1, radius: 1,
fx:0.5, fy:1,
stop:0.3 {color:bg}, stop:1 {color:bg-buttons}
)
/* background: qradialgradient(
cx:0.5, cy:0.5, radius: 2,
fx:0.5, fy:1,
stop:0.3 {color:bg}, stop:1 white
) */
/* background: qlineargradient(
x1: 0, y1: 0, x2: 0, y2: 1,
stop: 0 {color:bg-inputs}, stop: 1.0 {color:bg}
); */
}
QTabBar::tab:!selected {
/* Make it smaller*/
margin-top: 3px;
background: qradialgradient(
cx:0.5, cy:1, radius: 1,
fx:0.5, fy:1,
stop:0 {color:bg}, stop:1 {color:bg-inputs}
)
}
QTabBar::tab:!selected:hover {
background: qradialgradient(
cx:0.5, cy:1, radius: 1,
fx:0.5, fy:1,
stop:0.3 {color:bg-buttons}, stop:1 {color:bg}
)
}
QTabBar::tab:first:selected {
margin-left: 0;
}
QTabBar::tab:last:selected {
margin-right: 0;
}
QTabBar::tab:only-one {
margin: 0;
}
QHeaderView {
border: none;
border-radius: 2px;
margin: 0px;
padding: 0px;
}
QHeaderView::section {
background: {color:bg-inputs};
padding: 4px;
border: none;
border-radius: 0px;
text-align: center;
color: {color:font};
font-weight: bold;
}
/* Views QListView QTreeView QTableView */
QAbstractItemView {
border: 1px solid {color:border};
border-radius: 0.2em;
background: {color:bg-view};
alternate-background-color: {color:bg-view-alternate};
}
QAbstractItemView:disabled{
background: {color:bg-view-disabled};
alternate-background-color: {color:bg-view-alternate-disabled};
}
QAbstractItemView::item {}
QAbstractItemView::item:selected {
background: {color:bg-view-selection};
color: {color:font-view-selection};
}
/* Same as selected but give ability to easy change it */
QAbstractItemView::item:selected:!active {
background: {color:bg-view-selection};
color: {color:font-view-selection};
}
/* Progress bar */
QProgressBar {
border: 1px solid {color:border};
font-weight: bold;
text-align: center;
}
QProgressBar:horizontal {
height: 20px;
}
QProgressBar:vertical {
width: 20px;
}
QProgressBar::chunk {
background: qlineargradient(
x1: 0, y1: 0.5,
x2: 1, y2: 0.5,
stop: 0 {color:active_1},
stop: 1 {color:active_2}
);
}
/* Scroll bars */
QScrollBar:horizontal {
height: 15px;
margin: 3px 3px 3px 6px;
border: 1px transparent {color:bg-inputs};
border-radius: 4px;
background: {color:bg-inputs};
}
QScrollBar::handle:horizontal {
background: #4B5362;
min-width: 5px;
border-radius: 4px;
}
QScrollBar::add-line:horizontal {
margin: 0px 3px 0px 3px;
width: 0px;
height: 0px;
subcontrol-position: right;
subcontrol-origin: margin;
}
QScrollBar::sub-line:horizontal {
margin: 0px 3px 0px 3px;
height: 0px;
width: 0px;
subcontrol-position: left;
subcontrol-origin: margin;
}
QScrollBar::add-line:horizontal:hover,QScrollBar::add-line:horizontal:on {
height: 0px;
width: 0px;
subcontrol-position: right;
subcontrol-origin: margin;
}
QScrollBar::sub-line:horizontal:hover, QScrollBar::sub-line:horizontal:on {
height: 0px;
width: 0px;
subcontrol-position: left;
subcontrol-origin: margin;
}
QScrollBar::up-arrow:horizontal, QScrollBar::down-arrow:horizontal {
background: none;
}
QScrollBar::add-page:horizontal, QScrollBar::sub-page:horizontal {
background: none;
}
QScrollBar:vertical {
background: {color:bg-inputs};
width: 15px;
margin: 6px 3px 3px 3px;
border: 1px transparent {color:bg-inputs};
border-radius: 4px;
}
QScrollBar::handle:vertical {
background: #4B5362;
min-height: 5px;
border-radius: 4px;
}
QScrollBar::sub-line:vertical {
margin: 3px 0px 3px 0px;
height: 0px;
width: 0px;
subcontrol-position: top;
subcontrol-origin: margin;
}
QScrollBar::add-line:vertical {
margin: 3px 0px 3px 0px;
height: 0px;
width: 0px;
subcontrol-position: bottom;
subcontrol-origin: margin;
}
QScrollBar::sub-line:vertical:hover,QScrollBar::sub-line:vertical:on {
subcontrol-position: top;
subcontrol-origin: margin;
}
QScrollBar::add-line:vertical:hover, QScrollBar::add-line:vertical:on {
subcontrol-position: bottom;
subcontrol-origin: margin;
}
QScrollBar::up-arrow:vertical, QScrollBar::down-arrow:vertical {
background: none;
}
QScrollBar::add-page:vertical, QScrollBar::sub-page:vertical {
background: none;
}