QGIS API Documentation
4.3.0-Master (52aa6503bed)
Toggle main menu visibility
Loading...
Searching...
No Matches
src
gui
vector
qgsattributesformtreeviewitemdelegate.h
Go to the documentation of this file.
1
/***************************************************************************
2
qgsattributesformtreeviewitemdelegate.h
3
---------------------
4
begin : June 2025
5
copyright : (C) 2025 by Germán Carrillo
6
email : german at opengis dot ch
7
***************************************************************************
8
* *
9
* This program is free software; you can redistribute it and/or modify *
10
* it under the terms of the GNU General Public License as published by *
11
* the Free Software Foundation; either version 2 of the License, or *
12
* (at your option) any later version. *
13
* *
14
***************************************************************************/
15
16
#ifndef QGSATTRIBUTESFORMTREEVIEWITEMDELEGATE_H
17
#define QGSATTRIBUTESFORMTREEVIEWITEMDELEGATE_H
18
19
// We don't want to expose this in the public API
20
22
23
#include "
qgsproxystyle.h
"
24
25
#define SIP_NO_FILE
26
27
class
QgsAttributesFormTreeViewIndicator
;
28
class
QgsAttributesFormBaseView
;
29
30
#include <QStyledItemDelegate>
31
38
class
QgsAttributesFormTreeViewProxyStyle :
public
QgsProxyStyle
39
{
40
Q_OBJECT
41
42
public
:
46
explicit
QgsAttributesFormTreeViewProxyStyle( QgsAttributesFormBaseView *treeView );
47
48
QRect subElementRect( SubElement element,
const
QStyleOption *option,
const
QWidget *widget )
const override
;
49
50
static
const
auto
SE_AttributesFormTreeItemIndicator = SE_CustomBase + 1;
51
52
private
:
53
QgsAttributesFormBaseView *mAttributesFormTreeView;
54
};
55
56
63
class
QgsAttributesFormTreeViewItemDelegate :
public
QStyledItemDelegate
64
{
65
Q_OBJECT
66
public
:
70
explicit
QgsAttributesFormTreeViewItemDelegate( QgsAttributesFormBaseView *parent );
71
72
void
paint( QPainter *painter,
const
QStyleOptionViewItem &option,
const
QModelIndex &index )
const override
;
73
74
bool
helpEvent( QHelpEvent *event, QAbstractItemView *view,
const
QStyleOptionViewItem &option,
const
QModelIndex &index )
override
;
75
76
private
:
77
QgsAttributesFormBaseView *mAttributesFormTreeView;
78
};
79
81
82
#endif
// QGSATTRIBUTESFORMTREEVIEWITEMDELEGATE_H
QgsAttributesFormBaseView
Graphical representation for the attribute drag and drop editor.
Definition
qgsattributesformview.h:38
QgsAttributesFormTreeViewIndicator
Indicator that can be used in an Attributes Form tree view to display icons next to field items.
Definition
qgsattributesformtreeviewindicator.h:38
QgsProxyStyle
A QProxyStyle subclass which correctly sets the base style to match the QGIS application style,...
Definition
qgsproxystyle.h:32
qgsproxystyle.h
Generated on
for QGIS API Documentation by
1.17.0