]> sigrok.org Git - pulseview.git/blobdiff - pv/views/trace/trace.hpp
Allow for a context menu in the view area
[pulseview.git] / pv / views / trace / trace.hpp
index 758b2e97c46e0142238b842e8b3d42c013fda747..bc97736c03de58f1ccc4d9d2e09571c110c6d909 100644 (file)
@@ -94,6 +94,7 @@ private:
 
 protected:
        Trace(shared_ptr<data::SignalBase> channel);
+       ~Trace();
 
 public:
        /**
@@ -127,6 +128,14 @@ public:
         */
        QRectF label_rect(const QRectF &rect) const;
 
+       /**
+        * Computes the outline rectangle of the viewport hit-box.
+        * @param rect the rectangle of the viewport area.
+        * @return Returns the rectangle of the hit-box.
+        * @remarks The default implementation returns an empty hit-box.
+        */
+       virtual QRectF hit_box_rect(const ViewItemPaintParams &pp) const;
+
        void set_current_segment(const int segment);
 
        int get_current_segment() const;