QGIS API Documentation  2.11.0-Master
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
Public Types | Public Member Functions | Protected Member Functions | List of all members
QgsPreviewEffect Class Reference

A graphics effect which can be applied to a widget to simulate various printing and color blindness modes. More...

#include <qgsprevieweffect.h>

Inheritance diagram for QgsPreviewEffect:
Inheritance graph
[legend]

Public Types

enum  PreviewMode { PreviewGrayscale, PreviewMono, PreviewProtanope, PreviewDeuteranope }
 

Public Member Functions

 QgsPreviewEffect (QObject *parent)
 
 ~QgsPreviewEffect ()
 
PreviewMode mode () const
 Returns the mode used for the preview effect. More...
 
void setMode (PreviewMode mode)
 Sets the mode for the preview effect, which controls how the effect modifies a widgets appearance. More...
 
- Public Member Functions inherited from QGraphicsEffect
 QGraphicsEffect (QObject *parent)
 
virtual  ~QGraphicsEffect ()
 
QRectF boundingRect () const
 
virtual QRectF boundingRectFor (const QRectF &rect) const
 
void enabledChanged (bool enabled)
 
bool isEnabled () const
 
void setEnabled (bool enable)
 
void update ()
 
- Public Member Functions inherited from QObject
 QObject (QObject *parent)
 
 QObject (QObject *parent, const char *name)
 
virtual  ~QObject ()
 
bool blockSignals (bool block)
 
QObjectchild (const char *objName, const char *inheritsClass, bool recursiveSearch) const
 
const QObjectList & children () const
 
const char * className () const
 
bool connect (const QObject *sender, const char *signal, const char *method, Qt::ConnectionType type) const
 
void deleteLater ()
 
void destroyed (QObject *obj)
 
bool disconnect (const QObject *receiver, const char *method)
 
bool disconnect (const char *signal, const QObject *receiver, const char *method)
 
void dumpObjectInfo ()
 
void dumpObjectTree ()
 
QList< QByteArraydynamicPropertyNames () const
 
virtual bool event (QEvent *e)
 
virtual bool eventFilter (QObject *watched, QEvent *event)
 
findChild (const QString &name) const
 
QList< T > findChildren (const QRegExp &regExp) const
 
QList< T > findChildren (const QString &name) const
 
bool inherits (const char *className) const
 
void insertChild (QObject *object)
 
void installEventFilter (QObject *filterObj)
 
bool isA (const char *className) const
 
bool isWidgetType () const
 
void killTimer (int id)
 
virtual const QMetaObjectmetaObject () const
 
void moveToThread (QThread *targetThread)
 
const char * name () const
 
const char * name (const char *defaultName) const
 
QString objectName () const
 
QObjectparent () const
 
QVariant property (const char *name) const
 
void removeChild (QObject *object)
 
void removeEventFilter (QObject *obj)
 
void setName (const char *name)
 
void setObjectName (const QString &name)
 
void setParent (QObject *parent)
 
bool setProperty (const char *name, const QVariant &value)
 
bool signalsBlocked () const
 
int startTimer (int interval)
 
QThreadthread () const
 

Protected Member Functions

virtual void draw (QPainter *painter) override
 
- Protected Member Functions inherited from QGraphicsEffect
virtual void draw (QPainter *painter)=0
 
void drawSource (QPainter *painter)
 
QRectF sourceBoundingRect (Qt::CoordinateSystem system) const
 
virtual void sourceChanged (QFlags< QGraphicsEffect::ChangeFlag > flags)
 
bool sourceIsPixmap () const
 
QPixmap sourcePixmap (Qt::CoordinateSystem system, QPoint *offset, PixmapPadMode mode) const
 
void updateBoundingRect ()
 
- Protected Member Functions inherited from QObject
bool checkConnectArgs (const char *signal, const QObject *object, const char *method)
 
virtual void childEvent (QChildEvent *event)
 
virtual void connectNotify (const char *signal)
 
virtual void customEvent (QEvent *event)
 
virtual void disconnectNotify (const char *signal)
 
int receivers (const char *signal) const
 
QObjectsender () const
 
int senderSignalIndex () const
 
virtual void timerEvent (QTimerEvent *event)
 

Additional Inherited Members

- Static Public Member Functions inherited from QObject
bool connect (const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type)
 
bool connect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method, Qt::ConnectionType type)
 
bool disconnect (const QObject *sender, const char *signal, const QObject *receiver, const char *method)
 
bool disconnect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method)
 
QString tr (const char *sourceText, const char *disambiguation, int n)
 
QString trUtf8 (const char *sourceText, const char *disambiguation, int n)
 
- Public Attributes inherited from QGraphicsEffect
typedef ChangeFlags
 
- Static Protected Member Functions inherited from QObject
QByteArray normalizeSignalSlot (const char *signalSlot)
 
- Properties inherited from QGraphicsEffect
 enabled
 
- Properties inherited from QObject
 objectName
 

Detailed Description

A graphics effect which can be applied to a widget to simulate various printing and color blindness modes.

Definition at line 28 of file qgsprevieweffect.h.

Constructor & Destructor Documentation

QgsPreviewEffect::QgsPreviewEffect ( QObject parent)

Definition at line 22 of file qgsprevieweffect.cpp.

QgsPreviewEffect::~QgsPreviewEffect ( )

Definition at line 30 of file qgsprevieweffect.cpp.

Member Function Documentation

void QgsPreviewEffect::draw ( QPainter painter)
overrideprotectedvirtual

Definition at line 41 of file qgsprevieweffect.cpp.

PreviewMode QgsPreviewEffect::mode ( ) const
inline

Returns the mode used for the preview effect.

Returns
PreviewMode currently used by the effect
Note
added in 2.3
See also
setMode

Definition at line 55 of file qgsprevieweffect.h.

void QgsPreviewEffect::setMode ( QgsPreviewEffect::PreviewMode  mode)

Sets the mode for the preview effect, which controls how the effect modifies a widgets appearance.

Parameters
modePreviewMode to use to draw the widget
Note
added in 2.3
See also
mode

Definition at line 35 of file qgsprevieweffect.cpp.


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