projects
/
pulseview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
TimeMarker: Added default get_label_rect implementation
[pulseview.git]
/
pv
/
view
/
trace.cpp
diff --git
a/pv/view/trace.cpp
b/pv/view/trace.cpp
index fd440185c4e9c376e4c5cef307c4b88e79e1b923..e9235e56f2713bfd348f29ab6c3c14112968f81d 100644
(file)
--- a/
pv/view/trace.cpp
+++ b/
pv/view/trace.cpp
@@
-115,7
+115,7
@@
void Trace::paint_label(QPainter &p, int right, bool hover)
p.drawPolygon(points, countof(points));
// Paint the text
p.drawPolygon(points, countof(points));
// Paint the text
- p.setPen(
get_text_colour(
));
+ p.setPen(
select_text_colour(colour_
));
p.setFont(QApplication::font());
p.drawText(QRectF(r.x(), r.y(),
r.width() - label_arrow_length, r.height()),
p.setFont(QApplication::font());
p.drawText(QRectF(r.x(), r.y(),
r.width() - label_arrow_length, r.height()),
@@
-162,11
+162,6
@@
QRectF Trace::label_rect(int right) const
label_size.height());
}
label_size.height());
}
-QColor Trace::get_text_colour() const
-{
- return (colour_.lightness() > 64) ? Qt::black : Qt::white;
-}
-
void Trace::paint_axis(QPainter &p, const RowItemPaintParams &pp, int y)
{
p.setPen(AxisPen);
void Trace::paint_axis(QPainter &p, const RowItemPaintParams &pp, int y)
{
p.setPen(AxisPen);