UNIVERS
15.3
UNIVERS base processing software API
|
#include <zqb_placeholder.hpp>
Public Member Functions | |
ZqbPlaceholder (ZqbContainer &container, ZqbPixGroup *pPGX, ZqbPixGroup *pPGY, const char *szPhName=NULL) | |
virtual | ~ZqbPlaceholder () |
virtual void | redraw (QPainter &paint) |
virtual ZqbEventHint | input (QEvent &event) |
virtual void | updateLimits (QPainter *paint=NULL) |
virtual void | updateGeometry () |
virtual QPainter * | getScreenPainter () const |
virtual void | setScreenPainter (QPainter *pPainter) |
virtual QWidget * | getAreaWidget () const |
virtual void | setAreaWidget (QWidget *pWidget) |
virtual QRect | getRect () const |
virtual bool | addObject (ZqObject *obj) |
virtual bool | removeObject (ZqObject *obj) |
virtual bool | toFront (ZqObject *obj) |
virtual bool | toBack (ZqObject *obj) |
virtual int | setDrawOrder (const ZqbObjectArray &objects) |
bool | isPlaced () const |
bool | clipLine (int x[2], int y[2]) |
void | setDirty () |
void | resetDirty () |
bool | isDirty () const |
void | setAutoClear (bool bAutoClear) |
void | setAutoClear (bool bAutoClear, QColor qcFillColor) |
bool | getAutoClear (QColor *qcFillColor=NULL) const |
ZqbPlaceholder (ZqbContainer &container, ZqbPixGroup *pPGX, ZqbPixGroup *pPGY, const char *szPhName=NULL) | |
virtual | ~ZqbPlaceholder () |
virtual void | redraw (QPainter &paint) |
virtual ZqbEventHint | input (QEvent &event) |
virtual void | updateLimits (QPainter *paint=NULL) |
virtual void | updateGeometry () |
virtual QPainter * | getScreenPainter () const |
virtual void | setScreenPainter (QPainter *pPainter) |
virtual QWidget * | getAreaWidget () const |
virtual void | setAreaWidget (QWidget *pWidget) |
virtual QRect | getRect () const |
virtual bool | addObject (ZqObject *obj) |
virtual bool | removeObject (ZqObject *obj) |
virtual bool | toFront (ZqObject *obj) |
virtual bool | toBack (ZqObject *obj) |
virtual int | setDrawOrder (const ZqbObjectArray &objects) |
bool | isPlaced () const |
bool | clipLine (int x[2], int y[2]) |
void | setDirty () |
void | resetDirty () |
bool | isDirty () const |
void | setAutoClear (bool bAutoClear) |
void | setAutoClear (bool bAutoClear, QColor qcFillColor) |
bool | getAutoClear (QColor *qcFillColor=NULL) const |
Public Member Functions inherited from ZqbAutoName | |
ZqbAutoName (int *pCounter, const char *szRoot, const char *szCustomName=NULL) | |
virtual | ~ZqbAutoName () |
ZqbAutoName (int *pCounter, const char *szRoot, const char *szCustomName=NULL) | |
virtual | ~ZqbAutoName () |
Public Member Functions inherited from ZqbName | |
ZqbName (const char *szRoot, const char *szCustomName=NULL) | |
ZqbName (const ZqbName &name) | |
virtual | ~ZqbName () |
ZqbName & | operator= (const ZqbName &name) |
virtual const char * | getName () const |
virtual const char * | getType () const |
bool | hasName (const char *szString) const |
ZqbName (const char *szRoot, const char *szCustomName=NULL) | |
ZqbName (const ZqbName &name) | |
virtual | ~ZqbName () |
ZqbName & | operator= (const ZqbName &name) |
virtual const char * | getName () const |
virtual const char * | getType () const |
bool | hasName (const char *szString) const |
Public Member Functions inherited from ZqbVisible | |
ZqbVisible (bool bDrawable=false, bool bInputable=false, bool bTipable=false) | |
virtual | ~ZqbVisible () |
virtual bool | isDrawable () const |
virtual void | setDrawable (bool bFlag) |
virtual void | redraw () |
virtual bool | isHardcopy () const |
virtual void | setTipable (bool bFlag) |
virtual bool | isTipable () const |
virtual bool | tip (const QPoint &p, QString &qsShort, QString &qsLong) |
virtual bool | isInputable () const |
virtual void | setInputable (bool bFlag) |
virtual bool | getRect (QRect &) |
virtual bool | setRect (const QRect &) |
ZqbVisible (bool bDrawable=false, bool bInputable=false, bool bTipable=false) | |
virtual | ~ZqbVisible () |
virtual bool | isDrawable () const |
virtual void | setDrawable (bool bFlag) |
virtual void | redraw () |
virtual bool | isHardcopy () const |
virtual void | setTipable (bool bFlag) |
virtual bool | isTipable () const |
virtual bool | tip (const QPoint &p, QString &qsShort, QString &qsLong) |
virtual bool | isInputable () const |
virtual void | setInputable (bool bFlag) |
virtual bool | getRect (QRect &) |
virtual bool | setRect (const QRect &) |
Public Member Functions inherited from ZqbContainer | |
virtual | ~ZqbContainer () |
virtual int | numberOfObjects () const |
virtual bool | isEmpty () const |
virtual int | setDrawOrder (ZqObject *obj1,...) |
ZqbObjectArray::iterator | begin () |
ZqbObjectArray::iterator | end () |
ZqbObjectArray::reverse_iterator | rbegin () |
ZqbObjectArray::reverse_iterator | rend () |
void | addInteractiveObjects (bool bFlag, ZqbContainer &cont) |
void | redrawObjects (QPainter *paint) |
size_t | size () const |
virtual | ~ZqbContainer () |
virtual int | numberOfObjects () const |
virtual bool | isEmpty () const |
virtual int | setDrawOrder (ZqObject *obj1,...) |
ZqbObjectArray::iterator | begin () |
ZqbObjectArray::iterator | end () |
ZqbObjectArray::reverse_iterator | rbegin () |
ZqbObjectArray::reverse_iterator | rend () |
void | addInteractiveObjects (bool bFlag, ZqbContainer &cont) |
void | redrawObjects (QPainter *paint) |
size_t | size () const |
Public Attributes | |
ZqbPixGrpMember | px |
ZqbPixGrpMember | py |
Protected Attributes | |
ZqbContainer & | m_Container |
QPainter * | m_pqPainter |
QWidget * | m_pqWidget |
ZqObject * | m_pGrabber |
bool | m_bDirty |
bool | m_bAutoClear |
QColor | m_qcFillColor |
Protected Attributes inherited from ZqbName | |
char * | m_szName |
char * | m_szRoot |
Protected Attributes inherited from ZqbContainer | |
ZqbObjectArray | m_Objects |
Class for rectangular screen area abstraction as a location for numerous objects placed one over another.
Placeholders are managed inside some layout. Each placeholder has two pixel group memebers which refer to pixel groups in layout.
ZqbPlaceholder::ZqbPlaceholder | ( | ZqbContainer & | container, |
ZqbPixGroup * | pPGX, | ||
ZqbPixGroup * | pPGY, | ||
const char * | szPhName = NULL |
||
) |
Create placeholder with given name. If NULL pointer is passed as name an automatically generated name will be used. Reference to the external objects container and pointers to two pixel groups should be provided.
|
virtual |
Destroy this object.
ZqbPlaceholder::ZqbPlaceholder | ( | ZqbContainer & | container, |
ZqbPixGroup * | pPGX, | ||
ZqbPixGroup * | pPGY, | ||
const char * | szPhName = NULL |
||
) |
Create placeholder with given name. If NULL pointer is passed as name an automatically generated name will be used. Reference to the external objects container and pointers to two pixel groups should be provided.
|
virtual |
Destroy this object.
|
virtual |
Insert new object on the top of previous objects and return true. If object already added to this container or to another one lets do nothing and return false.
Reimplemented from ZqbContainer.
|
virtual |
Insert new object on the top of previous objects and return true. If object already added to this container or to another one lets do nothing and return false.
Reimplemented from ZqbContainer.
bool ZqbPlaceholder::clipLine | ( | int | x[2], |
int | y[2] | ||
) |
Clip given line segment by bounding rectangle of the placeholder. Clipped coordinates of the line segment are returned instead of input coordinates. Returns true if final line segment is inside place rectangle at least partially and false if line segment is outside the place rectangle. If geometry of the place is unknown then return false.
bool ZqbPlaceholder::clipLine | ( | int | x[2], |
int | y[2] | ||
) |
Clip given line segment by bounding rectangle of the placeholder. Clipped coordinates of the line segment are returned instead of input coordinates. Returns true if final line segment is inside place rectangle at least partially and false if line segment is outside the place rectangle. If geometry of the place is unknown then return false.
|
virtual |
Return pointer to Qt widget used for drawing area or NULL if it's not accessible.
Implements ZqbVisible.
|
virtual |
Return pointer to Qt widget used for drawing area or NULL if it's not accessible.
Implements ZqbVisible.
bool ZqbPlaceholder::getAutoClear | ( | QColor * | qcFillColor = NULL | ) | const |
Get value of clear flag and optinally get fill color.
bool ZqbPlaceholder::getAutoClear | ( | QColor * | qcFillColor = NULL | ) | const |
Get value of clear flag and optinally get fill color.
|
virtual |
Return bounding box of the placeholder.
|
virtual |
Return bounding box of the placeholder.
|
virtual |
Return pointer to default graphics context (screen drawing) or NULL if it's not accessible.
Implements ZqbVisible.
|
virtual |
Return pointer to default graphics context (screen drawing) or NULL if it's not accessible.
Implements ZqbVisible.
|
virtual |
General event processing method.
Implements ZqbVisible.
|
virtual |
General event processing method.
Implements ZqbVisible.
|
virtual |
Return value of the redraw request flag.
Implements ZqbVisible.
|
virtual |
Return value of the redraw request flag.
Implements ZqbVisible.
bool ZqbPlaceholder::isPlaced | ( | ) | const |
Returns true if both pixel groups are placed and false otherwise.
bool ZqbPlaceholder::isPlaced | ( | ) | const |
Returns true if both pixel groups are placed and false otherwise.
|
virtual |
General drawing method.
Implements ZqbVisible.
|
virtual |
General drawing method.
Implements ZqbVisible.
|
virtual |
Remove object from container and return true. If object is not found in this container lets do nothing and return false.
Reimplemented from ZqbContainer.
|
virtual |
Remove object from container and return true. If object is not found in this container lets do nothing and return false.
Reimplemented from ZqbContainer.
|
virtual |
Undo request for redraw.
Implements ZqbVisible.
|
virtual |
Undo request for redraw.
Implements ZqbVisible.
|
virtual |
Set pointer to Qt widget used for drawing area. NULL pointer is acceptable.
Implements ZqbVisible.
|
virtual |
Set pointer to Qt widget used for drawing area. NULL pointer is acceptable.
Implements ZqbVisible.
void ZqbPlaceholder::setAutoClear | ( | bool | bAutoClear | ) |
Set clear flag to exact value. It does not touch filling color.
void ZqbPlaceholder::setAutoClear | ( | bool | bAutoClear | ) |
Set clear flag to exact value. It does not touch filling color.
void ZqbPlaceholder::setAutoClear | ( | bool | bAutoClear, |
QColor | qcFillColor | ||
) |
Set clear flag to exact value and provide filling color.
void ZqbPlaceholder::setAutoClear | ( | bool | bAutoClear, |
QColor | qcFillColor | ||
) |
Set clear flag to exact value and provide filling color.
|
virtual |
Request to redraw all objects in this placeholder.
Implements ZqbVisible.
|
virtual |
Request to redraw all objects in this placeholder.
Implements ZqbVisible.
|
virtual |
Place listed objects in given order of drawing. The first listed object will be drawn the first, the last one will be drawn the last atop of other objects. Returns number of objects actually found in the container.
Reimplemented from ZqbContainer.
|
virtual |
Place listed objects in given order of drawing. The first listed object will be drawn the first, the last one will be drawn the last atop of other objects. Returns number of objects actually found in the container.
Reimplemented from ZqbContainer.
|
virtual |
Set pointer to default graphics context (screen drawing). NULL pointer is acceptable.
Implements ZqbVisible.
|
virtual |
Set pointer to default graphics context (screen drawing). NULL pointer is acceptable.
Implements ZqbVisible.
|
virtual |
Move the object under other objects and return true. If object is not found in this container then do nothing and return false.
Reimplemented from ZqbContainer.
|
virtual |
Move the object under other objects and return true. If object is not found in this container then do nothing and return false.
Reimplemented from ZqbContainer.
|
virtual |
Move the object atop of other objects and return true. If object is not found in this container then do nothing and return false.
Reimplemented from ZqbContainer.
|
virtual |
Move the object atop of other objects and return true. If object is not found in this container then do nothing and return false.
Reimplemented from ZqbContainer.
|
virtual |
General method to recalculate geometry of children objects (if any) because it's called when own geometry of the object is already calculated and assigned via pixel groups membership.
Implements ZqbVisible.
|
virtual |
General method to recalculate geometry of children objects (if any) because it's called when own geometry of the object is already calculated and assigned via pixel groups membership.
Implements ZqbVisible.
|
virtual |
General method to recalculate own size limitations and all children objects. In case the painter isn't a NULL it should be used for device specific sizes such as QFontMetrics.
Implements ZqbVisible.
|
virtual |
General method to recalculate own size limitations and all children objects. In case the painter isn't a NULL it should be used for device specific sizes such as QFontMetrics.
Implements ZqbVisible.
|
protected |
Auto-clear flag value. It's off (false) by default. The flag is used for fast redrawing of one placeholder only without rest area.
|
protected |
Flag is set to true when the placeholder should be redrawn.
|
protected |
External collection of objects.
|
protected |
Pointer to object who grabs the inpout or NULL if noone grab the input.
|
protected |
External default graphics context (screen drawing).
|
protected |
External widget used as common parent for all Qt objects inside Zq area.
|
protected |
Color used to auto-clear feature.
ZqbPixGrpMember ZqbPlaceholder::px |
1D geometry along X axis of the screen.
ZqbPixGrpMember ZqbPlaceholder::py |
1D geometry along Y axis of the screen.