Computer Assisted Medical Intervention Tool Kit  version 5.2
qtpropertymanager.h
Go to the documentation of this file.
1 /****************************************************************************
2 **
3 ** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
4 ** All rights reserved.
5 **
6 ** Contact: Nokia Corporation (qt-info@nokia.com)
7 **
8 ** This file is part of a Qt Solutions component.
9 **
10 ** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
11 ** Contact: http://www.qt-project.org/legal
12 **
13 ** This file is part of the Qt Solutions component.
14 **
15 ** You may use this file under the terms of the BSD license as follows:
16 **
17 ** "Redistribution and use in source and binary forms, with or without
18 ** modification, are permitted provided that the following conditions are
19 ** met:
20 ** * Redistributions of source code must retain the above copyright
21 ** notice, this list of conditions and the following disclaimer.
22 ** * Redistributions in binary form must reproduce the above copyright
23 ** notice, this list of conditions and the following disclaimer in
24 ** the documentation and/or other materials provided with the
25 ** distribution.
26 ** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
27 ** the names of its contributors may be used to endorse or promote
28 ** products derived from this software without specific prior written
29 ** permission.
30 ** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
31 ** of its contributors may be used to endorse or promote products derived
32 ** from this software without specific prior written permission.
33 **
34 ** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
35 ** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
36 ** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
37 ** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
38 ** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
39 ** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
40 ** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
41 ** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
42 ** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
43 ** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
44 ** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
45 **
46 ****************************************************************************/
47 
48 
49 #ifndef QTPROPERTYMANAGER_H
50 #define QTPROPERTYMANAGER_H
51 
52 #include "qtpropertybrowser.h"
53 #include <QPushButton>
54 #include <QLineEdit>
55 
56 #if QT_VERSION >= 0x040400
57 QT_BEGIN_NAMESPACE
58 #endif
59 
60 class QDate;
61 class QTime;
62 class QDateTime;
63 class QLocale;
64 class QRegularExpression;
65 
74  Q_OBJECT
75 public:
76  QtGroupPropertyManager(QObject* parent = nullptr);
77 
81  ~QtGroupPropertyManager() override = default;
82 
83 protected:
84  bool hasValue(const QtProperty* property) const override;
85 
86  void initializeProperty(QtProperty* property) override;
87  void uninitializeProperty(QtProperty* property) override;
88 };
89 
91 
93  Q_OBJECT
94 public:
95  QtIntPropertyManager(QObject* parent = nullptr);
96  ~QtIntPropertyManager() override;
97 
98  int value(const QtProperty* property) const;
99  int minimum(const QtProperty* property) const;
100  int maximum(const QtProperty* property) const;
101  int singleStep(const QtProperty* property) const;
102  bool isReadOnly(const QtProperty* property) const;
103 
104 public Q_SLOTS:
105  void setValue(QtProperty* property, int val);
106  void setMinimum(QtProperty* property, int minVal);
107  void setMaximum(QtProperty* property, int maxVal);
108  void setRange(QtProperty* property, int minVal, int maxVal);
109  void setSingleStep(QtProperty* property, int step);
110  void setReadOnly(QtProperty* property, bool readOnly);
111 Q_SIGNALS:
112  void valueChanged(QtProperty* property, int val);
113  void rangeChanged(QtProperty* property, int minVal, int maxVal);
114  void singleStepChanged(QtProperty* property, int step);
115  void readOnlyChanged(QtProperty* property, bool readOnly);
116 protected:
117  QString valueText(const QtProperty* property) const override;
118  void initializeProperty(QtProperty* property) override;
119  void uninitializeProperty(QtProperty* property) override;
120 private:
122  Q_DECLARE_PRIVATE(QtIntPropertyManager)
123 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
124  Q_DISABLE_COPY_MOVE(QtIntPropertyManager)
125 #else
126  Q_DISABLE_COPY(QtIntPropertyManager)
127 #endif
128 };
129 
131 
133  Q_OBJECT
134 public:
135  QtBoolPropertyManager(QObject* parent = nullptr);
136  ~QtBoolPropertyManager() override;
137 
138  bool value(const QtProperty* property) const;
139  bool textVisible(const QtProperty* property) const;
140 
141 public Q_SLOTS:
142  void setValue(QtProperty* property, bool val);
143  void setTextVisible(QtProperty* property, bool textVisible);
144 Q_SIGNALS:
145  void valueChanged(QtProperty* property, bool val);
146  void textVisibleChanged(QtProperty* property, bool);
147 protected:
148  QString valueText(const QtProperty* property) const override;
149  QIcon valueIcon(const QtProperty* property) const override;
150  void initializeProperty(QtProperty* property) override;
151  void uninitializeProperty(QtProperty* property) override;
152 private:
154  Q_DECLARE_PRIVATE(QtBoolPropertyManager)
155 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
156  Q_DISABLE_COPY_MOVE(QtBoolPropertyManager)
157 #else
158  Q_DISABLE_COPY(QtBoolPropertyManager)
159 #endif
160 };
161 
163 
165  Q_OBJECT
166 public:
167  QtDoublePropertyManager(QObject* parent = nullptr);
168  ~QtDoublePropertyManager() override;
169 
170  double value(const QtProperty* property) const;
171  double minimum(const QtProperty* property) const;
172  double maximum(const QtProperty* property) const;
173  double singleStep(const QtProperty* property) const;
174  int decimals(const QtProperty* property) const;
175  bool isReadOnly(const QtProperty* property) const;
176 
177 public Q_SLOTS:
178  void setValue(QtProperty* property, double val);
179  void setMinimum(QtProperty* property, double minVal);
180  void setMaximum(QtProperty* property, double maxVal);
181  void setRange(QtProperty* property, double minVal, double maxVal);
182  void setSingleStep(QtProperty* property, double step);
183  void setDecimals(QtProperty* property, int prec);
184  void setReadOnly(QtProperty* property, bool readOnly);
185 Q_SIGNALS:
186  void valueChanged(QtProperty* property, double val);
187  void rangeChanged(QtProperty* property, double minVal, double maxVal);
188  void singleStepChanged(QtProperty* property, double step);
189  void decimalsChanged(QtProperty* property, int prec);
190  void readOnlyChanged(QtProperty* property, bool readOnly);
191 protected:
192  QString valueText(const QtProperty* property) const override;
193  void initializeProperty(QtProperty* property) override;
194  void uninitializeProperty(QtProperty* property) override;
195 private:
197  Q_DECLARE_PRIVATE(QtDoublePropertyManager)
198 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
199  Q_DISABLE_COPY_MOVE(QtDoublePropertyManager)
200 #else
201  Q_DISABLE_COPY(QtDoublePropertyManager)
202 #endif
203 };
204 
206 
208  Q_OBJECT
209 public:
210  QtStringPropertyManager(QObject* parent = nullptr);
211  ~QtStringPropertyManager() override;
212 
213  QString value(const QtProperty* property) const;
214  QRegularExpression regExp(const QtProperty* property) const;
215  EchoMode echoMode(const QtProperty* property) const override;
216  bool isReadOnly(const QtProperty* property) const;
217 
218 public Q_SLOTS:
219  void setValue(QtProperty* property, const QString& val);
220  void setRegExp(QtProperty* property, const QRegularExpression& regExp);
221  void setEchoMode(QtProperty* property, EchoMode echoMode);
222  void setReadOnly(QtProperty* property, bool readOnly);
223 Q_SIGNALS:
224  void valueChanged(QtProperty* property, const QString& val);
225  void regExpChanged(QtProperty* property, const QRegularExpression& regExp);
226  void echoModeChanged(QtProperty* property, const int);
227  void readOnlyChanged(QtProperty* property, bool);
228 protected:
229  QString valueText(const QtProperty* property) const override;
230  QString displayText(const QtProperty* property) const override;
231  void initializeProperty(QtProperty* property) override;
232  void uninitializeProperty(QtProperty* property) override;
233 private:
235  Q_DECLARE_PRIVATE(QtStringPropertyManager)
236 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
237  Q_DISABLE_COPY_MOVE(QtStringPropertyManager)
238 #else
239  Q_DISABLE_COPY(QtStringPropertyManager)
240 #endif
241 };
242 
244 
246  Q_OBJECT
247 public:
248  QtDatePropertyManager(QObject* parent = nullptr);
249  ~QtDatePropertyManager() override;
250 
251  QDate value(const QtProperty* property) const;
252  QDate minimum(const QtProperty* property) const;
253  QDate maximum(const QtProperty* property) const;
254 
255 public Q_SLOTS:
256  void setValue(QtProperty* property, const QDate& val);
257  void setMinimum(QtProperty* property, const QDate& minVal);
258  void setMaximum(QtProperty* property, const QDate& maxVal);
259  void setRange(QtProperty* property, const QDate& minVal, const QDate& maxVal);
260 Q_SIGNALS:
261  void valueChanged(QtProperty* property, const QDate& val);
262  void rangeChanged(QtProperty* property, const QDate& minVal, const QDate& maxVal);
263 protected:
264  QString valueText(const QtProperty* property) const override;
265  void initializeProperty(QtProperty* property) override;
266  void uninitializeProperty(QtProperty* property) override;
267 private:
269  Q_DECLARE_PRIVATE(QtDatePropertyManager)
270 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
271  Q_DISABLE_COPY_MOVE(QtDatePropertyManager)
272 #else
273  Q_DISABLE_COPY(QtDatePropertyManager)
274 #endif
275 };
276 
278 
280  Q_OBJECT
281 public:
282  QtTimePropertyManager(QObject* parent = nullptr);
283  ~QtTimePropertyManager() override;
284 
285  QTime value(const QtProperty* property) const;
286 
287 public Q_SLOTS:
288  void setValue(QtProperty* property, const QTime& val);
289 Q_SIGNALS:
290  void valueChanged(QtProperty* property, const QTime& val);
291 protected:
292  QString valueText(const QtProperty* property) const override;
293  void initializeProperty(QtProperty* property) override;
294  void uninitializeProperty(QtProperty* property) override;
295 private:
297  Q_DECLARE_PRIVATE(QtTimePropertyManager)
298 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
299  Q_DISABLE_COPY_MOVE(QtTimePropertyManager)
300 #else
301  Q_DISABLE_COPY(QtTimePropertyManager)
302 #endif
303 };
304 
306 
308  Q_OBJECT
309 public:
310  QtDateTimePropertyManager(QObject* parent = nullptr);
311  ~QtDateTimePropertyManager() override;
312 
313  QDateTime value(const QtProperty* property) const;
314 
315 public Q_SLOTS:
316  void setValue(QtProperty* property, const QDateTime& val);
317 Q_SIGNALS:
318  void valueChanged(QtProperty* property, const QDateTime& val);
319 protected:
320  QString valueText(const QtProperty* property) const override;
321  void initializeProperty(QtProperty* property) override;
322  void uninitializeProperty(QtProperty* property) override;
323 private:
325  Q_DECLARE_PRIVATE(QtDateTimePropertyManager)
326 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
327  Q_DISABLE_COPY_MOVE(QtDateTimePropertyManager)
328 #else
329  Q_DISABLE_COPY(QtDateTimePropertyManager)
330 #endif
331 };
332 
334 
336  Q_OBJECT
337 public:
338  QtKeySequencePropertyManager(QObject* parent = nullptr);
339  ~QtKeySequencePropertyManager() override;
340 
341  QKeySequence value(const QtProperty* property) const;
342 
343 public Q_SLOTS:
344  void setValue(QtProperty* property, const QKeySequence& val);
345 Q_SIGNALS:
346  void valueChanged(QtProperty* property, const QKeySequence& val);
347 protected:
348  QString valueText(const QtProperty* property) const override;
349  void initializeProperty(QtProperty* property) override;
350  void uninitializeProperty(QtProperty* property) override;
351 private:
353  Q_DECLARE_PRIVATE(QtKeySequencePropertyManager)
354 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
355  Q_DISABLE_COPY_MOVE(QtKeySequencePropertyManager)
356 #else
357  Q_DISABLE_COPY(QtKeySequencePropertyManager)
358 #endif
359 };
360 
362 
364  Q_OBJECT
365 public:
366  QtCharPropertyManager(QObject* parent = nullptr);
367  ~QtCharPropertyManager() override;
368 
369  QChar value(const QtProperty* property) const;
370 
371 public Q_SLOTS:
372  void setValue(QtProperty* property, const QChar& val);
373 Q_SIGNALS:
374  void valueChanged(QtProperty* property, const QChar& val);
375 protected:
376  QString valueText(const QtProperty* property) const override;
377  void initializeProperty(QtProperty* property) override;
378  void uninitializeProperty(QtProperty* property) override;
379 private:
381  Q_DECLARE_PRIVATE(QtCharPropertyManager)
382 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
383  Q_DISABLE_COPY_MOVE(QtCharPropertyManager)
384 #else
385  Q_DISABLE_COPY(QtCharPropertyManager)
386 #endif
387 };
388 
391 
393  Q_OBJECT
394 public:
395  QtLocalePropertyManager(QObject* parent = nullptr);
396  ~QtLocalePropertyManager() override;
397 
398  QtEnumPropertyManager* subEnumPropertyManager() const;
399 
400  QLocale value(const QtProperty* property) const;
401 
402 public Q_SLOTS:
403  void setValue(QtProperty* property, const QLocale& val);
404 Q_SIGNALS:
405  void valueChanged(QtProperty* property, const QLocale& val);
406 protected:
407  QString valueText(const QtProperty* property) const override;
408  void initializeProperty(QtProperty* property) override;
409  void uninitializeProperty(QtProperty* property) override;
410 private:
412  Q_DECLARE_PRIVATE(QtLocalePropertyManager)
413 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
414  Q_DISABLE_COPY_MOVE(QtLocalePropertyManager)
415 #else
416  Q_DISABLE_COPY(QtLocalePropertyManager)
417 #endif
418  Q_PRIVATE_SLOT(d_func(), void slotEnumChanged(QtProperty*, int))
419  Q_PRIVATE_SLOT(d_func(), void slotPropertyDestroyed(QtProperty*))
420 };
421 
423 
425  Q_OBJECT
426 public:
427  QtPointPropertyManager(QObject* parent = nullptr);
428  ~QtPointPropertyManager() override;
429 
430  QtIntPropertyManager* subIntPropertyManager() const;
431 
432  QPoint value(const QtProperty* property) const;
433 
434 public Q_SLOTS:
435  void setValue(QtProperty* property, const QPoint& val);
436 Q_SIGNALS:
437  void valueChanged(QtProperty* property, const QPoint& val);
438 protected:
439  QString valueText(const QtProperty* property) const override;
440  void initializeProperty(QtProperty* property) override;
441  void uninitializeProperty(QtProperty* property) override;
442 private:
444  Q_DECLARE_PRIVATE(QtPointPropertyManager)
445 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
446  Q_DISABLE_COPY_MOVE(QtPointPropertyManager)
447 #else
448  Q_DISABLE_COPY(QtPointPropertyManager)
449 #endif
450  Q_PRIVATE_SLOT(d_func(), void slotIntChanged(QtProperty*, int))
451  Q_PRIVATE_SLOT(d_func(), void slotPropertyDestroyed(QtProperty*))
452 };
453 
455 
457  Q_OBJECT
458 public:
459  QtPointFPropertyManager(QObject* parent = nullptr);
460  ~QtPointFPropertyManager() override;
461 
462  QtDoublePropertyManager* subDoublePropertyManager() const;
463 
464  QPointF value(const QtProperty* property) const;
465  int decimals(const QtProperty* property) const;
466 
467 public Q_SLOTS:
468  void setValue(QtProperty* property, const QPointF& val);
469  void setDecimals(QtProperty* property, int prec);
470 Q_SIGNALS:
471  void valueChanged(QtProperty* property, const QPointF& val);
472  void decimalsChanged(QtProperty* property, int prec);
473 protected:
474  QString valueText(const QtProperty* property) const override;
475  void initializeProperty(QtProperty* property) override;
476  void uninitializeProperty(QtProperty* property) override;
477 private:
479  Q_DECLARE_PRIVATE(QtPointFPropertyManager)
480 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
481  Q_DISABLE_COPY_MOVE(QtPointFPropertyManager)
482 #else
483  Q_DISABLE_COPY(QtPointFPropertyManager)
484 #endif
485  Q_PRIVATE_SLOT(d_func(), void slotDoubleChanged(QtProperty*, double))
486  Q_PRIVATE_SLOT(d_func(), void slotPropertyDestroyed(QtProperty*))
487 };
488 
490 
492  Q_OBJECT
493 public:
494  QtSizePropertyManager(QObject* parent = nullptr);
495  ~QtSizePropertyManager() override;
496 
497  QtIntPropertyManager* subIntPropertyManager() const;
498 
499  QSize value(const QtProperty* property) const;
500  QSize minimum(const QtProperty* property) const;
501  QSize maximum(const QtProperty* property) const;
502 
503 public Q_SLOTS:
504  void setValue(QtProperty* property, const QSize& val);
505  void setMinimum(QtProperty* property, const QSize& minVal);
506  void setMaximum(QtProperty* property, const QSize& maxVal);
507  void setRange(QtProperty* property, const QSize& minVal, const QSize& maxVal);
508 Q_SIGNALS:
509  void valueChanged(QtProperty* property, const QSize& val);
510  void rangeChanged(QtProperty* property, const QSize& minVal, const QSize& maxVal);
511 protected:
512  QString valueText(const QtProperty* property) const override;
513  void initializeProperty(QtProperty* property) override;
514  void uninitializeProperty(QtProperty* property) override;
515 private:
517  Q_DECLARE_PRIVATE(QtSizePropertyManager)
518 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
519  Q_DISABLE_COPY_MOVE(QtSizePropertyManager)
520 #else
521  Q_DISABLE_COPY(QtSizePropertyManager)
522 #endif
523  Q_PRIVATE_SLOT(d_func(), void slotIntChanged(QtProperty*, int))
524  Q_PRIVATE_SLOT(d_func(), void slotPropertyDestroyed(QtProperty*))
525 };
526 
528 
530  Q_OBJECT
531 public:
532  QtSizeFPropertyManager(QObject* parent = nullptr);
533  ~QtSizeFPropertyManager() override;
534 
535  QtDoublePropertyManager* subDoublePropertyManager() const;
536 
537  QSizeF value(const QtProperty* property) const;
538  QSizeF minimum(const QtProperty* property) const;
539  QSizeF maximum(const QtProperty* property) const;
540  int decimals(const QtProperty* property) const;
541 
542 public Q_SLOTS:
543  void setValue(QtProperty* property, const QSizeF& val);
544  void setMinimum(QtProperty* property, const QSizeF& minVal);
545  void setMaximum(QtProperty* property, const QSizeF& maxVal);
546  void setRange(QtProperty* property, const QSizeF& minVal, const QSizeF& maxVal);
547  void setDecimals(QtProperty* property, int prec);
548 Q_SIGNALS:
549  void valueChanged(QtProperty* property, const QSizeF& val);
550  void rangeChanged(QtProperty* property, const QSizeF& minVal, const QSizeF& maxVal);
551  void decimalsChanged(QtProperty* property, int prec);
552 protected:
553  QString valueText(const QtProperty* property) const override;
554  void initializeProperty(QtProperty* property) override;
555  void uninitializeProperty(QtProperty* property) override;
556 private:
558  Q_DECLARE_PRIVATE(QtSizeFPropertyManager)
559 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
560  Q_DISABLE_COPY_MOVE(QtSizeFPropertyManager)
561 #else
562  Q_DISABLE_COPY(QtSizeFPropertyManager)
563 #endif
564  Q_PRIVATE_SLOT(d_func(), void slotDoubleChanged(QtProperty*, double))
565  Q_PRIVATE_SLOT(d_func(), void slotPropertyDestroyed(QtProperty*))
566 };
567 
569 
571  Q_OBJECT
572 public:
573  QtRectPropertyManager(QObject* parent = nullptr);
574  ~QtRectPropertyManager() override;
575 
576  QtIntPropertyManager* subIntPropertyManager() const;
577 
578  QRect value(const QtProperty* property) const;
579  QRect constraint(const QtProperty* property) const;
580 
581 public Q_SLOTS:
582  void setValue(QtProperty* property, const QRect& val);
583  void setConstraint(QtProperty* property, const QRect& constraint);
584 Q_SIGNALS:
585  void valueChanged(QtProperty* property, const QRect& val);
586  void constraintChanged(QtProperty* property, const QRect& constraint);
587 protected:
588  QString valueText(const QtProperty* property) const override;
589  void initializeProperty(QtProperty* property) override;
590  void uninitializeProperty(QtProperty* property) override;
591 private:
593  Q_DECLARE_PRIVATE(QtRectPropertyManager)
594 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
595  Q_DISABLE_COPY_MOVE(QtRectPropertyManager)
596 #else
597  Q_DISABLE_COPY(QtRectPropertyManager)
598 #endif
599  Q_PRIVATE_SLOT(d_func(), void slotIntChanged(QtProperty*, int))
600  Q_PRIVATE_SLOT(d_func(), void slotPropertyDestroyed(QtProperty*))
601 };
602 
604 
606  Q_OBJECT
607 public:
608  QtRectFPropertyManager(QObject* parent = nullptr);
609  ~QtRectFPropertyManager() override;
610 
611  QtDoublePropertyManager* subDoublePropertyManager() const;
612 
613  QRectF value(const QtProperty* property) const;
614  QRectF constraint(const QtProperty* property) const;
615  int decimals(const QtProperty* property) const;
616 
617 public Q_SLOTS:
618  void setValue(QtProperty* property, const QRectF& val);
619  void setConstraint(QtProperty* property, const QRectF& constraint);
620  void setDecimals(QtProperty* property, int prec);
621 Q_SIGNALS:
622  void valueChanged(QtProperty* property, const QRectF& val);
623  void constraintChanged(QtProperty* property, const QRectF& constraint);
624  void decimalsChanged(QtProperty* property, int prec);
625 protected:
626  QString valueText(const QtProperty* property) const override;
627  void initializeProperty(QtProperty* property) override;
628  void uninitializeProperty(QtProperty* property) override;
629 private:
631  Q_DECLARE_PRIVATE(QtRectFPropertyManager)
632 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
633  Q_DISABLE_COPY_MOVE(QtRectFPropertyManager)
634 #else
635  Q_DISABLE_COPY(QtRectFPropertyManager)
636 #endif
637  Q_PRIVATE_SLOT(d_func(), void slotDoubleChanged(QtProperty*, double))
638  Q_PRIVATE_SLOT(d_func(), void slotPropertyDestroyed(QtProperty*))
639 };
640 
641 
643 class QVector3D;
644 
646  Q_OBJECT
647 public:
648  QtVector3DPropertyManager(QObject* parent = nullptr);
649  ~QtVector3DPropertyManager() override;
650 
651  QtDoublePropertyManager* subDoublePropertyManager() const;
652 
653  QVector3D value(const QtProperty* property) const;
654  int decimals(const QtProperty* property) const;
655 
656 public Q_SLOTS:
657  void setValue(QtProperty* property, const QVector3D& val);
658  void setDecimals(QtProperty* property, int prec);
659 Q_SIGNALS:
660  void valueChanged(QtProperty* property, const QVector3D& val);
661  void decimalsChanged(QtProperty* property, int prec);
662 protected:
663  QString valueText(const QtProperty* property) const override;
664  void initializeProperty(QtProperty* property) override;
665  void uninitializeProperty(QtProperty* property) override;
666 private:
668  Q_DECLARE_PRIVATE(QtVector3DPropertyManager)
669 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
670  Q_DISABLE_COPY_MOVE(QtVector3DPropertyManager)
671 #else
672  Q_DISABLE_COPY(QtVector3DPropertyManager)
673 #endif
674  Q_PRIVATE_SLOT(d_func(), void slotDoubleChanged(QtProperty*, double))
675  Q_PRIVATE_SLOT(d_func(), void slotPropertyDestroyed(QtProperty*))
676 };
677 
679 
681  Q_OBJECT
682 public:
683  QtEnumPropertyManager(QObject* parent = nullptr);
684  ~QtEnumPropertyManager() override;
685 
686  int value(const QtProperty* property) const;
687  QStringList enumNames(const QtProperty* property) const;
688  QMap<int, QIcon> enumIcons(const QtProperty* property) const;
689 
690 public Q_SLOTS:
691  void setValue(QtProperty* property, int val);
692  void setEnumNames(QtProperty* property, const QStringList& names);
693  void setEnumIcons(QtProperty* property, const QMap<int, QIcon>& icons);
694 Q_SIGNALS:
695  void valueChanged(QtProperty* property, int val);
696  void enumNamesChanged(QtProperty* property, const QStringList& names);
697  void enumIconsChanged(QtProperty* property, const QMap<int, QIcon>& icons);
698 protected:
699  QString valueText(const QtProperty* property) const override;
700  QIcon valueIcon(const QtProperty* property) const override;
701  void initializeProperty(QtProperty* property) override;
702  void uninitializeProperty(QtProperty* property) override;
703 private:
705  Q_DECLARE_PRIVATE(QtEnumPropertyManager)
706 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
707  Q_DISABLE_COPY_MOVE(QtEnumPropertyManager)
708 #else
709  Q_DISABLE_COPY(QtEnumPropertyManager)
710 #endif
711 };
712 
714 
716  Q_OBJECT
717 public:
718  QtFlagPropertyManager(QObject* parent = nullptr);
719  ~QtFlagPropertyManager() override;
720 
721  QtBoolPropertyManager* subBoolPropertyManager() const;
722 
723  int value(const QtProperty* property) const;
724  QStringList flagNames(const QtProperty* property) const;
725 
726 public Q_SLOTS:
727  void setValue(QtProperty* property, int val);
728  void setFlagNames(QtProperty* property, const QStringList& names);
729 Q_SIGNALS:
730  void valueChanged(QtProperty* property, int val);
731  void flagNamesChanged(QtProperty* property, const QStringList& names);
732 protected:
733  QString valueText(const QtProperty* property) const override;
734  void initializeProperty(QtProperty* property) override;
735  void uninitializeProperty(QtProperty* property) override;
736 private:
738  Q_DECLARE_PRIVATE(QtFlagPropertyManager)
739 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
740  Q_DISABLE_COPY_MOVE(QtFlagPropertyManager)
741 #else
742  Q_DISABLE_COPY(QtFlagPropertyManager)
743 #endif
744  Q_PRIVATE_SLOT(d_func(), void slotBoolChanged(QtProperty*, bool))
745  Q_PRIVATE_SLOT(d_func(), void slotPropertyDestroyed(QtProperty*))
746 };
747 
749 
751  Q_OBJECT
752 public:
753  QtSizePolicyPropertyManager(QObject* parent = nullptr);
754  ~QtSizePolicyPropertyManager() override;
755 
756  QtIntPropertyManager* subIntPropertyManager() const;
757  QtEnumPropertyManager* subEnumPropertyManager() const;
758 
759  QSizePolicy value(const QtProperty* property) const;
760 
761 public Q_SLOTS:
762  void setValue(QtProperty* property, const QSizePolicy& val);
763 Q_SIGNALS:
764  void valueChanged(QtProperty* property, const QSizePolicy& val);
765 protected:
766  QString valueText(const QtProperty* property) const override;
767  void initializeProperty(QtProperty* property) override;
768  void uninitializeProperty(QtProperty* property) override;
769 private:
771  Q_DECLARE_PRIVATE(QtSizePolicyPropertyManager)
772 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
773  Q_DISABLE_COPY_MOVE(QtSizePolicyPropertyManager)
774 #else
775  Q_DISABLE_COPY(QtSizePolicyPropertyManager)
776 #endif
777  Q_PRIVATE_SLOT(d_func(), void slotIntChanged(QtProperty*, int))
778  Q_PRIVATE_SLOT(d_func(), void slotEnumChanged(QtProperty*, int))
779  Q_PRIVATE_SLOT(d_func(), void slotPropertyDestroyed(QtProperty*))
780 };
781 
783 
785  Q_OBJECT
786 public:
787  QtFontPropertyManager(QObject* parent = nullptr);
788  ~QtFontPropertyManager() override;
789 
790  QtIntPropertyManager* subIntPropertyManager() const;
791  QtEnumPropertyManager* subEnumPropertyManager() const;
792  QtBoolPropertyManager* subBoolPropertyManager() const;
793 
794  QFont value(const QtProperty* property) const;
795 
796 public Q_SLOTS:
797  void setValue(QtProperty* property, const QFont& val);
798 Q_SIGNALS:
799  void valueChanged(QtProperty* property, const QFont& val);
800 protected:
801  QString valueText(const QtProperty* property) const override;
802  QIcon valueIcon(const QtProperty* property) const override;
803  void initializeProperty(QtProperty* property) override;
804  void uninitializeProperty(QtProperty* property) override;
805 private:
807  Q_DECLARE_PRIVATE(QtFontPropertyManager)
808 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
809  Q_DISABLE_COPY_MOVE(QtFontPropertyManager)
810 #else
811  Q_DISABLE_COPY(QtFontPropertyManager)
812 #endif
813  Q_PRIVATE_SLOT(d_func(), void slotIntChanged(QtProperty*, int))
814  Q_PRIVATE_SLOT(d_func(), void slotEnumChanged(QtProperty*, int))
815  Q_PRIVATE_SLOT(d_func(), void slotBoolChanged(QtProperty*, bool))
816  Q_PRIVATE_SLOT(d_func(), void slotPropertyDestroyed(QtProperty*))
817  Q_PRIVATE_SLOT(d_func(), void slotFontDatabaseChanged())
818  Q_PRIVATE_SLOT(d_func(), void slotFontDatabaseDelayedChange())
819 };
820 
822 
824  Q_OBJECT
825 public:
826  QtColorPropertyManager(QObject* parent = nullptr);
827  ~QtColorPropertyManager() override;
828 
829  QtIntPropertyManager* subIntPropertyManager() const;
830 
831  QColor value(const QtProperty* property) const;
832 
833 public Q_SLOTS:
834  void setValue(QtProperty* property, const QColor& val);
835 Q_SIGNALS:
836  void valueChanged(QtProperty* property, const QColor& val);
837 protected:
838  QString valueText(const QtProperty* property) const override;
839  QIcon valueIcon(const QtProperty* property) const override;
840  void initializeProperty(QtProperty* property) override;
841  void uninitializeProperty(QtProperty* property) override;
842 private:
844  Q_DECLARE_PRIVATE(QtColorPropertyManager)
845 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
846  Q_DISABLE_COPY_MOVE(QtColorPropertyManager)
847 #else
848  Q_DISABLE_COPY(QtColorPropertyManager)
849 #endif
850  Q_PRIVATE_SLOT(d_func(), void slotIntChanged(QtProperty*, int))
851  Q_PRIVATE_SLOT(d_func(), void slotPropertyDestroyed(QtProperty*))
852 };
853 
855 
857  Q_OBJECT
858 public:
859  QtCursorPropertyManager(QObject* parent = nullptr);
860  ~QtCursorPropertyManager() override;
861 
862 #ifndef QT_NO_CURSOR
863  QCursor value(const QtProperty* property) const;
864 #endif
865 
866 public Q_SLOTS:
867  void setValue(QtProperty* property, const QCursor& val);
868 Q_SIGNALS:
869  void valueChanged(QtProperty* property, const QCursor& val);
870 protected:
871  QString valueText(const QtProperty* property) const override;
872  QIcon valueIcon(const QtProperty* property) const override;
873  void initializeProperty(QtProperty* property) override;
874  void uninitializeProperty(QtProperty* property) override;
875 private:
877  Q_DECLARE_PRIVATE(QtCursorPropertyManager)
878 #if QT_VERSION >= QT_VERSION_CHECK(5, 13, 0)
879  Q_DISABLE_COPY_MOVE(QtCursorPropertyManager)
880 #else
881  Q_DISABLE_COPY(QtCursorPropertyManager)
882 #endif
883 };
884 
885 #if QT_VERSION >= 0x040400
886 QT_END_NAMESPACE
887 #endif
888 
889 #endif
The QtAbstractPropertyManager provides an interface for property managers.
Definition: qtpropertybrowser.h:153
virtual EchoMode echoMode(const QtProperty *) const
Definition: qtpropertybrowser.cpp:735
virtual QString displayText(const QtProperty *property) const
Definition: qtpropertybrowser.cpp:722
virtual QIcon valueIcon(const QtProperty *property) const
Definition: qtpropertybrowser.cpp:694
virtual void initializeProperty(QtProperty *property)=0
virtual bool hasValue(const QtProperty *property) const
Definition: qtpropertybrowser.cpp:680
virtual QString valueText(const QtProperty *property) const
Definition: qtpropertybrowser.cpp:708
virtual void uninitializeProperty(QtProperty *property)
Definition: qtpropertybrowser.cpp:799
Definition: qtpropertymanager.cpp:1624
The QtBoolPropertyManager class provides and manages boolean properties.
Definition: qtpropertymanager.h:132
void valueChanged(QtProperty *property, bool val)
void textVisibleChanged(QtProperty *property, bool)
Definition: qtpropertymanager.cpp:2347
The QtCharPropertyManager provides and manages QChar properties.
Definition: qtpropertymanager.h:363
void valueChanged(QtProperty *property, const QChar &val)
Definition: qtpropertymanager.cpp:6457
The QtColorPropertyManager provides and manages QColor properties.
Definition: qtpropertymanager.h:823
void valueChanged(QtProperty *property, const QColor &val)
Definition: qtpropertymanager.cpp:6756
The QtCursorPropertyManager provides and manages QCursor properties.
Definition: qtpropertymanager.h:856
void valueChanged(QtProperty *property, const QCursor &val)
Definition: qtpropertymanager.cpp:1801
The QtDatePropertyManager provides and manages QDate properties.
Definition: qtpropertymanager.h:245
void rangeChanged(QtProperty *property, const QDate &minVal, const QDate &maxVal)
void valueChanged(QtProperty *property, const QDate &val)
Definition: qtpropertymanager.cpp:2137
The QtDateTimePropertyManager provides and manages QDateTime properties.
Definition: qtpropertymanager.h:307
void valueChanged(QtProperty *property, const QDateTime &val)
Definition: qtpropertymanager.cpp:937
The QtDoublePropertyManager provides and manages double properties.
Definition: qtpropertymanager.h:164
void readOnlyChanged(QtProperty *property, bool readOnly)
void valueChanged(QtProperty *property, double val)
void singleStepChanged(QtProperty *property, double step)
void decimalsChanged(QtProperty *property, int prec)
void rangeChanged(QtProperty *property, double minVal, double maxVal)
Definition: qtpropertymanager.cpp:5072
The QtEnumPropertyManager provides and manages enum properties.
Definition: qtpropertymanager.h:680
void enumIconsChanged(QtProperty *property, const QMap< int, QIcon > &icons)
void enumNamesChanged(QtProperty *property, const QStringList &names)
void valueChanged(QtProperty *property, int val)
Definition: qtpropertymanager.cpp:5340
The QtFlagPropertyManager provides and manages flag properties.
Definition: qtpropertymanager.h:715
void flagNamesChanged(QtProperty *property, const QStringList &names)
void valueChanged(QtProperty *property, int val)
Definition: qtpropertymanager.cpp:5981
The QtFontPropertyManager provides and manages QFont properties.
Definition: qtpropertymanager.h:784
void valueChanged(QtProperty *property, const QFont &val)
The description of this class will come soon !
Definition: qtpropertymanager.h:73
~QtGroupPropertyManager() override=default
Definition: qtpropertymanager.cpp:640
The QtIntPropertyManager provides and manages int properties.
Definition: qtpropertymanager.h:92
bool isReadOnly(const QtProperty *property) const
void rangeChanged(QtProperty *property, int minVal, int maxVal)
void singleStepChanged(QtProperty *property, int step)
void valueChanged(QtProperty *property, int val)
void readOnlyChanged(QtProperty *property, bool readOnly)
Definition: qtpropertymanager.cpp:2244
The QtKeySequencePropertyManager provides and manages QKeySequence properties.
Definition: qtpropertymanager.h:335
void valueChanged(QtProperty *property, const QKeySequence &val)
Definition: qtpropertymanager.cpp:2449
The QtLocalePropertyManager provides and manages QLocale properties.
Definition: qtpropertymanager.h:392
void valueChanged(QtProperty *property, const QLocale &val)
Definition: qtpropertymanager.cpp:2894
The QtPointFPropertyManager provides and manages QPointF properties.
Definition: qtpropertymanager.h:456
void valueChanged(QtProperty *property, const QPointF &val)
void decimalsChanged(QtProperty *property, int prec)
Definition: qtpropertymanager.cpp:2688
The QtPointPropertyManager provides and manages QPoint properties.
Definition: qtpropertymanager.h:424
void valueChanged(QtProperty *property, const QPoint &val)
The QtProperty class encapsulates an instance of a property.
Definition: qtpropertybrowser.h:113
Definition: qtpropertymanager.cpp:4307
The QtRectFPropertyManager provides and manages QRectF properties.
Definition: qtpropertymanager.h:605
void constraintChanged(QtProperty *property, const QRectF &constraint)
void decimalsChanged(QtProperty *property, int prec)
void valueChanged(QtProperty *property, const QRectF &val)
Definition: qtpropertymanager.cpp:3895
The QtRectPropertyManager provides and manages QRect properties.
Definition: qtpropertymanager.h:570
void constraintChanged(QtProperty *property, const QRect &constraint)
void valueChanged(QtProperty *property, const QRect &val)
Definition: qtpropertymanager.cpp:3501
The QtSizeFPropertyManager provides and manages QSizeF properties.
Definition: qtpropertymanager.h:529
void valueChanged(QtProperty *property, const QSizeF &val)
void rangeChanged(QtProperty *property, const QSizeF &minVal, const QSizeF &maxVal)
void decimalsChanged(QtProperty *property, int prec)
Definition: qtpropertymanager.cpp:5665
The QtSizePolicyPropertyManager provides and manages QSizePolicy properties.
Definition: qtpropertymanager.h:750
void valueChanged(QtProperty *property, const QSizePolicy &val)
Definition: qtpropertymanager.cpp:3165
The QtSizePropertyManager provides and manages QSize properties.
Definition: qtpropertymanager.h:491
void valueChanged(QtProperty *property, const QSize &val)
void rangeChanged(QtProperty *property, const QSize &minVal, const QSize &maxVal)
Definition: qtpropertymanager.cpp:1303
The QtStringPropertyManager provides and manages QString properties.
Definition: qtpropertymanager.h:207
void readOnlyChanged(QtProperty *property, bool)
void valueChanged(QtProperty *property, const QString &val)
void echoModeChanged(QtProperty *property, const int)
void regExpChanged(QtProperty *property, const QRegularExpression &regExp)
Definition: qtpropertymanager.cpp:2028
The QtTimePropertyManager provides and manages QTime properties.
Definition: qtpropertymanager.h:279
void valueChanged(QtProperty *property, const QTime &val)
Definition: qtpropertymanager.cpp:4783
The QtVector3DPropertyManager provides and manages QVector3D properties.
Definition: qtpropertymanager.h:645
void valueChanged(QtProperty *property, const QVector3D &val)
void decimalsChanged(QtProperty *property, int prec)
#define QT_QTPROPERTYBROWSER_EXPORT
Definition: qtpropertybrowser.h:59
QLineEdit::EchoMode EchoMode
Definition: qtpropertybrowser.h:62