Skip to content

Commit

Permalink
Fix some formatting in pyQGIS doc
Browse files Browse the repository at this point in the history
  • Loading branch information
DelazJ authored and nyalldawson committed Jan 29, 2021
1 parent 9ac3821 commit 8a8d2a2
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 16 deletions.
3 changes: 2 additions & 1 deletion python/core/auto_generated/geometry/qgsgeometry.sip.in
Expand Up @@ -672,7 +672,7 @@ Returns coordinates of a vertex.

:param atVertex: index of the vertex

:return: Coordinates of the vertex or empty :py:class:`QgsPoint`() on error
:return: Coordinates of the vertex or empty QgsPoint on error
%End

double sqrDistToVertexAt( QgsPointXY &point /In/, int atVertex ) const;
Expand Down Expand Up @@ -870,6 +870,7 @@ Splits this geometry according to a given line.
:return: OperationResult a result code: success or reason of failure

Example:

.. code-block:: python

geometry = QgsGeometry.fromWkt('CompoundCurveZ ((2749546.2003820720128715 1262904.45356595050543547 100, 2749557.82053794478997588 1262920.05570670193992555 200))')
Expand Down
6 changes: 3 additions & 3 deletions python/core/auto_generated/geometry/qgstriangle.sip.in
Expand Up @@ -29,7 +29,7 @@ Constructor for an empty triangle geometry.

QgsTriangle( const QgsPoint &p1, const QgsPoint &p2, const QgsPoint &p3 ) /HoldGIL/;
%Docstring
Construct a QgsTriangle from three :py:class:`QgsPointV2`.
Construct a QgsTriangle from three :py:class:`QgsPoint`.

:param p1: first point
:param p2: second point
Expand All @@ -38,7 +38,7 @@ Construct a QgsTriangle from three :py:class:`QgsPointV2`.

explicit QgsTriangle( const QgsPointXY &p1, const QgsPointXY &p2, const QgsPointXY &p3 ) /HoldGIL/;
%Docstring
Construct a QgsTriangle from three :py:class:`QgsPoint`.
Construct a QgsTriangle from three :py:class:`QgsPointXY`.

:param p1: first point
:param p2: second point
Expand Down Expand Up @@ -111,7 +111,7 @@ Returns coordinates of a vertex.

:param atVertex: index of the vertex

:return: Coordinates of the vertex or empty :py:class:`QgsPoint`() on error (``atVertex`` < 0 or > 3).
:return: Coordinates of the vertex or empty QgsPoint on error (``atVertex`` < 0 or > 3).
%End

QVector<double> lengths() const /HoldGIL/;
Expand Down
Expand Up @@ -16,11 +16,11 @@ class QgsVectorTileBasicRendererStyle
%Docstring
Definition of map rendering of a subset of vector tile data. The subset of data is defined by:

# sub-layer name
# geometry type (a single sub-layer may have multiple geometry types)
# filter expression
- sub-layer name
- geometry type (a single sub-layer may have multiple geometry types)
- filter expression

Renering is determined by the associated symbol (QgsSymbol). Symbol has to be of the same
Rendering is determined by the associated symbol (QgsSymbol). Symbol has to be of the same
type as the chosen :py:func:`~geometryType` - i.e. QgsMarkerSymbol for points, QgsLineSymbol for linestrings
and QgsFillSymbol for polygons.

Expand Down
3 changes: 2 additions & 1 deletion src/core/geometry/qgsgeometry.h
Expand Up @@ -733,7 +733,7 @@ class CORE_EXPORT QgsGeometry
/**
* Returns coordinates of a vertex.
* \param atVertex index of the vertex
* \returns Coordinates of the vertex or empty QgsPoint() on error
* \returns Coordinates of the vertex or empty QgsPoint on error
*/
QgsPoint vertexAt( int atVertex ) const;

Expand Down Expand Up @@ -902,6 +902,7 @@ class CORE_EXPORT QgsGeometry
* \returns OperationResult a result code: success or reason of failure
*
* Example:
*
* \code{.py}
* geometry = QgsGeometry.fromWkt('CompoundCurveZ ((2749546.2003820720128715 1262904.45356595050543547 100, 2749557.82053794478997588 1262920.05570670193992555 200))')
* split_line = [QgsPoint(2749544.19, 1262914.79), QgsPoint(2749557.64, 1262897.30)]
Expand Down
6 changes: 3 additions & 3 deletions src/core/geometry/qgstriangle.h
Expand Up @@ -40,15 +40,15 @@ class CORE_EXPORT QgsTriangle : public QgsPolygon
QgsTriangle() SIP_HOLDGIL;

/**
* Construct a QgsTriangle from three QgsPointV2.
* Construct a QgsTriangle from three QgsPoint.
* \param p1 first point
* \param p2 second point
* \param p3 third point
*/
QgsTriangle( const QgsPoint &p1, const QgsPoint &p2, const QgsPoint &p3 ) SIP_HOLDGIL;

/**
* Construct a QgsTriangle from three QgsPoint.
* Construct a QgsTriangle from three QgsPointXY.
* \param p1 first point
* \param p2 second point
* \param p3 third point
Expand Down Expand Up @@ -105,7 +105,7 @@ class CORE_EXPORT QgsTriangle : public QgsPolygon
/**
* Returns coordinates of a vertex.
* \param atVertex index of the vertex
* \returns Coordinates of the vertex or empty QgsPoint() on error (\a atVertex < 0 or > 3).
* \returns Coordinates of the vertex or empty QgsPoint on error (\a atVertex < 0 or > 3).
*/
QgsPoint vertexAt( int atVertex ) const SIP_HOLDGIL;

Expand Down
8 changes: 4 additions & 4 deletions src/core/vectortile/qgsvectortilebasicrenderer.h
Expand Up @@ -31,11 +31,11 @@ class QgsSymbol;
* \ingroup core
* Definition of map rendering of a subset of vector tile data. The subset of data is defined by:
*
* # sub-layer name
* # geometry type (a single sub-layer may have multiple geometry types)
* # filter expression
* - sub-layer name
* - geometry type (a single sub-layer may have multiple geometry types)
* - filter expression
*
* Renering is determined by the associated symbol (QgsSymbol). Symbol has to be of the same
* Rendering is determined by the associated symbol (QgsSymbol). Symbol has to be of the same
* type as the chosen geometryType() - i.e. QgsMarkerSymbol for points, QgsLineSymbol for linestrings
* and QgsFillSymbol for polygons.
*
Expand Down

0 comments on commit 8a8d2a2

Please sign in to comment.