TimeWidget.hh
Go to the documentation of this file.
1/*
2 * Copyright (C) 2015 Open Source Robotics Foundation
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 *
16 */
17#ifndef GAZEBO_GUI_TIMEWIDGET_HH_
18#define GAZEBO_GUI_TIMEWIDGET_HH_
19
20#include "gazebo/gui/qt.h"
22#include "gazebo/util/system.hh"
23
24namespace gazebo
25{
26 namespace gui
27 {
28 class TimeWidgetPrivate;
29 class TimePanel;
30
31 class GZ_GUI_VISIBLE TimeWidget : public QWidget
32 {
33 Q_OBJECT
34
37 public: explicit TimeWidget(QWidget *_parent = 0);
38
40 public: virtual ~TimeWidget();
41
44 public: void ShowRealTimeFactor(bool _show);
45
48 public: void ShowRealTime(bool _show);
49
52 public: void ShowSimTime(bool _show);
53
56 public: void ShowIterations(bool _show);
57
60 public: void ShowStepWidget(bool _show);
61
64 public: void ShowFPS(bool _show);
65
68 public: bool IsPaused() const;
69
73 public: void SetPaused(bool _paused);
74
77 public: void EmitSetSimTime(QString _string);
78
81 public: void EmitSetRealTime(QString _string);
82
85 public: void EmitSetIterations(QString _string);
86
89 public: void EmitSetFPS(QString _string);
90
93 public: void SetPercentRealTimeEdit(QString _text);
94
97 public slots: void OnStepValueChanged(int _value);
98
100 public slots: void OnTimeReset();
101
104 signals: void SetSimTime(QString _string);
105
108 signals: void SetRealTime(QString _string);
109
112 signals: void SetIterations(QString _string);
113
116 signals: void SetFPS(QString _string);
117
120 private: TimeWidgetPrivate *dataPtr;
121 };
122 }
123}
124
125#endif
gui
Definition KeyEventHandler.hh:29
Definition TimeWidget.hh:32
void EmitSetIterations(QString _string)
Emit a signal used to set the iterations line edit.
virtual ~TimeWidget()
Destructor.
void ShowRealTime(bool _show)
Show real time.
void ShowIterations(bool _show)
Show the iterations.
void ShowSimTime(bool _show)
Show sim time.
void SetFPS(QString _string)
A signal used to set the avg fps line edit.
void SetPercentRealTimeEdit(QString _text)
A signal used to set the sim time line edit.
void SetIterations(QString _string)
A signal used to set the iterations line edit.
TimeWidget(QWidget *_parent=0)
Constructor.
void SetRealTime(QString _string)
A signal used to set the real time line edit.
void EmitSetSimTime(QString _string)
Emit a signal used to set the sim time line edit.
void ShowFPS(bool _show)
Show fps.
void EmitSetRealTime(QString _string)
Emit a signal used to set the real time line edit.
void ShowRealTimeFactor(bool _show)
Show real time factor.
bool IsPaused() const
Returns if the simulation is displayed as paused.
void OnStepValueChanged(int _value)
Qt call back when the step value in the spinbox changed.
void SetPaused(bool _paused)
Set whether to display the simulation as paused.
void OnTimeReset()
QT callback when the reset time button is pressed.
void ShowStepWidget(bool _show)
Show the step widget.
void SetSimTime(QString _string)
A signal used to set the sim time line edit.
void EmitSetFPS(QString _string)
Emit a signal used to set the FPS line edit.
Forward declarations for the common classes.
Definition Animation.hh:27