ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
doublespinboxdelegate.h
Go to the documentation of this file.
1 // ----------------------------------------------------------------------------
2 // - CloudViewer: www.cloudViewer.org -
3 // ----------------------------------------------------------------------------
4 // Copyright (c) 2018-2024 www.cloudViewer.org
5 // SPDX-License-Identifier: MIT
6 // ----------------------------------------------------------------------------
7 
8 #pragma once
9 
10 #include <QStyledItemDelegate>
11 
12 #include "qPCL.h"
13 
14 namespace VtkUtils {
15 
16 class QPCL_ENGINE_LIB_API DoubleSpinBoxDelegate : public QStyledItemDelegate {
17  Q_OBJECT
18 
19 public:
20  DoubleSpinBoxDelegate(QObject *parent = 0);
21 
22  QWidget *createEditor(QWidget *parent,
23  const QStyleOptionViewItem &option,
24  const QModelIndex &index) const Q_DECL_OVERRIDE;
25 
26  void setEditorData(QWidget *editor,
27  const QModelIndex &index) const Q_DECL_OVERRIDE;
28  void setModelData(QWidget *editor,
29  QAbstractItemModel *model,
30  const QModelIndex &index) const Q_DECL_OVERRIDE;
31 
32  void updateEditorGeometry(QWidget *editor,
33  const QStyleOptionViewItem &option,
34  const QModelIndex &index) const Q_DECL_OVERRIDE;
35 };
36 
37 } // namespace VtkUtils
#define Q_DECL_OVERRIDE
Definition: qcustomplot.h:130
#define QPCL_ENGINE_LIB_API
Definition: qPCL.h:15