summaryrefslogtreecommitdiff
path: root/src/gui/guiFormSpecMenu.h
diff options
context:
space:
mode:
authorrubenwardy <rw@rubenwardy.com>2019-03-15 19:03:12 +0000
committerrubenwardy <rw@rubenwardy.com>2019-08-03 19:36:30 +0100
commitec3795a55c24685ec732fada3d1f5ba75ecd1cd5 (patch)
treec0b9dbcb480f2486c6030b7e989990a69b03d9af /src/gui/guiFormSpecMenu.h
parentd1a1c5cbf055e7eacbc4aeaa53174749d4c64d87 (diff)
downloadminetest-ec3795a55c24685ec732fada3d1f5ba75ecd1cd5.tar.gz
minetest-ec3795a55c24685ec732fada3d1f5ba75ecd1cd5.tar.bz2
minetest-ec3795a55c24685ec732fada3d1f5ba75ecd1cd5.zip
Add style[] tag with button support
Diffstat (limited to 'src/gui/guiFormSpecMenu.h')
-rw-r--r--src/gui/guiFormSpecMenu.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/gui/guiFormSpecMenu.h b/src/gui/guiFormSpecMenu.h
index 9c1ecb635..b310f8a77 100644
--- a/src/gui/guiFormSpecMenu.h
+++ b/src/gui/guiFormSpecMenu.h
@@ -30,6 +30,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include "client/joystick_controller.h"
#include "util/string.h"
#include "util/enriched_string.h"
+#include "StyleSpec.h"
class InventoryManager;
class ISimpleTextureSource;
@@ -401,6 +402,11 @@ protected:
const std::vector<std::string> &v_pos);
v2s32 getRealCoordinateGeometry(const std::vector<std::string> &v_geom);
+ std::unordered_map<std::string, StyleSpec> theme_by_type;
+ std::unordered_map<std::string, StyleSpec> theme_by_name;
+
+ StyleSpec getThemeForElement(const std::string &type, const std::string &name);
+
v2s32 padding;
v2f32 spacing;
v2s32 imgsize;
@@ -537,6 +543,7 @@ private:
void parsePosition(parserData *data, const std::string &element);
bool parseAnchorDirect(parserData *data, const std::string &element);
void parseAnchor(parserData *data, const std::string &element);
+ bool parseStyle(parserData *data, const std::string &element, bool style_type);
void tryClose();