1 /**************************************************************************** 2 * MeshLab o o * 3 * A versatile mesh processing toolbox o o * 4 * _ O _ * 5 * Copyright(C) 2005 \/)\/ * 6 * Visual Computing Lab /\/| * 7 * ISTI - Italian National Research Council | * 8 * \ * 9 * All rights reserved. * 10 * * 11 * This program is free software; you can redistribute it and/or modify * 12 * it under the terms of the GNU General Public License as published by * 13 * the Free Software Foundation; either version 2 of the License, or * 14 * (at your option) any later version. * 15 * * 16 * This program is distributed in the hope that it will be useful, * 17 * but WITHOUT ANY WARRANTY; without even the implied warranty of * 18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * 19 * GNU General Public License (http://www.gnu.org/licenses/gpl.txt) * 20 * for more details. * 21 * * 22 ****************************************************************************/ 23 24 25 #include <QDialog> 26 #include <QDockWidget> 27 #include <QColorDialog> 28 #include "common/filterparameter.h" 29 #include "stdpardialog.h" 30 31 32 class SettingDialog : public QDialog 33 { 34 Q_OBJECT 35 public: 36 SettingDialog(RichParameter* curPar,RichParameter* defPar,QWidget* parent = 0); 37 ~SettingDialog(); 38 public slots: 39 void save(); 40 void reset(); 41 void apply(); 42 void load(); 43 44 signals: 45 void applySettingSignal(); 46 47 private: 48 StdParFrame frame; 49 RichParameter* curPar; 50 RichParameter* defPar; 51 RichParameter* tmppar; 52 RichParameterSet tmpParSet; 53 QPushButton* savebut; 54 QPushButton* applybut; 55 QPushButton* resetbut; 56 QPushButton* closebut; 57 QPushButton* loadbut; 58 }; 59 60 class CustomDialog : public QDialog 61 { 62 Q_OBJECT 63 public: 64 CustomDialog(RichParameterSet& parset,RichParameterSet& defparset,QWidget *parent = 0); 65 ~CustomDialog(); 66 //void loadCurrentSetting(RichParameterSet& parset); 67 68 public slots: 69 void openSubDialog(QTableWidgetItem* itm); 70 void updateSettings(); 71 signals: 72 void applyCustomSetting(); 73 74 private: 75 RichParameterSet& curParSet; 76 RichParameterSet& defParSet; 77 QTableWidget* tw; 78 QVector<RichParameter*> vrp; 79 void dispatch(const RichParameter& par); 80 QPushButton* closebut; 81 }; 82