source: src/UIElements/TextUI/TextDialog.hpp@ d86d97

Action_Thermostats Adding_MD_integration_tests Adding_StructOpt_integration_tests AutomationFragmentation_failures Candidate_v1.6.1 ChemicalSpaceEvaluator Enhanced_StructuralOptimization Enhanced_StructuralOptimization_continued Exclude_Hydrogens_annealWithBondGraph Fix_Verbose_Codepatterns ForceAnnealing_with_BondGraph ForceAnnealing_with_BondGraph_continued ForceAnnealing_with_BondGraph_continued_betteresults ForceAnnealing_with_BondGraph_contraction-expansion Gui_displays_atomic_force_velocity JobMarket_RobustOnKillsSegFaults JobMarket_StableWorkerPool PythonUI_with_named_parameters Recreated_GuiChecks StoppableMakroAction TremoloParser_IncreasedPrecision
Last change on this file since d86d97 was 6af6470, checked in by Frederik Heber <frederik.heber@…>, 8 years ago

Removed Vector and Vectors from boost preprocessor magic.

  • this is preparatory for allowing to change the class Dialog::Query<Vector> by specialization and have the Vector stored as string and not directly as Vector.
  • Property mode set to 100644
File size: 2.4 KB
Line 
1/*
2 * TextDialog.hpp
3 *
4 * Created on: Jan 5, 2010
5 * Author: crueger
6 */
7
8#ifndef TEXTDIALOG_HPP_
9#define TEXTDIALOG_HPP_
10
11// include config.h
12#ifdef HAVE_CONFIG_H
13#include <config.h>
14#endif
15
16
17#include <string>
18
19#include "Dialog.hpp"
20
21class atom;
22class element;
23class molecule;
24class KeyValuePair;
25class RealSpaceMatrix;
26class Vector;
27
28class TextDialog : public Dialog
29{
30public:
31 TextDialog(const std::string &_title);
32 virtual ~TextDialog();
33
34 virtual void queryEmpty(const std::string ="", const std::string = "");
35
36 virtual void queryVector(Parameter<Vector> &, const std::string ="", const std::string = "");
37 virtual void queryVectors(Parameter< std::vector<Vector> > &, const std::string ="", const std::string = "");
38
39 /** With the following boost::preprocessor code we generate virtual function
40 * definitions for all desired query types in the abstract class Dialog.
41 */
42#include "UIElements/GlobalListOfParameterQueries.hpp"
43#include "UIElements/Dialog_impl_pre.hpp"
44
45 #include <boost/preprocessor/facilities/empty.hpp>
46
47 // iterate over all parameter query types
48 #if defined GLOBALLISTOFPARAMETERQUERIES_Token && defined GLOBALLISTOFPARAMETERQUERIES_Type
49 #define SUFFIX BOOST_PP_EMPTY()
50 #define BOOST_PP_LOCAL_MACRO(n) dialog_declaration(~, n, GLOBALLISTOFPARAMETERQUERIES_Token, GLOBALLISTOFPARAMETERQUERIES_Type)
51 #define BOOST_PP_LOCAL_LIMITS (0, MAXPARAMETERTOKENS-1)
52 #include BOOST_PP_LOCAL_ITERATE()
53 #undef dialog_declaration
54 #undef SUFFIX
55 #endif
56
57#include "Dialog_impl_undef.hpp"
58 /* End of preprocessor code piece */
59
60protected:
61
62 class EmptyTextQuery;
63
64 class VectorTextQuery;
65 class VectorsTextQuery;
66
67 /** With the following boost::preprocessor code we generate forward declarations
68 * of query class for all desired query types in the Qt specialization class of
69 * Dialog.
70 */
71#include "UIElements/GlobalListOfParameterQueries.hpp"
72#include "UIElements/Dialog_impl_pre.hpp"
73
74 #include <boost/preprocessor/facilities/empty.hpp>
75
76 // iterate over all parameter query types for forward declarations
77 #if defined GLOBALLISTOFPARAMETERQUERIES_Token && defined GLOBALLISTOFPARAMETERQUERIES_Type
78 #define BOOST_PP_LOCAL_MACRO(n) forward_declaration(~, n, GLOBALLISTOFPARAMETERQUERIES_Token, TextQuery)
79 #define BOOST_PP_LOCAL_LIMITS (0, MAXPARAMETERTOKENS-1)
80 #include BOOST_PP_LOCAL_ITERATE()
81 #undef forward_declaration
82 #endif
83
84#include "Dialog_impl_undef.hpp"
85 /* End of preprocessor code piece */
86
87};
88
89#endif /* TEXTDIALOG_HPP_ */
Note: See TracBrowser for help on using the repository browser.