Skip to content
Permalink
Browse files

Making lists in PyQGIS doc look better

and fix some wording
  • Loading branch information
DelazJ authored and nyalldawson committed May 20, 2020
1 parent 4587cc1 commit ea4f2bbfb962f309791cdf4468248061f8163089
@@ -33,6 +33,7 @@ Construct a point with the provided initial coordinate values.
If ``wkbType`` is set to `QgsWkbTypes.Point`, `QgsWkbTypes.PointZ`, `QgsWkbTypes.PointM` or `QgsWkbTypes.PointZM`
the type will be set accordingly. If it is left to the default `QgsWkbTypes.Unknown`, the type will be set
based on the following rules:

- If only x and y are specified, the type will be a 2D point.
- If any or both of the Z and M are specified, the appropriate type will be created.

@@ -268,7 +269,7 @@ when comparing distances.

double distanceSquared3D( double x, double y, double z ) const;
%Docstring
Returns the Cartesian 3D squared distance between this point a specified x, y, z coordinate. Calling
Returns the Cartesian 3D squared distance between this point and a specified x, y, z coordinate. Calling
this is faster than calling distance(), and may be useful in use cases such as comparing
distances where the extra expense of calling distance() is not required.

@@ -279,7 +280,7 @@ distances where the extra expense of calling distance() is not required.

double distanceSquared3D( const QgsPoint &other ) const;
%Docstring
Returns the Cartesian 3D squared distance between this point another point. Calling
Returns the Cartesian 3D squared distance between this point and another point. Calling
this is faster than calling distance(), and may be useful in use cases such as comparing
distances where the extra expense of calling distance() is not required.

@@ -15,6 +15,7 @@ class QgsFeatureRequest
%Docstring
This class wraps a request for features to a vector layer (or directly its vector data provider).
The request may apply a filter to fetch only a particular subset of features. Currently supported filters:

- no filter - all features are returned
- feature id - only feature that matches given feature id is returned
- feature ids - only features that match any of the given feature ids are returned
@@ -26,6 +27,7 @@ the intersection is often done only using feature's bounding box. There is a fla
ExactIntersect that makes sure that only intersecting features will be returned.

For efficiency, it is also possible to tell provider that some data is not required:

- NoGeometry flag
- SubsetOfAttributes flag
- SimplifyMethod for geometries to fetch
@@ -18,10 +18,8 @@ for a particular operation (e.g. report progress or pass some data for preview).

When cancel() is called, the internal code has two options to check for cancellation state:

- if the worker thread uses an event loop (e.g. for network communication), the code can
make a queued connection to canceled() signal and handle the cancellation in its slot.
- if the worker thread does not use an event loop, it can poll isCanceled() method regularly
to see if the operation should be canceled.
- if the worker thread uses an event loop (e.g. for network communication), the code can make a queued connection to canceled() signal and handle the cancellation in its slot.
- if the worker thread does not use an event loop, it can poll isCanceled() method regularly to see if the operation should be canceled.

The class is meant to be created and destroyed in the main thread.

@@ -19,10 +19,10 @@ Class defining I/O filters for QGIS Server and
implemented in plugins.

Filters can define any (or none) of the following hooks:
* requestReady() - called when request is ready
* responseComplete() - called when the response is complete
after core services have returned to main loop
* sendResponse() - called just before sending output to FGCI

- requestReady() - called when request is ready
- responseComplete() - called when the response is complete after core services have returned to main loop
- sendResponse() - called just before sending output to FGCI
%End

%TypeHeaderCode
@@ -56,7 +56,7 @@ Set the current log file
%Docstring
Activates logging to stderr.

.. versionadded:: 3.4.
.. versionadded:: 3.4
%End

public slots:
@@ -19,6 +19,7 @@ Subclasses must override operational and informative methods and define
the core functionality in handleRequest() method.

The following methods MUST be implemented:

- path
- operationId
- summary (shorter text)
@@ -28,6 +29,7 @@ The following methods MUST be implemented:
- schema

Optionally, override:

- tags
- parameters
- contentTypes
@@ -189,6 +191,7 @@ Available template functions:
See: https://github.com/pantor/inja#tutorial

Available custom template functions:

- path_append( path ): appends a directory path to the current url
- path_chomp( n ): removes the specified number "n" of directory components from the current url path
- json_dump(): prints current JSON data passed to the template
@@ -51,6 +51,7 @@ class CORE_EXPORT QgsPoint: public QgsAbstractGeometry
* If \a wkbType is set to `QgsWkbTypes::Point`, `QgsWkbTypes::PointZ`, `QgsWkbTypes::PointM` or `QgsWkbTypes::PointZM`
* the type will be set accordingly. If it is left to the default `QgsWkbTypes::Unknown`, the type will be set
* based on the following rules:
*
* - If only x and y are specified, the type will be a 2D point.
* - If any or both of the Z and M are specified, the appropriate type will be created.
*
@@ -387,7 +388,7 @@ class CORE_EXPORT QgsPoint: public QgsAbstractGeometry
double distance3D( const QgsPoint &other ) const;

/**
* Returns the Cartesian 3D squared distance between this point a specified x, y, z coordinate. Calling
* Returns the Cartesian 3D squared distance between this point and a specified x, y, z coordinate. Calling
* this is faster than calling distance(), and may be useful in use cases such as comparing
* distances where the extra expense of calling distance() is not required.
* \see distance()
@@ -396,7 +397,7 @@ class CORE_EXPORT QgsPoint: public QgsAbstractGeometry
double distanceSquared3D( double x, double y, double z ) const;

/**
* Returns the Cartesian 3D squared distance between this point another point. Calling
* Returns the Cartesian 3D squared distance between this point and another point. Calling
* this is faster than calling distance(), and may be useful in use cases such as comparing
* distances where the extra expense of calling distance() is not required.
* \see distance()
@@ -33,6 +33,7 @@
* \ingroup core
* This class wraps a request for features to a vector layer (or directly its vector data provider).
* The request may apply a filter to fetch only a particular subset of features. Currently supported filters:
*
* - no filter - all features are returned
* - feature id - only feature that matches given feature id is returned
* - feature ids - only features that match any of the given feature ids are returned
@@ -44,6 +45,7 @@
* ExactIntersect that makes sure that only intersecting features will be returned.
*
* For efficiency, it is also possible to tell provider that some data is not required:
*
* - NoGeometry flag
* - SubsetOfAttributes flag
* - SimplifyMethod for geometries to fetch
@@ -68,6 +70,7 @@
* # fetch only one feature
* QgsFeatureRequest().setFilterFid(45)
* \endcode
*
*/
class CORE_EXPORT QgsFeatureRequest
{
@@ -29,10 +29,8 @@
*
* When cancel() is called, the internal code has two options to check for cancellation state:
*
* - if the worker thread uses an event loop (e.g. for network communication), the code can
* make a queued connection to canceled() signal and handle the cancellation in its slot.
* - if the worker thread does not use an event loop, it can poll isCanceled() method regularly
* to see if the operation should be canceled.
* - if the worker thread uses an event loop (e.g. for network communication), the code can make a queued connection to canceled() signal and handle the cancellation in its slot.
* - if the worker thread does not use an event loop, it can poll isCanceled() method regularly to see if the operation should be canceled.
*
* The class is meant to be created and destroyed in the main thread.
*
@@ -35,10 +35,10 @@ class QgsServerInterface;
* implemented in plugins.
*
* Filters can define any (or none) of the following hooks:
* * requestReady() - called when request is ready
* * responseComplete() - called when the response is complete
* after core services have returned to main loop
* * sendResponse() - called just before sending output to FGCI
*
* - requestReady() - called when request is ready
* - responseComplete() - called when the response is complete after core services have returned to main loop
* - sendResponse() - called just before sending output to FGCI
*/
class SERVER_EXPORT QgsServerFilter
{
@@ -63,7 +63,7 @@ class SERVER_EXPORT QgsServerLogger : public QgsMessageLogConsole

/**
* Activates logging to stderr.
* \since QGIS 3.4.
* \since QGIS 3.4
*/
void setLogStderr();

@@ -38,6 +38,7 @@ class QgsServerApiContext;
* the core functionality in handleRequest() method.
*
* The following methods MUST be implemented:
*
* - path
* - operationId
* - summary (shorter text)
@@ -47,6 +48,7 @@ class QgsServerApiContext;
* - schema
*
* Optionally, override:
*
* - tags
* - parameters
* - contentTypes
@@ -208,6 +210,7 @@ class SERVER_EXPORT QgsServerOgcApiHandler
* See: https://github.com/pantor/inja#tutorial
*
* Available custom template functions:
*
* - path_append( path ): appends a directory path to the current url
* - path_chomp( n ):removes the specified number "n" of directory components from the current url path
* - json_dump( ): prints current JSON data passed to the template
@@ -295,6 +298,7 @@ class SERVER_EXPORT QgsServerOgcApiHandler
* See: https://github.com/pantor/inja#tutorial
*
* Available custom template functions:
*
* - path_append( path ): appends a directory path to the current url
* - path_chomp( n ): removes the specified number "n" of directory components from the current url path
* - json_dump(): prints current JSON data passed to the template

0 comments on commit ea4f2bb

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