diff --git a/dstyleplugin/brushschemes/ddark.css b/dstyleplugin/brushschemes/ddark.css index 7f03edf2..24b6040b 100644 --- a/dstyleplugin/brushschemes/ddark.css +++ b/dstyleplugin/brushschemes/ddark.css @@ -129,6 +129,7 @@ ScrollBar:hover { ScrollBar:pressed { HandleBrush: rgba(96, 96, 96, 0.3); + HandleBorderBrush: rgba(255, 255, 255, 0.05); } ScrollBar:focus { diff --git a/dstyleplugin/brushschemes/dsemidark.css b/dstyleplugin/brushschemes/dsemidark.css index db259715..f914ec39 100644 --- a/dstyleplugin/brushschemes/dsemidark.css +++ b/dstyleplugin/brushschemes/dsemidark.css @@ -129,6 +129,7 @@ ScrollBar:hover { ScrollBar:pressed { HandleBrush: rgba(96, 96, 96, 0.3); + HandleBorderBrush: rgba(255, 255, 255, 0.05); } ScrollBar:focus { diff --git a/dstyleplugin/scrollbarhelper.cpp b/dstyleplugin/scrollbarhelper.cpp index fc7978cc..c567b158 100644 --- a/dstyleplugin/scrollbarhelper.cpp +++ b/dstyleplugin/scrollbarhelper.cpp @@ -107,12 +107,12 @@ QRect Style::scrollbarSubControlRect(const QStyleOptionComplex *opt, QStyle::Sub case SC_ScrollBarSlider: if (scrollbar->orientation == Qt::Horizontal) { if (mouseOver && enabled) - ret.setRect(sliderstart, 1, sliderlen, scrollBarRect.height() - 2); + ret.setRect(sliderstart, 0, sliderlen, scrollBarRect.height()); else ret.setRect(sliderstart, scrollBarRect.height() / 4, sliderlen, scrollBarRect.height() / 2); } else { if (mouseOver && enabled) - ret.setRect(1, sliderstart, scrollBarRect.width() - 2, sliderlen); + ret.setRect(0, sliderstart, scrollBarRect.width(), sliderlen); else ret.setRect(scrollBarRect.width() / 4, sliderstart, scrollBarRect.width() / 2, sliderlen); } @@ -218,9 +218,6 @@ bool Style::drawScrollBarSliderControl(const QStyleOption *option, QPainter *pai QRectF rect = option->rect; - if (option->state & QStyle::State_Sunken) - rect.adjust(0.5, 0.5, 0, 0); - const QBrush &background = m_palette->brush(PaletteExtended::ScrollBar_HandleBrush, option, 0, Qt::lightGray); const QBrush &border = m_palette->brush(PaletteExtended::ScrollBar_HandleBorderBrush, option, 0, background); PainterHelper::drawRoundedRect(painter, rect, 3, 3, Qt::AbsoluteSize, background, Metrics::Painter_PenWidth, border);