All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
EditorItem.hh
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2012-2014 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 
18 #ifndef _EDITOR_ITEM_HH_
19 #define _EDITOR_ITEM_HH_
20 
21 #include <string>
22 #include "gazebo/gui/qt.h"
23 #include "gazebo/util/system.hh"
24 
25 namespace gazebo
26 {
27  namespace gui
28  {
31 
34  class GAZEBO_VISIBLE EditorItem : public QObject
35  {
36  Q_OBJECT
37 
39  public: EditorItem();
40 
42  public: ~EditorItem();
43 
46  public: virtual QVector3D GetSize() const;
47 
50  public: virtual QVector3D GetScenePosition() const;
51 
54  public: virtual double GetSceneRotation() const;
55 
58  public: virtual std::string GetType() const;
59 
62  public: virtual std::string GetName() const;
63 
66  public: virtual void SetName(const std::string &_name);
67 
72  Q_SIGNALS: void SizeChanged(double _width, double _depth,
73  double _height);
74 
82  Q_SIGNALS: void PoseChanged(double _x, double _y, double _z,
83  double _roll, double _pitch, double _yaw);
84 
92  Q_SIGNALS: void PoseOriginTransformed(double _x, double _y, double _z,
93  double _roll, double _pitch, double _yaw);
94 
99  Q_SIGNALS: void PositionChanged(double _x, double _y, double _z);
100 
105  Q_SIGNALS: void RotationChanged(double _roll, double _pitch, double _yaw);
106 
109  Q_SIGNALS: void WidthChanged(double _width);
110 
113  Q_SIGNALS: void DepthChanged(double _depth);
114 
117  Q_SIGNALS: void HeightChanged(double _height);
118 
122  Q_SIGNALS: void PosXChanged(double _posX);
123 
127  Q_SIGNALS: void PosYChanged(double _posY);
128 
132  Q_SIGNALS: void PosZChanged(double _posZ);
133 
137  Q_SIGNALS: void YawChanged(double _yaw);
138 
140  Q_SIGNALS: void ItemDeleted();
141 
143  protected: std::string editorType;
144 
146  protected: std::string name;
147  };
149  }
150 }
151 
152 #endif
Base class of an item in the editor.
Definition: EditorItem.hh:34
std::string editorType
Type of editor item.
Definition: EditorItem.hh:143
std::string name
Name of editor item.
Definition: EditorItem.hh:146
#define GAZEBO_VISIBLE
Use to represent "symbol visible" if supported.
Definition: system.hh:48