diff options
author | Felix Rohrbach <fxrh@gmx.de> | 2011-03-21 22:51:24 +0100 |
---|---|---|
committer | Andrea Diamantini <adjam7@gmail.com> | 2011-03-21 22:51:24 +0100 |
commit | f843422c46a9efa5d3f50d4cdb99a5e4ee71769f (patch) | |
tree | cf17526796e173b859b8ff2a8c76d9160c527d55 /src/urlbar | |
parent | Merge branch 'master' of git.kde.org:rekonq (diff) | |
download | rekonq-f843422c46a9efa5d3f50d4cdb99a5e4ee71769f.tar.xz |
Better color integration for the urlbar and the findbar
BUG:256535
Diffstat (limited to 'src/urlbar')
-rw-r--r-- | src/urlbar/urlbar.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/urlbar/urlbar.cpp b/src/urlbar/urlbar.cpp index 8f3e11ec..18ed9aaf 100644 --- a/src/urlbar/urlbar.cpp +++ b/src/urlbar/urlbar.cpp @@ -49,6 +49,7 @@ // KDE Includes #include <KCompletionBox> #include <KStandardDirs> +#include <KColorScheme> // Qt Includes #include <QtGui/QPainter> @@ -154,6 +155,7 @@ void UrlBar::activated(const KUrl& url, Rekonq::OpenType type) void UrlBar::paintEvent(QPaintEvent *event) { + KColorScheme colorScheme(palette().currentColorGroup()); QColor backgroundColor; QColor foregroundColor; @@ -176,8 +178,8 @@ void UrlBar::paintEvent(QPaintEvent *event) { if (_tab->url().scheme() == QL1S("https")) { - backgroundColor = QColor(255, 255, 171); // light yellow - foregroundColor = Qt::black; + backgroundColor = colorScheme.background(KColorScheme::NeutralBackground).color(); // light yellow + foregroundColor = colorScheme.foreground(KColorScheme::NormalText).color(); } p.setBrush(QPalette::Base, backgroundColor); p.setBrush(QPalette::Text, foregroundColor); |