X-Git-Url: http://git.code-monkey.de/?p=pulseview.git;a=blobdiff_plain;f=pv%2Fviews%2Ftrace%2Fcursorpair.hpp;h=6728268039f5e718d7363f68b63a9b43fa55758c;hp=5d53bacfd3ad839c825e6fbc90a33b21569a34cd;hb=581724de334181fc5338f1efa87954264cf90520;hpb=a3d5a7c7682ebb991718b49ae916c5840b3b6b51 diff --git a/pv/views/trace/cursorpair.hpp b/pv/views/trace/cursorpair.hpp index 5d53bac..6728268 100644 --- a/pv/views/trace/cursorpair.hpp +++ b/pv/views/trace/cursorpair.hpp @@ -25,6 +25,7 @@ #include #include +#include using std::pair; using std::shared_ptr; @@ -35,11 +36,15 @@ namespace pv { namespace views { namespace trace { +class View; + class CursorPair : public TimeItem { + Q_OBJECT + private: static const int DeltaPadding; - static const QColor ViewportFillColour; + static const QColor ViewportFillColor; public: /** @@ -48,7 +53,6 @@ public: */ CursorPair(View &view); -public: /** * Returns true if the item is visible and enabled. */ @@ -98,14 +102,17 @@ public: */ QString format_string(); - void compute_text_size(QPainter &p); - pair get_cursor_offsets() const; +public Q_SLOTS: + void on_hover_point_changed(const QWidget* widget, const QPoint &hp); + private: shared_ptr first_, second_; QSizeF text_size_; + QRectF label_area_; + bool label_incomplete_; }; } // namespace trace