UNIVERS
15.3
UNIVERS base processing software API
|
#include <zq_zoom.hpp>
Public Types | |
enum | ZoomMode { ZoomRubberRect, ZoomInClick, ZoomOutClick, ZoomRubberRect, ZoomInClick, ZoomOutClick } |
enum | ZoomMode { ZoomRubberRect, ZoomInClick, ZoomOutClick, ZoomRubberRect, ZoomInClick, ZoomOutClick } |
Public Types inherited from ZqRubberBox | |
enum | RangeMode { Vertical = 0x01, Horizontal = 0x02, Rectangle = 0x03, Vertical = 0x01, Horizontal = 0x02, Rectangle = 0x03 } |
enum | RangeMode { Vertical = 0x01, Horizontal = 0x02, Rectangle = 0x03, Vertical = 0x01, Horizontal = 0x02, Rectangle = 0x03 } |
Public Member Functions | |
ZqZoom (ZqbNatGroup &rNatAxis, ZqRubberBox::RangeMode eRangeMode, const char *szName=NULL) | |
ZqZoom (ZqbNatGroup &rNatAxisX, ZqbNatGroup &rNatAxisY, const char *szName=NULL) | |
ZqZoom (ZqbNatGroup &rNatAxis, ZqRubberBox::RangeMode eRangeMode, ZqbPlaceholder *pPh, const char *szName=NULL) | |
ZqZoom (ZqbNatGroup &rNatAxisX, ZqbNatGroup &rNatAxisY, ZqbPlaceholder *pPh, const char *szName=NULL) | |
virtual void | zoomAll () |
virtual void | zoomClick (float sf, double nxy[2]=NULL) |
virtual void | setZoomMode (ZoomMode eMode) |
virtual ZoomMode | getZoomMode () const |
virtual void | setScaleFactor (float fScale) |
virtual float | getScaleFactor () const |
virtual ZqbEventHint | input (QEvent &event) |
virtual void | box (QRect r) |
virtual void | click (QRect r) |
ZqZoom (ZqbNatGroup &rNatAxis, ZqRubberBox::RangeMode eRangeMode, const char *szName=NULL) | |
ZqZoom (ZqbNatGroup &rNatAxisX, ZqbNatGroup &rNatAxisY, const char *szName=NULL) | |
ZqZoom (ZqbNatGroup &rNatAxis, ZqRubberBox::RangeMode eRangeMode, ZqbPlaceholder *pPh, const char *szName=NULL) | |
ZqZoom (ZqbNatGroup &rNatAxisX, ZqbNatGroup &rNatAxisY, ZqbPlaceholder *pPh, const char *szName=NULL) | |
virtual void | zoomAll () |
virtual void | zoomClick (float sf, double nxy[2]=NULL) |
virtual void | setZoomMode (ZoomMode eMode) |
virtual ZoomMode | getZoomMode () const |
virtual void | setScaleFactor (float fScale) |
virtual float | getScaleFactor () const |
virtual ZqbEventHint | input (QEvent &event) |
virtual void | box (QRect r) |
virtual void | click (QRect r) |
Public Member Functions inherited from ZqRubberBox | |
ZqRubberBox (const char *szName=NULL) | |
ZqRubberBox (ZqbPlaceholder *pPh, const char *szName=NULL) | |
virtual void | setThickness (int iThickness) |
virtual int | getThickness () const |
virtual void | setRangeMode (int mMode) |
virtual int | getRangeMode () const |
virtual void | setSensExtWidth (int iWidth) |
virtual int | getSensExtWidth () const |
virtual void | setInputable (bool bFlag) |
ZqRubberBox (const char *szName=NULL) | |
ZqRubberBox (ZqbPlaceholder *pPh, const char *szName=NULL) | |
virtual | ~ZqRubberBox () |
virtual bool | attachToPlace (ZqbPlaceholder *pPh) |
virtual bool | detachFromPlace () |
virtual void | setThickness (int iThickness) |
virtual int | getThickness () const |
virtual void | setRangeMode (int mMode) |
virtual int | getRangeMode () const |
virtual void | setSensExtWidth (int iWidth) |
virtual int | getSensExtWidth () const |
virtual void | setInputable (bool bFlag) |
Public Member Functions inherited from ZqObject | |
ZqObject (const char *szName=NULL) | |
ZqObject (ZqbPlaceholder *pPh, const char *szName=NULL) | |
virtual | ~ZqObject () |
virtual void | debugState () |
virtual void | clearPlace () |
virtual ZqbPlaceholderVector * | placeholders () |
virtual void | redraw (QPainter &paint) |
virtual void | updateLimits (QPainter *paint=NULL) |
virtual void | updateGeometry () |
virtual QPainter * | getScreenPainter () const |
virtual void | setScreenPainter (QPainter *pPainter) |
virtual QzqArea * | getArea () const |
virtual QWidget * | getAreaWidget () const |
virtual void | setAreaWidget (QWidget *pWidget) |
virtual bool | isHardcopy () const |
bool | isPlaced () const |
ZqbPlaceholder * | getPlace () const |
ZqbPixGrpMember * | px () const |
ZqbPixGrpMember * | py () const |
bool | getRect (QRect &rect) const |
virtual void | setDirty () |
virtual void | resetDirty () |
virtual bool | isDirty () const |
void | setInteractive (bool bInteractive) |
bool | isInteractive () const |
virtual void | fullRedraw (bool bForce=false) |
virtual void | interactiveRedraw () |
ZqObject (const char *szName=NULL) | |
ZqObject (ZqbPlaceholder *pPh, const char *szName=NULL) | |
virtual | ~ZqObject () |
virtual void | debugState () |
virtual void | clearPlace () |
virtual ZqbPlaceholderVector * | placeholders () |
virtual void | redraw (QPainter &paint) |
virtual void | updateLimits (QPainter *paint=NULL) |
virtual void | updateGeometry () |
virtual QPainter * | getScreenPainter () const |
virtual void | setScreenPainter (QPainter *pPainter) |
virtual QzqArea * | getArea () const |
virtual QWidget * | getAreaWidget () const |
virtual void | setAreaWidget (QWidget *pWidget) |
virtual bool | isHardcopy () const |
bool | isPlaced () const |
ZqbPlaceholder * | getPlace () const |
ZqbPixGrpMember * | px () const |
ZqbPixGrpMember * | py () const |
bool | getRect (QRect &rect) const |
virtual void | setDirty () |
virtual void | resetDirty () |
virtual bool | isDirty () const |
void | setInteractive (bool bInteractive) |
bool | isInteractive () const |
virtual void | fullRedraw (bool bForce=false) |
virtual void | interactiveRedraw () |
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 void | setTipable (bool bFlag) |
virtual bool | isTipable () const |
virtual bool | tip (const QPoint &p, QString &qsShort, QString &qsLong) |
virtual bool | isInputable () const |
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 void | setTipable (bool bFlag) |
virtual bool | isTipable () const |
virtual bool | tip (const QPoint &p, QString &qsShort, QString &qsLong) |
virtual bool | isInputable () const |
virtual bool | getRect (QRect &) |
virtual bool | setRect (const QRect &) |
Protected Member Functions | |
void | zoomClick (double nc, ZqbNatGroup &group, float fScaleFactor) |
int | pos2nat (const QPoint &p, double nc[2]) const |
void | forceRedraw (ZqbNatGrpMember *pNGm) |
void | zoomClick (double nc, ZqbNatGroup &group, float fScaleFactor) |
int | pos2nat (const QPoint &p, double nc[2]) const |
void | forceRedraw (ZqbNatGrpMember *pNGm) |
Protected Member Functions inherited from ZqRubberBox | |
void | drawRubberRect (const QRect &r) |
void | drawRubberRect (const QRect &r) |
void | updateRubberRect (const QRect &r) |
void | hideRubberRect () |
Protected Attributes | |
ZoomMode | m_eZoomMode |
float | m_fScale |
ZqbNatGrpMember * | m_pNatX |
ZqbNatGrpMember * | m_pNatY |
bool | m_bDragToMove |
Protected Attributes inherited from ZqRubberBox | |
bool | m_bDrawn |
QRect | m_qRect |
QPoint | m_qCurrent |
QPoint | m_qStart |
int | m_iThickness |
int | m_mMode |
int | m_iExtWidth |
QRubberBand * | m_qRB |
Protected Attributes inherited from ZqObject | |
ZqbPlaceholder * | m_pPh |
ZqbPixGrpMember * | m_pPx |
ZqbPixGrpMember * | m_pPy |
bool | m_bInteractive |
Protected Attributes inherited from ZqbName | |
char * | m_szName |
char * | m_szRoot |
Class implements all standard zoom functions: zoom in by click, zoom out by click, zoom by rubber rectangle and zoom all by middle button double click.
enum ZqZoom::ZoomMode |
Mode of zooming.
enum ZqZoom::ZoomMode |
Mode of zooming.
ZqZoom::ZqZoom | ( | ZqbNatGroup & | rNatAxis, |
ZqRubberBox::RangeMode | eRangeMode, | ||
const char * | szName = NULL |
||
) |
Create 1D zoom object without exact place. Range mode should be Vertical or Horizontal otherwise object will not function. Default mode is rubber rectangle zoom in.
ZqZoom::ZqZoom | ( | ZqbNatGroup & | rNatAxisX, |
ZqbNatGroup & | rNatAxisY, | ||
const char * | szName = NULL |
||
) |
Create 2D zoom object without exact place. Default mode is rubber rectangle zoom in.
ZqZoom::ZqZoom | ( | ZqbNatGroup & | rNatAxis, |
ZqRubberBox::RangeMode | eRangeMode, | ||
ZqbPlaceholder * | pPh, | ||
const char * | szName = NULL |
||
) |
Create 1D zoom object in given placeholder. Range mode should be Vertical or Horizontal otherwise object will not function. Default mode is rubber rectangle zoom in.
ZqZoom::ZqZoom | ( | ZqbNatGroup & | rNatAxisX, |
ZqbNatGroup & | rNatAxisY, | ||
ZqbPlaceholder * | pPh, | ||
const char * | szName = NULL |
||
) |
Create 2D zoom object in given placeholder. Default mode is rubber rectangle zoom in.
ZqZoom::ZqZoom | ( | ZqbNatGroup & | rNatAxis, |
ZqRubberBox::RangeMode | eRangeMode, | ||
const char * | szName = NULL |
||
) |
Create 1D zoom object without exact place. Range mode should be Vertical or Horizontal otherwise object will not function. Default mode is rubber rectangle zoom in.
ZqZoom::ZqZoom | ( | ZqbNatGroup & | rNatAxisX, |
ZqbNatGroup & | rNatAxisY, | ||
const char * | szName = NULL |
||
) |
Create 2D zoom object without exact place. Default mode is rubber rectangle zoom in.
ZqZoom::ZqZoom | ( | ZqbNatGroup & | rNatAxis, |
ZqRubberBox::RangeMode | eRangeMode, | ||
ZqbPlaceholder * | pPh, | ||
const char * | szName = NULL |
||
) |
Create 1D zoom object in given placeholder. Range mode should be Vertical or Horizontal otherwise object will not function. Default mode is rubber rectangle zoom in.
ZqZoom::ZqZoom | ( | ZqbNatGroup & | rNatAxisX, |
ZqbNatGroup & | rNatAxisY, | ||
ZqbPlaceholder * | pPh, | ||
const char * | szName = NULL |
||
) |
Create 2D zoom object in given placeholder. Default mode is rubber rectangle zoom in.
|
virtual |
Rubber rectangle zoom action processing.
Reimplemented from ZqRubberBox.
|
virtual |
Rubber rectangle zoom action processing.
Reimplemented from ZqRubberBox.
|
virtual |
Click instead of rectangle selection action processing.
Reimplemented from ZqRubberBox.
|
virtual |
Click instead of rectangle selection action processing.
Reimplemented from ZqRubberBox.
|
protected |
Prepare redrawing by setting dirty flags of all members of given natural group (obtained as pNGm->group() if !NULL).
|
protected |
Prepare redrawing by setting dirty flags of all members of given natural group (obtained as pNGm->group() if !NULL).
|
virtual |
Get current scaling factor.
|
virtual |
Get current scaling factor.
|
virtual |
Get mode of zooming.
|
virtual |
Get mode of zooming.
|
virtual |
Switch mouse events processing depending the mode of the zoom.
Reimplemented from ZqRubberBox.
|
virtual |
Switch mouse events processing depending the mode of the zoom.
Reimplemented from ZqRubberBox.
|
protected |
Convert given QPoint to pair of natural coordinates (both X and Y if possible; if not undefined value will take place). Return mask of two bits where the low one (1 << 0) designates presence of X and the high one (1 << 1) - presence of Y in returned result.
|
protected |
Convert given QPoint to pair of natural coordinates (both X and Y if possible; if not undefined value will take place). Return mask of two bits where the low one (1 << 0) designates presence of X and the high one (1 << 1) - presence of Y in returned result.
|
virtual |
Set scaling factor for zoom in/zoom out. To get expected behaviour the value should be >1.
|
virtual |
Set scaling factor for zoom in/zoom out. To get expected behaviour the value should be >1.
|
virtual |
Set mode of zooming. Changing mode of zooming while processig input events may cause strange and unpredictable results. It's wise to setup zoom mode just after object creation and don't change it forever.
|
virtual |
Set mode of zooming. Changing mode of zooming while processig input events may cause strange and unpredictable results. It's wise to setup zoom mode just after object creation and don't change it forever.
|
virtual |
Action of zooming the whole contents in preset bounds of natual group(s).
|
virtual |
Action of zooming the whole contents in preset bounds of natual group(s).
|
virtual |
Action of zooming in (or out, depending given scale factor) objects with natural group(s) by preset scale factor. Given natural coordinates are used as center of zooming. If NULL is passed instead of coordinates then current center of natural group coordinates is used.
|
virtual |
Action of zooming in (or out, depending given scale factor) objects with natural group(s) by preset scale factor. Given natural coordinates are used as center of zooming. If NULL is passed instead of coordinates then current center of natural group coordinates is used.
|
protected |
Zoom by given factor around given natural position in given natural group.
|
protected |
Zoom by given factor around given natural position in given natural group.
|
protected |
Drag-to-move activity flag.
|
protected |
Mode of zooming.
|
protected |
Scaling factor.
|
protected |
Horizontal natural group member or NULL if this dimension is not scaled.
|
protected |
Vertical natural group member or NULL if this dimension is not scaled.