ddt  0.1
Public Member Functions | Protected Attributes | List of all members
DdtGraphicalElementStatRectangle Class Reference

#include <ddtGraphicalElementStatRectangle.hpp>

Inheritance diagram for DdtGraphicalElementStatRectangle:
DdtGraphicalElement

Public Member Functions

 DdtGraphicalElementStatRectangle (const DdtGraphicalElementProperties element_properties, const double x1, const double y1, const double x2, const double y2)
 
virtual ~DdtGraphicalElementStatRectangle ()
 
virtual void DrawElement (QPainter *painter)
 
QRectF boundingRect () const
 
void RedrawCorners (QGraphicsScene *scene)
 
int type () const
 
void ReDrawRectangle (const QPointF p1, const QPointF p2)
 
QPointF Start () const
 
QPointF End () const
 
QPointF UpperRight () const
 
QPointF LowerLeft () const
 
void ResetEventFilter ()
 
- Public Member Functions inherited from DdtGraphicalElement
 DdtGraphicalElement (DdtGraphicalElementProperties element_properties)
 
virtual ~DdtGraphicalElement ()
 
void paint (QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget)
 
virtual bool IsHidden ()
 
virtual float ScaleThreshold ()
 
virtual void SetShowFlag (bool show)
 
virtual DdtOverlayType GetType ()
 
virtual QString GetTypeString ()
 
virtual QString GetTag ()
 

Protected Attributes

double x1
 
double y1
 
double x2
 
double y2
 
CornerGrabbercorners [4]
 
bool installed_event_filters
 
- Protected Attributes inherited from DdtGraphicalElement
DdtGraphicalElementProperties element_properties
 
DdtOverlayType element_type
 

Detailed Description

Class for the graphical elements drawing resizeable rectangles

Constructor & Destructor Documentation

◆ DdtGraphicalElementStatRectangle()

DdtGraphicalElementStatRectangle::DdtGraphicalElementStatRectangle ( const DdtGraphicalElementProperties  element_properties,
const double  x1,
const double  y1,
const double  x2,
const double  y2 
)
explicit

Constructor

◆ ~DdtGraphicalElementStatRectangle()

DdtGraphicalElementStatRectangle::~DdtGraphicalElementStatRectangle ( )
virtual

Destructor

Member Function Documentation

◆ boundingRect()

QRectF DdtGraphicalElementStatRectangle::boundingRect ( ) const
virtual

Function returning the bounding box of the graphics item

Returns
Rectangle with the bounding box

Reimplemented from DdtGraphicalElement.

◆ DrawElement()

void DdtGraphicalElementStatRectangle::DrawElement ( QPainter *  painter)
virtual

Virtual function for rendering the graphical element

Implements DdtGraphicalElement.

◆ End()

QPointF DdtGraphicalElementStatRectangle::End ( ) const

Returns the end point of the rectangle

Returns
end point

◆ LowerLeft()

QPointF DdtGraphicalElementStatRectangle::LowerLeft ( ) const

Returns the lower left coordinates of the rectangle

Returns
lower left point

◆ RedrawCorners()

void DdtGraphicalElementStatRectangle::RedrawCorners ( QGraphicsScene *  scene)

Method which can be called to redraw the corner grabbers of this rectangle

Parameters
sceneScene to add the corners to

◆ ReDrawRectangle()

void DdtGraphicalElementStatRectangle::ReDrawRectangle ( const QPointF  p1,
const QPointF  p2 
)

Redraw the rectangle at new coordinates

Parameters
startStart point
endEnd point

◆ ResetEventFilter()

void DdtGraphicalElementStatRectangle::ResetEventFilter ( )

Reset the event filter flag; used after item had been removed from the scene, so that the event filter is re-installed in the corner grabbers

◆ Start()

QPointF DdtGraphicalElementStatRectangle::Start ( ) const

Returns the starting point of the rectangle

Returns
starting point

◆ type()

int DdtGraphicalElementStatRectangle::type ( ) const

Check type of graphics item

Returns
type

◆ UpperRight()

QPointF DdtGraphicalElementStatRectangle::UpperRight ( ) const

Member Data Documentation

◆ corners

CornerGrabber* DdtGraphicalElementStatRectangle::corners[4]
protected

Corner grabbers for resizable rectangle

◆ installed_event_filters

bool DdtGraphicalElementStatRectangle::installed_event_filters
protected

Flag for event filters

◆ x1

double DdtGraphicalElementStatRectangle::x1
protected

x position of one corner of the rectangle

◆ x2

double DdtGraphicalElementStatRectangle::x2
protected

x position of the other corner of the rectangle

◆ y1

double DdtGraphicalElementStatRectangle::y1
protected

y position of one corner of the rectangle

◆ y2

double DdtGraphicalElementStatRectangle::y2
protected

x position of the other corner of the rectangle


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