QGIS API Documentation 4.1.0-Master (3b8ef1f72a3)
Loading...
Searching...
No Matches
qgsaddtaborgroup.h
Go to the documentation of this file.
1/***************************************************************************
2 qgsaddtaborgroup.h
3 Add a tab or a group for the tab and group display of fields
4 -------------------
5 begin : 2012-07-30
6 copyright : (C) 2012 by Denis Rouzaud
7 email : denis dot rouzaud at gmail dot com
8***************************************************************************/
9
10/***************************************************************************
11 * *
12 * This program is free software; you can redistribute it and/or modify *
13 * it under the terms of the GNU General Public License as published by *
14 * the Free Software Foundation; either version 2 of the License, or *
15 * (at your option) any later version. *
16 * *
17 ***************************************************************************/
18
19#ifndef QGSADDTABORGROUP
20#define QGSADDTABORGROUP
21
22// We don't want to expose this in the public API
23
24#include "ui_qgsaddtaborgroupbase.h"
25
26#include "qgis_gui.h"
27#include "qgsguiutils.h"
28
29#define SIP_NO_FILE
30
31class QgsVectorLayer;
33
41class GUI_EXPORT QgsAddAttributeFormContainerDialog : public QDialog, private Ui::QgsAddTabOrGroupBase
42{
43 Q_OBJECT
44
45 public:
46 typedef QPair<QString, QModelIndex> ContainerPair;
47
48 public:
50 QgsAddAttributeFormContainerDialog( QgsVectorLayer *layer, const QList<ContainerPair> &existingContainerList, QModelIndex &currentItemIndex, QWidget *parent = nullptr );
51
53 QString name();
54
61 QModelIndex parentContainerItem() const;
62
64 int columnCount() const;
65
72
74 void accept() override;
75
76 private slots:
77 void showHelp();
78 void containerTypeChanged();
79
80 protected:
82 QList<ContainerPair> mExistingContainers;
83
84 public:
89};
90
91#endif
AttributeEditorContainerType
Attribute editor container types.
Definition qgis.h:5925
QPair< QString, QModelIndex > ContainerPair
QModelIndex parentContainerItem() const
Returns tree model index corresponding to the selected parent container.
QgsAddAttributeFormContainerDialog(QgsVectorLayer *layer, const QList< ContainerPair > &existingContainerList, QModelIndex &currentItemIndex, QWidget *parent=nullptr)
constructor
Qgis::AttributeEditorContainerType containerType() const
Returns the container type.
QString name()
Returns the name of the container.
void accept() override
Accepts the dialog.
static const QgsSettingsEntryInteger * settingsDefaultGroupColumnCount
Settings entry for the default column count for group box containers.
static const QgsSettingsEntryInteger * settingsDefaultTabColumnCount
Settings entry for the default column count for tab containers.
int columnCount() const
Returns the column count.
QList< ContainerPair > mExistingContainers
An integer settings entry.
Represents a vector layer which manages a vector based dataset.