COVISE Core
coColormapChoiceParam.h
Go to the documentation of this file.
1/* This file is part of COVISE.
2
3 You can use it under the terms of the GNU Lesser General Public License
4 version 2.1 or later, see lgpl-2.1.txt.
5
6 * License: LGPL 2+ */
7
8#ifndef _CO_COLORMAPCHOICE_PARAM_H_
9#define _CO_COLORMAPCHOICE_PARAM_H_
10
11// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
12// + +
13// + coColormapChoiceParam Parameter handling class +
14// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
15
16#include <covise/covise.h>
17#include <appl/CoviseBase.h>
18#include "coUifPara.h"
19
20namespace covise
21{
22
25{
26public:
28 coColormapChoiceParam(const char *name, const char *desc);
29
31 virtual ~coColormapChoiceParam();
32
34 virtual int isOfType(coUifPara::Typeinfo type);
35
37 static coUifPara::Typeinfo getType();
38
40 virtual int paramChange();
41
43 virtual void initialize();
44
46 virtual void print(ostream &str) const;
47
49 int setValue(int numChoices, int actChoice, TColormapChoice *list);
50
52 int setValue(int actChoice);
53
55 int getValue() const;
56
58 TColormapChoice getValue(int i) const;
59
61 const string getActLabel() const;
62
64 const string getLabel(int i) const;
65
67 int getNumChoices() const;
68
70 virtual const char *getTypeString() const;
71
73 virtual const char *getValString() const;
74
76 virtual void setValString(const char *str);
77
78private:
79 enum
80 {
81 MAX_CHOICE_LABELS = 256
82 };
83
86
89
92
95
100
101 // Parameter type name
102 static const char *s_type;
103};
104}
105#endif
#define APIEXPORT
Definition: coExport.h:275
GLuint const GLchar * name
Definition: khronos-glext.h:6722
GLenum type
Definition: khronos-glext.h:6279
list of all chemical elements
Definition: coConfig.h:27
std::enable_if< I==sizeof...(Tp), void >::type print(Stream &s, const std::tuple< Tp... > &t)
Definition: tokenbuffer_util.h:68
Definition: CoviseBase.h:53
parameter to choose values from a list
Definition: coColormapChoiceParam.h:25
static coUifPara::Typeinfo s_paraType
my type info
Definition: coColormapChoiceParam.h:94
coColormapChoiceParam & operator=(const coColormapChoiceParam &)
Assignment operator: NOT IMPLEMENTED.
coColormapChoiceParam()
Default constructor: NOT IMPLEMENTED.
int d_numChoices
Port data fields.
Definition: coColormapChoiceParam.h:97
coColormapChoiceParam(const coColormapChoiceParam &)
Copy-Constructor: NOT IMPLEMENTED.
TColormapChoice * colormaps
Definition: coColormapChoiceParam.h:99
static const char * s_type
Definition: coColormapChoiceParam.h:102
int d_activeChoice
Definition: coColormapChoiceParam.h:98
Definition: coUifPara.h:24
int Typeinfo
Definition: coUifPara.h:28