rock_widget_collection  0.1
Public Member Functions | List of all members
EllipseItem Class Reference

#include <EllipseItem.h>

Inherits RectangleItem.

Public Member Functions

 EllipseItem (int posX, int posY, int groupNr, const QColor &color, int width, int height)
 
virtual ~EllipseItem ()
 
DrawType getType ()
 
void draw (QPainter *painter, QRectF &source, QRectF &target)
 
- Public Member Functions inherited from RectangleItem
 RectangleItem (int posX, int posY, int groupNr, const QColor &color, int width, int height)
 
virtual ~RectangleItem ()
 
int getWidth ()
 
int getHeight ()
 
DrawType getType ()
 
void setWidth (int width)
 
void setHeight (int height)
 
void draw (QPainter *painter, QRectF &source, QRectF &target)
 
- Public Member Functions inherited from FillItem
 FillItem (int posX, int posY, int groupNr, const QColor &color)
 
bool isDrawBorder ()
 
QColor * getInteriorColor ()
 
void setDrawBorder (bool drawBorder)
 
void setInteriorColor (QColor *interiorColor)
 
- Public Member Functions inherited from DrawItem
 DrawItem (int posX, int posY, int groupNr, const QColor &color)
 
virtual ~DrawItem ()
 
bool operator== (const DrawItem &other)
 
virtual void renderOnGl (QGLWidget &widget, QRectF &source, QRectF &target)
 
int getPosY ()
 
int getGroupNr ()
 
QColor getColor ()
 
void setPosX (int posX)
 
void setPosY (int posY)
 
void setGroupNr (int groupNr)
 
void setColor (const QColor &color)
 
int getLineWidth ()
 
Qt::PenStyle getPenStyle ()
 
Qt::PenCapStyle getPenCapStyle ()
 
void setLineWidth (int lineWidth)
 
void setPenStyle (Qt::PenStyle penStyle)
 
void setPenCapStyle (Qt::PenCapStyle penCapStyle)
 
int getID () const
 
void openGL (bool value)
 
bool onOpenGL ()
 
void setPosFactor (float fx, float fy)
 

Additional Inherited Members

- Public Slots inherited from DrawItem
int getPosX ()
 
- Protected Member Functions inherited from FillItem
void addBrushStyle (QPainter *painter)
 
- Protected Member Functions inherited from DrawItem
void addPenStyle (QPainter *painter)
 
- Protected Attributes inherited from RectangleItem
int width
 
int height
 
- Protected Attributes inherited from FillItem
bool drawBorder
 
QColor * interiorColor
 
- Protected Attributes inherited from DrawItem
int groupNr
 
int posX
 
int posY
 
QColor color
 
int lineWidth
 
Qt::PenCapStyle penCapStyle
 
Qt::PenStyle penStyle
 
int m_id
 
float position_factor_x
 
float position_factor_y
 
bool brender_on_opengl
 
- Static Protected Attributes inherited from DrawItem
static int _ID = 0
 

Detailed Description

Ellipse Item which subclasses a Rectangle item and currently does not add any functionality. Ellipses will be drawn within an oulying rectangle.

Definition at line 18 of file EllipseItem.h.

Constructor & Destructor Documentation

◆ EllipseItem()

EllipseItem::EllipseItem ( int  posX,
int  posY,
int  groupNr,
const QColor &  color,
int  width,
int  height 
)

Creates an Ellipseitem

Parameters
posXthe x position of the outlying rectangle
posYthe y position of the outlying rectangle
groupNrteh group number
colorthe color of the border
widththe width of the outlying rectangle
heightthe height of the oulying rectangle

Definition at line 12 of file EllipseItem.cc.

14 {
15 }
int posY
Definition: DrawItem.h:182
int posX
Definition: DrawItem.h:180
RectangleItem(int posX, int posY, int groupNr, const QColor &color, int width, int height)
int groupNr
Definition: DrawItem.h:169
QColor color
Definition: DrawItem.h:184

◆ ~EllipseItem()

virtual EllipseItem::~EllipseItem ( )
inlinevirtual

Destructor

Definition at line 35 of file EllipseItem.h.

35 {};

Member Function Documentation

◆ draw()

void EllipseItem::draw ( QPainter *  painter,
QRectF &  source,
QRectF &  target 
)
virtual
See also
DrawItem::draw

Implements DrawItem.

Definition at line 17 of file EllipseItem.cc.

18 {
19  FillItem::draw(painter,source,target);
20  painter->drawEllipse(posX, posY, width, height);
21 }
int posY
Definition: DrawItem.h:182
int posX
Definition: DrawItem.h:180
void draw(QPainter *painter, QRectF &source, QRectF &target)
Definition: FillItem.cc:26

◆ getType()

DrawType EllipseItem::getType ( )
inlinevirtual

Returns DrawType::Ellipse

Returns
DrawType::Ellipse

Implements DrawItem.

Definition at line 41 of file EllipseItem.h.

41 {return Ellipse;};

The documentation for this class was generated from the following files: