// SPDX-License-Identifier: GPL-2.0 #ifndef RULERITEM_H #define RULERITEM_H #include "qt-quick/chartitem.h" #include #include class ProfileView; class ProfileScene; class RulerItemHandle; struct plot_info; struct dive; class RulerItem { ChartItemPtr line; ChartItemPtr handle1, handle2; ChartItemPtr tooltip; QFont font; QFontMetrics fm; double fontHeight; QPixmap title; public: RulerItem(ProfileView &view, double dpr); ~RulerItem(); void setVisible(bool visible); void update(const dive *d, double dpr, const ProfileScene &scene, const plot_info &info, int animspeed); void anim(double progress); }; #endif