mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-21 22:24:07 +01:00
checked scrollbar colors
This commit is contained in:
parent
8a175be810
commit
c8ce55a54e
3 changed files with 14 additions and 3 deletions
|
@ -97,6 +97,9 @@ void ColorScheme::setColors(double hue, double multiplier)
|
||||||
ChatInputBorder = getColor(0, 0.1, 0.9);
|
ChatInputBorder = getColor(0, 0.1, 0.9);
|
||||||
|
|
||||||
ScrollbarBG = ChatBackground;
|
ScrollbarBG = ChatBackground;
|
||||||
|
ScrollbarThumb = getColor(0, 0.1, 0.85);
|
||||||
|
ScrollbarThumbSelected = getColor(0, 0.1, 0.7);
|
||||||
|
ScrollbarArrow = getColor(0, 0.1, 0.4);
|
||||||
|
|
||||||
// generate color lookuptable
|
// generate color lookuptable
|
||||||
fillLookupTableValues(this->middleLookupTable, 0.000, 0.166, 0.66, 0.5);
|
fillLookupTableValues(this->middleLookupTable, 0.000, 0.166, 0.66, 0.5);
|
||||||
|
|
|
@ -49,6 +49,7 @@ public:
|
||||||
QColor TextFocused;
|
QColor TextFocused;
|
||||||
QColor Menu;
|
QColor Menu;
|
||||||
QColor MenuBorder;
|
QColor MenuBorder;
|
||||||
|
|
||||||
QColor ScrollbarBG;
|
QColor ScrollbarBG;
|
||||||
QColor ScrollbarThumb;
|
QColor ScrollbarThumb;
|
||||||
QColor ScrollbarThumbSelected;
|
QColor ScrollbarThumbSelected;
|
||||||
|
|
|
@ -199,10 +199,17 @@ void ScrollBar::paintEvent(QPaintEvent *)
|
||||||
QPainter painter(this);
|
QPainter painter(this);
|
||||||
painter.fillRect(rect(), this->colorScheme.ScrollbarBG);
|
painter.fillRect(rect(), this->colorScheme.ScrollbarBG);
|
||||||
|
|
||||||
painter.fillRect(QRect(0, 0, width(), _buttonHeight), QColor(255, 0, 0));
|
painter.fillRect(QRect(0, 0, width(), _buttonHeight), this->colorScheme.ScrollbarArrow);
|
||||||
painter.fillRect(QRect(0, height() - _buttonHeight, width(), _buttonHeight), QColor(255, 0, 0));
|
painter.fillRect(QRect(0, height() - _buttonHeight, width(), _buttonHeight), this->colorScheme.ScrollbarArrow);
|
||||||
|
|
||||||
painter.fillRect(_thumbRect, QColor(0, 255, 255));
|
// mouse over thumb
|
||||||
|
if (this->_mouseDownIndex == 2) {
|
||||||
|
painter.fillRect(_thumbRect, this->colorScheme.ScrollbarThumbSelected);
|
||||||
|
}
|
||||||
|
// mouse not over thumb
|
||||||
|
else {
|
||||||
|
painter.fillRect(_thumbRect, this->colorScheme.ScrollbarThumb);
|
||||||
|
}
|
||||||
|
|
||||||
// ScrollBarHighlight *highlight = highlights;
|
// ScrollBarHighlight *highlight = highlights;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue