BreezeStyleSheets/dist/qrc/light/stylesheet.qss

2244 lines
48 KiB
Plaintext
Raw Normal View History

/*
* BreezeDark stylesheet.
*
* :author: Colin Duquesnoy
* :editor: Alex Huszagh
2016-10-26 18:12:35 +00:00
* :license: MIT, see LICENSE.md
*
* This is originally a fork of QDarkStyleSheet, and is based on Breeze/
* BreezeDark color scheme, but is in no way affiliated with KDE.
2016-10-26 18:12:35 +00:00
*
* ---------------------------------------------------------------------
* The MIT License (MIT)
*
* Copyright (c) <2013-2014> <Colin Duquesnoy>
* Copyright (c) <2015-2021> <Alex Huszagh>
*
2016-10-26 18:12:35 +00:00
* Permission is hereby granted, free of charge, to any person obtaining
* a copy of this software and associated documentation files (the
* "Software"), to deal in the Software without restriction, including
* without limitation the rights to use, copy, modify, merge, publish,
* distribute, sublicense, and/or sell copies of the Software, and to
* permit persons to whom the Software is furnished to do so, subject to
* the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
2016-10-26 18:12:35 +00:00
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
* ---------------------------------------------------------------------
*/
/**
* MAIN STYLESHEET
* ---------------
*/
QToolTip
{
/* 0.2ex is the smallest value that's not ignored on Windows. */
border: 0.04em solid #31363b;
background-color: #eff0f1;
alternate-background-color: #eaebec;
color: #31363b;
padding: 0.1em;
opacity: 200;
}
QWidget
{
color: #31363b;
background-color: #eff0f1;
selection-background-color: rgba(51, 164, 223, 0.5);
selection-color: #31363b;
background-clip: border;
border-image: none;
}
QWidget:disabled
{
color: #b4b4b4;
background-color: #eff0f1;
}
2021-07-17 05:09:44 +00:00
QWidget:disabled:hover
{
background-color: #eff0f1;
}
QCheckBox
{
spacing: 0.23em;
outline: none;
color: #31363b;
margin-bottom: 0.09em;
opacity: 200;
}
QCheckBox:disabled
{
color: #bab9b8;
}
QGroupBox
{
/* Need to make sure the groupbox doesn't compress below the title. */
min-height: 1.2em;
border: 0.04em solid #bab9b8;
border-radius: 0.09em;
/**
* This gives us enough space at the top to ensure we can move the
* title to be inside the guidelines, and the padding at the top
* ensures we have space below the title.
*/
margin-top: 0.5em;
padding-top: 1em;
}
QGroupBox:focus
{
border: 0.04em solid #bab9b8;
border-radius: 0.09em;
}
QGroupBox::title
{
/* We need to move 0.6em up to be inside the lines, +1em for padding. */
top: -1.6em;
subcontrol-origin: content;
subcontrol-position: top center;
background: #eff0f1;
padding-left: 0.2em;
padding-right: 0.2em;
}
QCheckBox::indicator,
QTreeView::indicator
{
width: 1em;
height: 1em;
}
QCheckBox::indicator:unchecked,
QCheckBox::indicator:unchecked:focus,
QTreeView::indicator:unchecked,
QTreeView::indicator:unchecked:focus
{
2016-10-26 18:44:37 +00:00
border-image: url(:/light/checkbox_unchecked_disabled.svg);
}
QCheckBox::indicator:unchecked:hover,
QCheckBox::indicator:unchecked:pressed,
QTreeView::indicator:unchecked:hover,
QTreeView::indicator:unchecked:pressed,
QGroupBox::indicator:unchecked,
QGroupBox::indicator:unchecked:hover,
QGroupBox::indicator:unchecked:focus,
QGroupBox::indicator:unchecked:pressed
{
border: none;
border-image: url(:/light/checkbox_unchecked.svg);
}
QCheckBox::indicator:checked,
QTreeView::indicator:checked,
QGroupBox::indicator:checked
{
2016-10-26 18:44:37 +00:00
border-image: url(:/light/checkbox_checked.svg);
}
QCheckBox::indicator:checked:hover,
QCheckBox::indicator:checked:focus,
QCheckBox::indicator:checked:pressed,
QTreeView::indicator:checked:hover,
QTreeView::indicator:checked:focus,
QTreeView::indicator:checked:pressed,
QGroupBox::indicator:checked:hover,
QGroupBox::indicator:checked:focus,
QGroupBox::indicator:checked:pressed
{
border: none;
2016-10-26 18:44:37 +00:00
border-image: url(:/light/checkbox_checked.svg);
}
QCheckBox::indicator:indeterminate,
QTreeView::indicator:indeterminate
{
2016-10-26 18:44:37 +00:00
border-image: url(:/light/checkbox_indeterminate.svg);
}
QCheckBox::indicator:indeterminate:focus,
QCheckBox::indicator:indeterminate:hover,
QCheckBox::indicator:indeterminate:pressed,
QTreeView::indicator:indeterminate:focus,
QTreeView::indicator:indeterminate:hover,
QTreeView::indicator:indeterminate:pressed
{
border-image: url(:/light/checkbox_indeterminate.svg);
}
QCheckBox::indicator:indeterminate:disabled,
QTreeView::indicator:indeterminate:disabled
{
2016-10-26 18:44:37 +00:00
border-image: url(:/light/checkbox_indeterminate_disabled.svg);
}
QCheckBox::indicator:checked:disabled,
QTreeView::indicator:checked:disabled,
QGroupBox::indicator:checked:disabled
{
2016-10-26 18:44:37 +00:00
border-image: url(:/light/checkbox_checked_disabled.svg);
}
QCheckBox::indicator:unchecked:disabled,
QTreeView::indicator:unchecked:disabled,
QGroupBox::indicator:unchecked:disabled
{
2016-10-26 18:44:37 +00:00
border-image: url(:/light/checkbox_unchecked_disabled.svg);
}
QRadioButton
{
spacing: 0.23em;
outline: none;
color: #31363b;
margin-bottom: 0.09em;
}
QRadioButton:disabled
{
color: #bab9b8;
}
QRadioButton::indicator
{
width: 1em;
height: 1em;
}
QRadioButton::indicator:unchecked,
QRadioButton::indicator:unchecked:focus
{
2016-10-26 18:14:20 +00:00
border-image: url(:/light/radio_unchecked_disabled.svg);
}
QRadioButton::indicator:unchecked:hover,
QRadioButton::indicator:unchecked:pressed
{
border: none;
outline: none;
border-image: url(:/light/radio_unchecked.svg);
}
QRadioButton::indicator:checked
{
border: none;
outline: none;
2016-10-26 18:14:20 +00:00
border-image: url(:/light/radio_checked.svg);
}
QRadioButton::indicator:checked:hover,
QRadioButton::indicator:checked:focus,
QRadioButton::indicator:checked:pressed
{
border: none;
outline: none;
2016-10-26 18:14:20 +00:00
border-image: url(:/light/radio_checked.svg);
}
QRadioButton::indicator:checked:disabled
{
outline: none;
2016-10-26 18:14:20 +00:00
border-image: url(:/light/radio_checked_disabled.svg);
}
QRadioButton::indicator:unchecked:disabled
{
2016-10-26 18:14:20 +00:00
border-image: url(:/light/radio_unchecked_disabled.svg);
}
QMenuBar
{
background-color: #eff0f1;
color: #31363b;
}
QMenuBar::item
{
background: transparent;
}
QMenuBar::item:selected
{
background: transparent;
}
2021-07-17 05:09:44 +00:00
QMenuBar::item:disabled
{
color: #bab9b8;
}
QMenuBar::item:pressed
{
background-color: rgba(51, 164, 223, 0.5);
color: #31363b;
margin-bottom: -0.09em;
padding-bottom: 0.09em;
}
QMenu
{
color: #31363b;
margin: 0.09em;
}
QMenu::icon
{
margin: 0.23em;
}
QMenu::item
{
/* Add extra padding on the right for the QMenu arrow */
padding: 0.23em 1.5em 0.23em 1.3em;
border: 0.09em solid transparent;
background: transparent;
}
QMenu::item:selected
{
color: #31363b;
background-color: rgba(51, 164, 223, 0.5);
}
2021-07-17 05:09:44 +00:00
QMenu::item:selected:disabled
2016-10-26 19:51:01 +00:00
{
2021-07-17 05:09:44 +00:00
background-color: #eff0f1;
}
QMenu::item:disabled
{
color: #bab9b8;
}
QMenu::indicator
{
width: 1em;
height: 1em;
}
2016-10-26 19:51:01 +00:00
QMenu::indicator:non-exclusive:unchecked
{
border-image: url(:/light/checkbox_unchecked_disabled.svg);
}
2016-10-26 19:51:01 +00:00
QMenu::indicator:non-exclusive:unchecked:selected
{
border-image: url(:/light/checkbox_unchecked_disabled.svg);
}
2016-10-26 19:51:01 +00:00
QMenu::indicator:non-exclusive:checked
{
border-image: url(:/light/checkbox_checked.svg);
}
2016-10-26 19:51:01 +00:00
QMenu::indicator:non-exclusive:checked:selected
{
border-image: url(:/light/checkbox_checked.svg);
}
2016-10-26 19:51:01 +00:00
QMenu::indicator:exclusive:unchecked
{
border-image: url(:/light/radio_unchecked_disabled.svg);
}
2016-10-26 19:51:01 +00:00
QMenu::indicator:exclusive:unchecked:selected
{
border-image: url(:/light/radio_unchecked_disabled.svg);
}
2016-10-26 19:51:01 +00:00
QMenu::indicator:exclusive:checked
{
border-image: url(:/light/radio_checked.svg);
}
2016-10-26 19:51:01 +00:00
QMenu::indicator:exclusive:checked:selected
{
border-image: url(:/light/radio_checked.svg);
}
2016-10-26 19:51:01 +00:00
QMenu::right-arrow
{
margin: 0.23em;
2016-10-26 19:51:01 +00:00
border-image: url(:/light/right_arrow.svg);
width: 0.5em;
height: 0.8em;
}
2021-07-17 05:09:44 +00:00
QMenu::right-arrow:disabled
{
border-image: url(:/light/right_arrow_disabled.svg);
}
QAbstractItemView
{
alternate-background-color: #eff0f1;
color: #31363b;
border: 0.09em solid #bab9b8;
border-radius: 0.09em;
}
2021-07-17 05:09:44 +00:00
QMenuBar::item:focus:!disabled
{
border: 0.04em solid rgba(51, 164, 223, 0.5);
}
2016-10-26 19:51:01 +00:00
QTabWidget:focus,
QCheckBox:focus,
QRadioButton:focus,
QSlider:focus
{
border: none;
}
QLineEdit
{
background-color: #eff0f1;
padding: 0.23em;
border-style: solid;
border: 0.04em solid #bab9b8;
border-radius: 0.09em;
color: #31363b;
}
QAbstractScrollArea
2016-10-26 19:51:01 +00:00
{
border-radius: 0.09em;
border: 0.09em solid #bab9b8;
background-color: transparent;
}
/**
* This is the background for the box in the bottom-right corner
* whene both scrollbars are active.
*/
QAbstractScrollArea::corner
2016-10-26 19:51:01 +00:00
{
background: #eff0f1;
}
/**
* Can't do the KDE style of where the scrollbar handle
* becomes light on the hover, and only when the handle
* is hovered does it become stylized. This is because
* both the handle and the background events are treated
* together.
*/
QScrollBar:horizontal
{
background-color: #eff0f1;
height: 0.65em;
margin: 0.13em 0.65em 0.13em 0.65em;
border: 0.04em transparent #eff0f1;
border-radius: 0.17em;
}
QScrollBar:horizontal:hover
{
background-color: #c7c7c6;
}
QScrollBar::handle:horizontal
{
background-color: rgba(51, 164, 223, 0.8);
border: 0.04em solid rgba(51, 164, 223, 0.8);
min-width: 0.5em;
border-radius: 0.17em;
}
QScrollBar::handle:horizontal:hover
{
background-color: rgba(51, 164, 223, 0.8);
border: 0.04em solid rgba(51, 164, 223, 0.8);
}
QScrollBar::add-line:horizontal
{
margin: 0em 0.13em 0em 0.13em;
border-image: url(:/light/transparent.svg);
width: 0.41em;
height: 0.41em;
subcontrol-position: right;
subcontrol-origin: margin;
}
QScrollBar::sub-line:horizontal
{
margin: 0em 0.13em 0em 0.13em;
border-image: url(:/light/transparent.svg);
width: 0.41em;
height: 0.41em;
subcontrol-position: left;
subcontrol-origin: margin;
}
QScrollBar::add-line:horizontal:hover,
QScrollBar::add-line:horizontal:on
{
border-image: url(:/light/transparent.svg);
width: 0.41em;
height: 0.41em;
subcontrol-position: right;
subcontrol-origin: margin;
}
QScrollBar::sub-line:horizontal:hover,
QScrollBar::sub-line:horizontal:on
{
border-image: url(:/light/transparent.svg);
width: 0.41em;
height: 0.41em;
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: #eff0f1;
width: 0.65em;
margin: 0.65em 0.13em 0.65em 0.13em;
border: 0.04em transparent #eff0f1;
border-radius: 0.17em;
}
QScrollBar:vertical:hover
{
background-color: #c7c7c6;
}
QScrollBar::handle:vertical
{
background-color: rgba(51, 164, 223, 0.8);
border: 0.04em solid rgba(51, 164, 223, 0.8);
min-height: 0.5em;
border-radius: 0.17em;
}
QScrollBar::handle:vertical:hover
{
background-color: rgba(51, 164, 223, 0.8);
border: 0.04em solid rgba(51, 164, 223, 0.8);
}
QScrollBar::sub-line:vertical
{
margin: 0.13em 0em 0.13em 0em;
border-image: url(:/light/transparent.svg);
height: 0.41em;
width: 0.41em;
subcontrol-position: top;
subcontrol-origin: margin;
}
QScrollBar::add-line:vertical
{
margin: 0.13em 0em 0.13em 0em;
border-image: url(:/light/transparent.svg);
height: 0.41em;
width: 0.41em;
subcontrol-position: bottom;
subcontrol-origin: margin;
}
2016-10-26 20:25:02 +00:00
QScrollBar::sub-line:vertical:hover,
QScrollBar::sub-line:vertical:on
{
border-image: url(:/light/transparent.svg);
height: 0.41em;
width: 0.41em;
subcontrol-position: top;
subcontrol-origin: margin;
}
2016-10-26 20:25:02 +00:00
QScrollBar::add-line:vertical:hover,
QScrollBar::add-line:vertical:on
{
border-image: url(:/light/transparent.svg);
height: 0.41em;
width: 0.41em;
subcontrol-position: bottom;
subcontrol-origin: margin;
}
2016-10-26 20:25:02 +00:00
QScrollBar::up-arrow:vertical,
QScrollBar::down-arrow:vertical
{
background: none;
}
2016-10-26 20:25:02 +00:00
QScrollBar::add-page:vertical,
QScrollBar::sub-page:vertical
{
background: none;
}
QTextEdit
{
background-color: #eff0f1;
color: #31363b;
border: 0.04em solid #bab9b8;
}
QPlainTextEdit
{
background-color: #eff0f1;
color: #31363b;
border-radius: 0.09em;
border: 0.04em solid #bab9b8;
}
2016-10-26 22:37:58 +00:00
QSizeGrip
{
2016-10-26 20:25:02 +00:00
border-image: url(:/light/sizegrip.svg);
width: 0.5em;
height: 0.5em;
}
/**
* Set the separator to be transparent, since the dock has a border.
* On PyQt6, neither the border nor the background seem to be respected.
*/
QMainWindow::separator
{
border: 0.09em transparent #bab9b8;
background: transparent;
}
QMenu::separator
{
height: 0.09em;
background-color: #bab9b8;
padding-left: 0.2em;
margin-top: 0.2em;
margin-bottom: 0.2em;
margin-left: 0.41em;
margin-right: 0.41em;
}
QFrame[frameShape="2"], /* QFrame::Panel == 0x0003 */
QFrame[frameShape="3"], /* QFrame::WinPanel == 0x0003 */
QFrame[frameShape="4"], /* QFrame::HLine == 0x0004 */
QFrame[frameShape="5"], /* QFrame::VLine == 0x0005 */
QFrame[frameShape="6"] /* QFrame::StyledPanel == 0x0006 */
{
border-width: 0.04em;
padding: 0.09em;
border-style: solid;
border-color: #eff0f1;
background-color: #bab9b8;
border-radius: 0.23em;
}
/* Provide highlighting for frame objects. */
QFrame[frameShape="2"]:hover,
QFrame[frameShape="3"]:hover,
QFrame[frameShape="4"]:hover,
QFrame[frameShape="5"]:hover,
QFrame[frameShape="6"]:hover
{
border: 0.04em solid rgba(51, 164, 223, 0.5);
}
/* Don't provide an outline if we have a widget that takes up the space. */
QFrame[frameShape] QAbstractItemView:hover
{
border: 0em solid black;
}
/**
* Note: I can't really change the background of the toolbars
* independently, since KDE Breeze has different colors for the
* window bar and the rest of the UI. The top toolbar uses
* the window style, and the rest use the application style,
* which we can't do.
*/
2016-10-26 20:25:02 +00:00
QToolBar
{
font-weight: bold;
}
QToolBar:horizontal
{
background: 0.09em solid #eff0f1;
}
QToolBar:vertical
{
background: 0.09em solid #eff0f1;
}
2016-10-26 20:25:02 +00:00
QToolBar::handle:horizontal
{
border-image: url(:/light/hmovetoolbar.svg);
}
2016-10-26 20:25:02 +00:00
QToolBar::handle:vertical
{
border-image: url(:/light/vmovetoolbar.svg);
}
2016-10-26 20:25:02 +00:00
QToolBar::separator:horizontal
{
border-image: url(:/light/hseptoolbar.svg);
}
2016-10-26 20:25:02 +00:00
QToolBar::separator:vertical
{
border-image: url(:/light/vseptoolbar.svg);
}
QToolBar QToolButton
{
font-weight: bold;
min-height: 1em;
min-width: 2em;
border: 0.04em transparent black;
padding-left: 0.2em;
padding-right: 0.3em;
}
QToolBar QToolButton:hover
{
border: 0.04em solid rgba(51, 164, 223, 0.5);
}
QToolBar QToolButton:pressed
{
border: 0.04em solid rgba(51, 164, 223, 0.5);
/* The padding doesn't inherit from `QToolBar QToolButton`, so leave it in. */
padding-left: 0.2em;
padding-right: 0.3em;
}
QPushButton
{
color: #31363b;
background-color: #eaebec;
border: 0.04em solid #bab9b8;
padding: 0.23em;
border-radius: 0.09em;
outline: none;
min-height: 1.1em;
}
QComboBox:open,
QPushButton:open
{
border-width: 0.04em;
border-color: #bab9b8;
}
QComboBox:closed,
QPushButton:closed
{
border-width: 0.04em;
border-color: #bab9b8;
}
QPushButton:disabled
{
background-color: #eff0f1;
border-width: 0.04em;
border-color: #bab9b8;
border-style: solid;
padding-top: 0.23em;
padding-bottom: 0.23em;
2016-10-26 20:25:02 +00:00
padding-left: 1ex;
padding-right: 1ex;
border-radius: 0.04em;
color: #b4b4b4;
}
2016-10-26 20:25:02 +00:00
QPushButton:focus
{
color: #31363b;
}
QPushButton:pressed
{
background-color: #bedfec;
padding-top: -0.65em;
padding-bottom: -0.74em;
color: #31363b;
}
QComboBox
{
border: 0.04em solid #bab9b8;
border-radius: 0.09em;
padding: 0.23em;
min-width: 2.5em;
}
QComboBox:editable
{
background-color: #eff0f1;
}
2016-10-26 20:25:02 +00:00
QPushButton:checked
{
background-color: #c7c7c6;
border: 0.04em solid #bab9b8;
color: #31363b;
}
QPushButton:hover
{
background-color: #eaebec;
border: 0.04em solid rgba(51, 164, 223, 0.5);
color: #31363b;
}
QPushButton:checked:hover
{
background-color: #c7c7c6;
border: 0.04em solid rgba(51, 164, 223, 0.5);
color: #31363b;
}
2016-10-26 20:25:02 +00:00
QComboBox:hover,
QComboBox:focus,
2016-10-26 20:25:02 +00:00
QAbstractSpinBox:hover,
QAbstractSpinBox:focus,
2016-10-26 20:25:02 +00:00
QLineEdit:hover,
QLineEdit:focus,
2016-10-26 20:25:02 +00:00
QTextEdit:hover,
QTextEdit:focus,
2016-10-26 20:25:02 +00:00
QPlainTextEdit:hover,
QPlainTextEdit:focus,
2016-10-26 20:25:02 +00:00
QAbstractView:hover,
QTreeView:hover,
QTreeView:focus
{
border: 0.04em solid rgba(51, 164, 223, 0.5);
color: #31363b;
}
QComboBox:hover:pressed:!editable,
2016-10-26 20:25:02 +00:00
QPushButton:hover:pressed,
QAbstractSpinBox:hover:pressed,
QLineEdit:hover:pressed,
QTextEdit:hover:pressed,
QPlainTextEdit:hover:pressed,
QAbstractView:hover:pressed,
QTreeView:hover:pressed
{
background-color: #eff0f1;
}
QComboBox:hover:pressed:editable
{
background-color: #eff0f1;
}
QComboBox QAbstractItemView
{
/* This happens for the drop-down menu always, whether editable or not.*/
background-color: #eff0f1;
selection-background-color: rgba(45, 147, 200, 0.5);
outline-color: 0em;
border-radius: 0.09em;
}
QComboBox::drop-down
{
subcontrol-origin: padding;
subcontrol-position: top right;
width: 0.65em;
border-left-width: 0em;
border-left-style: solid;
border-top-right-radius: 0.13em;
border-bottom-right-radius: 0.13em;
}
QComboBox::down-arrow
{
2016-10-26 20:25:02 +00:00
border-image: url(:/light/down_arrow_disabled.svg);
width: 0.8em;
height: 0.5em;
margin-right: 0.41em;
}
2016-10-26 20:25:02 +00:00
QComboBox::down-arrow:on,
QComboBox::down-arrow:hover,
QComboBox::down-arrow:focus
{
2016-10-26 20:25:02 +00:00
border-image: url(:/light/down_arrow.svg);
width: 0.8em;
height: 0.5em;
margin-right: 0.41em;
}
2016-10-26 20:25:02 +00:00
QAbstractSpinBox
{
padding: 0.23em;
border: 0.09em solid #bab9b8;
background-color: #eff0f1;
color: #31363b;
border-radius: 0.09em;
min-width: 3em;
min-height: 1em;
}
QAbstractSpinBox:hover
{
border: 0.09em solid rgba(51, 164, 223, 0.5);
}
QAbstractSpinBox:up-button,
QAbstractSpinBox:up-button:hover
{
background-color: transparent;
subcontrol-origin: padding;
subcontrol-position: center right;
padding-right: 0.1em;
width: 0.8em;
height: 0.5em;
}
QAbstractSpinBox:down-button,
QAbstractSpinBox:down-button:hover
{
background-color: transparent;
subcontrol-origin: padding;
subcontrol-position: center left;
padding-left: 0.1em;
width: 0.8em;
height: 0.5em;
}
/**
* Bug fixes for elongated items in QSpinBoxes.
* By default, the items are bounded by `down-button`
* and `up-button`, so this doesn't actually affect the styling.
*
* This does however affect some custom styling using
* QStyle.CC_ComboBox, which affects QDateEdit. This cannot
* be selected using QDateEdit, since it uses a global style.
* This sounds nonsensical, because CC_ComboBox isn't a spin box,
* but through trial and error, this is in fact the case.
*
* Affects #40.
*/
QAbstractSpinBox::up-arrow,
QAbstractSpinBox::up-arrow:disabled,
QAbstractSpinBox::up-arrow:off,
QAbstractSpinBox::up-arrow:!off:!disabled:hover,
QAbstractSpinBox::down-arrow,
QAbstractSpinBox::down-arrow:disabled,
QAbstractSpinBox::down-arrow:off,
QAbstractSpinBox::down-arrow:!off:!disabled:hover
{
border-image: none;
width: 0.8em;
height: 0.5em;
}
QAbstractSpinBox::up-arrow
{
image: url(:/light/up_arrow.svg);
}
2016-10-26 20:25:02 +00:00
QAbstractSpinBox::up-arrow:disabled,
QAbstractSpinBox::up-arrow:off
{
image: url(:/light/up_arrow_disabled.svg);
}
2016-10-26 20:25:02 +00:00
QAbstractSpinBox::up-arrow:hover
{
image: url(:/light/up_arrow_hover.svg);
}
QAbstractSpinBox::down-arrow
{
image: url(:/light/down_arrow.svg);
}
2016-10-26 20:25:02 +00:00
QAbstractSpinBox::down-arrow:disabled,
QAbstractSpinBox::down-arrow:off
{
image: url(:/light/down_arrow_disabled.svg);
}
2016-10-26 20:25:02 +00:00
QAbstractSpinBox::down-arrow:!off:!disabled:hover
{
image: url(:/light/down_arrow_hover.svg);
}
QDoubleSpinBox
{
min-width: 4em;
}
/**
* `QCalendarWidget QAbstractItemView:enabled` sets the color, background
* color, and selection color for active dates in the view.
* `QCalendarWidget QAbstractItemView:enabled` sets the disabled dates.
*/
QCalendarWidget QAbstractItemView:enabled
{
color: #31363b;
selection-color: #31363b;
selection-background-color: rgba(51, 164, 223, 0.5);
}
/* Won't take hover events. */
QPrevNextCalButton#qt_calendar_nextmonth
{
image: none;
subcontrol-origin: content;
subcontrol-position: right;
}
QPrevNextCalButton#qt_calendar_prevmonth
{
image: none;
subcontrol-origin: content;
subcontrol-position: left;
}
/**
* Setting for the month and year displays and drop-down menu for the
* month select. We style this separately because we want a drop-down
* indicator in the bottom right, unlike the normal QToolButton.
*/
QCalendarWidget QToolButton
{
background-color: transparent;
border: 0.04em solid #bab9b8;
border-radius: 0.09em;
margin: 0.23em;
padding: 0.23em;
padding-top: 0.1em;
padding-right: 1.2em;
min-height: 1.1em;
}
QCalendarWidget QToolButton:hover
{
border: 0.04em solid rgba(51, 164, 223, 0.5);
}
QCalendarWidget QToolButton:checked,
QCalendarWidget QToolButton:pressed
{
background-color: rgba(51, 164, 223, 0.5);
padding: 0.23em;
padding-right: 1.2em;
min-height: 1.3em;
outline: none;
}
/**
* The QCalendarWidget for QDateTimeEdit seems to improperly
* style the year QToolButton, which has an object name
* `qt_datetimedit_calendar`, so ensure we style it as well.
*/
QCalendarWidget QToolButton::menu-indicator,
#qt_datetimedit_calendar QCalendarWidget QToolButton::menu-indicator
{
border-image: none;
image: url(:/light/down_arrow.svg);
width: 0.8em;
height: 0.5em;
top: -0.7ex;
left: -0.09em;
padding-right: -1.11em;
subcontrol-origin: content;
subcontrol-position: bottom right;
}
QCalendarWidget QToolButton::menu-arrow,
#qt_datetimedit_calendar QCalendarWidget QToolButton::menu-arrow
{
border-image: none;
image: url(:/light/down_arrow.svg);
width: 0.8em;
height: 0.5em;
padding-right: 0.09em;
subcontrol-origin: content;
subcontrol-position: bottom right;
}
/**
* Setting for the year button. Both the month select and the year
* select are QToolButtons, and both are auto-raised. The year
* button however has the popup mode set to `DelayedPopup`.
*/
QCalendarWidget QToolButton[autoRaise="true"][popupMode="0"]
{
padding: 0.23em;
}
QCalendarWidget QSpinBox
{
max-height: 1.5em;
min-width: 3.5em;
margin: 0em;
margin-top: 0.2em;
padding: 0em;
outline: 0em;
padding-left: 0.5em;
}
QLabel
{
border: 0em solid black;
}
/* BORDERS */
2016-10-26 22:37:58 +00:00
QTabWidget::pane
{
padding: 0.23em;
margin: 0.04em;
}
2016-10-26 22:37:58 +00:00
QTabWidget::pane:top
{
border: 0.04em solid #bab9b8;
top: -0.04em;
}
2016-10-26 22:37:58 +00:00
QTabWidget::pane:bottom
{
border: 0.04em solid #bab9b8;
bottom: -0.04em;
}
2016-10-26 22:37:58 +00:00
QTabWidget::pane:left
{
border: 0.04em solid #bab9b8;
left: -0.04em;
}
2016-10-26 22:37:58 +00:00
QTabWidget::pane:right
{
border: 0.04em solid #bab9b8;
right: -0.04em;
}
QTabBar
{
qproperty-drawBase: 0;
left: 0.23em;
border-radius: 0.13em;
/**
* Note: this is the underline for each tab title. It's not
* documented, and this took forever to track down. At least
* 10 hours have been wasted trying to turn off this line,
* do not deleted this comment.
*/
selection-color: transparent;
}
QTabBar:focus
{
border: 0em transparent black;
}
2016-10-26 22:37:58 +00:00
QTabBar::close-button
{
/* Doesn't seem possible to resize these buttons */
border-image: url(:/light/transparent.svg);
image: url(:/light/close.svg);
background: transparent;
}
QTabBar::close-button:hover
2016-10-26 22:37:58 +00:00
{
image: url(:/light/close_hover.svg);
}
QTabBar::close-button:pressed
2016-10-26 22:37:58 +00:00
{
image: url(:/light/close_pressed.svg);
}
/* TOP TABS */
QTabBar::tab:top,
QTabBar::tab:top:last,
2016-10-26 18:12:35 +00:00
QTabBar::tab:top:only-one
{
color: #31363b;
border: 0.04em transparent black;
border-left: 0.04em solid #bab9b8;
border-right: 0.04em solid #bab9b8;
border-top: 0.09em solid rgba(51, 164, 223, 0.5);
background-color: #eff0f1;
padding: 0.23em;
min-width: 50px;
border-radius: 0.09em;
border-bottom-left-radius: 0em;
border-bottom-right-radius: 0em;
}
QTabBar::tab:top:!selected
{
color: #31363b;
background-color: #d9d8d7;
border: 0.04em transparent black;
border-right: 0.04em solid #bab9b8;
border-bottom: 0.04em solid #bab9b8;
border-radius: 0.09em;
border-bottom-left-radius: 0em;
border-bottom-right-radius: 0em;
}
QTabBar::tab:top:next-selected
{
border-right: 0.04em transparent #d9d8d7;
border-bottom-left-radius: 0em;
border-bottom-right-radius: 0em;
}
2016-10-26 22:37:58 +00:00
QTabBar::tab:top:!selected:hover
{
background-color: rgba(61, 173, 232, 0.2);
border-radius: 0.09em;
border-bottom-left-radius: 0em;
border-bottom-right-radius: 0em;
}
2016-10-26 22:37:58 +00:00
QTabBar::tab:top:!selected:first:hover
{
background-color: rgba(61, 173, 232, 0.2);
border-radius: 0.09em;
border-bottom-left-radius: 0em;
border-bottom-right-radius: 0em;
}
/* BOTTOM TABS */
QTabBar::tab:bottom,
QTabBar::tab:bottom:last,
2016-10-26 18:12:35 +00:00
QTabBar::tab:bottom:only-one
{
color: #31363b;
border: 0.04em transparent black;
border-left: 0.04em solid #bab9b8;
border-right: 0.04em solid #bab9b8;
border-bottom: 0.09em solid rgba(51, 164, 223, 0.5);
background-color: #eff0f1;
padding: 0.23em;
min-width: 50px;
border-radius: 0.09em;
border-top-left-radius: 0em;
border-top-right-radius: 0em;
}
QTabBar::tab:bottom:!selected
{
color: #31363b;
background-color: #d9d8d7;
border: 0.04em transparent black;
border-top: 0.04em solid #bab9b8;
border-right: 0.04em solid #bab9b8;
border-radius: 0.09em;
border-top-left-radius: 0em;
border-top-right-radius: 0em;
}
QTabBar::tab:bottom:next-selected
{
border-right: 0.04em transparent #d9d8d7;
border-top-left-radius: 0em;
border-top-right-radius: 0em;
}
2016-10-26 22:37:58 +00:00
QTabBar::tab:bottom:!selected:hover
{
background-color: rgba(61, 173, 232, 0.2);
border-radius: 0.09em;
border-top-left-radius: 0em;
border-top-right-radius: 0em;
}
2016-10-26 22:37:58 +00:00
QTabBar::tab:bottom:!selected:first:hover
{
background-color: rgba(61, 173, 232, 0.2);
border-radius: 0.09em;
border-top-left-radius: 0em;
border-top-right-radius: 0em;
}
/* LEFT TABS */
QTabBar::tab:left,
QTabBar::tab:left:last,
QTabBar::tab:left:only-one
{
color: #31363b;
border: 0.04em transparent black;
border-top: 0.09em solid rgba(51, 164, 223, 0.5);
border-bottom: 0.04em solid #bab9b8;
border-left: 0.04em solid #bab9b8;
background-color: #eff0f1;
padding: 0.23em;
min-height: 50px;
border-radius: 0.09em;
border-top-right-radius: 0em;
border-bottom-right-radius: 0em;
}
QTabBar::tab:left:!selected
{
color: #31363b;
background-color: #d9d8d7;
border: 0.04em transparent black;
border-top: 0.04em solid #bab9b8;
border-right: 0.04em solid #bab9b8;
border-radius: 0.09em;
border-top-right-radius: 0em;
border-bottom-right-radius: 0em;
}
QTabBar::tab:left:previous-selected
2016-10-26 22:37:58 +00:00
{
border-top: 0.04em transparent #d9d8d7;
border-top-right-radius: 0em;
border-bottom-right-radius: 0em;
}
QTabBar::tab:left:!selected:hover
2016-10-26 22:37:58 +00:00
{
background-color: rgba(61, 173, 232, 0.2);
border-radius: 0.09em;
border-top-right-radius: 0em;
border-bottom-right-radius: 0em;
}
QTabBar::tab:left:!selected:first:hover
2016-10-26 22:37:58 +00:00
{
background-color: rgba(61, 173, 232, 0.2);
border-radius: 0.09em;
border-top-right-radius: 0em;
border-bottom-right-radius: 0em;
}
/* RIGHT TABS */
QTabBar::tab:right,
QTabBar::tab:right:last,
2016-10-26 18:12:35 +00:00
QTabBar::tab:right:only-one
{
color: #31363b;
border: 0.04em transparent black;
border-top: 0.09em solid rgba(51, 164, 223, 0.5);
border-bottom: 0.04em solid #bab9b8;
border-right: 0.04em solid #bab9b8;
background-color: #eff0f1;
padding: 0.23em;
min-height: 50px;
border-radius: 0.09em;
border-top-left-radius: 0em;
border-bottom-left-radius: 0em;
}
QTabBar::tab:right:!selected
{
color: #31363b;
background-color: #d9d8d7;
border: 0.04em transparent black;
border-top: 0.04em solid #bab9b8;
border-left: 0.04em solid #bab9b8;
border-radius: 0.09em;
border-top-left-radius: 0em;
border-bottom-left-radius: 0em;
}
QTabBar::tab:right:previous-selected
{
border-top: 0.04em transparent #d9d8d7;
border-top-left-radius: 0em;
border-bottom-left-radius: 0em;
}
2016-10-26 22:37:58 +00:00
QTabBar::tab:right:!selected:hover
{
background-color: rgba(61, 173, 232, 0.2);
border-radius: 0.09em;
border-top-left-radius: 0em;
border-bottom-left-radius: 0em;
}
2016-10-26 22:37:58 +00:00
QTabBar::tab:right:!selected:first:hover
{
background-color: rgba(61, 173, 232, 0.2);
border-radius: 0.09em;
border-top-left-radius: 0em;
border-bottom-left-radius: 0em;
}
2016-10-26 22:37:58 +00:00
QTabBar QToolButton::right-arrow:enabled
{
border-image: url(:/light/right_arrow.svg);
width: 0.5em;
height: 0.8em;
2016-10-26 22:37:58 +00:00
}
2016-10-26 22:37:58 +00:00
QTabBar QToolButton::left-arrow:enabled
{
border-image: url(:/light/left_arrow.svg);
width: 0.5em;
height: 0.8em;
2016-10-26 22:37:58 +00:00
}
2016-10-26 22:37:58 +00:00
QTabBar QToolButton::right-arrow:disabled
{
border-image: url(:/light/right_arrow_disabled.svg);
width: 0.5em;
height: 0.8em;
2016-10-26 22:37:58 +00:00
}
2016-10-26 22:37:58 +00:00
QTabBar QToolButton::left-arrow:disabled
{
border-image: url(:/light/left_arrow_disabled.svg);
width: 0.5em;
height: 0.8em;
2016-10-26 22:37:58 +00:00
}
/**
* Special styles for triangular QTabWidgets.
* These ignore the border attributes, and the border and
* text color seems to be set via the `QTabBar::tab` color
* property. This seemingly cannot be changed.
*
* The rounded shapes are 0-3, and the triangular ones are 4-7.
*
* The QTabBar outline doesn't respect on QTabBar::tab:
* border-color
* outline-color
*/
QTabBar[shape="4"]::tab,
QTabBar[shape="5"]::tab,
QTabBar[shape="6"]::tab,
QTabBar[shape="7"]::tab,
QTabBar[shape="4"]::tab:last,
QTabBar[shape="5"]::tab:last,
QTabBar[shape="6"]::tab:last,
QTabBar[shape="7"]::tab:last,
QTabBar[shape="4"]::tab:only-one,
QTabBar[shape="5"]::tab:only-one,
QTabBar[shape="6"]::tab:only-one,
QTabBar[shape="7"]::tab:only-one
{
/* Need a dark color without alpha channel since it affects the text. */
color: #3daef3;
background-color: #eff0f1;
padding: 0.23em;
}
QTabBar[shape="4"]::tab,
QTabBar[shape="5"]::tab,
QTabBar[shape="4"]::tab:last,
QTabBar[shape="5"]::tab:last,
QTabBar[shape="4"]::tab:only-one,
QTabBar[shape="5"]::tab:only-one
{
min-width: 50px;
}
QTabBar[shape="6"]::tab,
QTabBar[shape="7"]::tab,
QTabBar[shape="6"]::tab:last,
QTabBar[shape="7"]::tab:last,
QTabBar[shape="6"]::tab:only-one,
QTabBar[shape="7"]::tab:only-one
{
min-height: 50px;
}
QTabBar[shape="4"]::tab:!selected,
QTabBar[shape="5"]::tab:!selected,
QTabBar[shape="6"]::tab:!selected,
QTabBar[shape="7"]::tab:!selected
{
color: #31363b;
background-color: #d9d8d7;
}
/**
* Increase padding on the opposite side of the icon to avoid text clipping.
*
* BUG: The padding works for North, West, and East in Qt5, South does not
* work. All tab positions work for triangular tabs in Qt6.
*/
QTabBar[shape="4"][tabsClosable="true"]::tab,
QTabBar[shape="5"][tabsClosable="true"]::tab
{
padding-left: 0.5em;
}
QTabBar[shape="6"][tabsClosable="true"]::tab
{
padding-bottom: 0.5em;
}
QTabBar[shape="7"][tabsClosable="true"]::tab
{
padding-top: 0.5em;
}
/**
* Undo the padding for the tab.
*
* Enumerated values are North, South, West, East in that order,
* from 4-7.
*
* NOTE: Any higher padding will clip the icon.
*/
QTabBar[shape="4"]::close-button,
QTabBar[shape="5"]::close-button
{
padding-left: -0.12em;
}
QTabBar[shape="6"]::close-button
{
padding-bottom: -0.18em;
}
QTabBar[shape="7"]::close-button
{
padding-top: -0.18em;
}
2016-10-26 22:37:58 +00:00
QDockWidget
{
background: #eaebec;
/**
* It doesn't seem possible to change the border of the
* QDockWidget without changing the content margins.
*/
/**
* This is a bug fix so we can handle hover, pressed, and other events.
* Reference: https://stackoverflow.com/questions/32145080/qdockwidget-float-close-button-hover-images
*/
titlebar-close-icon: url(:/light/transparent.svg);
titlebar-normal-icon: url(:/light/transparent.svg);
}
/**
* Don't style the title, since it gives a weird, missing border
* around the rest of the dock widget, which the remaining border
* cannot be removed.
*
* There is a bug in Qt6, where the icons are small. It doesn't
* change if we use `image` instead of `border-image`, nor if we
* use `qproperty-icon`, etc. The icon seem to be half the size
* of our desired values.
*/
2016-10-26 22:37:58 +00:00
QDockWidget::close-button,
QDockWidget::float-button
{
border: 0.04em solid transparent;
border-radius: 0.09em;
background: transparent;
/* Maximum icon size for buttons */
icon-size: 14px;
}
2016-10-26 22:37:58 +00:00
QDockWidget::float-button
{
border-image: url(:/light/transparent.svg);
image: url(:/light/undock.svg);
}
2016-10-26 22:37:58 +00:00
QDockWidget::float-button:hover
{
image: url(:/light/undock_hover.svg);
}
/* The :pressed events don't register, seems to be a Qt bug. */
QDockWidget::float-button:pressed
{
image: url(:/light/undock_hover.svg);
}
2016-10-26 22:37:58 +00:00
QDockWidget::close-button
{
border-image: url(:/light/transparent.svg);
image: url(:/light/close.svg);
}
2016-10-26 22:37:58 +00:00
QDockWidget::close-button:hover
{
image: url(:/light/close_hover.svg);
}
/* The :pressed events don't register, seems to be a Qt bug. */
2016-10-26 22:37:58 +00:00
QDockWidget::close-button:pressed
{
image: url(:/light/close_pressed.svg);
}
2016-10-26 22:37:58 +00:00
QTreeView,
QListView
{
background-color: #eff0f1;
border: 0em solid black;
}
QTreeView:selected,
QTreeView:!selected,
QListView:selected,
QListView:!selected
{
border: 0em solid black;
}
QTreeView::branch:has-siblings
2016-10-26 22:37:58 +00:00
{
border-image: url(:/light/vline.svg);
image: none;
}
/* These branch indicators don't scale */
TreeView::branch:!has-siblings
{
border-image: none;
image: none;
}
2016-10-26 22:37:58 +00:00
QTreeView::branch:has-siblings:adjoins-item
{
border-image: url(:/light/branch_more.svg);
}
2016-10-26 22:37:58 +00:00
QTreeView::branch:!has-children:!has-siblings:adjoins-item
{
border-image: url(:/light/branch_end.svg);
}
QTreeView::branch:has-children:!has-siblings:closed,
2016-10-26 22:37:58 +00:00
QTreeView::branch:closed:has-children:has-siblings
{
image: url(:/light/branch_closed.svg);
}
QTreeView::branch:has-children:!has-siblings:closed:hover,
QTreeView::branch:closed:has-children:has-siblings:hover
{
image: url(:/light/branch_closed_hover.svg);
}
QTreeView::branch:has-children:!has-siblings:closed,
QTreeView::branch:open:has-children:!has-siblings
{
border-image: url(:/light/branch_end_arrow.svg);
}
QTreeView::branch:closed:has-children:has-siblings,
QTreeView::branch:open:has-children:has-siblings
{
border-image: url(:/light/branch_more_arrow.svg);
}
QTreeView::branch:open:has-children:!has-siblings,
2016-10-26 22:37:58 +00:00
QTreeView::branch:open:has-children:has-siblings
{
image: url(:/light/branch_open.svg);
}
QTreeView::branch:open:has-children:!has-siblings:hover,
QTreeView::branch:open:has-children:has-siblings:hover
{
image: url(:/light/branch_open_hover.svg);
}
QListView
{
/* Give space for elements aligned left or right. */
padding: 0.2em;
}
2016-10-26 18:12:35 +00:00
QTableView::item,
2016-10-17 23:03:19 +00:00
QListView::item,
QTreeView::item
{
padding: 0.13em;
color: #31363b;
2016-10-17 23:03:19 +00:00
}
2016-10-26 18:12:35 +00:00
QTableView::item:!selected:hover,
QListView::item:!selected:hover,
QTreeView::item:!selected:hover
2016-10-17 23:03:19 +00:00
{
background-color: rgba(61, 173, 232, 0.2);
outline: 0;
color: #31363b;
padding: 0.13em;
}
QSlider::handle:horizontal,
QSlider::handle:vertical
2016-10-26 22:37:58 +00:00
{
background: #eff0f1;
border: 0.04em solid rgba(106, 105, 105, 0.7);
width: 0.7em;
height: 0.7em;
border-radius: 0.35em;
}
QSlider:horizontal
{
height: 2em;
}
QSlider:vertical
{
width: 2em;
}
2016-10-26 22:37:58 +00:00
QSlider::handle:horizontal
{
margin: -0.23em 0;
}
QSlider::handle:vertical
{
margin: 0 -0.23em;
}
QSlider::groove:horizontal,
2016-10-26 22:37:58 +00:00
QSlider::groove:vertical
{
background: #d9d8d7;
border: 0em solid #eff0f1;
border-radius: 0.19em;
}
QSlider::groove:horizontal
{
height: 0.4em;
}
QSlider::groove:vertical
2016-10-26 22:37:58 +00:00
{
width: 0.4em;
}
QSlider::handle:horizontal:hover,
QSlider::handle:horizontal:focus,
QSlider::handle:vertical:hover,
QSlider::handle:vertical:focus
{
border: 0.04em solid #3daef3;
}
QSlider::handle:horizontal:!focus:!hover,
QSlider::handle:vertical:!focus:!hover
{
border: 0.04em solid rgba(106, 105, 105, 0.7);
}
2016-10-26 18:12:35 +00:00
QSlider::sub-page:horizontal,
QSlider::add-page:vertical
{
background: #3daef3;
border-radius: 0.19em;
}
2016-10-26 18:12:35 +00:00
QSlider::add-page:horizontal,
QSlider::sub-page:vertical
{
background: rgba(106, 105, 105, 0.7);
border-radius: 0.19em;
}
/* QToolButton */
/**
* QToolButton's that have a push button need to be styled differently,
* and auto-raise is automatically disabled if there is a push button,
* IE, there is no arrow attached to the text in the QToolButton.
* Note that this is not affected by the following:
* popupMode: any pop-up mode does not affect the right arrow style.
* arrowType: only replaces the icon.
* toolButtonStyle: this is almost always set to icon only, even with text.
*
* This particularly affects QFileDialog, but also affects anything with
* auto-raise set to true. Therefore, our styles should only be set when
* auto-raise is false.
*
* The affected issues are #22 and #28.
* https://github.com/Alexhuszagh/BreezeStyleSheets/issues/22
* https://github.com/Alexhuszagh/BreezeStyleSheets/issues/28
*
* The invalid clear text icon in issue #28 still has:
* autoRaise: false
* arrowType: 0
* toolButtonStyle: 0
*/
QToolButton[autoRaise="false"]
2016-10-26 22:37:58 +00:00
{
background-color: transparent;
border: 0.04em solid #bab9b8;
border-radius: 0.09em;
margin: 0.23em;
padding: 0.23em;
padding-top: 0.1em;
padding-right: 1.2em;
}
QToolButton[autoRaise="false"]::right-arrow,
QToolButton[autoRaise="false"]::left-arrow,
QToolButton[autoRaise="false"]::up-arrow,
QToolButton[autoRaise="false"]::down-arrow
2016-10-26 22:37:58 +00:00
{
subcontrol-origin: margin;
subcontrol-position: right;
}
QToolButton::right-arrow
2016-10-26 22:37:58 +00:00
{
image: url(:/light/right_arrow.svg);
width: 0.8em;
height: 0.5em;
}
QToolButton::left-arrow
2016-10-26 22:37:58 +00:00
{
image: url(:/light/left_arrow.svg);
width: 0.8em;
height: 0.5em;
}
QToolButton::up-arrow
2016-10-26 22:37:58 +00:00
{
image: url(:/light/up_arrow.svg);
height: 0.8em;
width: 0.5em;
}
QToolButton::down-arrow
2016-10-26 22:37:58 +00:00
{
image: url(:/light/down_arrow.svg);
height: 0.8em;
width: 0.5em;
}
QToolButton[autoRaise="false"]:hover
2016-10-26 22:37:58 +00:00
{
border: 0.04em solid rgba(51, 164, 223, 0.5);
}
QToolButton[autoRaise="false"]:checked,
QToolButton[autoRaise="false"]:pressed
{
border: 0.04em solid rgba(51, 164, 223, 0.5);
background-color: rgba(51, 164, 223, 0.5);
padding: 0.23em;
padding-right: 1.2em;
outline: none;
}
QToolButton[autoRaise="false"]::menu-indicator
{
border-image: none;
image: url(:/light/down_arrow.svg);
width: 0.8em;
height: 0.5em;
left: -0.09em;
/* -1.2em + 0.09em */
padding-right: -1.11em;
/**
* Qt5 and Qt6 differ if the subcontrol-origin is set to
* the default, AKA, padding. Setting it to the content,
* which we adjust the padding to, makes it uniform between
* both.
*/
subcontrol-origin: content;
subcontrol-position: right;
}
QToolButton[autoRaise="false"]::menu-arrow
{
border-image: none;
image: url(:/light/down_arrow.svg);
width: 0.8em;
height: 0.5em;
padding-right: 0.09em;
subcontrol-position: right;
}
QToolButton[autoRaise="false"]::menu-button
2016-10-26 22:37:58 +00:00
{
border-top-right-radius: 0.5em;
border-bottom-right-radius: 0.5em;
2016-10-26 22:37:58 +00:00
/* 1ex width + 0.4ex for border + no text = 2ex allocated above */
width: 1.3em;
padding: 0.23em;
outline: none;
}
QToolButton[autoRaise="false"]::menu-button::menu-arrow
2016-10-26 22:37:58 +00:00
{
left: -0.09em;
subcontrol-position: right;
}
QToolButton[autoRaise="false"]::menu-button:hover
2016-10-26 22:37:58 +00:00
{
background-color: transparent;
}
QToolButton[autoRaise="false"]::menu-button:pressed
{
background-color: transparent;
padding: 0.23em;
outline: none;
}
QToolButton[autoRaise="true"]
{
background-color: transparent;
border: 0.04em solid transparent;
}
QToolButton[autoRaise="true"]:hover
{
border: 0.04em solid rgba(51, 164, 223, 0.5);
}
QToolButton[autoRaise="true"]:checked,
QToolButton[autoRaise="true"]:pressed
{
border: 0.04em solid rgba(51, 164, 223, 0.5);
background-color: rgba(51, 164, 223, 0.5);
}
QTableView
{
border: 0em solid black;
gridline-color: #bab9b8;
background-color: #eff0f1;
}
QTableView:!selected,
QTableView:selected
{
border: 0em solid black;
}
QTableView
{
border-radius: 0em;
}
QAbstractItemView::item
{
color: #31363b;
}
QAbstractItemView::item:pressed
{
background: rgba(45, 147, 200, 0.5);
color: #31363b;
}
QAbstractItemView::item:selected:!active
{
background: rgba(61, 173, 232, 0.2);
}
/* Use background with qlineargradient to avoid ugly border on widget. */
QAbstractItemView::item:selected:active
{
background: qlineargradient(
x1: 0.5, y1: 0.5
x2: 0.5, y2: 1,
stop: 0 rgba(45, 147, 200, 0.5),
stop: 1 rgba(45, 147, 200, 0.5)
);
color: #31363b;
}
QAbstractItemView::item:selected:hover
{
background: qlineargradient(
x1: 0.5, y1: 0.5
x2: 0.5, y2: 1,
stop: 0 rgba(71, 184, 243, 0.6),
stop: 1 rgba(71, 184, 243, 0.6)
);
color: #31363b;
}
QHeaderView
{
background-color: #eff0f1;
border: 0.04em transparent;
border-radius: 0em;
margin: 0em;
padding: 0em;
}
2016-10-26 22:37:58 +00:00
QHeaderView::section
{
background-color: #eff0f1;
border: 0.04em solid #bab9b8;
color: #31363b;
border-radius: 0em;
padding: 0em 0.23em 0em 0.23em;
text-align: center;
}
2016-10-26 22:37:58 +00:00
QHeaderView::section::vertical::first,
QHeaderView::section::vertical::only-one
{
border-top: 0.04em solid #bab9b8;
}
QHeaderView::section::vertical
{
border-top: transparent;
}
QHeaderView::section::horizontal::first,
QHeaderView::section::horizontal::only-one
{
border-left: 0.04em solid #bab9b8;
}
QHeaderView::section::horizontal
{
border-left: transparent;
}
QHeaderView[showSortIndicator="true"]::section::horizontal
{
/* Same as the width of the arrow subcontrols below. */
padding-right: 0.8em;
}
QHeaderView::section:checked
{
color: #272b2f;
background-color: #b9dae7;
}
/* Note that this doesn't work for QTreeView unless the header is clickable */
QHeaderView::section:hover,
QHeaderView::section::horizontal::first:hover,
QHeaderView::section::horizontal::only-one:hover,
QHeaderView::section::vertical::first:hover,
QHeaderView::section::vertical::only-one:hover
{
border: 0.04em solid rgba(51, 164, 223, 0.5);
}
QHeaderView[showSortIndicator="true"]::down-arrow
2016-10-26 22:37:58 +00:00
{
image: url(:/light/down_arrow.svg);
/**
* Qt5 and Qt6 differ if the subcontrol-origin is set to
* the default, AKA, padding. Setting it to the content,
* which we adjust the padding to, makes it uniform between
* both.
*/
subcontrol-origin: content;
subcontrol-position: center right;
width: 0.8em;
height: 0.5em;
/**
* Qt5 and Qt6 have different ideas of the padding of the
* arrow subcontrols: using `padding-left` to ensure that
* the width is undone fixes the padding of the content by
* an extra `0.8em` in Qt6, but doesn't affect Qt5.
*/
padding-right: 0.09em;
padding-left: -0.8em;
}
QHeaderView[showSortIndicator="true"]::up-arrow
2016-10-26 22:37:58 +00:00
{
image: url(:/light/up_arrow.svg);
subcontrol-origin: content;
subcontrol-position: center right;
width: 0.8em;
height: 0.5em;
padding-right: 0.09em;
padding-left: -0.8em;
}
QTableView QTableCornerButton::section
2016-10-26 22:37:58 +00:00
{
background-color: #eff0f1;
border: 0.04em transparent #bab9b8;
border-top: 0.04em solid #bab9b8;
border-left: 0.04em solid #bab9b8;
border-radius: 0em;
}
/* No hover event */
QTableView QTableCornerButton:hover
2016-10-26 22:37:58 +00:00
{
border: 0.04em transparent #bab9b8;
}
QTableView QTableCornerButton::section:pressed
2016-10-26 22:37:58 +00:00
{
border: 0.04em solid rgba(51, 164, 223, 0.5);
border-radius: 0em;
}
QToolBox
2016-10-26 22:37:58 +00:00
{
padding: 0.23em;
border: 0.09em transparent black;
}
QToolBox::tab
2016-10-26 22:37:58 +00:00
{
border-bottom: 0.09em solid #bab9b8;
margin-left: 1.5em;
}
QToolBox::tab:selected,
QToolBox::tab:hover
2016-10-26 22:37:58 +00:00
{
border-bottom: 0.09em solid rgba(51, 164, 223, 0.5);
}
QSplitter::handle
2016-10-26 22:37:58 +00:00
{
border: 0.09em solid #d9d8d7;
background: -0.5em solid #d9d8d7;
max-width: 0em;
max-height: 0em;
}
/**
* It's not possible to get satisfactory rounded borders here.
* If you set the border to be negative, while adjusting the
* widths, you get an asymmetrical curve which produces an
* unappealing border.
*/
QProgressBar:horizontal,
QProgressBar:vertical
2016-10-26 22:37:58 +00:00
{
background-color: rgba(106, 105, 105, 0.7);
border: 0.9em solid #eff0f1;
border-radius: 0.13em;
padding: 0em;
}
2016-10-26 22:37:58 +00:00
QProgressBar:horizontal
{
height: 0.2em;
min-width: 6em;
text-align: right;
padding-left: -0.03em;
padding-right: -0.03em;
margin-top: 0.2em;
margin-bottom: 0.2em;
margin-right: 1.3em;
}
QProgressBar:vertical
2016-10-26 22:37:58 +00:00
{
width: 0.2em;
min-height: 6em;
text-align: bottom;
padding-top: -0.03em;
padding-bottom: -0.03em;
margin-left: 0.2em;
margin-right: 0.2em;
margin-bottom: 0.41em;
}
QProgressBar::chunk:horizontal,
QProgressBar::chunk:vertical
2016-10-26 22:37:58 +00:00
{
background-color: #3daef3;
border: 0.9em transparent;
border-radius: 0.08em;
}
QScrollArea,
QScrollArea:focus,
QScrollArea:hover
{
border: 0em solid black;
}
/* ICONS */
/**
* Qt's built-in icons can look pretty bad if the system theme
* is a different color than the current one. For example, when
* using a dark theme, with a light UI, the `Ok` button is greyed
* out for an about dialog.
*
* QDialogButtonBox will apply for all standard buttons in all standard
* widgets, such as QMessageBox, etc. However, we do need to override
* standard icons elsewhere.
*
* The rest of the icons make little sense to implement:
* Qt uses native window decorations.
* Qt normally uses native file dialogs, which look nicer.
* Media controls are used in custom widgets, which aren't standard.
*/
QDialogButtonBox
{
dialogbuttonbox-buttons-have-icons: true;
dialog-cancel-icon: url(:/light/dialog_cancel.svg);
dialog-close-icon: url(:/light/dialog_close.svg);
dialog-ok-icon: url(:/light/dialog_ok.svg);
dialog-open-icon: url(:/light/dialog_open.svg);
dialog-reset-icon: url(:/light/dialog_reset.svg);
dialog-save-icon: url(:/light/dialog_save.svg);
/**
* No support yet for overriding saveall.
* dialog-saveall-icon: url(:/light/dialog_saveall.svg);
*/
dialog-yes-icon: url(:/light/dialog_ok.svg);
dialog-help-icon: url(:/light/dialog_help.svg);
dialog-no-icon: url(:/light/dialog_no.svg);
dialog-apply-icon: url(:/light/dialog_ok.svg);
dialog-discard-icon: url(:/light/dialog_discard.svg);
}
QMessageBox
{
messagebox-critical-icon: url(:/light/message_critical.svg);
messagebox-information-icon: url(:/light/message_information.svg);
messagebox-question-icon: url(:/light/message_question.svg);
messagebox-warning-icon: url(:/light/message_warning.svg);
}
2021-07-17 04:24:48 +00:00
/* Set some styles for these custom dialog buttons */
QDialogButtonBox QPushButton,
QMessageBox QPushButton
{
min-height: 1.1em;
min-width: 5em;
}