QGIS/python/core/auto_generated/symbology/qgsinvertedpolygonrenderer.sip.in

153 lines
5.5 KiB
Plaintext
Raw Normal View History

2017-06-06 11:03:05 +02:00
/************************************************************************
* This file has been generated automatically from *
* *
2017-08-06 13:39:03 +02:00
* src/core/symbology/qgsinvertedpolygonrenderer.h *
2017-06-06 11:03:05 +02:00
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/
2016-08-06 11:01:42 +02:00
class QgsInvertedPolygonRenderer : QgsFeatureRenderer
2014-05-23 19:56:18 +02:00
{
2017-06-06 11:03:05 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
QgsInvertedPolygonRenderer is a polygon-only feature renderer used to
display features inverted, where the exterior is turned to an interior
and where the exterior theoretically spans the entire plane, allowing
to mask the surroundings of some features.
2017-06-06 11:03:05 +02:00
2017-12-15 10:36:55 -04:00
It is designed on top of another feature renderer, which is called "embedded"
Most of the methods are then only proxies to the embedded renderer.
2017-06-06 11:03:05 +02:00
2017-12-15 10:36:55 -04:00
Features are collected to form one "inverted" polygon
during renderFeature() and rendered on stopRender().
2017-06-06 11:03:05 +02:00
.. versionadded:: 2.4
%End
2014-05-23 19:56:18 +02:00
%TypeHeaderCode
2017-06-06 11:03:05 +02:00
#include "qgsinvertedpolygonrenderer.h"
2014-05-23 19:56:18 +02:00
%End
public:
QgsInvertedPolygonRenderer( QgsFeatureRenderer *embeddedRenderer /Transfer/ = 0 );
2017-06-06 11:03:05 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Constructor
2017-12-15 21:36:08 -04:00
:param embeddedRenderer: optional embeddedRenderer. If ``None``, a default one will be assigned.
Ownership will be transferred.
2017-06-06 11:03:05 +02:00
%End
2014-05-23 19:56:18 +02:00
virtual QgsInvertedPolygonRenderer *clone() const /Factory/;
2017-06-06 11:03:05 +02:00
%Docstring
Direct copies are forbidden. Use clone() instead.
%End
virtual void startRender( QgsRenderContext &context, const QgsFields &fields );
2014-05-23 19:56:18 +02:00
virtual bool renderFeature( const QgsFeature &feature, QgsRenderContext &context, int layer = -1, bool selected = false, bool drawVertexMarker = false ) throw( QgsCsException );
2017-06-06 11:03:05 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Renders a given feature.
This will here collect features. The actual rendering will be postponed to stopRender()
2017-12-15 21:36:08 -04:00
2017-12-15 10:36:55 -04:00
:param feature: the feature to render
:param context: the rendering context
:param layer: the symbol layer to render, if that makes sense
:param selected: whether this feature has been selected (this will add decorations)
:param drawVertexMarker: whether this feature has vertex markers (in edit mode usually)
2019-02-26 19:54:09 +10:00
:return: ``True`` if the rendering was OK
2017-06-06 11:03:05 +02:00
%End
2014-05-23 19:56:18 +02:00
virtual void stopRender( QgsRenderContext &context );
2017-06-06 11:03:05 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
The actual rendering will take place here.
Features collected during renderFeature() are rendered using the embedded feature renderer
2017-06-06 11:03:05 +02:00
%End
2014-05-23 19:56:18 +02:00
2014-05-24 12:07:23 +02:00
virtual QString dump() const;
2014-05-23 19:56:18 +02:00
virtual QSet<QString> usedAttributes( const QgsRenderContext &context ) const;
virtual bool filterNeedsGeometry() const;
2016-08-06 11:01:42 +02:00
virtual QgsFeatureRenderer::Capabilities capabilities();
2018-04-18 12:51:48 +02:00
virtual QgsSymbolList symbols( QgsRenderContext &context ) const;
virtual QgsSymbol *symbolForFeature( const QgsFeature &feature, QgsRenderContext &context ) const;
virtual QgsSymbol *originalSymbolForFeature( const QgsFeature &feature, QgsRenderContext &context ) const;
virtual QgsSymbolList symbolsForFeature( const QgsFeature &feature, QgsRenderContext &context ) const;
virtual QgsSymbolList originalSymbolsForFeature( const QgsFeature &feature, QgsRenderContext &context ) const;
virtual QgsLegendSymbolList legendSymbolItems() const;
virtual bool willRenderFeature( const QgsFeature &feature, QgsRenderContext &context ) const;
2017-06-06 11:03:05 +02:00
static QgsFeatureRenderer *create( QDomElement &element, const QgsReadWriteContext &context ) /Factory/;
%Docstring
Creates a renderer out of an XML, for loading
%End
2014-05-23 19:56:18 +02:00
2017-06-06 11:03:05 +02:00
virtual QDomElement save( QDomDocument &doc, const QgsReadWriteContext &context );
2014-05-23 19:56:18 +02:00
2017-06-06 11:03:05 +02:00
virtual void setEmbeddedRenderer( QgsFeatureRenderer *subRenderer /Transfer/ );
virtual const QgsFeatureRenderer *embeddedRenderer() const;
2014-05-23 19:56:18 +02:00
2014-05-27 09:11:13 +02:00
virtual void setLegendSymbolItem( const QString &key, QgsSymbol *symbol );
2017-06-06 11:03:05 +02:00
virtual bool legendSymbolItemsCheckable() const;
2017-06-06 11:03:05 +02:00
virtual bool legendSymbolItemChecked( const QString &key );
2017-06-06 11:03:05 +02:00
virtual void checkLegendSymbolItem( const QString &key, bool state = true );
virtual bool accept( QgsStyleEntityVisitorInterface *visitor ) const;
2014-06-10 11:10:42 +07:00
bool preprocessingEnabled() const;
2017-06-06 11:03:05 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
2019-02-26 19:54:09 +10:00
:return: ``True`` if the geometries are to be preprocessed (merged with an union) before rendering.
2017-06-06 11:03:05 +02:00
%End
2014-06-10 11:10:42 +07:00
void setPreprocessingEnabled( bool enabled );
2017-06-06 11:03:05 +02:00
%Docstring
2017-12-15 21:36:08 -04:00
2017-12-15 10:36:55 -04:00
:param enabled: enables or disables the preprocessing.
When enabled, geometries will be merged with an union before being rendered.
It allows fixing some rendering artifacts (when rendering overlapping polygons for instance).
This will involve some CPU-demanding computations and is thus disabled by default.
2017-06-06 11:03:05 +02:00
%End
static QgsInvertedPolygonRenderer *convertFromRenderer( const QgsFeatureRenderer *renderer ) /Factory/;
2017-06-06 11:03:05 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Creates a QgsInvertedPolygonRenderer by a conversion from an existing renderer.
:return: a new renderer if the conversion was possible, otherwise 0.
2017-12-16 10:38:54 -04:00
.. versionadded:: 2.5
2017-06-06 11:03:05 +02:00
%End
2014-05-23 19:56:18 +02:00
};
2017-06-06 11:03:05 +02:00
/************************************************************************
* This file has been generated automatically from *
* *
2017-08-06 13:39:03 +02:00
* src/core/symbology/qgsinvertedpolygonrenderer.h *
2017-06-06 11:03:05 +02:00
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/