Skip to content
Permalink
Browse files

dxf export: complete doxymentation updates (followup 07113b0)

  • Loading branch information
jef-n committed Jun 27, 2016
1 parent 07113b0 commit 7eeb69c3a9c6f8d70e5f07af4cdc1b0c985915ed
Showing with 28 additions and 4 deletions.
  1. +28 −4 src/core/dxf/qgsdxfpallabeling.h
@@ -39,31 +39,55 @@ class QgsDxfLabelProvider : public QgsVectorLayerLabelProvider
//! construct the provider
explicit QgsDxfLabelProvider( QgsVectorLayer* layer, QgsDxfExport* dxf, const QgsPalLayerSettings *settings );

//! re-implementation that writes to DXF file instead of drawing with QPainter
/** Re-implementation that writes to DXF file instead of drawing with QPainter
* @param context render context
* @param label label
*/
void drawLabel( QgsRenderContext& context, pal::LabelPosition* label ) const override;

//! registration method that keeps track of DXF layer names of individual features
/** Registration method that keeps track of DXF layer names of individual features
* @param feature feature
* @param context render context
* @param dxfLayerName name of dxf layer
*/
void registerDxfFeature( QgsFeature& feature, QgsRenderContext &context, const QString& dxfLayerName );

protected:
//! pointer to parent DXF export where this instance is used
QgsDxfExport* mDxfExport;
};

/** Implements a derived label provider for rule based labels internally used
* for DXF export
*
* Internal class, not in public API. Backported from QGIS 2.15
* @note not available in Python bindings
*/
class QgsDxfRuleBasedLabelProvider : public QgsRuleBasedLabelProvider
{
public:
//! construct the provider
explicit QgsDxfRuleBasedLabelProvider( const QgsRuleBasedLabeling &rules, QgsVectorLayer* layer, QgsDxfExport* dxf );

/** Reinitialize the subproviders with QgsDxfLabelProviders
* @param layer layer
*/
void reinit( QgsVectorLayer* layer );

//! re-implementation that writes to DXF file instead of drawing with QPainter
/** Re-implementation that writes to DXF file instead of drawing with QPainter
* @param context render context
* @param label label
*/
void drawLabel( QgsRenderContext &context, pal::LabelPosition *label ) const override;

//! registration method that keeps track of DXF layer names of individual features
/** Registration method that keeps track of DXF layer names of individual features
* @param feature feature
* @param context render context
* @param dxfLayerName name of dxf layer
*/
void registerDxfFeature( QgsFeature& feature, QgsRenderContext &context, const QString& dxfLayerName );

//! create QgsDxfLabelProvider
virtual QgsVectorLayerLabelProvider *createProvider( QgsVectorLayer *layer, bool withFeatureLoop, const QgsPalLayerSettings *settings ) override;

protected:

0 comments on commit 7eeb69c

Please sign in to comment.
You can’t perform that action at this time.