File: qgslegendpatchshapebutton.sip.in

package info (click to toggle)
qgis 3.40.10%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 1,183,672 kB
  • sloc: cpp: 1,595,771; python: 372,544; xml: 23,474; sh: 3,761; perl: 3,664; ansic: 2,257; sql: 2,137; yacc: 1,068; lex: 577; javascript: 540; lisp: 411; makefile: 161
file content (150 lines) | stat: -rw-r--r-- 3,984 bytes parent folder | download | duplicates (12)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
/************************************************************************
 * This file has been generated automatically from                      *
 *                                                                      *
 * src/gui/qgslegendpatchshapebutton.h                                  *
 *                                                                      *
 * Do not edit manually ! Edit header and run scripts/sipify.py again   *
 ************************************************************************/



class QgsLegendPatchShapeButton : QToolButton
{
%Docstring(signature="appended")
A button for creating and modifying :py:class:`QgsLegendPatchShape`
settings.

.. versionadded:: 3.14
%End

%TypeHeaderCode
#include "qgslegendpatchshapebutton.h"
%End
  public:
    QgsLegendPatchShapeButton( QWidget *parent /TransferThis/ = 0, const QString &dialogTitle = QString() );
%Docstring
Construct a new patch shape button with the specified ``parent`` widget.
Use ``dialogTitle`` string to define the title to show in the legend
patch shape widget.
%End
    ~QgsLegendPatchShapeButton();

    virtual QSize minimumSizeHint() const;

    virtual QSize sizeHint() const;


    void setSymbolType( Qgis::SymbolType type );
%Docstring
Sets the symbol ``type`` which the button requires. If the type differs
from the current symbol type, the symbol will be reset to a default
symbol style of the new type.

.. seealso:: :py:func:`symbolType`
%End

    Qgis::SymbolType symbolType() const;
%Docstring
Returns the symbol type which the button requires.

.. seealso:: :py:func:`setSymbolType`
%End

    void setPreviewSymbol( QgsSymbol *symbol /Transfer/ );
%Docstring
Sets the symbol to use for previewing the legend patch shape.

Ownership is transferred to the button. It is the caller's
responsibility to ensure that the symbol type matches the button's
:py:func:`~QgsLegendPatchShapeButton.symbolType`
%End

    void setDialogTitle( const QString &title );
%Docstring
Sets the ``title`` for the symbol settings dialog window.

.. seealso:: :py:func:`dialogTitle`
%End

    QString dialogTitle() const;
%Docstring
Returns the title for the symbol settings dialog window.

.. seealso:: :py:func:`setDialogTitle`
%End

    QgsLegendPatchShape shape();
%Docstring
Returns the current shape defined by the button.

.. seealso:: :py:func:`setShape`

.. seealso:: :py:func:`changed`
%End

    void setMessageBar( QgsMessageBar *bar );
%Docstring
Sets the message ``bar`` associated with the widget. This allows the
widget to push feedback messages to the appropriate message bar.

.. seealso:: :py:func:`messageBar`

.. versionadded:: 3.6
%End

    QgsMessageBar *messageBar() const;
%Docstring
Returns the message bar associated with the widget.

.. seealso:: :py:func:`setMessageBar`

.. versionadded:: 3.6
%End

  public slots:

    void setShape( const QgsLegendPatchShape &shape );
%Docstring
Sets the ``shape`` for the button.

.. seealso:: :py:func:`shape`

.. seealso:: :py:func:`changed`
%End

    void setToDefault();
%Docstring
Resets the shape to the default shape.
%End

  signals:

    void changed();
%Docstring
Emitted when the shape's settings are changed.

.. seealso:: :py:func:`shape`

.. seealso:: :py:func:`setShape`
%End

  protected:
    virtual void changeEvent( QEvent *e );

    virtual void showEvent( QShowEvent *e );

    virtual void resizeEvent( QResizeEvent *event );


    virtual void mousePressEvent( QMouseEvent *e );


};

/************************************************************************
 * This file has been generated automatically from                      *
 *                                                                      *
 * src/gui/qgslegendpatchshapebutton.h                                  *
 *                                                                      *
 * Do not edit manually ! Edit header and run scripts/sipify.py again   *
 ************************************************************************/