QGIS/python/gui/symbology-ng/qgssymbolselectordialog.sip

276 lines
6.3 KiB
Plaintext
Raw Normal View History

2017-06-08 15:30:38 +02:00
/************************************************************************
* This file has been generated automatically from *
* *
* src/gui/symbology-ng/qgssymbolselectordialog.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/
class QgsSymbolSelectorWidget: QgsPanelWidget
2016-06-13 18:07:39 +10:00
{
2017-06-08 15:30:38 +02:00
%Docstring
Symbol selector widget that cna be used to select and build a symbol
2016-06-13 18:07:39 +10:00
%End
2017-06-08 15:30:38 +02:00
%TypeHeaderCode
#include "qgssymbolselectordialog.h"
%End
2016-06-13 18:07:39 +10:00
public:
2017-06-08 15:30:38 +02:00
QgsSymbolSelectorWidget( QgsSymbol *symbol, QgsStyle *style, const QgsVectorLayer *vl, QWidget *parent /TransferThis/ = 0 );
%Docstring
Symbol selector widget that can be used to select and build a symbol
\param symbol The symbol to load into the widget as a start point.
\param style The style used by the widget.
\param vl The vector layer for the symbol.
\param parent
%End
QMenu *advancedMenu();
2017-06-08 15:30:38 +02:00
%Docstring
return menu for "advanced" button - create it if doesn't exist and show the advanced button
:rtype: QMenu
%End
2016-06-13 18:07:39 +10:00
void setContext( const QgsSymbolWidgetContext &context );
2017-06-08 15:30:38 +02:00
%Docstring
Sets the context in which the symbol widget is shown, e.g., the associated map canvas and expression contexts.
\param context symbol widget context
.. seealso:: context()
.. versionadded:: 3.0
%End
2016-09-12 13:51:14 +10:00
QgsSymbolWidgetContext context() const;
2017-06-08 15:30:38 +02:00
%Docstring
Returns the context in which the symbol widget is shown, e.g., the associated map canvas and expression contexts.
.. seealso:: setContext()
.. versionadded:: 3.0
:rtype: QgsSymbolWidgetContext
%End
2016-06-13 18:07:39 +10:00
QgsSymbol *symbol();
2017-06-08 15:30:38 +02:00
%Docstring
Return the symbol that is currently active in the widget. Can be null.
:return: The active symbol.
:rtype: QgsSymbol
%End
2016-06-13 18:07:39 +10:00
protected:
void loadSymbol();
2017-06-08 15:30:38 +02:00
%Docstring
Reload the current symbol in the view.
%End
2016-06-13 18:07:39 +10:00
void updateUi();
2017-06-08 15:30:38 +02:00
%Docstring
Update the state of the UI based on the currently set symbol layer.
%End
2016-06-13 18:07:39 +10:00
void updateLockButton();
2017-06-08 15:30:38 +02:00
%Docstring
Update the lock button states based on the current symbol layer.
%End
2016-06-13 18:07:39 +10:00
QgsSymbolLayer *currentLayer();
2017-06-08 15:30:38 +02:00
%Docstring
The current symbol layer that is active in the interface.
:return: The active symbol layer.
:rtype: QgsSymbolLayer
%End
2016-06-13 18:07:39 +10:00
void moveLayerByOffset( int offset );
2017-06-08 15:30:38 +02:00
%Docstring
Move the current active layer by a set offset in the list.
\param offset The offset to move the layer by
%End
2016-06-13 18:07:39 +10:00
void setWidget( QWidget *widget );
2017-06-08 15:30:38 +02:00
%Docstring
Set the properties widget for the active symbol layer.
\param widget The widget to set to configure the active symbol layer.
%End
2016-06-13 18:07:39 +10:00
signals:
2017-06-08 15:30:38 +02:00
2016-06-13 18:07:39 +10:00
void symbolModified();
2017-06-08 15:30:38 +02:00
%Docstring
Emiited when a symbol is modified in the widget.
%End
2016-06-13 18:07:39 +10:00
public slots:
2017-06-08 15:30:38 +02:00
2016-06-13 18:07:39 +10:00
void moveLayerDown();
2017-06-08 15:30:38 +02:00
%Docstring
Move the active symbol layer down.
%End
2016-06-13 18:07:39 +10:00
void moveLayerUp();
2017-06-08 15:30:38 +02:00
%Docstring
Move the active symbol layer up.
%End
2016-06-13 18:07:39 +10:00
void addLayer();
2017-06-08 15:30:38 +02:00
%Docstring
Add a symobl layer to the bottom of the stack.
%End
2016-06-13 18:07:39 +10:00
void removeLayer();
2017-06-08 15:30:38 +02:00
%Docstring
Remove the current active symbol layer.
%End
2016-06-13 18:07:39 +10:00
void lockLayer();
2017-06-08 15:30:38 +02:00
%Docstring
Lock the current active symbol layer.
%End
2016-06-13 18:07:39 +10:00
void duplicateLayer();
2017-06-08 15:30:38 +02:00
%Docstring
.. versionadded:: 2.14
%End
2016-06-13 18:07:39 +10:00
void layerChanged();
2017-06-08 15:30:38 +02:00
%Docstring
Called when the layer changes in the widget. Updates the active properties for
active symbol layer.
%End
2016-06-13 18:07:39 +10:00
void updateLayerPreview();
2017-06-08 15:30:38 +02:00
%Docstring
Update the single symbol layer preview in the widget.
%End
2016-06-13 18:07:39 +10:00
void updatePreview();
2017-06-08 15:30:38 +02:00
%Docstring
Update the preview of the whole symbol in the interface.
%End
2016-06-13 18:07:39 +10:00
void symbolChanged();
2017-06-08 15:30:38 +02:00
%Docstring
Slot to update tree when a new symbol from style
%End
void changeLayer( QgsSymbolLayer *layer );
2017-06-08 15:30:38 +02:00
%Docstring
\note: The layer is received from the LayerPropertiesWidget
%End
protected: // data
2016-06-13 18:07:39 +10:00
};
2016-08-05 08:09:43 +02:00
class QgsSymbolSelectorDialog : QDialog
{
2017-06-08 15:30:38 +02:00
%TypeHeaderCode
2017-06-08 15:30:38 +02:00
#include "qgssymbolselectordialog.h"
%End
public:
QgsSymbolSelectorDialog( QgsSymbol *symbol, QgsStyle *style, const QgsVectorLayer *vl, QWidget *parent /TransferThis/ = 0, bool embedded = false );
2017-06-08 15:30:38 +02:00
~QgsSymbolSelectorDialog();
QMenu *advancedMenu();
2017-06-08 15:30:38 +02:00
%Docstring
return menu for "advanced" button - create it if doesn't exist and show the advanced button
:rtype: QMenu
%End
void setContext( const QgsSymbolWidgetContext &context );
2017-06-08 15:30:38 +02:00
%Docstring
Sets the context in which the symbol widget is shown, e.g., the associated map canvas and expression contexts.
\param context symbol widget context
.. seealso:: context()
.. versionadded:: 3.0
%End
2016-09-12 13:51:14 +10:00
QgsSymbolWidgetContext context() const;
2017-06-08 15:30:38 +02:00
%Docstring
Returns the context in which the symbol widget is shown, e.g., the associated map canvas and expression contexts.
.. seealso:: setContext()
.. versionadded:: 3.0
:rtype: QgsSymbolWidgetContext
%End
QgsSymbol *symbol();
2017-06-08 15:30:38 +02:00
%Docstring
Return the symbol that is currently active in the widget. Can be null.
:return: The active symbol.
:rtype: QgsSymbol
%End
protected:
2017-06-08 15:30:38 +02:00
virtual void keyPressEvent( QKeyEvent *e );
void loadSymbol();
2017-06-08 15:30:38 +02:00
void updateUi();
void updateLockButton();
QgsSymbolLayer *currentLayer();
2017-06-08 15:30:38 +02:00
%Docstring
:rtype: QgsSymbolLayer
%End
void moveLayerByOffset( int offset );
void setWidget( QWidget *widget );
signals:
void symbolModified();
public slots:
void moveLayerDown();
void moveLayerUp();
void addLayer();
void removeLayer();
void lockLayer();
void duplicateLayer();
2017-06-08 15:30:38 +02:00
%Docstring
.. versionadded:: 2.14
%End
void layerChanged();
void updateLayerPreview();
void updatePreview();
void symbolChanged();
2017-06-08 15:30:38 +02:00
%Docstring
Slot to update tree when a new symbol from style
%End
void changeLayer( QgsSymbolLayer *layer );
2017-06-08 15:30:38 +02:00
%Docstring
\note: The layer is received from the LayerPropertiesWidget
%End
};
2017-06-08 15:30:38 +02:00
/************************************************************************
* This file has been generated automatically from *
* *
* src/gui/symbology-ng/qgssymbolselectordialog.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/