Moved Cursor markers to the outside
[pulseview.git] / pv / view / cursorpair.cpp
index a677c50347a75ed4c57ff2d5bfcb891314be7ed5..feac91d20d47a513c60f0a294c97b4f4fbda65cb 100644 (file)
@@ -30,8 +30,8 @@ namespace pv {
 namespace view {
 
 CursorPair::CursorPair(const View &view) :
-       _first(view, 0.0),
-       _second(view, 1.0),
+       _first(view, 0.0, _second),
+       _second(view, 1.0, _first),
        _view(view)
 {
 }
@@ -56,6 +56,13 @@ Cursor& CursorPair::second()
        return _second;
 }
 
+void CursorPair::draw_markers(QPainter &p,
+       const QRect &rect, unsigned int prefix)
+{
+       _first.paint_label(p, rect, prefix);
+       _second.paint_label(p, rect, prefix);
+}
+
 void CursorPair::draw_viewport_background(QPainter &p,
        const QRect &rect)
 {