"Fossies" - the Fresh Open Source Software Archive

Member "mathmod-branches-r508-trunk/ui_modules/parametersoptions.h" (8 Mar 2021, 3778 Bytes) of package /linux/misc/mathmod-11.0-source.zip:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file. For more information about "parametersoptions.h" see the Fossies "Dox" file reference documentation and the latest Fossies "Diffs" side-by-side code changes report: 10.1_vs_11.0.

    1 /***************************************************************************
    2  *   Copyright (C) 2021 by Abderrahman Taha                                *
    3  *                                                                         *
    4  *                                                                         *
    5  *   This program is free software; you can redistribute it and/or modify  *
    6  *   it under the terms of the GNU General Public License as published by  *
    7  *   the Free Software Foundation; either version 2 of the License, or     *
    8  *   (at your option) any later version.                                   *
    9  *                                                                         *
   10  *   This program is distributed in the hope that it will be useful,       *
   11  *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
   12  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
   13  *   GNU General Public License for more details.                          *
   14  *                                                                         *
   15  *   You should have received a copy of the GNU General Public License     *
   16  *   along with this program; if not, write to the                         *
   17  *   Free Software Foundation, Inc.,                                       *
   18  *   51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA            *
   19  ***************************************************************************/
   20 
   21 #ifndef PARAMETERSOPTIONS_H
   22 #define PARAMETERSOPTIONS_H
   23 
   24 #include "../json_parser/parisodef.h"
   25 #include "ui_parametersoptions.h"
   26 #include <QFileDialog>
   27 #include <QJsonObject>
   28 #include <QMainWindow>
   29 #include <QMessageBox>
   30 #include <QStyleFactory>
   31 
   32 struct ListeModelTexture
   33 {
   34     QStringList listeModels;
   35     QStringList listeTextures;
   36     QStringList listePigments;
   37 };
   38 
   39 class Parametersoptions : public QWidget
   40 {
   41     Q_OBJECT
   42 
   43 public:
   44     Parametersoptions(QWidget *parent = nullptr);
   45     QString dotsymbol = ".";
   46     QString model = "CloseIso_2";
   47     QString filecollection = "mathmodcollection.js";
   48     QString fileconfig = "mathmodconfig.js";
   49     QString advancedmodels = "advancedmodels.js";
   50     QString fullpath;
   51     QJsonObject JConfig, Collection, IsoParam;
   52     QPalette mypalette, mypalette2, darkpalette;
   53     QApplication *MainApp;
   54     int ControlX = 20;
   55     int ControlY = 20;
   56     int GlwinX = 575;
   57     int GlwinY = 20;
   58     int ControlW = 538;
   59     int ControlH = 700;
   60     int GlwinW = 780;
   61     int GlwinH = 700;
   62     int Specular[4]={50,50,50,100};
   63     int Ambient[4]={50,50,50,100};
   64     int Diffuse[4]={80,80,80,100};
   65     int Shininess=110;
   66     int Threads[3]={8,1,64};
   67     int CalculFactor[3]={4,4,4};
   68     int IsoMaxGrid = 305;
   69     int ParMaxGrid = 505;
   70     int InitParGrid = 50;
   71     int InitIsoGrid = 40;
   72 public slots:
   73     void ReadConfigFile(QString, QJsonObject &);
   74     void ReadJsonFile(QString, QJsonObject &);
   75     void ReadCollectionFile(QString, QJsonObject &);
   76     void SetStyleAndTheme(QApplication &, QString, QString);
   77     void slot_about_clicked();
   78     void GuiUpdate();
   79     void maxisogri_valueChanged(int);
   80     void maxpargri_valueChanged(int);
   81     void on_loadconfig_clicked();
   82     void SaveToFile_CurentMathModel(QJsonObject CurrentJsonObject);
   83     void on_save_clicked();
   84     void LoadConfig(QApplication &, int argc, char *argv[]);
   85     ListeModelTexture LoadCollectionModels(QJsonObject &, jcollection &, int);
   86     bool isFloat(std::string);
   87     void on_comboBox_2_activated(const QString &);
   88     void on_comboBox_3_activated(const QString &);
   89     void on_comboBox_activated(const QString &);
   90     void onred_2valueChanged(int);
   91     void ongreen_2valueChanged(int);
   92     void onblue_2valueChanged(int);
   93     void on_TestConfig_clicked();
   94 
   95 public:
   96     Ui::Parametersoptions ui;
   97 };
   98 
   99 #endif