QGIS API Documentation  2.8.2-Wien
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes | List of all members
QgsMapHitTest Class Reference

Class that runs a hit test with given map settings. More...

#include <qgsmaphittest.h>

Public Member Functions

 QgsMapHitTest (const QgsMapSettings &settings)
void run ()
QSet< QgsSymbolV2 * > symbolsForLayer (QgsVectorLayer *layer) const

Protected Types

typedef QMap< QgsVectorLayer
*, SymbolV2Set
HitTest
typedef QSet< QgsSymbolV2 * > SymbolV2Set

Protected Member Functions

void runHitTestLayer (QgsVectorLayer *vl, SymbolV2Set &usedSymbols, QgsRenderContext &context)

Protected Attributes

HitTest mHitTest
QgsMapSettings mSettings

Detailed Description

Class that runs a hit test with given map settings.

Based on the hit test it returns which symbols will be visible on the map - this is useful for content based legend.

Note
added in 2.6

Definition at line 18 of file qgsmaphittest.h.

Member Typedef Documentation

Definition at line 30 of file qgsmaphittest.h.

typedef QSet<QgsSymbolV2*> QgsMapHitTest::SymbolV2Set
protected

Definition at line 29 of file qgsmaphittest.h.

Constructor & Destructor Documentation

QgsMapHitTest::QgsMapHitTest ( const QgsMapSettings settings)

Definition at line 10 of file qgsmaphittest.cpp.

Member Function Documentation

void QgsMapHitTest::run ( )

Definition at line 16 of file qgsmaphittest.cpp.

void QgsMapHitTest::runHitTestLayer ( QgsVectorLayer vl,
SymbolV2Set usedSymbols,
QgsRenderContext context 
)
protected

Definition at line 53 of file qgsmaphittest.cpp.

QSet<QgsSymbolV2*> QgsMapHitTest::symbolsForLayer ( QgsVectorLayer layer) const
inline

Definition at line 25 of file qgsmaphittest.h.

Member Data Documentation

HitTest QgsMapHitTest::mHitTest
protected

Definition at line 35 of file qgsmaphittest.h.

QgsMapSettings QgsMapHitTest::mSettings
protected

Definition at line 34 of file qgsmaphittest.h.


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