QWT Dial, show unit
问题 I try do speedometer in QT 5.8. I use widget QWT Dial. But I have problem as show a label for unit (km/h). I used google, but I don't find it. How Can I do it? thank you 回答1: The solution I propose is to create a class that inherits from QwtDial and overwrite the paintEvent method. mydial.h #ifndef MYDIAL_H #define MYDIAL_H #include <qwt_dial.h> class myDial : public QwtDial { Q_OBJECT public: myDial(QWidget *parent = NULL ); protected: void paintEvent(QPaintEvent *event); }; #endif // MYDIAL