2017-05-08 08:36:06 +02:00
|
|
|
/************************************************************************
|
|
|
|
* This file has been generated automatically from *
|
|
|
|
* *
|
|
|
|
* src/gui/editorwidgets/qgssearchwidgettoolbutton.h *
|
|
|
|
* *
|
|
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
|
|
************************************************************************/
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-11-03 17:47:03 +01:00
|
|
|
%ModuleHeaderCode
|
|
|
|
#include "qgssearchwidgettoolbutton.h"
|
|
|
|
%End
|
|
|
|
|
2016-05-17 14:16:17 +10:00
|
|
|
class QgsSearchWidgetToolButton : QToolButton
|
|
|
|
{
|
2017-05-08 08:36:06 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
A tool button widget which is displayed next to search widgets in forms, and
|
|
|
|
allows for controlling how the widget behaves and how the filtering/searching
|
|
|
|
operates.
|
|
|
|
|
2017-05-08 08:36:06 +02:00
|
|
|
.. versionadded:: 2.16
|
|
|
|
%End
|
|
|
|
|
2016-05-17 14:16:17 +10:00
|
|
|
%TypeHeaderCode
|
2017-05-08 08:36:06 +02:00
|
|
|
#include "qgssearchwidgettoolbutton.h"
|
2017-11-03 17:47:03 +01:00
|
|
|
%End
|
|
|
|
%ConvertToSubClassCode
|
|
|
|
if ( qobject_cast<QgsSearchWidgetToolButton *>( sipCpp ) )
|
|
|
|
sipType = sipType_QgsSearchWidgetToolButton;
|
|
|
|
else
|
|
|
|
sipType = nullptr;
|
2016-05-17 14:16:17 +10:00
|
|
|
%End
|
|
|
|
public:
|
|
|
|
|
2017-05-02 07:21:20 +02:00
|
|
|
explicit QgsSearchWidgetToolButton( QWidget *parent /TransferThis/ = 0 );
|
2017-05-08 08:36:06 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Constructor for QgsSearchWidgetToolButton.
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param parent: parent object
|
2017-05-08 08:36:06 +02:00
|
|
|
%End
|
2016-05-17 14:16:17 +10:00
|
|
|
|
|
|
|
void setAvailableFlags( QgsSearchWidgetWrapper::FilterFlags flags );
|
2017-05-08 08:36:06 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the available filter flags to show in the widget. Any active flags
|
|
|
|
(see activeFlags()) which are not present in the new available filter
|
|
|
|
flags will be cleared;
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param flags: available flags to show in widget
|
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`availableFlags`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`setActiveFlags`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`setDefaultFlags`
|
2017-05-08 08:36:06 +02:00
|
|
|
%End
|
2016-05-17 14:16:17 +10:00
|
|
|
|
2016-05-23 19:25:12 +10:00
|
|
|
void setDefaultFlags( QgsSearchWidgetWrapper::FilterFlags flags );
|
2017-05-08 08:36:06 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the default filter flags to show in the widget.
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param flags: default flags to show in widget
|
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`setAvailableFlags`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`setActiveFlags`
|
2017-05-08 08:36:06 +02:00
|
|
|
%End
|
2016-05-23 19:25:12 +10:00
|
|
|
|
2016-05-17 14:16:17 +10:00
|
|
|
QgsSearchWidgetWrapper::FilterFlags availableFlags() const;
|
2017-05-08 08:36:06 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the available filter flags shown in the widget.
|
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`setAvailableFlags`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`activeFlags`
|
2017-05-08 08:36:06 +02:00
|
|
|
%End
|
2016-05-17 14:16:17 +10:00
|
|
|
|
|
|
|
void setActiveFlags( QgsSearchWidgetWrapper::FilterFlags flags );
|
2017-05-08 08:36:06 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the current active filter flags for the widget. Any flags
|
|
|
|
which are not present in the available filter flags (see availableFlags())
|
|
|
|
will not be set.
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param flags: active flags to show in widget
|
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`toggleFlag`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`activeFlags`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`setAvailableFlags`
|
2017-05-08 08:36:06 +02:00
|
|
|
%End
|
2016-05-17 14:16:17 +10:00
|
|
|
|
|
|
|
void toggleFlag( QgsSearchWidgetWrapper::FilterFlag flag );
|
2017-05-08 08:36:06 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Toggles an individual active filter flag for the widget. Any flags
|
|
|
|
which are not present in the available filter flags (see availableFlags())
|
|
|
|
will be ignore. Other flags may be cleared if they conflict with the newly
|
|
|
|
toggled flag.
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param flag: flag to toggle
|
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`setActiveFlags`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`activeFlags`
|
2017-05-08 08:36:06 +02:00
|
|
|
%End
|
2016-05-17 14:16:17 +10:00
|
|
|
|
|
|
|
QgsSearchWidgetWrapper::FilterFlags activeFlags() const;
|
2017-05-08 08:36:06 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns the active filter flags shown in the widget.
|
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`setActiveFlags`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`toggleFlag`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`availableFlags`
|
2017-05-08 08:36:06 +02:00
|
|
|
%End
|
2016-05-17 14:16:17 +10:00
|
|
|
|
|
|
|
bool isActive() const;
|
2017-05-08 08:36:06 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Returns true if the widget is set to be included in the search.
|
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`setInactive`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`setActive`
|
2017-05-08 08:36:06 +02:00
|
|
|
%End
|
2016-05-17 14:16:17 +10:00
|
|
|
|
|
|
|
public slots:
|
|
|
|
|
|
|
|
void setInactive();
|
2017-05-08 08:36:06 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the search widget as inactive, ie do not search the corresponding field.
|
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`isActive`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`setActive`
|
2017-05-08 08:36:06 +02:00
|
|
|
%End
|
2016-05-17 14:16:17 +10:00
|
|
|
|
|
|
|
void setActive();
|
2017-05-08 08:36:06 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Sets the search widget as active by selecting the first available search type.
|
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`isActive`
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2018-01-09 17:26:37 -04:00
|
|
|
.. seealso:: :py:func:`setInactive`
|
2017-05-08 08:36:06 +02:00
|
|
|
%End
|
2016-05-17 14:16:17 +10:00
|
|
|
|
2016-05-23 19:25:12 +10:00
|
|
|
signals:
|
|
|
|
|
|
|
|
void activeFlagsChanged( QgsSearchWidgetWrapper::FilterFlags flags );
|
2017-05-08 08:36:06 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Emitted when the active flags selected in the widget is changed
|
2017-12-15 21:36:08 -04:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
:param flags: active flags
|
2017-05-08 08:36:06 +02:00
|
|
|
%End
|
2016-05-23 19:25:12 +10:00
|
|
|
|
2016-05-17 14:16:17 +10:00
|
|
|
};
|
2017-05-08 08:36:06 +02:00
|
|
|
|
|
|
|
/************************************************************************
|
|
|
|
* This file has been generated automatically from *
|
|
|
|
* *
|
|
|
|
* src/gui/editorwidgets/qgssearchwidgettoolbutton.h *
|
|
|
|
* *
|
|
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
|
|
************************************************************************/
|