projects
/
pulseview.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
32c589f
)
ViewItem: Adjust the threshold between dark and light colors
author
Jens Steinhauser
<jens.steinhauser@gmail.com>
Thu, 3 Sep 2015 12:47:13 +0000
(14:47 +0200)
committer
Uwe Hermann
<uwe@hermann-uwe.de>
Fri, 4 Sep 2015 10:54:52 +0000
(12:54 +0200)
Previously, the function returned 'Qt::black' for all used colors except
when black itself was passed in, making the text on brown, blue or violet
backgrounds very hard to read.
pv/view/viewitem.cpp
patch
|
blob
|
history
diff --git
a/pv/view/viewitem.cpp
b/pv/view/viewitem.cpp
index 55243860c0f4b342c86238fb9bae3f07968acf29..a9c9b3dd8095673a8ef73717e965a2c4163ef13b 100644
(file)
--- a/
pv/view/viewitem.cpp
+++ b/
pv/view/viewitem.cpp
@@
-107,7
+107,7
@@
void ViewItem::paint_fore(QPainter &p, const ViewItemPaintParams &pp)
QColor ViewItem::select_text_colour(QColor background)
{
- return (background.lightness() >
64
) ? Qt::black : Qt::white;
+ return (background.lightness() >
110
) ? Qt::black : Qt::white;
}
} // namespace view