mirror of
https://github.com/qgis/QGIS.git
synced 2025-10-16 00:05:45 -04:00
164 lines
4.5 KiB
Plaintext
164 lines
4.5 KiB
Plaintext
/************************************************************************
|
|
* This file has been generated automatically from *
|
|
* *
|
|
* src/gui/symbology/qgscategorizedsymbolrendererwidget.h *
|
|
* *
|
|
* Do not edit manually ! Edit header and run scripts/sipify.py again *
|
|
************************************************************************/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class QgsCategorizedSymbolRendererWidget : QgsRendererWidget
|
|
{
|
|
%Docstring(signature="appended")
|
|
A widget for configuring a :py:class:`QgsCategorizedSymbolRenderer`.
|
|
%End
|
|
|
|
%TypeHeaderCode
|
|
#include "qgscategorizedsymbolrendererwidget.h"
|
|
%End
|
|
public:
|
|
|
|
enum class CustomRole /BaseType=IntEnum/
|
|
{
|
|
Value
|
|
};
|
|
|
|
static QgsRendererWidget *create( QgsVectorLayer *layer, QgsStyle *style, QgsFeatureRenderer *renderer ) /Factory/;
|
|
|
|
QgsCategorizedSymbolRendererWidget( QgsVectorLayer *layer, QgsStyle *style, QgsFeatureRenderer *renderer );
|
|
~QgsCategorizedSymbolRendererWidget();
|
|
|
|
virtual QgsFeatureRenderer *renderer();
|
|
|
|
virtual void setContext( const QgsSymbolWidgetContext &context );
|
|
|
|
virtual QgsExpressionContext createExpressionContext() const;
|
|
|
|
|
|
int matchToSymbols( QgsStyle *style );
|
|
%Docstring
|
|
Replaces category symbols with the symbols from a style that have a matching
|
|
name.
|
|
|
|
:param style: style containing symbols to match with
|
|
|
|
:return: number of symbols matched
|
|
|
|
.. seealso:: :py:func:`matchToSymbolsFromLibrary`
|
|
|
|
.. seealso:: :py:func:`matchToSymbolsFromXml`
|
|
%End
|
|
|
|
public slots:
|
|
void changeCategorizedSymbol();
|
|
void categoryColumnChanged( const QString &field );
|
|
void categoriesDoubleClicked( const QModelIndex &idx );
|
|
void addCategory();
|
|
void addCategories();
|
|
|
|
void applyColorRamp();
|
|
%Docstring
|
|
Applies the color ramp passed on by the color ramp button
|
|
%End
|
|
|
|
void deleteCategories();
|
|
void deleteAllCategories();
|
|
|
|
void deleteUnusedCategories();
|
|
%Docstring
|
|
Deletes unused categories from the widget which are not used by the layer renderer.
|
|
%End
|
|
|
|
void showSymbolLevels();
|
|
|
|
void rowsMoved();
|
|
|
|
void matchToSymbolsFromLibrary();
|
|
%Docstring
|
|
Replaces category symbols with the symbols from the users' symbol library that have a
|
|
matching name.
|
|
|
|
.. seealso:: :py:func:`matchToSymbolsFromXml`
|
|
|
|
.. seealso:: :py:func:`matchToSymbols`
|
|
%End
|
|
|
|
void matchToSymbolsFromXml();
|
|
%Docstring
|
|
Prompts for selection of an xml file, then replaces category symbols with the symbols
|
|
from the XML file with a matching name.
|
|
|
|
.. seealso:: :py:func:`matchToSymbolsFromLibrary`
|
|
|
|
.. seealso:: :py:func:`matchToSymbols`
|
|
%End
|
|
|
|
protected:
|
|
virtual void setSymbolLevels( const QgsLegendSymbolList &levels, bool enabled );
|
|
|
|
|
|
protected slots:
|
|
|
|
virtual void pasteSymbolToSelection();
|
|
|
|
|
|
protected:
|
|
void updateUiFromRenderer();
|
|
|
|
void populateCategories();
|
|
|
|
int currentCategoryRow();
|
|
%Docstring
|
|
Returns row index for the currently selected category (-1 if on no selection)
|
|
%End
|
|
|
|
QList<int> selectedCategories();
|
|
%Docstring
|
|
Returns a list of indexes for the categories under selection
|
|
%End
|
|
|
|
void changeSelectedSymbols();
|
|
%Docstring
|
|
Changes the selected symbols alone for the change button, if there is a selection
|
|
%End
|
|
|
|
void changeCategorySymbol();
|
|
void applyChangeToSymbol();
|
|
%Docstring
|
|
Applies current symbol to selected categories, or to all categories if none is selected
|
|
%End
|
|
|
|
QList<QVariant> layerUniqueValues( const QString &attrName );
|
|
%Docstring
|
|
Returns the list of unique values in the current widget's layer for attribute name ``attrName``.
|
|
|
|
Called by :py:func:`~QgsCategorizedSymbolRendererWidget.addCategories` and :py:func:`~QgsCategorizedSymbolRendererWidget.deleteUnusedCategories`
|
|
%End
|
|
|
|
virtual QList<QgsSymbol *> selectedSymbols();
|
|
|
|
QgsCategoryList selectedCategoryList();
|
|
virtual void refreshSymbolView();
|
|
|
|
virtual void keyPressEvent( QKeyEvent *event );
|
|
|
|
|
|
protected:
|
|
|
|
|
|
|
|
};
|
|
|
|
/************************************************************************
|
|
* This file has been generated automatically from *
|
|
* *
|
|
* src/gui/symbology/qgscategorizedsymbolrendererwidget.h *
|
|
* *
|
|
* Do not edit manually ! Edit header and run scripts/sipify.py again *
|
|
************************************************************************/
|