mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-14 00:07:35 -04:00
run sipify
This commit is contained in:
parent
9ae54eaafa
commit
41495058d1
@ -118,6 +118,7 @@ INCLUDE_DIRECTORIES(
|
||||
${CMAKE_SOURCE_DIR}/src/core/raster
|
||||
${CMAKE_SOURCE_DIR}/src/core/scalebar
|
||||
${CMAKE_SOURCE_DIR}/src/core/symbology
|
||||
${CMAKE_SOURCE_DIR}/src/core/symbology/classification
|
||||
${CMAKE_SOURCE_DIR}/src/core/validity
|
||||
${CMAKE_SOURCE_DIR}/src/plugins
|
||||
${CMAKE_SOURCE_DIR}/external
|
||||
|
@ -711,6 +711,14 @@ Returns the application's plugin layer registry, used for managing plugin layer
|
||||
.. versionadded:: 3.0
|
||||
%End
|
||||
|
||||
static QgsClassificationMethodRegistry *classificationMethodRegistry() /KeepReference/;
|
||||
%Docstring
|
||||
Returns the application's classification methods registry, used in graduated renderer
|
||||
|
||||
.. versionadded:: 3.10
|
||||
%End
|
||||
|
||||
|
||||
static QgsMessageLog *messageLog();
|
||||
%Docstring
|
||||
Returns the application's message log.
|
||||
|
@ -0,0 +1,44 @@
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/core/symbology/classification/qgsclassificationcustom.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
||||
|
||||
|
||||
|
||||
|
||||
class QgsClassificationCustom : QgsClassificationMethod
|
||||
{
|
||||
%Docstring
|
||||
QgsClassificationCustom is a dummy implementation of QgsClassification
|
||||
which does not compute any break.
|
||||
|
||||
.. versionadded:: 3.10
|
||||
%End
|
||||
|
||||
%TypeHeaderCode
|
||||
#include "qgsclassificationcustom.h"
|
||||
%End
|
||||
public:
|
||||
QgsClassificationCustom();
|
||||
|
||||
virtual QgsClassificationMethod *clone() const;
|
||||
|
||||
virtual QString name() const;
|
||||
|
||||
virtual QString id() const;
|
||||
|
||||
|
||||
static const QString METHOD_ID;
|
||||
|
||||
};
|
||||
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/core/symbology/classification/qgsclassificationcustom.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
@ -0,0 +1,43 @@
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/core/symbology/classification/qgsclassificationequalinterval.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
||||
|
||||
|
||||
|
||||
class QgsClassificationEqualInterval : QgsClassificationMethod
|
||||
{
|
||||
%Docstring
|
||||
QgsClassificationCustom is an implementation of QgsClassification
|
||||
for equal intervals
|
||||
|
||||
.. versionadded:: 3.10
|
||||
%End
|
||||
|
||||
%TypeHeaderCode
|
||||
#include "qgsclassificationequalinterval.h"
|
||||
%End
|
||||
public:
|
||||
QgsClassificationEqualInterval();
|
||||
|
||||
virtual QString name() const;
|
||||
|
||||
virtual QString id() const;
|
||||
|
||||
virtual QgsClassificationMethod *clone() const;
|
||||
|
||||
|
||||
static const QString METHOD_ID;
|
||||
|
||||
};
|
||||
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/core/symbology/classification/qgsclassificationequalinterval.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
@ -0,0 +1,41 @@
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/core/symbology/classification/qgsclassificationjenks.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
||||
|
||||
|
||||
|
||||
class QgsClassificationJenks : QgsClassificationMethod
|
||||
{
|
||||
%Docstring
|
||||
QgsClassificationCustom is an implementation of QgsClassification
|
||||
for natural breaks based on Jenks method
|
||||
|
||||
.. versionadded:: 3.10
|
||||
%End
|
||||
|
||||
%TypeHeaderCode
|
||||
#include "qgsclassificationjenks.h"
|
||||
%End
|
||||
public:
|
||||
QgsClassificationJenks();
|
||||
|
||||
virtual QString name() const;
|
||||
|
||||
virtual QString id() const;
|
||||
|
||||
virtual QgsClassificationMethod *clone() const;
|
||||
|
||||
|
||||
};
|
||||
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/core/symbology/classification/qgsclassificationjenks.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
@ -0,0 +1,277 @@
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/core/symbology/classification/qgsclassificationmethod.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
// This is required for the ConvertToSubClassCode to work properly
|
||||
// so RTTI for casting is available in the whole module.
|
||||
%ModuleCode
|
||||
#include "qgsclassificationequalinterval.h"
|
||||
#include "qgsclassificationjenks.h"
|
||||
#include "qgsclassificationprettybreaks.h"
|
||||
#include "qgsclassificationquantile.h"
|
||||
#include "qgsclassificationstandarddeviation.h"
|
||||
%End
|
||||
|
||||
|
||||
|
||||
class QgsClassificationRange
|
||||
{
|
||||
%Docstring
|
||||
QgsClassificationRange contains the information about a classification range
|
||||
%End
|
||||
|
||||
%TypeHeaderCode
|
||||
#include "qgsclassificationmethod.h"
|
||||
%End
|
||||
public:
|
||||
QgsClassificationRange( const QString &label, const double &lowerBound, const double &upperBound );
|
||||
%Docstring
|
||||
Constructor
|
||||
%End
|
||||
double lowerBound() const;
|
||||
%Docstring
|
||||
Returns the lower bound
|
||||
%End
|
||||
double upperBound() const;
|
||||
%Docstring
|
||||
Returns the upper bound
|
||||
%End
|
||||
|
||||
QString label() const;
|
||||
%Docstring
|
||||
Returns the lower bound
|
||||
%End
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
||||
class QgsClassificationMethod /Abstract/
|
||||
{
|
||||
%Docstring
|
||||
QgsClassification is an abstract class for implementations of classification methods
|
||||
|
||||
.. versionadded:: 3.10
|
||||
%End
|
||||
|
||||
%TypeHeaderCode
|
||||
#include "qgsclassificationmethod.h"
|
||||
%End
|
||||
%ConvertToSubClassCode
|
||||
if ( dynamic_cast<QgsClassificationEqualInterval *>( sipCpp ) )
|
||||
sipType = sipType_QgsClassificationEqualInterval;
|
||||
else if ( dynamic_cast<QgsClassificationJenks *>( sipCpp ) )
|
||||
sipType = sipType_QgsClassificationJenks;
|
||||
else if ( dynamic_cast<QgsClassificationPrettyBreaks *>( sipCpp ) )
|
||||
sipType = sipType_QgsClassificationPrettyBreaks;
|
||||
else if ( dynamic_cast<QgsClassificationQuantile *>( sipCpp ) )
|
||||
sipType = sipType_QgsClassificationQuantile;
|
||||
else if ( dynamic_cast<QgsClassificationStandardDeviation *>( sipCpp ) )
|
||||
sipType = sipType_QgsClassificationStandardDeviation;
|
||||
else
|
||||
sipType = 0;
|
||||
%End
|
||||
public:
|
||||
|
||||
enum ClassPosition
|
||||
{
|
||||
LowerBound,
|
||||
Inner,
|
||||
UpperBound
|
||||
};
|
||||
|
||||
explicit QgsClassificationMethod( bool valuesRequired, bool symmetricModeAvailable, int codeComplexity = 1 );
|
||||
%Docstring
|
||||
Creates a classification method.
|
||||
|
||||
:param valuesRequired: if ``True``, this means that the method requires a set of values to determine the classes
|
||||
:param symmetricModeAvailable: if ``True``, this allows using symmetric classification
|
||||
:param codeCommplexity: as the exponent in the big O notation
|
||||
\param
|
||||
%End
|
||||
|
||||
virtual ~QgsClassificationMethod();
|
||||
|
||||
virtual QgsClassificationMethod *clone() const = 0 /Factory/;
|
||||
|
||||
virtual QString name() const = 0;
|
||||
%Docstring
|
||||
The readable and translate name of the method
|
||||
%End
|
||||
|
||||
virtual QString id() const = 0; // as saved in the project, must be unique in registry
|
||||
|
||||
virtual QString labelForRange( const double &lowerValue, const double &upperValue, ClassPosition position = Inner ) const;
|
||||
%Docstring
|
||||
Returns the label for a range
|
||||
%End
|
||||
|
||||
|
||||
virtual void saveExtra( QDomElement &element, const QgsReadWriteContext &context ) const;
|
||||
%Docstring
|
||||
Writes extra information about the method
|
||||
%End
|
||||
virtual void readExtra( const QDomElement &element, const QgsReadWriteContext &context );
|
||||
%Docstring
|
||||
Reads extra information to apply it to the method
|
||||
%End
|
||||
|
||||
|
||||
bool valuesRequired() const;
|
||||
%Docstring
|
||||
Returns if the method requires values to calculate the classes
|
||||
If not, bounds are sufficient
|
||||
%End
|
||||
|
||||
int codeComplexity() const;
|
||||
%Docstring
|
||||
Code complexity as the exponent in Big O notation
|
||||
%End
|
||||
|
||||
bool symmetricModeAvailable() const;
|
||||
%Docstring
|
||||
Returns if the method supports symmetric calculation
|
||||
%End
|
||||
|
||||
bool symmetricModeEnabled() const;
|
||||
%Docstring
|
||||
Returns if the symmetric mode is enabled
|
||||
%End
|
||||
|
||||
double symmetryPoint() const;
|
||||
%Docstring
|
||||
Returns the symmetry point for symmetric mode
|
||||
%End
|
||||
|
||||
bool astride() const;
|
||||
%Docstring
|
||||
Returns if the symmetric mode is astride
|
||||
if ``True``, it will remove the symmetry point break so that the 2 classes form only one
|
||||
%End
|
||||
|
||||
void setSymmetricMode( bool enabled, double symmetryPoint = 0, bool astride = false );
|
||||
%Docstring
|
||||
Defines if the symmetric mode is enables and configures its parameters.
|
||||
If the symmetric mode is not available in the current implementation, calling this method has no effect.
|
||||
|
||||
:param enabled: if the symmetric mode is enabled
|
||||
:param symmetryPoint: the value of the symmetry point
|
||||
:param astride: if ``True``, it will remove the symmetry point break so that the 2 classes form only one
|
||||
%End
|
||||
|
||||
QString labelFormat() const;
|
||||
%Docstring
|
||||
Returns the format of the label for the classes
|
||||
%End
|
||||
void setLabelFormat( const QString &format );
|
||||
%Docstring
|
||||
Defines the format of the labels for the classes, using %1 and %2 for the bounds
|
||||
%End
|
||||
int labelPrecision() const;
|
||||
%Docstring
|
||||
Returns the precision for the formatting of the labels
|
||||
%End
|
||||
void setLabelPrecision( int labelPrecision );
|
||||
%Docstring
|
||||
Defines the precision for the formatting of the labels
|
||||
%End
|
||||
bool labelTrimTrailingZeroes() const;
|
||||
%Docstring
|
||||
Returns if the trailing 0 are trimmed in the label
|
||||
%End
|
||||
void setLabelTrimTrailingZeroes( bool trimTrailingZeroes );
|
||||
%Docstring
|
||||
Defines if the trailing 0 are trimmed in the label
|
||||
%End
|
||||
|
||||
static QList<double> listToValues( const QList<QgsClassificationRange> classes );
|
||||
%Docstring
|
||||
Transforms a list of classes to a list of breaks
|
||||
%End
|
||||
|
||||
QList<QgsClassificationRange> classes( const QgsVectorLayer *vl, const QString &expression, int numberOfClasses );
|
||||
%Docstring
|
||||
This will calculate the breaks for a given layer to define the classes.
|
||||
The breaks do not contain the uppper and lower bounds (minimum and maximum values).
|
||||
|
||||
:param vl: The vector layer
|
||||
:param fieldName: The name of the field on which the classes are calculated
|
||||
:param numberOfClasses: The number of classes to be returned
|
||||
%End
|
||||
|
||||
QList<QgsClassificationRange> classes( const QList<double> &values, int numberOfClasses );
|
||||
%Docstring
|
||||
This will calculate the breaks for a list of values.
|
||||
The breaks do not contain the uppper and lower bounds (minimum and maximum values)
|
||||
|
||||
:param values: The list of values
|
||||
:param numberOfClasses: The number of classes to be returned
|
||||
%End
|
||||
|
||||
QList<QgsClassificationRange> classes( double minimum, double maximum, int numberOfClasses );
|
||||
%Docstring
|
||||
This will calculate the classes for defined bounds without any values.
|
||||
The breaks do not contain the uppper and lower bounds (minimum and maximum values)
|
||||
|
||||
.. warning::
|
||||
|
||||
If the method implementation requires values, this will return an empty list.
|
||||
|
||||
:param values: The list of values
|
||||
:param numberOfClasses: The number of classes to be returned
|
||||
%End
|
||||
|
||||
QDomElement save( QDomDocument &doc, const QgsReadWriteContext &context ) const;
|
||||
static QgsClassificationMethod *create( const QDomElement &element, const QgsReadWriteContext &context ) /Factory/;
|
||||
|
||||
static void makeBreaksSymmetric( QList<double> &breaks /In,Out/, double symmetryPoint, bool astride );
|
||||
%Docstring
|
||||
Remove the breaks that are above the existing opposite sign classes to keep colors symmetrically balanced around symmetryPoint
|
||||
Does not put a break on the symmetryPoint. This is done before.
|
||||
|
||||
:param breaks: The breaks of an already-done classification
|
||||
:param symmetryPoint: The point around which we want a symmetry
|
||||
:param astride: A bool indicating if the symmetry is made astride the symmetryPoint or not ( [-1,1] vs. [-1,0][0,1] )
|
||||
%End
|
||||
|
||||
QString labelForRange( const QgsRendererRange &range, ClassPosition position = Inner ) const;
|
||||
%Docstring
|
||||
Returns the label for a range
|
||||
%End
|
||||
|
||||
|
||||
|
||||
static const int MAX_PRECISION;
|
||||
static const int MIN_PRECISION;
|
||||
|
||||
protected:
|
||||
|
||||
void copyBase( QgsClassificationMethod *c ) const;
|
||||
%Docstring
|
||||
Copy the parameters (shall be used in clone implementation)
|
||||
%End
|
||||
|
||||
QString formatNumber( double value ) const;
|
||||
%Docstring
|
||||
Format the number according to label properties
|
||||
%End
|
||||
|
||||
|
||||
|
||||
};
|
||||
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/core/symbology/classification/qgsclassificationmethod.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
@ -0,0 +1,54 @@
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/core/symbology/classification/qgsclassificationmethodregistry.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
class QgsClassificationMethodRegistry
|
||||
{
|
||||
%Docstring
|
||||
This class manages all known classification methods
|
||||
|
||||
QgsClassificationMethodRegistry is not usually directly created, but rather accessed through
|
||||
:py:func:`QgsApplication.classificationMethodRegistry()`
|
||||
|
||||
.. versionadded:: 3.10
|
||||
%End
|
||||
|
||||
%TypeHeaderCode
|
||||
#include "qgsclassificationmethodregistry.h"
|
||||
%End
|
||||
public:
|
||||
QgsClassificationMethodRegistry();
|
||||
|
||||
void addMethod( QgsClassificationMethod *method /Transfer/ );
|
||||
%Docstring
|
||||
Adds a method to the registry
|
||||
%End
|
||||
|
||||
QgsClassificationMethod *method( const QString &id );
|
||||
%Docstring
|
||||
Return a new instance of the method for the given id
|
||||
%End
|
||||
|
||||
QMap<QString, QString> methodNames() const;
|
||||
%Docstring
|
||||
Returns a map <id, name> of all registered methods
|
||||
%End
|
||||
|
||||
};
|
||||
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/core/symbology/classification/qgsclassificationmethodregistry.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
@ -0,0 +1,41 @@
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/core/symbology/classification/qgsclassificationprettybreaks.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
||||
|
||||
|
||||
|
||||
class QgsClassificationPrettyBreaks : QgsClassificationMethod
|
||||
{
|
||||
%Docstring
|
||||
QgsClassificationCustom is an implementation of QgsClassification
|
||||
for pretty breaks
|
||||
|
||||
.. versionadded:: 3.10
|
||||
%End
|
||||
|
||||
%TypeHeaderCode
|
||||
#include "qgsclassificationprettybreaks.h"
|
||||
%End
|
||||
public:
|
||||
QgsClassificationPrettyBreaks();
|
||||
|
||||
virtual QString name() const;
|
||||
|
||||
virtual QString id() const;
|
||||
|
||||
virtual QgsClassificationMethod *clone() const;
|
||||
|
||||
|
||||
};
|
||||
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/core/symbology/classification/qgsclassificationprettybreaks.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
@ -0,0 +1,42 @@
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/core/symbology/classification/qgsclassificationquantile.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
||||
|
||||
|
||||
|
||||
|
||||
class QgsClassificationQuantile : QgsClassificationMethod
|
||||
{
|
||||
%Docstring
|
||||
QgsClassificationCustom is an implementation of QgsClassification
|
||||
based on quantiles
|
||||
|
||||
.. versionadded:: 3.10
|
||||
%End
|
||||
|
||||
%TypeHeaderCode
|
||||
#include "qgsclassificationquantile.h"
|
||||
%End
|
||||
public:
|
||||
QgsClassificationQuantile();
|
||||
|
||||
virtual QString name() const;
|
||||
|
||||
virtual QString id() const;
|
||||
|
||||
virtual QgsClassificationMethod *clone() const;
|
||||
|
||||
|
||||
};
|
||||
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/core/symbology/classification/qgsclassificationquantile.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
@ -0,0 +1,49 @@
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/core/symbology/classification/qgsclassificationstandarddeviation.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
||||
|
||||
|
||||
|
||||
class QgsClassificationStandardDeviation : QgsClassificationMethod
|
||||
{
|
||||
%Docstring
|
||||
QgsClassificationCustom is an implementation of QgsClassification
|
||||
based on standard deviation
|
||||
|
||||
.. versionadded:: 3.10
|
||||
%End
|
||||
|
||||
%TypeHeaderCode
|
||||
#include "qgsclassificationstandarddeviation.h"
|
||||
%End
|
||||
public:
|
||||
QgsClassificationStandardDeviation();
|
||||
|
||||
virtual QString name() const;
|
||||
|
||||
virtual QString id() const;
|
||||
|
||||
virtual QgsClassificationMethod *clone() const;
|
||||
|
||||
virtual QString labelForRange( const double &lowerValue, const double &upperValue, ClassPosition position ) const;
|
||||
|
||||
virtual void saveExtra( QDomElement &element, const QgsReadWriteContext &context ) const;
|
||||
|
||||
virtual void readExtra( const QDomElement &element, const QgsReadWriteContext &context );
|
||||
|
||||
|
||||
static const QString METHOD_ID;
|
||||
|
||||
};
|
||||
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/core/symbology/classification/qgsclassificationstandarddeviation.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
@ -9,6 +9,8 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
class QgsGraduatedSymbolRenderer : QgsFeatureRenderer
|
||||
{
|
||||
|
||||
@ -117,6 +119,21 @@ Tests whether classes assigned to the renderer have gaps between the ranges.
|
||||
void sortByValue( Qt::SortOrder order = Qt::AscendingOrder );
|
||||
void sortByLabel( Qt::SortOrder order = Qt::AscendingOrder );
|
||||
|
||||
QgsClassificationMethod *classificationMethod() const;
|
||||
%Docstring
|
||||
Returns the classification method
|
||||
|
||||
.. versionadded:: 3.10
|
||||
%End
|
||||
|
||||
void setClassificationMethod( QgsClassificationMethod *method /Transfer/ );
|
||||
%Docstring
|
||||
Defines the classification method
|
||||
This will take ownership of the method
|
||||
|
||||
.. versionadded:: 3.10
|
||||
%End
|
||||
|
||||
enum Mode
|
||||
{
|
||||
EqualInterval,
|
||||
@ -127,54 +144,74 @@ Tests whether classes assigned to the renderer have gaps between the ranges.
|
||||
Custom
|
||||
};
|
||||
|
||||
Mode mode() const;
|
||||
void setMode( Mode mode );
|
||||
Mode mode() const /Deprecated/;
|
||||
%Docstring
|
||||
|
||||
bool useSymmetricMode() const;
|
||||
.. deprecated:: since QGIS 3.10 use classficationMethod instead
|
||||
%End
|
||||
void setMode( Mode mode ) /Deprecated/;
|
||||
%Docstring
|
||||
|
||||
.. deprecated:: since QGIS 3.10 use classficationMethod instead
|
||||
%End
|
||||
|
||||
bool useSymmetricMode() const /Deprecated/;
|
||||
%Docstring
|
||||
Returns if we want to classify symmetric around a given value
|
||||
|
||||
.. versionadded:: 3.4
|
||||
|
||||
.. deprecated:: since QGIS 3.10 use classficationMethod instead
|
||||
%End
|
||||
|
||||
void setUseSymmetricMode( bool useSymmetricMode );
|
||||
void setUseSymmetricMode( bool useSymmetricMode ) /Deprecated/;
|
||||
%Docstring
|
||||
Set if we want to classify symmetric around a given value
|
||||
|
||||
.. versionadded:: 3.4
|
||||
|
||||
.. deprecated:: since QGIS 3.10 use classficationMethod instead
|
||||
%End
|
||||
|
||||
double symmetryPoint() const;
|
||||
double symmetryPoint() const /Deprecated/;
|
||||
%Docstring
|
||||
Returns the pivot value for symmetric classification
|
||||
|
||||
.. versionadded:: 3.4
|
||||
|
||||
.. deprecated:: since QGIS 3.10 use classficationMethod instead
|
||||
%End
|
||||
|
||||
void setSymmetryPoint( double symmetryPoint );
|
||||
void setSymmetryPoint( double symmetryPoint ) /Deprecated/;
|
||||
%Docstring
|
||||
Set the pivot point
|
||||
|
||||
.. versionadded:: 3.4
|
||||
|
||||
.. deprecated:: since QGIS 3.10 use classficationMethod instead
|
||||
%End
|
||||
|
||||
|
||||
|
||||
bool astride() const;
|
||||
bool astride() const /Deprecated/;
|
||||
%Docstring
|
||||
Returns if we want to have a central class astride the pivot value
|
||||
|
||||
.. versionadded:: 3.4
|
||||
|
||||
.. deprecated:: since QGIS 3.10 use classficationMethod instead
|
||||
%End
|
||||
|
||||
void setAstride( bool astride );
|
||||
void setAstride( bool astride ) /Deprecated/;
|
||||
%Docstring
|
||||
Set if we want a central class astride the pivot value
|
||||
|
||||
.. versionadded:: 3.4
|
||||
|
||||
.. deprecated:: since QGIS 3.10 use classficationMethod instead
|
||||
%End
|
||||
|
||||
static void makeBreaksSymmetric( QList<double> &breaks /In,Out/, double symmetryPoint, bool astride );
|
||||
static void makeBreaksSymmetric( QList<double> &breaks /In,Out/, double symmetryPoint, bool astride ) /Deprecated/;
|
||||
%Docstring
|
||||
Remove the breaks that are above the existing opposite sign classes to keep colors symmetrically balanced around symmetryPoint
|
||||
Does not put a break on the symmetryPoint. This is done before.
|
||||
@ -184,9 +221,11 @@ Does not put a break on the symmetryPoint. This is done before.
|
||||
:param astride: A bool indicating if the symmetry is made astride the symmetryPoint or not ( [-1,1] vs. [-1,0][0,1] )
|
||||
|
||||
.. versionadded:: 3.4
|
||||
|
||||
.. deprecated:: since QGIS 3.10, use QgsClassificationMethod.makeBreaksSymmetric instead
|
||||
%End
|
||||
|
||||
static QList<double> calcEqualIntervalBreaks( double minimum, double maximum, int classes, bool useSymmetricMode, double symmetryPoint, bool astride );
|
||||
static QList<double> calcEqualIntervalBreaks( double minimum, double maximum, int classes, bool useSymmetricMode, double symmetryPoint, bool astride );
|
||||
%Docstring
|
||||
Compute the equal interval classification
|
||||
|
||||
@ -196,9 +235,11 @@ Compute the equal interval classification
|
||||
:param useSymmetricMode: A bool indicating if we want to have classes and hence colors ramp symmetric around a value
|
||||
:param symmetryPoint: The point around which we want a symmetry
|
||||
:param astride: A bool indicating if the symmetry is made astride the symmetryPoint or not ( [-1,1] vs. [-1,0][0,1] )
|
||||
|
||||
.. deprecated:: since QGIS 3.10 use QgsClassificationEqualInterval class instead
|
||||
%End
|
||||
|
||||
void updateClasses( QgsVectorLayer *vlayer, Mode mode, int nclasses, bool useSymmetricMode = false, double symmetryPoint = 0.0, bool astride = false );
|
||||
void updateClasses( QgsVectorLayer *vlayer, Mode mode, int nclasses, bool useSymmetricMode = false, double symmetryPoint = 0.0, bool astride = false ) /Deprecated/;
|
||||
%Docstring
|
||||
Recalculate classes for a layer
|
||||
|
||||
@ -210,16 +251,27 @@ Recalculate classes for a layer
|
||||
:param astride: A bool indicating if the symmetry is made astride the symmetryPoint or not ( [-1,1] vs. [-1,0][0,1] )
|
||||
|
||||
.. versionadded:: 2.6
|
||||
|
||||
.. deprecated:: since QGIS 3.10
|
||||
%End
|
||||
|
||||
const QgsRendererRangeLabelFormat &labelFormat() const;
|
||||
void updateClasses( const QgsVectorLayer *vl, int numberOfClasses );
|
||||
%Docstring
|
||||
Recalculate classes for a layer
|
||||
|
||||
:param vlayer: The layer being rendered (from which data values are calculated)
|
||||
%End
|
||||
|
||||
const QgsRendererRangeLabelFormat &labelFormat() const;
|
||||
%Docstring
|
||||
Returns the label format used to generate default classification labels
|
||||
|
||||
.. versionadded:: 2.6
|
||||
|
||||
.. deprecated:: since QGIS 3.10 use classificationMethod() and QgsClassificationMethod.setLabelFormat instead
|
||||
%End
|
||||
|
||||
void setLabelFormat( const QgsRendererRangeLabelFormat &labelFormat, bool updateRanges = false );
|
||||
void setLabelFormat( const QgsRendererRangeLabelFormat &labelFormat, bool updateRanges = false ) /Deprecated/;
|
||||
%Docstring
|
||||
Set the label format used to generate default classification labels
|
||||
|
||||
@ -227,6 +279,8 @@ Set the label format used to generate default classification labels
|
||||
:param updateRanges: If ``True`` then ranges ending with the old unit string are updated to the new.
|
||||
|
||||
.. versionadded:: 2.6
|
||||
|
||||
.. deprecated:: since QGIS 3.10 use classificationMethod() and QgsClassificationMethod.setLabelFormat instead
|
||||
%End
|
||||
|
||||
void calculateLabelPrecision( bool updateRanges = true );
|
||||
@ -238,7 +292,8 @@ Reset the label decimal places to a numberbased on the minimum class interval
|
||||
.. versionadded:: 2.6
|
||||
%End
|
||||
|
||||
static QgsGraduatedSymbolRenderer *createRenderer( QgsVectorLayer *vlayer,
|
||||
|
||||
static QgsGraduatedSymbolRenderer *createRenderer( QgsVectorLayer *vlayer,
|
||||
const QString &attrName,
|
||||
int classes,
|
||||
Mode mode,
|
||||
@ -248,7 +303,7 @@ Reset the label decimal places to a numberbased on the minimum class interval
|
||||
bool useSymmetricMode = false,
|
||||
double symmetryPoint = 0.0,
|
||||
QStringList listForCboPrettyBreaks = QStringList(),
|
||||
bool astride = false );
|
||||
bool astride = false ) /Deprecated/;
|
||||
%Docstring
|
||||
Creates a new graduated renderer.
|
||||
|
||||
@ -265,6 +320,8 @@ Creates a new graduated renderer.
|
||||
:param astride: A bool indicating if the symmetry is made astride the symmetryPoint or not ( [-1,1] vs. [-1,0][0,1] )
|
||||
|
||||
:return: new QgsGraduatedSymbolRenderer object
|
||||
|
||||
.. deprecated:: since QGIS 3.10
|
||||
%End
|
||||
|
||||
static QgsFeatureRenderer *create( QDomElement &element, const QgsReadWriteContext &context ) /Factory/;
|
||||
@ -418,6 +475,13 @@ Returns configuration of appearance of legend when using data-defined size for m
|
||||
Will return ``None`` if the functionality is disabled.
|
||||
|
||||
.. versionadded:: 3.0
|
||||
%End
|
||||
|
||||
void updateRangeLabels();
|
||||
%Docstring
|
||||
Updates the labels of the ranges
|
||||
|
||||
.. versionadded:: 3.10
|
||||
%End
|
||||
|
||||
protected:
|
||||
@ -437,6 +501,7 @@ Returns the matching legend key for a value.
|
||||
|
||||
|
||||
|
||||
|
||||
private:
|
||||
QgsGraduatedSymbolRenderer( const QgsGraduatedSymbolRenderer & );
|
||||
QgsGraduatedSymbolRenderer &operator=( const QgsGraduatedSymbolRenderer & );
|
||||
|
@ -24,6 +24,7 @@ class QgsRendererRange
|
||||
%Docstring
|
||||
Constructor for QgsRendererRange.
|
||||
%End
|
||||
QgsRendererRange( const QgsClassificationRange &range, QgsSymbol *symbol /Transfer/, bool render = true );
|
||||
QgsRendererRange( double lowerValue, double upperValue, QgsSymbol *symbol /Transfer/, const QString &label, bool render = true );
|
||||
QgsRendererRange( const QgsRendererRange &range );
|
||||
|
||||
@ -64,11 +65,14 @@ Creates a DOM element representing the range in SLD format.
|
||||
|
||||
typedef QList<QgsRendererRange> QgsRangeList;
|
||||
|
||||
class QgsRendererRangeLabelFormat
|
||||
|
||||
class QgsRendererRangeLabelFormat /Deprecated/
|
||||
{
|
||||
%Docstring
|
||||
|
||||
.. versionadded:: 2.6
|
||||
|
||||
.. deprecated:: since QGIS 3.10, use QgsClassificationMethod instead
|
||||
%End
|
||||
|
||||
%TypeHeaderCode
|
||||
|
@ -255,6 +255,14 @@
|
||||
%Include auto_generated/scalebar/qgsscalebarrenderer.sip
|
||||
%Include auto_generated/scalebar/qgssingleboxscalebarrenderer.sip
|
||||
%Include auto_generated/scalebar/qgsticksscalebarrenderer.sip
|
||||
%Include auto_generated/symbology/classification/qgsclassificationmethodregistry.sip
|
||||
%Include auto_generated/symbology/classification/qgsclassificationmethod.sip
|
||||
%Include auto_generated/symbology/classification/qgsclassificationcustom.sip
|
||||
%Include auto_generated/symbology/classification/qgsclassificationequalinterval.sip
|
||||
%Include auto_generated/symbology/classification/qgsclassificationprettybreaks.sip
|
||||
%Include auto_generated/symbology/classification/qgsclassificationquantile.sip
|
||||
%Include auto_generated/symbology/classification/qgsclassificationjenks.sip
|
||||
%Include auto_generated/symbology/classification/qgsclassificationstandarddeviation.sip
|
||||
%Include auto_generated/symbology/qgs25drenderer.sip
|
||||
%Include auto_generated/symbology/qgsarrowsymbollayer.sip
|
||||
%Include auto_generated/symbology/qgscategorizedsymbolrenderer.sip
|
||||
|
Loading…
x
Reference in New Issue
Block a user