#include <extdef.h>
#include <assert.h>
-#include <math.h>
+#include <cmath>
#include <QApplication>
#include <QFormLayout>
using pv::widgets::Popup;
popup_ = new Popup(parent);
+ popup_->set_position(parent->mapToGlobal(
+ point(parent->rect())), Popup::Right);
create_popup_form();
label_size.height());
}
+QRectF Trace::hit_box_rect(const QRectF &rect) const
+{
+ const float h = QFontMetrics(QApplication::font()).height();
+ return QRectF(rect.left(), get_visual_y() - h / 2.0f,
+ rect.width(), h);
+}
+
void Trace::paint_axis(QPainter &p, const ViewItemPaintParams &pp, int y)
{
p.setPen(AxisPen);