GeoGen Development snapshot a3
|
00001 /* 00002 00003 This file is part of GeoGen. 00004 00005 GeoGen is free software: you can redistribute it and/or modify 00006 it under the terms of the GNU General Public License as published by 00007 the Free Software Foundation, either version 2 of the License, or 00008 (at your option) any later version. 00009 00010 GeoGen is distributed in the hope that it will be useful, 00011 but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00013 GNU General Public License for more details. 00014 00015 You should have received a copy of the GNU General Public License 00016 along with GeoGen. If not, see <http://www.gnu.org/licenses/>. 00017 00018 */ 00019 00024 #pragma once 00025 00026 /* Hide the "wstring needs to have dll-interface to be used by clients of class 'GGen_ScriptArg'" */ 00027 #pragma warning(disable: 4251) 00028 00029 #include <vector> 00030 #include "ggen_support.h" 00031 00032 class GGEN_EXPORT GGen_ScriptArg{ 00033 public: 00034 int value; 00035 GGen_String name; 00036 GGen_String label; 00037 GGen_String description; 00038 GGen_Arg_Type type; 00039 int min_value; 00040 int max_value; 00041 int default_value; 00042 int step_size; 00043 vector<GGen_String> options;; 00044 00045 bool SetValue(int new_value); 00046 00047 }; 00048 00059 void GGen_AddIntArg(const GGen_String& name, const GGen_String& label, const GGen_String& description, int default_value, int min_value, int max_value, int step_size); 00060 00068 void GGen_AddBoolArg(const GGen_String& name, const GGen_String& label, const GGen_String& description, bool default_value); 00069 00078 void GGen_AddEnumArg(const GGen_String& name, const GGen_String& label, const GGen_String& description, int default_value, const GGen_String& options); 00079 00085 int GGen_GetArgValue(const GGen_String& name);