Skip to content
Permalink
Browse files

More list formatting fixes

  • Loading branch information
nyalldawson committed Jun 13, 2020
1 parent 561a832 commit cedd73ee4ddb242edc31a26fa838145266e86a05
Showing with 260 additions and 119 deletions.
  1. +6 −3 python/core/auto_generated/geometry/qgsabstractgeometry.sip.in
  2. +6 −3 python/core/auto_generated/geometry/qgsgeometry.sip.in
  3. +9 −3 python/core/auto_generated/geometry/qgsgeometryutils.sip.in
  4. +3 −1 python/core/auto_generated/geometry/qgspoint.sip.in
  5. +54 −18 python/core/auto_generated/geometry/qgstriangle.sip.in
  6. +2 −1 python/core/auto_generated/qgseditformconfig.sip.in
  7. +2 −1 python/core/auto_generated/qgsfeature.sip.in
  8. +3 −2 python/core/auto_generated/symbology/qgsrenderer.sip.in
  9. +10 −2 python/core/auto_generated/textrenderer/qgstextformat.sip.in
  10. +4 −3 python/gui/auto_generated/editorwidgets/core/qgseditorwidgetautoconf.sip.in
  11. +5 −4 python/gui/auto_generated/editorwidgets/core/qgseditorwidgetfactory.sip.in
  12. +6 −4 python/gui/auto_generated/qgscollapsiblegroupbox.sip.in
  13. +7 −6 python/server/auto_generated/qgsaccesscontrolfilter.sip.in
  14. +3 −0 scripts/doxygen_space.pl
  15. +8 −3 src/core/geometry/qgsabstractgeometry.h
  16. +6 −3 src/core/geometry/qgsgeometry.h
  17. +9 −3 src/core/geometry/qgsgeometryutils.h
  18. +3 −1 src/core/geometry/qgspoint.h
  19. +54 −18 src/core/geometry/qgstriangle.h
  20. +0 −1 src/core/mesh/qgsmeshdataset.h
  21. +4 −4 src/core/processing/qgsprocessingparameters.h
  22. +2 −1 src/core/qgseditformconfig.h
  23. +2 −1 src/core/qgsfeature.h
  24. +1 −1 src/core/qgsmaplayerstore.h
  25. +1 −1 src/core/qgsproject.h
  26. +1 −1 src/core/qgssqlexpressioncompiler.h
  27. +3 −2 src/core/symbology/qgsrenderer.h
  28. +10 −2 src/core/textrenderer/qgstextformat.h
  29. +4 −3 src/gui/editorwidgets/core/qgseditorwidgetautoconf.h
  30. +5 −4 src/gui/editorwidgets/core/qgseditorwidgetfactory.h
  31. +4 −1 src/gui/editorwidgets/core/qgswidgetwrapper.h
  32. +1 −1 src/gui/qgisinterface.cpp
  33. +6 −4 src/gui/qgscollapsiblegroupbox.h
  34. +1 −1 src/plugins/grass/qgsgrassmodule.cpp
  35. +1 −1 src/plugins/topology/topol.h
  36. +7 −6 src/server/qgsaccesscontrolfilter.h
  37. +6 −4 src/server/qgsmapserviceexception.h
  38. +1 −1 src/server/qgsserverinterface.cpp
@@ -528,7 +528,8 @@ Ownership is transferred to the caller.
If the gridified geometry could not be calculated ``None`` will be returned.
It may generate an invalid geometry (in some corner cases).
It can also be thought as rounding the edges and it may be useful for removing errors.
Example:

### Example:

In this case we use a 2D grid of 1x1 to gridify.
In this case, it can be thought like rounding the x and y of all the points/vertices to full units (remove all decimals).
@@ -687,7 +688,8 @@ Checks validity of the geometry, and returns ``True`` if the geometry is valid.
Returns Java-style iterator for traversal of parts of the geometry. This iterator
can safely be used to modify parts of the geometry.

* Example:
### Example:

.. code-block:: python

# print the WKT representation of each part in a multi-point geometry
@@ -726,7 +728,8 @@ Returns a read-only, Java-style iterator for traversal of vertices of all the ge
The iterator returns a copy of individual vertices, and accordingly geometries cannot be
modified using the iterator. See transformVertices() for a safe method to modify vertices "in-place".

* Example:
### Example:

.. code-block:: python

# print the x and y coordinate for each vertex in a LineString
@@ -410,7 +410,8 @@ Returns a read-only, Java-style iterator for traversal of vertices of all the ge
The iterator returns a copy of individual vertices, and accordingly geometries cannot be
modified using the iterator. See transformVertices() for a safe method to modify vertices "in-place".

* Example:
### Example:

.. code-block:: python

# print the x and y coordinate for each vertex in a LineString
@@ -437,7 +438,8 @@ can safely be used to modify parts of the geometry.
This method forces a detach. Use constParts() to avoid the detach
if the parts are not going to be modified.

* Example:
### Example:

.. code-block:: python

# print the WKT representation of each part in a multi-point geometry
@@ -476,7 +478,8 @@ returns read-only references to parts and cannot be used to modify the parts.
Unlike parts(), this method does not force a detach and is more efficient if read-only
iteration only is required.

* Example:
### Example:

.. code-block:: python

# print the WKT representation of each part in a multi-point geometry
@@ -116,7 +116,9 @@ Compute the intersection between two segments

:return: - Whether the segments intersect
- intersectionPoint: Output parameter, the intersection point
* Example:

### Example:

.. code-block:: python

ret = QgsGeometryUtils.segmentIntersection( QgsPoint( 0, 0 ), QgsPoint( 0, 1 ), QgsPoint( 1, 1 ), QgsPoint( 1, 0 ) )
@@ -474,7 +476,9 @@ M value is computed if one of this point have M.
:param pt2: second point.

:return: New point at middle between points pt1 and pt2.
* Example:

### Example:

.. code-block:: python

p = QgsPoint( 4, 6 ) # 2D point
@@ -620,7 +624,9 @@ An algorithm to calculate an (approximate) intersection of two lines in 3D.

:return: - ``True`` if the intersection can be found, ``False`` - otherwise.
- intersection: is the result intersection, of it can be found.
example:

### Example:

.. code-block:: python

QgsGeometryUtils.linesIntersection3D(QgsVector3D(0,0,0), QgsVector3D(5,0,0), QgsVector3D(2,1,0), QgsVector3D(2,3,0))
@@ -316,7 +316,9 @@ M value is preserved.

:return: The point projected. If a 2D point is projected a 3D point will be returned except if
inclination is 90. A 3D point is always returned if a 3D point is projected.
Example:

### Example:

.. code-block:: python

p = QgsPoint( 1, 2 ) # 2D point
@@ -116,7 +116,9 @@ Returns the three lengths of the triangle.

:return: Lengths of triangle ABC where [AB] is at 0, [BC] is at 1, [CA] is at 2.
An empty list is returned for empty triangle.
* Example:

### Example:

.. code-block:: python

tri = QgsTriangle( QgsPoint( 0, 0 ), QgsPoint( 0, 5 ), QgsPoint( 5, 5 ) )
@@ -132,7 +134,9 @@ Returns the three angles of the triangle.

:return: Angles in radians of triangle ABC where angle BAC is at 0, angle ABC is at 1, angle BCA is at 2.
An empty list is returned for empty triangle.
* Example:

### Example:

.. code-block:: python

tri = QgsTriangle( QgsPoint( 0, 0 ), QgsPoint( 0, 5 ), QgsPoint( 5, 5 ) )
@@ -147,7 +151,9 @@ Returns the three angles of the triangle.
Convenient method checking if the geometry is degenerate (have duplicate or colinear point(s)).

:return: ``True`` if the triangle is degenerate or empty, otherwise ``False``.
Example:

### Example:

.. code-block:: python

tri = QgsTriangle()
@@ -171,7 +177,9 @@ Is the triangle isocele (two sides with the same length)?
:param lengthTolerance: The tolerance to use

:return: ``True`` or ``False``. Always ``False`` for empty triangle.
* Example:

### Example:

.. code-block:: python

tri = QgsTriangle( QgsPoint( 0, 0 ), QgsPoint( 0, 5 ), QgsPoint( 5, 5 ) )
@@ -191,7 +199,9 @@ Is the triangle equilateral (three sides with the same length)?
:param lengthTolerance: The tolerance to use

:return: ``True`` or ``False``. Always ``False`` for empty triangle.
* Example:

### Example:

.. code-block:: python

tri = QgsTriangle( QgsPoint( 10, 10 ), QgsPoint( 16, 10 ), QgsPoint( 13, 15.1962 ) )
@@ -211,7 +221,9 @@ Is the triangle right-angled?
:param angleTolerance: The tolerance to use

:return: ``True`` or ``False``. Always ``False`` for empty triangle.
* Example:

### Example:

.. code-block:: python

tri = QgsTriangle( QgsPoint( 0, 0 ), QgsPoint( 0, 5 ), QgsPoint( 5, 5 ) )
@@ -231,7 +243,9 @@ Is the triangle scalene (all sides have different lengths)?
:param lengthTolerance: The tolerance to use

:return: ``True`` or ``False``. Always ``False`` for empty triangle.
* Example:

### Example:

.. code-block:: python

tri = QgsTriangle( QgsPoint( 7.2825, 4.2368 ), QgsPoint( 13.0058, 3.3218 ), QgsPoint( 9.2145, 6.5242 ) )
@@ -250,7 +264,9 @@ An altitude is a segment (defined by a :py:class:`QgsLineString`) from a vertex

:return: Three altitudes from this triangle.
An empty list is returned for empty triangle.
* Example:

### Example:

.. code-block:: python

tri = QgsTriangle( QgsPoint( 0, 0 ), QgsPoint( 0, 5 ), QgsPoint( 5, 5 ) )
@@ -266,7 +282,9 @@ A median is a segment (defined by a :py:class:`QgsLineString`) from a vertex to

:return: Three medians from this triangle.
An empty list is returned for empty triangle.
* Example:

### Example:

.. code-block:: python

tri = QgsTriangle( QgsPoint( 0, 0 ), QgsPoint( 0, 5 ), QgsPoint( 5, 5 ) )
@@ -284,7 +302,9 @@ The segment (defined by a :py:class:`QgsLineString`) returned bisect the angle o

:return: Three angle bisector from this triangle.
An empty list is returned for empty triangle.
* Example:

### Example:

.. code-block:: python

tri = QgsTriangle( QgsPoint( 0, 0 ), QgsPoint( 0, 5 ), QgsPoint( 5, 5 ) )
@@ -300,7 +320,9 @@ Medial (or midpoint) triangle of a triangle ABC is the triangle with vertices at

:return: The medial from this triangle.
An empty triangle is returned for empty triangle.
* Example:

### Example:

.. code-block:: python

tri = QgsTriangle( QgsPoint( 0, 0 ), QgsPoint( 0, 5 ), QgsPoint( 5, 5 ) )
@@ -318,7 +340,9 @@ An orthocenter is the point of intersection of the altitudes of a triangle.

:return: The orthocenter of the triangle.
An empty point is returned for empty triangle.
* Example:

### Example:

.. code-block:: python

tri = QgsTriangle( QgsPoint( 0, 0 ), QgsPoint( 0, 5 ), QgsPoint( 5, 5 ) )
@@ -334,7 +358,9 @@ Center of the circumscribed circle of the triangle.

:return: The center of the circumscribed circle of the triangle.
An empty point is returned for empty triangle.
* Example:

### Example:

.. code-block:: python

tri = QgsTriangle( QgsPoint( 0, 0 ), QgsPoint( 0, 5 ), QgsPoint( 5, 5 ) )
@@ -350,7 +376,9 @@ Radius of the circumscribed circle of the triangle.

:return: The radius of the circumscribed circle of the triangle.
0.0 is returned for empty triangle.
* Example:

### Example:

.. code-block:: python

tri = QgsTriangle( QgsPoint( 0, 0 ), QgsPoint( 0, 5 ), QgsPoint( 5, 5 ) )
@@ -366,7 +394,9 @@ Circumscribed circle of the triangle.

:return: The circumbscribed of the triangle with a :py:class:`QgsCircle`.
An empty circle is returned for empty triangle.
Example:

### Example:

.. code-block:: python

tri = QgsTriangle( QgsPoint( 0, 0 ), QgsPoint( 0, 5 ), QgsPoint( 5, 5 ) )
@@ -383,7 +413,9 @@ supported and is retrieved from the first 3D point amongst vertices.

:return: The center of the inscribed circle of the triangle.
An empty point is returned for empty triangle.
* Example:

### Example:

.. code-block:: python

tri = QgsTriangle( QgsPoint( 0, 0 ), QgsPoint( 0, 5 ), QgsPoint( 5, 5 ) )
@@ -399,7 +431,9 @@ Radius of the inscribed circle of the triangle.

:return: The radius of the inscribed circle of the triangle.
0.0 is returned for empty triangle.
* Example:

### Example:

.. code-block:: python

tri = QgsTriangle( QgsPoint( 0, 0 ), QgsPoint( 0, 5 ), QgsPoint( 5, 5 ) )
@@ -415,7 +449,9 @@ Inscribed circle of the triangle.

:return: The inscribed of the triangle with a :py:class:`QgsCircle`.
An empty circle is returned for empty triangle.
Example:

### Example:

.. code-block:: python

tri = QgsTriangle( QgsPoint( 0, 0 ), QgsPoint( 0, 5 ), QgsPoint( 5, 5 ) )
@@ -138,7 +138,8 @@ If ``ui`` is a URL, a local copy of the file will be made and will be used to cr
%Docstring
Set the editor widget config for a widget which is not for a simple field.

Example:
### Example:

.. code-block:: python

editFormConfig = layer.editFormConfig()
@@ -338,7 +338,8 @@ This method is a shortcut for calling:

feature.setGeometry( QgsGeometry( geometry ) )

* Example:
### Example:

.. code-block:: python

# Sets a feature's geometry to a point geometry
@@ -527,8 +527,9 @@ coordinates
%Docstring
Clones generic renderer data to another renderer.
Currently clones
* Order By
* Paint Effect

- Order By
- Paint Effect

:param destRenderer: destination renderer for copied effect
%End
@@ -341,7 +341,11 @@ the rendered text.
.. warning::

Only a small subset of HTML formatting is supported. Currently this is restricted to:
* text color formatting

- text color formatting
- strikethrough
- underline
- overline

.. seealso:: :py:func:`setAllowHtmlFormatting`

@@ -356,7 +360,11 @@ the rendered text.
.. warning::

Only a small subset of HTML formatting is supported. Currently this is restricted to:
* text color formatting

- text color formatting
- strikethrough
- underline
- overline

.. seealso:: :py:func:`allowHtmlFormatting`

@@ -26,9 +26,10 @@ Base class for plugins allowing to pick automatically a widget type for editing
virtual QgsEditorWidgetSetup editorWidgetSetup( const QgsVectorLayer *vl, const QString &fieldName, int &score /Out/ ) const = 0;
%Docstring
Typical scores are:
* 0: no matching type found.
* 10: a widget has been guessed from the type of field.
* 20: a widget has been determined from an external configuration (for example a database table)

- 0: no matching type found.
- 10: a widget has been guessed from the type of field.
- 20: a widget has been determined from an external configuration (for example a database table)

:param vl: The vector layer for which this widget will be created
:param fieldName: The field name on the specified layer for which this widget will be created
@@ -90,10 +90,11 @@ By default, it returns 5 for every fields.
Reimplement this if you only support certain fields.

Typical return values are:
* 0: not supported
* 5: maybe support (for example, Datetime support strings depending on their content)
* 10: basic support (this is what returns TextEdit for example, since it supports everything in a crude way)
* 20: specialized support

- 0: not supported
- 5: maybe support (for example, Datetime support strings depending on their content)
- 10: basic support (this is what returns TextEdit for example, since it supports everything in a crude way)
- 20: specialized support

:param vl:
:param fieldIdx:

0 comments on commit cedd73e

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