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

#include <qgspalgeometry.h>

Inheritance diagram for QgsPalGeometry:
Inheritance graph
[legend]

Public Member Functions

 QgsPalGeometry (QgsFeatureId id, QString text, GEOSGeometry *g, qreal ltrSpacing=0.0, qreal wordSpacing=0.0, bool curvedLabeling=false)
 ~QgsPalGeometry ()
const GEOSGeometry * getGeosGeometry ()
 get the GEOSGeometry of the feature This method is called by Pal each time it needs a geom's coordinates
void releaseGeosGeometry (const GEOSGeometry *)
 Called by Pal when it doesn't need the coordinates anymore.
const char * strId ()
QString text ()
pal::LabelInfoinfo (QFontMetricsF *fm, const QgsMapToPixel *xform, double fontScale, double maxinangle, double maxoutangle)
const QMap
< QgsPalLayerSettings::DataDefinedProperties,
QVariant > & 
dataDefinedValues () const
void addDataDefinedValue (QgsPalLayerSettings::DataDefinedProperties p, QVariant v)
void setIsDiagram (bool d)
bool isDiagram () const
void setIsPinned (bool f)
bool isPinned () const
void setDefinedFont (QFont f)
QFont definedFont ()
QFontMetricsF * getLabelFontMetrics ()
void setDiagramAttributes (const QgsAttributes &attrs)
const QgsAttributesdiagramAttributes ()
void feature (QgsFeature &feature)
void setDxfLayer (QString dxfLayer)
QString dxfLayer () const
- Public Member Functions inherited from pal::PalGeometry
virtual ~PalGeometry ()

Protected Attributes

GEOSGeometry * mG
QString mText
QByteArray mStrId
QgsFeatureId mId
LabelInfomInfo
bool mIsDiagram
bool mIsPinned
QFont mDefinedFont
QFontMetricsF * mFontMetrics
qreal mLetterSpacing
qreal mWordSpacing
bool mCurvedLabeling
QMap
< QgsPalLayerSettings::DataDefinedProperties,
QVariant > 
mDataDefinedValues
 Stores attribute values for data defined properties.
QgsAttributes mDiagramAttributes
 Stores attribute values for diagram rendering.
QString mDxfLayer

Constructor & Destructor Documentation

QgsPalGeometry::QgsPalGeometry ( QgsFeatureId  id,
QString  text,
GEOSGeometry *  g,
qreal  ltrSpacing = 0.0,
qreal  wordSpacing = 0.0,
bool  curvedLabeling = false 
)
inline
QgsPalGeometry::~QgsPalGeometry ( )
inline

Member Function Documentation

void QgsPalGeometry::addDataDefinedValue ( QgsPalLayerSettings::DataDefinedProperties  p,
QVariant  v 
)
inline
const QMap< QgsPalLayerSettings::DataDefinedProperties, QVariant >& QgsPalGeometry::dataDefinedValues ( ) const
inline
QFont QgsPalGeometry::definedFont ( )
inline
const QgsAttributes& QgsPalGeometry::diagramAttributes ( )
inline
QString QgsPalGeometry::dxfLayer ( ) const
inline
void QgsPalGeometry::feature ( QgsFeature feature)
inline
const GEOSGeometry* QgsPalGeometry::getGeosGeometry ( )
inlinevirtual

get the GEOSGeometry of the feature This method is called by Pal each time it needs a geom's coordinates

Returns
GEOSGeometry * a pointer the geos geom

Implements pal::PalGeometry.

QFontMetricsF* QgsPalGeometry::getLabelFontMetrics ( )
inline
pal::LabelInfo* QgsPalGeometry::info ( QFontMetricsF *  fm,
const QgsMapToPixel xform,
double  fontScale,
double  maxinangle,
double  maxoutangle 
)
inline
bool QgsPalGeometry::isDiagram ( ) const
inline
bool QgsPalGeometry::isPinned ( ) const
inline
void QgsPalGeometry::releaseGeosGeometry ( const GEOSGeometry *  the_geom)
inlinevirtual

Called by Pal when it doesn't need the coordinates anymore.

Parameters
the_geomis the geoms geom from PalGeometry::getfeomGeometry()

Implements pal::PalGeometry.

void QgsPalGeometry::setDefinedFont ( QFont  f)
inline
void QgsPalGeometry::setDiagramAttributes ( const QgsAttributes attrs)
inline
void QgsPalGeometry::setDxfLayer ( QString  dxfLayer)
inline
void QgsPalGeometry::setIsDiagram ( bool  d)
inline
void QgsPalGeometry::setIsPinned ( bool  f)
inline
const char* QgsPalGeometry::strId ( )
inline
QString QgsPalGeometry::text ( void  )
inline

Member Data Documentation

bool QgsPalGeometry::mCurvedLabeling
protected
QMap< QgsPalLayerSettings::DataDefinedProperties, QVariant > QgsPalGeometry::mDataDefinedValues
protected

Stores attribute values for data defined properties.

QFont QgsPalGeometry::mDefinedFont
protected
QgsAttributes QgsPalGeometry::mDiagramAttributes
protected

Stores attribute values for diagram rendering.

QString QgsPalGeometry::mDxfLayer
protected
QFontMetricsF* QgsPalGeometry::mFontMetrics
protected
GEOSGeometry* QgsPalGeometry::mG
protected
QgsFeatureId QgsPalGeometry::mId
protected
LabelInfo* QgsPalGeometry::mInfo
protected
bool QgsPalGeometry::mIsDiagram
protected
bool QgsPalGeometry::mIsPinned
protected
qreal QgsPalGeometry::mLetterSpacing
protected
QByteArray QgsPalGeometry::mStrId
protected
QString QgsPalGeometry::mText
protected
qreal QgsPalGeometry::mWordSpacing
protected

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