File tree Expand file tree Collapse file tree 1 file changed +2
-0
lines changed Expand file tree Collapse file tree 1 file changed +2
-0
lines changed Original file line number Diff line number Diff line change @@ -41,6 +41,7 @@ QgsAtlasComposition::QgsAtlasComposition( QgsComposition* composition ) :
41
41
QgsExpression::setSpecialColumn ( " $feature" , QVariant (( int )0 ) );
42
42
QgsExpression::setSpecialColumn ( " $numpages" , QVariant (( int )1 ) );
43
43
QgsExpression::setSpecialColumn ( " $numfeatures" , QVariant (( int )0 ) );
44
+ QgsExpression::setSpecialColumn ( " $currentfeature" , QVariant (( int )0 ) );
44
45
}
45
46
46
47
QgsAtlasComposition::~QgsAtlasComposition ()
@@ -225,6 +226,7 @@ void QgsAtlasComposition::prepareForFeature( int featureI )
225
226
226
227
// retrieve the next feature, based on its id
227
228
mCoverageLayer ->getFeatures ( QgsFeatureRequest ().setFilterFid ( mFeatureIds [ featureI ] ) ).nextFeature ( mCurrentFeature );
229
+ QgsExpression::setSpecialColumn ( " $currentfeature" , mCurrentFeature .id () );
228
230
229
231
if ( !mSingleFile && mFilenamePattern .size () > 0 )
230
232
{
You can’t perform that action at this time.
0 commit comments