File: qgsdecoratedscrollbar.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 (154 lines) | stat: -rw-r--r-- 3,791 bytes parent folder | download | duplicates (6)
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
151
152
153
154
/************************************************************************
 * This file has been generated automatically from                      *
 *                                                                      *
 * src/gui/qgsdecoratedscrollbar.h                                      *
 *                                                                      *
 * Do not edit manually ! Edit header and run scripts/sipify.py again   *
 ************************************************************************/






class QgsScrollBarHighlight
{
%Docstring(signature="appended")
Encapsulates the details of a highlight in a scrollbar, used alongside
:py:class:`QgsScrollBarHighlightController`.

.. versionadded:: 3.38
%End

%TypeHeaderCode
#include "qgsdecoratedscrollbar.h"
%End
  public:
    enum class Priority /BaseType=IntEnum/
    {
      Invalid,
      LowPriority,
      NormalPriority,
      HighPriority,
      HighestPriority
    };

    QgsScrollBarHighlight( int category, int position, const QColor &color, QgsScrollBarHighlight::Priority priority = QgsScrollBarHighlight::Priority::NormalPriority );
%Docstring
Constructor for QgsScrollBarHighlight.
%End

    QgsScrollBarHighlight();

    int category;

    int position;

    QColor color;

    QgsScrollBarHighlight::Priority priority;
};

class QgsScrollBarHighlightController
{
%Docstring(signature="appended")
Adds highlights (colored markers) to a scrollbar.

.. versionadded:: 3.38
%End

%TypeHeaderCode
#include "qgsdecoratedscrollbar.h"
%End
  public:
    QgsScrollBarHighlightController();
    ~QgsScrollBarHighlightController();

    QScrollBar *scrollBar() const;
%Docstring
Returns the associated scroll bar.
%End

    QAbstractScrollArea *scrollArea() const;
%Docstring
Returns the associated scroll area.

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

    void setScrollArea( QAbstractScrollArea *scrollArea );
%Docstring
Sets the associated scroll bar.

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

    double lineHeight() const;
%Docstring
Returns the line height for text associated with the scroll area.

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

    void setLineHeight( double height );
%Docstring
Sets the line ``height`` for text associated with the scroll area.

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

    double visibleRange() const;
%Docstring
Returns the visible range of the scroll area (i.e. the viewport's
height).

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

    void setVisibleRange( double visibleRange );
%Docstring
Sets the visible range of the scroll area (i.e. the viewport's height).

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

    double margin() const;
%Docstring
Returns the document margins for the associated viewport.

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

    void setMargin( double margin );
%Docstring
Sets the document ``margin`` for the associated viewport.

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


    void addHighlight( const QgsScrollBarHighlight &highlight );
%Docstring
Adds a ``highlight`` to the scrollbar.
%End

    void removeHighlights( int category );
%Docstring
Removes all highlights with matching ``category`` from the scrollbar.
%End

    void removeAllHighlights();
%Docstring
Removes all highlights from the scroll bar.
%End

};


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