mirror of
https://github.com/qgis/QGIS.git
synced 2025-06-19 00:02:48 -04:00
fix API doc and init values
This commit is contained in:
parent
838dbef3c0
commit
13119193ba
@ -34,6 +34,9 @@ from the map layer registry.
|
|||||||
struct InsertionPoint
|
struct InsertionPoint
|
||||||
{
|
{
|
||||||
InsertionPoint( QgsLayerTreeGroup *parent, int position );
|
InsertionPoint( QgsLayerTreeGroup *parent, int position );
|
||||||
|
%Docstring
|
||||||
|
Construcs an insertion point as layer tree group with its corresponding position.
|
||||||
|
%End
|
||||||
QgsLayerTreeGroup *parent;
|
QgsLayerTreeGroup *parent;
|
||||||
int position;
|
int position;
|
||||||
};
|
};
|
||||||
@ -54,7 +57,7 @@ Create the instance that synchronizes given project with a layer tree root
|
|||||||
Set where the new layers should be inserted - can be used to follow current selection.
|
Set where the new layers should be inserted - can be used to follow current selection.
|
||||||
By default it is root group with zero index.
|
By default it is root group with zero index.
|
||||||
|
|
||||||
.. deprecated:: since QGIS 3.10
|
.. deprecated:: since QGIS 3.10 use setLayerInsertionPoint( const InsertionPoint &insertionPoint ) instead
|
||||||
%End
|
%End
|
||||||
|
|
||||||
void setLayerInsertionPoint( const InsertionPoint &insertionPoint );
|
void setLayerInsertionPoint( const InsertionPoint &insertionPoint );
|
||||||
|
@ -634,8 +634,8 @@ Take screenshots for user documentation
|
|||||||
|
|
||||||
virtual QgsLayerTreeRegistryBridge::InsertionPoint layerTreeInsertionPoint() = 0;
|
virtual QgsLayerTreeRegistryBridge::InsertionPoint layerTreeInsertionPoint() = 0;
|
||||||
%Docstring
|
%Docstring
|
||||||
Returns the insertion group with its insertion index
|
Returns the insertion point.
|
||||||
In Python, returns a tuple (insertionGroup, insertionIndex)
|
This represents the current layer tree group and index where newly added map layers should be inserted into.
|
||||||
|
|
||||||
.. versionadded:: 3.10
|
.. versionadded:: 3.10
|
||||||
%End
|
%End
|
||||||
|
@ -47,16 +47,18 @@ class CORE_EXPORT QgsLayerTreeRegistryBridge : public QObject
|
|||||||
public:
|
public:
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A structure to define the insertion point to the layer tree
|
* A structure to define the insertion point to the layer tree.
|
||||||
|
* This represents the current layer tree group and index where newly added map layers should be inserted into.
|
||||||
* \since QGIS 3.10
|
* \since QGIS 3.10
|
||||||
*/
|
*/
|
||||||
struct InsertionPoint
|
struct InsertionPoint
|
||||||
{
|
{
|
||||||
|
//! Construcs an insertion point as layer tree group with its corresponding position.
|
||||||
InsertionPoint( QgsLayerTreeGroup *parent, int position )
|
InsertionPoint( QgsLayerTreeGroup *parent, int position )
|
||||||
: parent( parent ), position( position ) {}
|
: parent( parent ), position( position ) {}
|
||||||
|
|
||||||
QgsLayerTreeGroup *parent;
|
QgsLayerTreeGroup *parent = nullptr;
|
||||||
int position;
|
int position = 0;
|
||||||
};
|
};
|
||||||
|
|
||||||
//! Create the instance that synchronizes given project with a layer tree root
|
//! Create the instance that synchronizes given project with a layer tree root
|
||||||
@ -71,7 +73,7 @@ class CORE_EXPORT QgsLayerTreeRegistryBridge : public QObject
|
|||||||
/**
|
/**
|
||||||
* Set where the new layers should be inserted - can be used to follow current selection.
|
* Set where the new layers should be inserted - can be used to follow current selection.
|
||||||
* By default it is root group with zero index.
|
* By default it is root group with zero index.
|
||||||
* \deprecated since QGIS 3.10
|
* \deprecated since QGIS 3.10 use setLayerInsertionPoint( const InsertionPoint &insertionPoint ) instead
|
||||||
*/
|
*/
|
||||||
Q_DECL_DEPRECATED void setLayerInsertionPoint( QgsLayerTreeGroup *parentGroup, int index ) SIP_DEPRECATED;
|
Q_DECL_DEPRECATED void setLayerInsertionPoint( QgsLayerTreeGroup *parentGroup, int index ) SIP_DEPRECATED;
|
||||||
|
|
||||||
|
@ -564,8 +564,8 @@ class GUI_EXPORT QgisInterface : public QObject
|
|||||||
virtual void takeAppScreenShots( const QString &saveDirectory, const int categories = 0 ) {Q_UNUSED( saveDirectory ) Q_UNUSED( categories );}
|
virtual void takeAppScreenShots( const QString &saveDirectory, const int categories = 0 ) {Q_UNUSED( saveDirectory ) Q_UNUSED( categories );}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the insertion group with its insertion index
|
* Returns the insertion point.
|
||||||
* In Python, returns a tuple (insertionGroup, insertionIndex)
|
* This represents the current layer tree group and index where newly added map layers should be inserted into.
|
||||||
* \since QGIS 3.10
|
* \since QGIS 3.10
|
||||||
*/
|
*/
|
||||||
virtual QgsLayerTreeRegistryBridge::InsertionPoint layerTreeInsertionPoint() = 0;
|
virtual QgsLayerTreeRegistryBridge::InsertionPoint layerTreeInsertionPoint() = 0;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user