Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Some doxymentation and const'ing
  • Loading branch information
m-kuhn committed Aug 2, 2015
1 parent d107603 commit 6a2df33
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/core/qgsvectorlayer.cpp
Expand Up @@ -2775,7 +2775,7 @@ void QgsVectorLayer::setLabelOnTop( int idx, bool onTop )
mLabelOnTop[ fields[idx].name()] = onTop;
}

QgsFeatureRendererV2* QgsVectorLayer::rendererV2()
QgsFeatureRendererV2* QgsVectorLayer::rendererV2() const
{
return mRendererV2;
}
Expand Down
9 changes: 7 additions & 2 deletions src/core/qgsvectorlayer.h
Expand Up @@ -957,7 +957,7 @@ class CORE_EXPORT QgsVectorLayer : public QgsMapLayer
const QgsDiagramLayerSettings *diagramLayerSettings() const { return mDiagramLayerSettings; }

/** Return renderer V2. */
QgsFeatureRendererV2* rendererV2();
QgsFeatureRendererV2* rendererV2() const;

This comment has been minimized.

Copy link
@nyalldawson

nyalldawson Aug 2, 2015

Collaborator

@m-kuhn is this correct? - if the pointer is non-const, then the method isn't really const... Would a better approach be adding a separate "const QgsFeatureRendererV2* rendererV2() const" method?

/** Set renderer V2. */
void setRendererV2( QgsFeatureRendererV2* r );

Expand Down Expand Up @@ -1322,7 +1322,12 @@ class CORE_EXPORT QgsVectorLayer : public QgsMapLayer
*/
bool setReadOnly( bool readonly = true );

/** Make layer editable */
/**
* Make layer editable.
* This starts an edit session on this layer. Changes made in this edit session will not
* be made persistent until {@link commitChanges()} is called and can be reverted by calling
* {@link rollBack()}.
*/
bool startEditing();

/** Change feature's geometry */
Expand Down

0 comments on commit 6a2df33

Please sign in to comment.