Base class for widgets that display topic data. More...
#include <TopicView.hh>
Public Member Functions | |
TopicView (QWidget *_parent, const std::string &_msgType, const std::string &_viewType, unsigned int _displayPeriod=500) | |
Constructor. More... | |
virtual | ~TopicView () |
Destructor. More... | |
virtual void | SetTopic (const std::string &_topicName) |
Set the name of the topic to get data from. More... | |
Protected Member Functions | |
virtual void | closeEvent (QCloseEvent *_event) |
Qt close event callback. More... | |
void | OnMsg (const common::Time &_dataTime, int _size) |
Used by child class to indicate when a message has been received. More... | |
Protected Attributes | |
QFrame * | frame |
This is the frame that each child class should populate. More... | |
std::string | msgTypeName |
Typename of the messages that can be displayed. More... | |
transport::NodePtr | node |
Pointer to the node for communication. More... | |
transport::SubscriberPtr | sub |
Pointer to the topic subscriber that receives display data. More... | |
Base class for widgets that display topic data.
gazebo::gui::TopicView::TopicView | ( | QWidget * | _parent, |
const std::string & | _msgType, | ||
const std::string & | _viewType, | ||
unsigned int | _displayPeriod = 500 |
||
) |
Constructor.
[in] | _parent | Parent QWidget. |
[in] | _msgType | Type of message that the viewer can display. |
[in] | _parent | Pointer to the parent widget. |
[in] | _viewType | The type of the viewer. |
[in] | _displayPeriod | Milliseconds between display updates. |
|
virtual |
Destructor.
|
protectedvirtual |
Qt close event callback.
[in] | _event | The close event info. |
|
protected |
Used by child class to indicate when a message has been received.
[in] | _dataTime | Time the data was created. This time should be the timestamp when data was generated on the server. |
[in] | _size | Size of the message in bytes. |
|
virtual |
Set the name of the topic to get data from.
[in] | _topicName | Name of the topic to use. |
Reimplemented in gazebo::gui::ImagesView, gazebo::gui::ImageView, gazebo::gui::LaserView, and gazebo::gui::TextView.
|
protected |
This is the frame that each child class should populate.
|
protected |
Typename of the messages that can be displayed.
|
protected |
Pointer to the node for communication.
|
protected |
Pointer to the topic subscriber that receives display data.