itom
Loading...
Searching...
No Matches
paramStringWidget.h
1/* ********************************************************************
2 itom software
3 URL: http://www.uni-stuttgart.de/ito
4 Copyright (C) 2020, Institut für Technische Optik (ITO),
5 Universität Stuttgart, Germany
6
7 This file is part of itom and its software development toolkit (SDK).
8
9 itom is free software; you can redistribute it and/or modify it
10 under the terms of the GNU Library General Public Licence as published by
11 the Free Software Foundation; either version 2 of the Licence, or (at
12 your option) any later version.
13
14 In addition, as a special exception, the Institut für Technische
15 Optik (ITO) gives you certain additional rights.
16 These rights are described in the ITO LGPL Exception version 1.0,
17 which can be found in the file LGPL_EXCEPTION.txt in this package.
18
19 itom is distributed in the hope that it will be useful, but
20 WITHOUT ANY WARRANTY; without even the implied warranty of
21 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library
22 General Public Licence for more details.
23
24 You should have received a copy of the GNU Library General Public License
25 along with itom. If not, see <http://www.gnu.org/licenses/>.
26
27*********************************************************************** */
28
29#ifndef PARAMSTRINGWIDGET_H
30#define PARAMSTRINGWIDGET_H
31
32#include <QWidget>
33
34#include "common/param.h"
35
36#include "commonWidgets.h"
37
38namespace ito
39{
40
41class ParamStringWidgetPrivate; // forward declare
42
43class ITOMWIDGETS_EXPORT ParamStringWidget : public QWidget
44{
45 Q_OBJECT
46
47public:
48 explicit ParamStringWidget(QWidget *parent = 0);
49 virtual ~ParamStringWidget();
50
51 ito::Param param() const;
52 QByteArray value() const;
53 ito::StringMeta meta() const;
54
55Q_SIGNALS:
56 void valueChanged(const QByteArray &value);
57
58public Q_SLOTS:
59 void setParam(const ito::Param &param, bool forceValueChanged = false);
60 void setValue(const QByteArray &value);
61 void setMeta(const ito::StringMeta &meta);
62
63protected:
64 QScopedPointer<ParamStringWidgetPrivate> d_ptr; // QScopedPointer to forward declared class
65
66private:
67 Q_DECLARE_PRIVATE(ParamStringWidget);
68 Q_DISABLE_COPY(ParamStringWidget);
69
70 Q_PRIVATE_SLOT(d_func(), void slotValueChanged(QString))
71 Q_PRIVATE_SLOT(d_func(), void slotEditingFinished())
72};
73
74} //end namespace ito
75
76#endif // PARAMINTWIDGET_H
class for parameter handling e.g. to pass parameters to plugins
Definition param.h:477
Definition paramStringWidget.h:44
Meta-information for Param of type String.
Definition paramMeta.h:527
Definition apiFunctionsGraph.cpp:40
PyObject * setParam(ito::AddInBase *addInObj, PyObject *args)
Definition pythonPlugins.cpp:1249