QGIS/python/core/symbology-ng/qgslegendsymbolitem.sip

126 lines
3.8 KiB
Plaintext
Raw Normal View History

2017-06-06 11:03:05 +02:00
/************************************************************************
* This file has been generated automatically from *
* *
* src/core/symbology-ng/qgslegendsymbolitem.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/
2014-08-20 19:32:29 +07:00
2016-08-06 11:01:42 +02:00
class QgsLegendSymbolItem
2014-08-20 19:32:29 +07:00
{
2017-06-06 11:03:05 +02:00
%Docstring
The class stores information about one class/rule of a vector layer renderer in a unified way
that can be used by legend model for rendering of legend.
.. seealso:: QgsSymbolLegendNode
.. versionadded:: 2.6
2014-08-20 19:32:29 +07:00
%End
2017-06-06 11:03:05 +02:00
%TypeHeaderCode
#include "qgslegendsymbolitem.h"
%End
2014-08-20 19:32:29 +07:00
public:
2016-08-06 11:01:42 +02:00
QgsLegendSymbolItem();
QgsLegendSymbolItem( QgsSymbol *symbol, const QString &label, const QString &ruleKey, bool checkable = false, int scaleMinDenom = -1, int scaleMaxDenom = -1, int level = 0, const QString &parentRuleKey = QString() );
2017-06-06 11:03:05 +02:00
%Docstring
.. versionadded:: 2.8
%End
2016-08-06 11:01:42 +02:00
~QgsLegendSymbolItem();
2017-06-26 12:18:34 +10:00
QgsLegendSymbolItem( const QgsLegendSymbolItem &other );
2014-08-20 19:32:29 +07:00
QgsSymbol *symbol() const;
2017-06-06 11:03:05 +02:00
%Docstring
Return associated symbol. May be null.
:rtype: QgsSymbol
%End
2014-08-20 19:32:29 +07:00
QString label() const;
2017-06-06 11:03:05 +02:00
%Docstring
Return text label
:rtype: str
%End
2014-08-20 19:32:29 +07:00
QString ruleKey() const;
2017-06-06 11:03:05 +02:00
%Docstring
Return unique identifier of the rule for identification of the item within renderer
:rtype: str
%End
2014-08-20 19:32:29 +07:00
bool isCheckable() const;
2017-06-06 11:03:05 +02:00
%Docstring
Return whether the item is user-checkable - whether renderer supports enabling/disabling it
:rtype: bool
%End
2014-08-20 19:32:29 +07:00
QgsSymbol *legacyRuleKey() const;
2017-06-06 11:03:05 +02:00
%Docstring
Used for older code that identifies legend entries from symbol pointer within renderer
:rtype: QgsSymbol
%End
2014-08-20 19:32:29 +07:00
bool isScaleOK( double scale ) const;
2017-06-06 11:03:05 +02:00
%Docstring
Determine whether given scale is within the scale range. Returns true if scale or scale range is invalid (value <= 0)
:rtype: bool
%End
2014-08-20 19:32:29 +07:00
int scaleMinDenom() const;
2017-06-06 11:03:05 +02:00
%Docstring
Value <= 0 means the range is unbounded on this side
:rtype: int
%End
2014-08-20 19:32:29 +07:00
int scaleMaxDenom() const;
2017-06-06 11:03:05 +02:00
%Docstring
Value <= 0 means the range is unbounded on this side
:rtype: int
%End
2014-08-20 19:32:29 +07:00
int level() const;
2017-06-06 11:03:05 +02:00
%Docstring
Identation level that tells how deep the item is in a hierarchy of items. For flat lists level is 0
:rtype: int
%End
QString parentRuleKey() const;
2017-06-06 11:03:05 +02:00
%Docstring
.. note::
Parameter parentRuleKey added in QGIS 2.8
:rtype: str
%End
void setSymbol( QgsSymbol *s /Transfer/ );
2017-06-06 11:03:05 +02:00
%Docstring
Set symbol of the item. Takes ownership of symbol.
%End
void setDataDefinedSizeLegendSettings( QgsDataDefinedSizeLegend *settings /Transfer/ );
%Docstring
Sets extra information about data-defined size. If set, this item should be converted to QgsDataDefinedSizeLegendNode
rather than QgsSymbolLegendNode instance as usual. Passing null removes any data-defined size legend settings.
Takes ownership of the settings object.
.. versionadded:: 3.0
%End
QgsDataDefinedSizeLegend *dataDefinedSizeLegendSettings() const;
%Docstring
Returns extra information for data-defined size legend rendering. Normally it returns null.
.. versionadded:: 3.0
:rtype: QgsDataDefinedSizeLegend
%End
2014-08-20 19:32:29 +07:00
};
typedef QList< QgsLegendSymbolItem > QgsLegendSymbolList;
2017-06-06 11:03:05 +02:00
/************************************************************************
* This file has been generated automatically from *
* *
* src/core/symbology-ng/qgslegendsymbolitem.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/