VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
animatedLabel.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2023 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 
6 #pragma once
7 
9 #include <QLabel>
10 
11 class QTimer;
12 
13 namespace makVrv
14 {
15  class DtDe;
16 }
17 
18 namespace makVrf
19 {
21  {
22  Q_OBJECT
23 
24  public:
25  explicit DtAnimatedLabel(makVrv::DtDe&, QWidget *parent = NULL);
26 
27  virtual ~DtAnimatedLabel();
28 
29  virtual void start(double secondsToAnimateIcon);
30  virtual void stop();
31 
32  virtual void paintEvent(QPaintEvent*) override;
33 
34  void setToolTip(const QString&);
35  virtual void setAddTimeToToolTip(bool b);
36  bool addTimeToToolTip() const
37  {
38  return myAddTimeToToolTip;
39  }
40 
41  virtual bool event(QEvent*) override;
42 
43  protected slots:
44  virtual void animate();
45 
46  protected:
47  QPixmap myScaledPixmap;
48  QTimer* myAnimationTimer = nullptr;
49  int myStep = 0;
50  bool myAddTimeToToolTip = false;
51  QString myToolTip;
52  double myDuration = 0.;
53  double myLastTimeCheck = 0.;
55  };
56 }
Definition: animatedLabel.h:20
makVrv::DtDe & myDe
Definition: animatedLabel.h:54
bool addTimeToToolTip() const
Definition: animatedLabel.h:36
#define DT_DLL_VRFGUICOMMONQT
Definition: vrfGuiCommonQt.h:20
QPixmap myScaledPixmap
Definition: animatedLabel.h:47
The DtDe is the core component of any VR-Vantage application. It owns a DtRenderer, DtDeCommunicator, as well as a DtDisplay and other things.
Definition: DtDe.h:72
QString myToolTip
Definition: animatedLabel.h:51

Document ID: Generated on Tue Sep 24 19:28:17 EDT 2024 from SVN revision 269799
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)