2D rectangle. More...
#include <RectItem.hh>


Public Types | |
| enum | ResizeFlags { NONE = 0x00, ITEM_WIDTH = 0x01, ITEM_HEIGHT = 0x02 } |
| Resize flags used to indicate which dimension can be resized. More... | |
Public Member Functions | |
| RectItem () | |
| Constructor. More... | |
| virtual | ~RectItem () |
| Destructor. More... | |
| double | GetHeight () const |
| Get the height of the rect item. More... | |
| virtual double | GetRotation () const |
| Get the rotation of the rect item. More... | |
| virtual QVector3D | GetScenePosition () const |
| Get the scene position of editor item. More... | |
| virtual double | GetSceneRotation () const |
| Get the scene rotation of the editor item. More... | |
| virtual QVector3D | GetSize () const |
| Get the size of the item in pixels. More... | |
| double | GetWidth () const |
| Get the width of the rect item. More... | |
| void | SetHeight (int _height) |
| Set the height of the rect item. More... | |
| virtual void | SetPosition (const QPointF &_pos) |
| Set the position of the rect item. More... | |
| virtual void | SetPosition (double _x, double _y) |
| Set the position of the rect item. More... | |
| virtual void | SetResizeFlag (unsigned int _flag) |
| Set the resize flag of the rect item. More... | |
| virtual void | SetRotation (double _angle) |
| Set the rotation of the rect item. More... | |
| void | SetSize (QSize _size) |
| Set the size of the rect item. More... | |
| void | SetWidth (int _width) |
| Set the width of the rect item. More... | |
| void | ShowHandles (bool _show) |
| Show the grabber and rotate handles of the rect item. More... | |
Public Member Functions inherited from gazebo::gui::EditorItem | |
| EditorItem () | |
| Constructor. More... | |
| ~EditorItem () | |
| Destructor. More... | |
| virtual std::string | GetName () const |
| Get the name of the editor item. More... | |
| virtual std::string | GetType () const |
| Get the type of the editor item. More... | |
| virtual void | SetName (const std::string &_name) |
| Set the name of this editor item. More... | |
Protected Member Functions | |
| virtual QRectF | boundingRect () const |
| Get the bounding box of the rect item. More... | |
| void | DrawBoundingBox (QPainter *_painter) |
| Draw bounding box. More... | |
| void | UpdateCornerPositions () |
| Helper method for Updating the corner positions of the rect item. More... | |
Protected Attributes | |
| QColor | borderColor |
| Border color of the rect item. More... | |
| QAction * | deleteItemAct |
| Qt action for deleting the item. More... | |
| double | drawingHeight |
| Actual height of rect item drawn in pixels. More... | |
| double | drawingOriginX |
| X origin of the rect item in pixels. More... | |
| double | drawingOriginY |
| Y origin of the rect item in pixels. More... | |
| double | drawingWidth |
| Actual width of rect item drawn in pixels. More... | |
| double | height |
| Height of rect item in pixels. More... | |
| QAction * | openInspectorAct |
| Qt action for opening the inspector. More... | |
| double | rotationAngle |
| Rotation angle of the rect item in degrees. More... | |
| double | width |
| Width of rect item in pixels. More... | |
| int | zValueIdle |
| Z ordering of the rect item when idle (unselected.) More... | |
Protected Attributes inherited from gazebo::gui::EditorItem | |
| std::string | editorType |
| Type of editor item. More... | |
| std::string | name |
| Name of editor item. More... | |
Additional Inherited Members | |
Signals inherited from gazebo::gui::EditorItem | |
| void | DepthChanged (double _depth) |
| Qt signal emitted when the editor item depth has changed. More... | |
| void | HeightChanged (double _height) |
| Qt signal emitted when the editor item height has changed. More... | |
| void | ItemDeleted () |
| Qt signal emitted when the editor item is being deleted. More... | |
| void | PoseChanged (double _x, double _y, double _z, double _roll, double _pitch, double _yaw) |
| Qt signal emitted when the editor item pose has changed. More... | |
| void | PoseOriginTransformed (double _x, double _y, double _z, double _roll, double _pitch, double _yaw) |
| Qt signal emitted when the editor item pose origin has changed. More... | |
| void | PositionChanged (double _x, double _y, double _z) |
| Qt signal emitted when the editor item position has changed. More... | |
| void | PosXChanged (double _posX) |
| Qt signal emitted when the editor item's X position has changed. More... | |
| void | PosYChanged (double _posY) |
| Qt signal emitted when the editor item's Y position has changed. More... | |
| void | PosZChanged (double _posZ) |
| Qt signal emitted when the editor item's Z position has changed. More... | |
| void | RotationChanged (double _roll, double _pitch, double _yaw) |
| Qt signal emitted when the editor item rotation has changed. More... | |
| void | SizeChanged (double _width, double _depth, double _height) |
| Qt signal emitted when the editor item size has changed. More... | |
| void | WidthChanged (double _width) |
| Qt signal emitted when the editor item width has changed. More... | |
| void | YawChanged (double _yaw) |
| Qt signal emitted when the editor item yaw rotation has changed. More... | |
2D rectangle.
| gazebo::gui::RectItem::RectItem | ( | ) |
Constructor.
|
virtual |
Destructor.
|
protectedvirtual |
Get the bounding box of the rect item.
|
protected |
Draw bounding box.
| [in] | _painter | Qt painter object. |
| double gazebo::gui::RectItem::GetHeight | ( | ) | const |
Get the height of the rect item.
|
virtual |
Get the rotation of the rect item.
|
virtual |
Get the scene position of editor item.
Reimplemented from gazebo::gui::EditorItem.
Reimplemented in gazebo::gui::DoorItem, gazebo::gui::FloorItem, gazebo::gui::StairsItem, and gazebo::gui::WindowItem.
|
virtual |
Get the scene rotation of the editor item.
Reimplemented from gazebo::gui::EditorItem.
Reimplemented in gazebo::gui::DoorItem, gazebo::gui::FloorItem, gazebo::gui::StairsItem, and gazebo::gui::WindowItem.
|
virtual |
Get the size of the item in pixels.
Reimplemented from gazebo::gui::EditorItem.
Reimplemented in gazebo::gui::DoorItem, gazebo::gui::FloorItem, gazebo::gui::StairsItem, and gazebo::gui::WindowItem.
| double gazebo::gui::RectItem::GetWidth | ( | ) | const |
Get the width of the rect item.
| void gazebo::gui::RectItem::SetHeight | ( | int | _height | ) |
Set the height of the rect item.
| [in] | _height | Height of the rect item in pixels. |
|
virtual |
Set the position of the rect item.
| [in] | _pos | Position in pixel coordinates. |
|
virtual |
Set the position of the rect item.
| [in] | _x | X position in pixel coordinates. |
| [in] | _y | Y position in pixel coordinates. |
|
virtual |
Set the resize flag of the rect item.
| [in] | _flag | Resize flag which controls how the item can be resized. |
|
virtual |
Set the rotation of the rect item.
| [in] | _angle | Rotation angle in degrees. |
| void gazebo::gui::RectItem::SetSize | ( | QSize | _size | ) |
Set the size of the rect item.
| [in] | _size | Size of the rect item in pixels. |
| void gazebo::gui::RectItem::SetWidth | ( | int | _width | ) |
Set the width of the rect item.
| [in] | _width | Width of the rect item in pixels. |
| void gazebo::gui::RectItem::ShowHandles | ( | bool | _show | ) |
Show the grabber and rotate handles of the rect item.
| [in] | _show | True to draw the handles, and false to hide them. |
|
protected |
Helper method for Updating the corner positions of the rect item.
|
protected |
Border color of the rect item.
|
protected |
Qt action for deleting the item.
|
protected |
Actual height of rect item drawn in pixels.
|
protected |
X origin of the rect item in pixels.
|
protected |
Y origin of the rect item in pixels.
|
protected |
Actual width of rect item drawn in pixels.
|
protected |
Height of rect item in pixels.
|
protected |
Qt action for opening the inspector.
|
protected |
Rotation angle of the rect item in degrees.
|
protected |
Width of rect item in pixels.
|
protected |
Z ordering of the rect item when idle (unselected.)